Dirichlet condition applied in the facet normal direction.
|
| subroutine | facet_normal_init (this, coef, json) |
| | Constructor.
|
| |
| subroutine | facet_normal_init_from_components (this, coef) |
| | Constructor from components.
|
| |
| subroutine | facet_normal_apply_scalar (this, x, n, time, strong) |
| | No-op scalar apply.
|
| |
| subroutine | facet_normal_apply_scalar_dev (this, x_d, time, strong, strm) |
| | No-op scalar apply on device.
|
| |
| subroutine | facet_normal_apply_vector_dev (this, x_d, y_d, z_d, time, strong, strm) |
| | No-op vector apply on device.
|
| |
| subroutine | facet_normal_apply_vector (this, x, y, z, n, time, strong) |
| | No-op vector apply.
|
| |
| subroutine | facet_normal_apply_surfvec (this, x, y, z, u, v, w, n, time) |
| | Apply in facet normal direction (vector valued)
|
| |
| subroutine | facet_normal_apply_surfvec_sub (this, res, u, v, w, c, n) |
| | Subtract the normal projection of a vector from a scalar field, on the facet nodes only.
|
| |
| subroutine | facet_normal_apply_surfvec_dev (this, x_d, y_d, z_d, u_d, v_d, w_d, time, strm) |
| | Apply in facet normal direction (vector valued, device version)
|
| |
| subroutine | facet_normal_free (this) |
| | Destructor.
|
| |
| subroutine | facet_normal_finalize (this) |
| | Finalize.
|
| |
| subroutine | facet_normal_recompute_normals (this) |
| | Recompute area-weighted normals from the current mesh.
|
| |
| subroutine facet_normal::facet_normal_apply_surfvec_sub |
( |
class(facet_normal_t), intent(in) |
this, |
|
|
real(kind=rp), dimension(n), intent(inout) |
res, |
|
|
real(kind=rp), dimension(n), intent(in) |
u, |
|
|
real(kind=rp), dimension(n), intent(in) |
v, |
|
|
real(kind=rp), dimension(n), intent(in) |
w, |
|
|
real(kind=rp), intent(in) |
c, |
|
|
integer, intent(in) |
n |
|
) |
| |
|
private |
Computes res(k) = res(k) - c * (u,v,w)(k) . n(k) over the unique facet-node mask. This is the fused form of zeroing three full fields, calling apply_surfvec into them, and then reading all three back across the whole domain: the surface term is nonzero only on the mask, so the full-field traffic carries nothing. Safe to accumulate in place because unique_mask visits every dof exactly once, with the normals of all adjoining faces already summed into nx/ny/nz (see finalize).
- Note
- This carries orphaned worksharing rather than opening its own parallel region, so the caller can cover several of these and the loops around them with one region. The trailing barrier of the
!$omp do is required: consecutive calls read and write the same res entries wherever two facet masks meet. Encountered outside a parallel region it still gives the right answer, just on one thread.
- Parameters
-
| res | Scalar field to subtract from. |
| u | First component of the vector. |
| v | Second component of the vector. |
| w | Third component of the vector. |
| c | Scalar coefficient applied to the projection. |
| n | Number of entries in each array. |
Definition at line 197 of file facet_normal.f90.