Template Function pcms::CreateUniformGridBinaryField(Omega_h::Mesh&, const UniformGrid<Dim>&)
Defined in File uniform_grid_binary_field.h
Function Documentation
Create a binary (inside/outside) mask field on a uniform grid.
Each DOF in the returned order-1 (vertex-centered) field is set to 1.0 if the vertex lies inside the mesh and 0.0 otherwise. A single point search pass over the grid vertices is performed; no intermediate source field is required.
- Template Parameters:
Dim – Spatial dimension (2 or 3).
- Parameters:
mesh – The Omega_h mesh defining the domain.
grid – Uniform grid whose vertices are tested.
- Returns:
Pair of (layout, field) with binary mask values.