Report Typos and Errors    
Semi-Lagrangian Library
Modular library for kinetic and gyrokinetic simulations of plasmas in fusion energy devices.
sll_m_descriptors.F90
Go to the documentation of this file.
1 !This file was generated using the macro descriptors.m4
2 !Usage: m4 descriptors.m4 > sll_m_descriptors.F90
10 
12 !+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
13 #include "sll_working_precision.h"
14 
15  implicit none
16 
17  public :: &
22 
23  private
24 !+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
26  sll_int32 :: id
27  character(len=32), private :: pname
28  contains
29  procedure, pass(self) :: name => name_vlasovpoisson_sim
30  procedure, pass(self) :: parse => parse_vlasovpoisson_sim
32 
33  interface operator(.eq.)
34  module procedure sll_vlasovpoisson_sim_compare
35  end interface
36 
37  type(sll_t_vlasovpoisson_sim), parameter :: sll_p_landau_diag = sll_t_vlasovpoisson_sim(1, "sll_p_landau_diag")
38  type(sll_t_vlasovpoisson_sim), parameter :: sll_p_landau_sum = sll_t_vlasovpoisson_sim(2, "sll_p_landau_sum")
39  type(sll_t_vlasovpoisson_sim), parameter :: sll_p_landau_prod = sll_t_vlasovpoisson_sim(3, "sll_p_landau_prod")
40  type(sll_t_vlasovpoisson_sim), parameter :: sll_twostream = sll_t_vlasovpoisson_sim(4, "SLL_TWOSTREAM")
41  type(sll_t_vlasovpoisson_sim), parameter :: sll_bumpontail = sll_t_vlasovpoisson_sim(5, "SLL_BUMPONTAIL")
42 
44  sll_int32 :: id
45  character(len=32), private :: pname
46  contains
47  procedure, pass(self) :: name => name_boundary
48  procedure, pass(self) :: parse => parse_boundary
49  end type sll_boundary
50 
51  interface operator(.eq.)
52  module procedure sll_boundary_compare
53  end interface
54 
55  type(sll_boundary), parameter :: open = sll_boundary(1, "OPEN")
56  type(sll_boundary), parameter :: closed = sll_boundary(2, "CLOSED")
57 
58 contains
59 
60  !----------------------------------------------------------------------
61  !------------------- vlasovpoisson_sim -----------------------------------------
62  pure function name_vlasovpoisson_sim(self) result(r)
63  class(sll_t_vlasovpoisson_sim), intent(in) :: self
64  character(len=10) :: r
65  r = self%pname(1:10)
66  end function name_vlasovpoisson_sim
67 
68  pure function sll_vlasovpoisson_sim_compare(bc1, bc2) result(compare)
69  type(sll_t_vlasovpoisson_sim), intent(in) :: bc1, bc2
70  logical :: compare
71  compare = bc1%id .eq. bc2%id
73 
74  subroutine parse_vlasovpoisson_sim(self, str)
75  class(sll_t_vlasovpoisson_sim), intent(inout) :: self
76  character(len=*), intent(in) :: str
77  character(len=3) :: strc
78 
79  !Remove blanks left and right
80  strc = adjustl(trim(str))
81 
82  if (strc .eq. sll_p_landau_diag%name()) then
83  self%id = sll_p_landau_diag%id
84  self%pname = sll_p_landau_diag%pname
85  elseif (strc .eq. sll_p_landau_sum%name()) then
86  self%id = sll_p_landau_sum%id
87  self%pname = sll_p_landau_sum%pname
88  elseif (strc .eq. sll_p_landau_prod%name()) then
89  self%id = sll_p_landau_prod%id
90  self%pname = sll_p_landau_prod%pname
91  elseif (strc .eq. sll_twostream%name()) then
92  self%id = sll_twostream%id
93  self%pname = sll_twostream%pname
94  elseif (strc .eq. sll_bumpontail%name()) then
95  self%id = sll_bumpontail%id
96  self%pname = sll_bumpontail%pname
97  elseif (.true.) then
98  end if
99 
100  end subroutine parse_vlasovpoisson_sim
101  !----------------------------------------------------------------------
102 
103  !----------------------------------------------------------------------
104  !------------------- boundary -----------------------------------------
105  pure function name_boundary(self) result(r)
106  class(sll_boundary), intent(in) :: self
107  character(len=10) :: r
108  r = self%pname(1:10)
109  end function name_boundary
110 
111  pure function sll_boundary_compare(bc1, bc2) result(compare)
112  type(sll_boundary), intent(in) :: bc1, bc2
113  logical :: compare
114  compare = bc1%id .eq. bc2%id
115  end function sll_boundary_compare
116 
117  subroutine parse_boundary(self, str)
118  class(sll_boundary), intent(inout) :: self
119  character(len=*), intent(in) :: str
120  character(len=3) :: strc
121 
122  !Remove blanks left and right
123  strc = adjustl(trim(str))
124 
125  if (strc .eq. open%name()) then
126  self%id = open%id
127  self%pname = open%pname
128  elseif (strc .eq. closed%name()) then
129  self%id = closed%id
130  self%pname = closed%pname
131  elseif (.true.) then
132  end if
133 
134  end subroutine parse_boundary
135  !----------------------------------------------------------------------
136 
137 end module sll_m_descriptors
Describes different global flags throughout the library.
pure character(len=10) function name_boundary(self)
pure character(len=10) function name_vlasovpoisson_sim(self)
type(sll_boundary), parameter closed
subroutine parse_boundary(self, str)
pure logical function sll_vlasovpoisson_sim_compare(bc1, bc2)
type(sll_t_vlasovpoisson_sim), parameter, public sll_p_landau_prod
type(sll_t_vlasovpoisson_sim), parameter sll_twostream
type(sll_t_vlasovpoisson_sim), parameter sll_bumpontail
subroutine parse_vlasovpoisson_sim(self, str)
type(sll_t_vlasovpoisson_sim), parameter, public sll_p_landau_sum
type(sll_boundary), parameter open
type(sll_t_vlasovpoisson_sim), parameter, public sll_p_landau_diag
pure logical function sll_boundary_compare(bc1, bc2)
    Report Typos and Errors