40 use device,
only: c_ptr, c_size_t
102 type(
field_list_t),
intent(inout) :: dirichlet_field_list
103 type(
bc_list_t),
intent(inout) :: dirichlet_bc_list
104 type(
coef_t),
intent(inout) :: coef
105 real(kind=
rp),
intent(in) :: t
106 integer,
intent(in) :: tstep
107 character(len=*),
intent(in) :: which_solver
119 character(len=*),
intent(in) :: bc_name
121 call this%field_bc%init(this%dof, bc_name)
122 call this%field_list%init(1)
123 call this%field_list%assign_to_field(1, this%field_bc)
132 call this%field_bc%free()
133 call this%field_list%free()
135 if (
associated(this%update))
then
136 this%update => null()
148 integer,
intent(in) :: n
149 real(kind=
rp),
intent(inout),
dimension(n) :: x
150 real(kind=
rp),
intent(in),
optional :: t
151 integer,
intent(in),
optional :: tstep
153 if (this%msk(0) .gt. 0)
then
154 call masked_copy(x, this%field_bc%x, this%msk, n, this%msk(0))
166 real(kind=
rp),
intent(in),
optional :: t
167 integer,
intent(in),
optional :: tstep
169 if (this%msk(0) .gt. 0)
then
171 this%field_bc%dof%size(), this%msk(0))
185 integer,
intent(in) :: n
186 real(kind=
rp),
intent(inout),
dimension(n) :: x
187 real(kind=
rp),
intent(inout),
dimension(n) :: y
188 real(kind=
rp),
intent(inout),
dimension(n) :: z
189 real(kind=
rp),
intent(in),
optional :: t
190 integer,
intent(in),
optional :: tstep
192 call neko_error(
"field_dirichlet cannot apply vector BCs.&
193&Use field_dirichlet_vector instead!")
208 real(kind=
rp),
intent(in),
optional :: t
209 integer,
intent(in),
optional :: tstep
211 call neko_error(
"field_dirichlet cannot apply vector BCs.&
212&Use field_dirichlet_vector instead!")
Abstract interface defining a dirichlet condition on a list of fields.
Defines a boundary condition.
subroutine, public device_masked_copy(a_d, b_d, mask_d, n, m)
Copy a masked vector .
Device abstraction, common interface for various accelerators.
Defines a dirichlet boundary condition.
Defines a mapping of the degrees of freedom.
Defines inflow dirichlet conditions.
subroutine field_dirichlet_apply_vector(this, x, y, z, n, t, tstep)
(No-op) Apply vector.
subroutine field_dirichlet_apply_scalar_dev(this, x_d, t, tstep)
Apply scalar (device).
subroutine field_dirichlet_apply_vector_dev(this, x_d, y_d, z_d, t, tstep)
(No-op) Apply vector (device).
subroutine field_dirichlet_apply_scalar(this, x, n, t, tstep)
Apply scalar by performing a masked copy.
subroutine field_dirichlet_init(this, bc_name)
Initializes thisfield_bc.
subroutine field_dirichlet_free(this)
Destructor. Currently thisfield_bc is being freed in fluid_scheme::free
subroutine, public masked_copy(a, b, mask, n, m)
Copy a masked vector .
integer, parameter, public rp
Global precision used in computations.
character(len=100) function, dimension(:), allocatable, public split_string(string, delimiter)
Split a string based on delimiter (tokenizer) OBS: very hacky, this should really be improved,...
Base type for a boundary condition.
A list of allocatable `bc_t`. Follows the standard interface of lists.
Coefficients defined on a given (mesh, ) tuple. Arrays use indices (i,j,k,e): element e,...
Generic Dirichlet boundary condition on .
User defined dirichlet condition, for which the user can work with an entire field....
field_list_t, To be able to group fields together