t8  UNKNOWN
t8code is a C library to manage a forest of adaptive space-trees of general element classes in parallel.
t8_geometry_analytic.h
Go to the documentation of this file.
1 /*
2  This file is part of t8code.
3  t8code is a C library to manage a collection (a forest) of multiple
4  connected adaptive space-trees of general element classes in parallel.
5 
6  Copyright (C) 2024 the developers
7 
8  t8code is free software; you can redistribute it and/or modify
9  it under the terms of the GNU General Public License as published by
10  the Free Software Foundation; either version 2 of the License, or
11  (at your option) any later version.
12 
13  t8code is distributed in the hope that it will be useful,
14  but WITHOUT ANY WARRANTY; without even the implied warranty of
15  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16  GNU General Public License for more details.
17 
18  You should have received a copy of the GNU General Public License
19  along with t8code; if not, write to the Free Software Foundation, Inc.,
20  51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
21 */
22 
27 #ifndef T8_GEOMETRY_ANALYTIC_H
28 #define T8_GEOMETRY_ANALYTIC_H
29 
42 typedef void (*t8_geom_analytic_fn) (t8_cmesh_t cmesh, t8_gloidx_t gtreeid, const double *ref_coords,
43  const size_t num_coords, double *out_coords, const void *tree_data,
44  const void *user_data);
45 
57 typedef void (*t8_geom_analytic_jacobian_fn) (t8_cmesh_t cmesh, t8_gloidx_t gtreeid, const double *ref_coords,
58  const size_t num_coords, double *jacobian, const void *tree_data,
59  const void *user_data);
60 
67 typedef void (*t8_geom_load_tree_data_fn) (t8_cmesh_t cmesh, t8_gloidx_t gtreeid, const void **tree_data);
68 
73 
74 T8_EXTERN_C_BEGIN ();
75 
79 void
81 
86 t8_geometry_analytic_new (int dim, const char *name, t8_geom_analytic_fn analytical,
88  t8_geom_tree_negative_volume_fn tree_negative_volume, const void *user_data);
89 
96 void
97 t8_geom_load_tree_data_vertices (t8_cmesh_t cmesh, t8_gloidx_t gtreeid, const void **user_data);
98 
99 T8_EXTERN_C_END ();
100 
101 #endif /* T8_GEOMETRY_ANALYTIC_H */
This structure holds the connectivity data of the coarse mesh.
Definition: t8_cmesh_types.h:88
The base class for all geometries.
Definition: t8_geometry_base.hxx:48
int64_t t8_gloidx_t
A type for global indexing that holds really big numbers.
Definition: t8.h:100
void t8_geometry_analytic_destroy(t8_geometry_c **geom)
Destroy a geometry analytic object.
Definition: t8_geometry_analytic.cxx:93
t8_geometry_c * t8_geometry_analytic_new(int dim, const char *name, t8_geom_analytic_fn analytical, t8_geom_analytic_jacobian_fn jacobian, t8_geom_load_tree_data_fn load_tree_data, t8_geom_tree_negative_volume_fn tree_negative_volume, const void *user_data)
Create a new analytical geometry.
Definition: t8_geometry_analytic.cxx:102
void(* t8_geom_analytic_jacobian_fn)(t8_cmesh_t cmesh, t8_gloidx_t gtreeid, const double *ref_coords, const size_t num_coords, double *jacobian, const void *tree_data, const void *user_data)
Definition for the jacobian of an analytic geometry function.
Definition: t8_geometry_analytic.h:57
void t8_geom_load_tree_data_vertices(t8_cmesh_t cmesh, t8_gloidx_t gtreeid, const void **user_data)
Load vertex data from given tree.
Definition: t8_geometry_analytic.cxx:112
void(* t8_geom_load_tree_data_fn)(t8_cmesh_t cmesh, t8_gloidx_t gtreeid, const void **tree_data)
Definition for the load tree data function.
Definition: t8_geometry_analytic.h:67
int(* t8_geom_tree_negative_volume_fn)()
Definition for the negative volume function.
Definition: t8_geometry_analytic.h:72
void(* t8_geom_analytic_fn)(t8_cmesh_t cmesh, t8_gloidx_t gtreeid, const double *ref_coords, const size_t num_coords, double *out_coords, const void *tree_data, const void *user_data)
Definition of an analytic geometry function.
Definition: t8_geometry_analytic.h:42