Defines a Dirichlet condition prescribed by a mathematical expression.
|
| type | expression_dirichlet_t |
| | Dirichlet condition \( x = g(x, y, z, t) \) on \(\partial \Omega\), where \( g \) is a mathematical expression given in the case file. More...
|
| |
|
| subroutine | expression_dirichlet_init (this, coef, json) |
| | Constructor from JSON.
|
| |
| subroutine | expression_dirichlet_init_from_components (this, coef, str) |
| | Constructor from components.
|
| |
| subroutine | expression_dirichlet_free (this) |
| | Destructor.
|
| |
| subroutine | expression_dirichlet_finalize (this, only_facets) |
| | Finalize.
|
| |
| subroutine | expression_dirichlet_update (this, time, strm) |
| | Bring g up to date with the current time.
|
| |
| subroutine | expression_dirichlet_apply_scalar (this, x, n, time, strong) |
| | Apply the condition to a scalar field.
|
| |
| subroutine | expression_dirichlet_apply_vector (this, x, y, z, n, time, strong) |
| | (No-op) Apply vector.
|
| |
| subroutine | expression_dirichlet_apply_scalar_dev (this, x_d, time, strong, strm) |
| | Apply the condition to a scalar field (device version).
|
| |
| subroutine | expression_dirichlet_apply_vector_dev (this, x_d, y_d, z_d, time, strong, strm) |
| | (No-op) Apply vector (device version).
|
| |
| subroutine, public | expression_mask_coords (bc, xm, ym, zm) |
| | Tabulate the coordinates of the points of the mask of a boundary condition.
|
| |
| subroutine | gather_coords (msk, m, x, y, z, n, xm, ym, zm) |
| | Gather the coordinates of the masked points into contiguous arrays.
|
| |
◆ expression_dirichlet_apply_scalar()
| subroutine expression_dirichlet::expression_dirichlet_apply_scalar |
( |
class(expression_dirichlet_t), intent(inout) |
this, |
|
|
real(kind=rp), dimension(n), intent(inout) |
x, |
|
|
integer, intent(in) |
n, |
|
|
type(time_state_t), intent(in), optional |
time, |
|
|
logical, intent(in), optional |
strong |
|
) |
| |
|
private |
- Parameters
-
| [in,out] | x | The field onto which to apply the values. |
| [in] | n | The size of x. |
| [in] | time | The current time state. |
| [in] | strong | Whether the condition is applied strongly. |
Definition at line 238 of file expression_dirichlet.f90.
◆ expression_dirichlet_apply_scalar_dev()
| subroutine expression_dirichlet::expression_dirichlet_apply_scalar_dev |
( |
class(expression_dirichlet_t), intent(inout), target |
this, |
|
|
type(c_ptr), intent(inout) |
x_d, |
|
|
type(time_state_t), intent(in), optional |
time, |
|
|
logical, intent(in), optional |
strong, |
|
|
type(c_ptr), intent(inout) |
strm |
|
) |
| |
|
private |
- Parameters
-
| [in,out] | x_d | Device pointer to the field. |
| [in] | time | The current time state. |
| [in] | strong | Whether the condition is applied strongly. |
| [in,out] | strm | The device stream to issue the work on. |
Definition at line 294 of file expression_dirichlet.f90.
◆ expression_dirichlet_apply_vector()
| subroutine expression_dirichlet::expression_dirichlet_apply_vector |
( |
class(expression_dirichlet_t), intent(inout) |
this, |
|
|
real(kind=rp), dimension(n), intent(inout) |
x, |
|
|
real(kind=rp), dimension(n), intent(inout) |
y, |
|
|
real(kind=rp), dimension(n), intent(inout) |
z, |
|
|
integer, intent(in) |
n, |
|
|
type(time_state_t), intent(in), optional |
time, |
|
|
logical, intent(in), optional |
strong |
|
) |
| |
|
private |
- Parameters
-
| [in,out] | x | The x-component of the field. |
| [in,out] | y | The y-component of the field. |
| [in,out] | z | The z-component of the field. |
| [in] | n | The size of x, y and z. |
| [in] | time | The current time state. |
| [in] | strong | Whether the condition is applied strongly. |
Definition at line 279 of file expression_dirichlet.f90.
◆ expression_dirichlet_apply_vector_dev()
| subroutine expression_dirichlet::expression_dirichlet_apply_vector_dev |
( |
class(expression_dirichlet_t), intent(inout), target |
this, |
|
|
type(c_ptr), intent(inout) |
x_d, |
|
|
type(c_ptr), intent(inout) |
y_d, |
|
|
type(c_ptr), intent(inout) |
z_d, |
|
|
type(time_state_t), intent(in), optional |
time, |
|
|
logical, intent(in), optional |
strong, |
|
|
type(c_ptr), intent(inout) |
strm |
|
) |
| |
|
private |
- Parameters
-
| [in,out] | x_d | Device pointer to the x-component of the field. |
| [in,out] | y_d | Device pointer to the y-component of the field. |
| [in,out] | z_d | Device pointer to the z-component of the field. |
| [in] | time | The current time state. |
| [in] | strong | Whether the condition is applied strongly. |
| [in,out] | strm | The device stream to issue the work on. |
Definition at line 326 of file expression_dirichlet.f90.
◆ expression_dirichlet_finalize()
Tabulates the coordinates of the points of the mask, which is only known once the mask has been built, and evaluates the expression right away if it does not depend on time.
- Parameters
-
| [in] | only_facets | Whether to only mark the facets of the mask. |
Definition at line 160 of file expression_dirichlet.f90.
◆ expression_dirichlet_free()
◆ expression_dirichlet_init()
- Parameters
-
| [in] | coef | The SEM coefficients. |
| [in,out] | json | The JSON object configuring the boundary condition. |
Definition at line 103 of file expression_dirichlet.f90.
◆ expression_dirichlet_init_from_components()
- Parameters
-
| [in] | coef | The SEM coefficients. |
| [in] | str | The expression prescribing the boundary value. |
Definition at line 118 of file expression_dirichlet.f90.
◆ expression_dirichlet_update()
A no-op unless the expression depends on time and the values have not already been updated in this timestep.
- Parameters
-
| [in] | time | The current time state. |
| [in,out] | strm | The device stream to issue the copy on. |
Definition at line 202 of file expression_dirichlet.f90.
◆ expression_mask_coords()
| subroutine, public expression_dirichlet::expression_mask_coords |
( |
class(bc_t), intent(in) |
bc, |
|
|
real(kind=rp), dimension(:), intent(inout) |
xm, |
|
|
real(kind=rp), dimension(:), intent(inout) |
ym, |
|
|
real(kind=rp), dimension(:), intent(inout) |
zm |
|
) |
| |
- Parameters
-
| [in] | bc | The boundary condition, which must have been finalized. |
| [in,out] | xm | The x-coordinates of the points of the mask. |
| [in,out] | ym | The y-coordinates of the points of the mask. |
| [in,out] | zm | The z-coordinates of the points of the mask. |
Definition at line 343 of file expression_dirichlet.f90.
◆ gather_coords()
| subroutine expression_dirichlet::gather_coords |
( |
integer, dimension(0:m), intent(in) |
msk, |
|
|
integer, intent(in) |
m, |
|
|
real(kind=rp), dimension(n), intent(in) |
x, |
|
|
real(kind=rp), dimension(n), intent(in) |
y, |
|
|
real(kind=rp), dimension(n), intent(in) |
z, |
|
|
integer, intent(in) |
n, |
|
|
real(kind=rp), dimension(m), intent(inout) |
xm, |
|
|
real(kind=rp), dimension(m), intent(inout) |
ym, |
|
|
real(kind=rp), dimension(m), intent(inout) |
zm |
|
) |
| |
|
private |
Split out from expression_mask_coords so that the rank 4 coordinate arrays of the dofmap are linearised by the call.
- Parameters
-
| [in] | msk | The mask, where msk(0) is its length. |
| [in] | m | The number of masked points. |
| [in] | x | The x-coordinates of every point of the dofmap. |
| [in] | y | The y-coordinates of every point of the dofmap. |
| [in] | z | The z-coordinates of every point of the dofmap. |
| [in] | n | The number of points of the dofmap. |
| [in,out] | xm | The x-coordinates of the masked points. |
| [in,out] | ym | The y-coordinates of the masked points. |
| [in,out] | zm | The z-coordinates of the masked points. |
Definition at line 366 of file expression_dirichlet.f90.