Struct t8_geometry_zero
Defined in File t8_geometry_zero.hxx
Inheritance Relationships
Base Type
public t8_geometry(Struct t8_geometry)
Struct Documentation
-
struct t8_geometry_zero : public t8_geometry
Zero geometry which maps every point to zero.
Only meant for debugging purposes.
Public Functions
-
t8_geometry_zero()
Constructor of the zero geometry.
The geometry is viable with all tree types. This geometry maps all points to zero and is meant for debugging purposes. Sets the dimension and the name to “t8_geom_zero”
-
inline virtual bool t8_geom_tree_negative_volume() const override
Check if the currently active tree has a negative volume.
- Returns:
True (non-zero) if the currently loaded tree has a negative volume. 0 otherwise.
-
virtual ~t8_geometry_zero()
The destructor.
Clears the allocated memory.
-
inline virtual t8_geometry_type_t t8_geom_get_type() const override
Get the type of this geometry.
- Returns:
The type.
-
virtual void t8_geom_evaluate(t8_cmesh_t cmesh, t8_gloidx_t gtreeid, const double *ref_coords, const size_t num_coords, double *out_coords) const override
Maps points in the reference space \( [0,1]^\mathrm{dim} \to \mathbb{R}^3 \).
Note
All entries in out_coords will be set to 0.
- Parameters:
cmesh – [in] The cmesh in which the point lies.
gtreeid – [in] The global tree (of the cmesh) in which the reference point is.
ref_coords – [in] Array of tree dimension x num_coords many entries, specifying points in \( [0,1]^\mathrm{dim} \).
num_coords – [in] Amount of points of \( \mathrm{dim} \) to map.
out_coords – [out] The mapped coordinates in physical space of ref_coords. The length is num_coords * 3.
-
virtual void t8_geom_evaluate_jacobian(t8_cmesh_t cmesh, t8_gloidx_t gtreeid, const double *ref_coords, const size_t num_coords, double *jacobian) const override
Compute the jacobian of the t8_geom_evaluate map at a point in the reference space \( [0,1]^\mathrm{dim} \).
Note
All entries in jacobian will be set to zero.
- Parameters:
cmesh – [in] The cmesh in which the point lies.
gtreeid – [in] The global tree (of the cmesh) in which the reference point is.
ref_coords – [in] Array of tree dimension x num_coords many entries, specifying points in \( [0,1]^\mathrm{dim} \).
num_coords – [in] Amount of points of \( \mathrm{dim} \) to map.
jacobian – [out] The jacobian at ref_coords. Array of size num_coords x dimension x 3. Indices \( 3 \cdot i\) , \( 3 \cdot i+1 \) , \( 3 \cdot i+2 \) correspond to the \( i \)-th column of the jacobian (Entry \( 3 \cdot i + j \) is \( \frac{\partial f_j}{\partial x_i} \)).
-
inline void t8_geom_point_batch_inside_element([[maybe_unused]] t8_forest_t forest, [[maybe_unused]] t8_locidx_t ltreeid, [[maybe_unused]] const t8_element_t *element, const double *points, const int num_points, int *is_inside, const double tolerance) const override
- Parameters:
forest – [in] The forest of the element.
ltreeid – [in] The local tree id of the element’s tree
element – [in] The element
points – [in] points to check
num_points – [in] Number of points to check
is_inside – [inout] Array to fill with flags whether the point is inside or not
tolerance – [in] Tolerance of the inside-check
-
inline virtual void t8_geom_load_tree_data(t8_cmesh_t cmesh, t8_gloidx_t gtreeid) override
Update a possible internal data buffer for per tree data.
This function is called before the first coordinates in a new tree are evaluated. In this implementation, we do nothing, since we do not need any tree data.
- Parameters:
cmesh – [in] The cmesh.
gtreeid – [in] The global tree.
-
inline virtual bool t8_geom_check_tree_compatibility() const override
Check for compatibility of the currently loaded tree with the geometry.
This geometry supports all element types, hence it returns true.
- Returns:
True if the geometry is compatible with the tree.
-
t8_geometry_zero()