t8  1.2.0
t8code is a C library to manage a forest of adaptive space-trees of general element classes in parallel.
Public Member Functions
t8_geometry_analytic Struct Reference
Inheritance diagram for t8_geometry_analytic:
t8_geometry

Public Member Functions

 t8_geometry_analytic (int dimension, const char *name, t8_geom_analytic_fn analytical, t8_geom_analytic_jacobian_fn jacobian, t8_geom_load_tree_data_fn load_tree_data, const void *user_data)
 Constructor with analytical and jacobian functions. More...
 
virtual ~ t8_geometry_analytic ()
 The destructor. More...
 
virtual void t8_geom_evaluate (t8_cmesh_t cmesh, t8_gloidx_t gtreeid, const double *ref_coords, double out_coords[3]) const
 Map a point in the reference space $$[0,1]^dimension$$ to $$\mathbb R^3$$. More...
 
virtual void t8_geom_evalute_jacobian (t8_cmesh_t cmesh, t8_gloidx_t gtreeid, const double *ref_coords, double *jacobian) const
 Compute the jacobian of the t8_geom_evaluate map at a point in the reference space $$[0,1]^dimension$$. More...
 
virtual void t8_geom_load_tree_data (t8_cmesh_t cmesh, t8_gloidx_t gtreeid)
 Update a possible internal data buffer for per tree data. More...
 
const void * t8_geom_analytic_get_user_data ()
 
- Public Member Functions inherited from t8_geometry
 t8_geometry (int dimension, const char *name, const char *attribute_name=NULL)
 
virtual ~ t8_geometry ()
 The destructor. More...
 
int t8_geom_get_dimension () const
 Get the dimension of this geometry. More...
 
const char * t8_geom_get_name () const
 Get the name of this geometry. More...
 

Additional Inherited Members

- Protected Attributes inherited from t8_geometry
int dimension
 The dimension of reference space for which this is a geometry.
 
const char * name
 The name of this geometry.
 

Constructor & Destructor Documentation

◆ t8_geometry_analytic()

t8_geometry_analytic::t8_geometry_analytic ( int  dimension,
const char *  name,
t8_geom_analytic_fn  analytical,
t8_geom_analytic_jacobian_fn  jacobian,
t8_geom_load_tree_data_fn  load_tree_data,
const void *  user_data 
)

Constructor with analytical and jacobian functions.

Parameters
[in]dimensionThe dimension of this geometry.
[in]nameThe name to give this geometry.
[in]analyticalThe analytical function to use for this geometry.
[in]jacobianThe jacobian of analytical.
[in]load_tree_dataThe function that is used to load a tree's data.

◆ ~ t8_geometry_analytic()

virtual t8_geometry_analytic::~ t8_geometry_analytic ( )
inlinevirtual

The destructor.

Clears the allocated memory.

Member Function Documentation

◆ t8_geom_evaluate()

void t8_geometry_analytic::t8_geom_evaluate ( t8_cmesh_t  cmesh,
t8_gloidx_t  gtreeid,
const double *  ref_coords,
double  out_coords[3] 
) const
virtual

Map a point in the reference space $$[0,1]^dimension$$ to $$\mathbb R^3$$.

Parameters
[in]cmeshThe cmesh in which the point lies.
[in]gtreeidThe global tree (of the cmesh) in which the reference point is.
[in]ref_coordsArray of dimension many entries, specifying a point in [0,1]^dimension.
[out]out_coordsThe mapped coordinates in physical space of ref_coords.
Note
Since this is the identity geometry, out_coords will be equal to ref_coords.
Parameters
[in]gtreeidThe global tree (of the cmesh) in which the reference point is.
[in]ref_coordsArray of dimension many entries, specifying a point in [0,1]^dimension.
[out]out_coordsThe mapped coordinates in physical space of ref_coords.

Implements t8_geometry.

◆ t8_geom_evalute_jacobian()

void t8_geometry_analytic::t8_geom_evalute_jacobian ( t8_cmesh_t  cmesh,
t8_gloidx_t  gtreeid,
const double *  ref_coords,
double *  jacobian_out 
) const
virtual

Compute the jacobian of the t8_geom_evaluate map at a point in the reference space $$[0,1]^dimension$$.

Parameters
[in]cmeshThe cmesh in which the point lies.
[in]gtreeidThe global tree (of the cmesh) in which the reference point is.
[in]ref_coordsArray of dimension many entries, specifying a point in [0,1]^dimension.
[out]jacobianThe jacobian at ref_coords. Array of size dimension x 3. Indices 3*i, 3*i+1, 3*i+2 correspond to the i-th column of the jacobian (Entry 3*i + j is del f_j/del x_i).
Note
The jacobian will be (1) (1 0) (1 0 0) dim 1: J = (0) dim 2: J = (0 1) dim 3: J = (0 1 0) (0) (0 0) (0 0 1)
Parameters
[in]gtreeidThe global tree (of the cmesh) in which the reference point is.
[in]ref_coordsArray of dimension many entries, specifying a point in [0,1]^dimension.
[out]jacobianThe jacobian at ref_coords. Array of size dimension x 3. Indices 3*i, 3*i+1, 3*i+2 correspond to the i-th column of the jacobian (Entry 3*i + j is del f_j/del x_i).

Implements t8_geometry.

◆ t8_geom_load_tree_data()

void t8_geometry_analytic::t8_geom_load_tree_data ( t8_cmesh_t  cmesh,
t8_gloidx_t  gtreeid 
)
virtual

Update a possible internal data buffer for per tree data.

This function is called before the first coordinates in a new tree are evaluated. You can use it for example to load the vertex coordinates of the tree into an internal buffer (as is done in the linear geometry).

Parameters
[in]cmeshThe cmesh.
[in]gtreeidThe global tree.

Implements t8_geometry.


The documentation for this struct was generated from the following files: