Go to the source code of this file.
Data Structures | |
| struct | cs_adjacency_t |
| struct | cs_mesh_adjacencies_t |
Macros | |
| #define | CS_ADJACENCY_SHARED (1 << 0) |
| #define | CS_ADJACENCY_STRIDE (1 << 1) |
| #define | CS_ADJACENCY_SIGNED (1 << 2) |
Functions | |
| cs_mesh_adjacencies_t * | cs_mesh_adjacencies_get_global (void) |
| Get non-const pointer to cs_glob_mesh_adacencies. | |
| void | cs_mesh_adjacencies_initialize (void) |
| Initialize mesh adjacencies helper API. | |
| void | cs_mesh_adjacencies_finalize (void) |
| Finalize mesh adjacencies helper API. | |
| void | cs_mesh_adjacencies_update_mesh (void) |
| Update mesh adjacencies helper API relative to mesh. | |
| void | cs_mesh_adjacencies_update_cell_cells_e (void) |
| Update extended cell -> cell connectivites in mesh adjacencies helper API relative to mesh. | |
| void | cs_mesh_adjacencies_update_cell_i_faces (void) |
| Ensure presence of cell -> interior face connectivites in mesh adjacencies helper API relative to mesh. | |
| void | cs_mesh_adjacencies_update_device (cs_alloc_mode_t alloc_mode) |
| Map some global mesh adjacency arrays for use on device. | |
| const cs_adjacency_t * | cs_mesh_adjacencies_cell_faces (void) |
| Return cell -> face connectivites in mesh adjacencies helper API relative to mesh. | |
| const cs_adjacency_t * | cs_mesh_adjacencies_cell_vertices (void) |
| Return cell -> vertex connectivites in mesh adjacencies helper API relative to mesh. | |
| cs_adjacency_t * | cs_adjacency_create (cs_flag_t flag, int stride, cs_lnum_t n_elts) |
| Create a cs_adjacency_t structure of size n_elts. | |
| cs_adjacency_t * | cs_adjacency_create_from_s_arrays (cs_lnum_t n_elts, int stride, cs_lnum_t *ids, short int *sgn) |
| Create a cs_adjacency_t structure sharing arrays scanned with a stride. | |
| cs_adjacency_t * | cs_adjacency_create_from_i_arrays (cs_lnum_t n_elts, cs_lnum_t *idx, cs_lnum_t *ids, short int *sgn) |
| Create a cs_adjacency_t structure sharing arrays scanned with an index. | |
| void | cs_adjacency_destroy (cs_adjacency_t **p_adj) |
| Destroy a cs_adjacency_t structure. | |
| cs_adjacency_t * | cs_adjacency_compose (int n_c_elts, const cs_adjacency_t *a2b, const cs_adjacency_t *b2c) |
| Create a new cs_adjacency_t structure from the composition of two cs_adjacency_t structures: (1) A -> B and (2) B -> C The resulting structure describes A -> C. It does not rely on a stride and has no sgn member. | |
| cs_adjacency_t * | cs_adjacency_transpose (int n_b_elts, const cs_adjacency_t *a2b) |
| Create a new cs_adjacency_t structure from a one corresponding to A -> B. The resulting structure deals with B -> A. | |
| void | cs_adjacency_sort (cs_adjacency_t *adj) |
| Sort each sub-list related to an entry in a cs_adjacency_t structure. | |
| void | cs_adjacency_remove_self_entries (cs_adjacency_t *adj) |
| In an indexed list, remove id(s) corresponding to the current index. Useful for instance in order to prepare a matrix structure in MSR storage. | |
| void | cs_adjacency_dump (const char *name, FILE *_f, cs_adjacency_t *adj) |
| Dump a cs_adjacency_t structure to a file or into the standard output. | |
| cs_adjacency_t * | cs_mesh_adjacency_c2f (const cs_mesh_t *m, int boundary_order) |
| Build a cells to faces adjacency structure. | |
| cs_adjacency_t * | cs_mesh_adjacency_c2f_lower (const cs_mesh_t *m, int boundary_order) |
| Build a partial cells to faces adjacency structure. | |
| cs_adjacency_t * | cs_mesh_adjacency_c2f_boundary (const cs_mesh_t *m) |
| Build a cells to boundary faces adjacency structure. | |
| cs_adjacency_t * | cs_mesh_adjacency_v2v (const cs_mesh_t *m) |
Variables | |
| const cs_mesh_adjacencies_t * | cs_glob_mesh_adjacencies |
| cs_adjacency_t * cs_adjacency_compose | ( | int | n_c_elts, |
| const cs_adjacency_t * | a2b, | ||
| const cs_adjacency_t * | b2c ) |
Create a new cs_adjacency_t structure from the composition of two cs_adjacency_t structures: (1) A -> B and (2) B -> C The resulting structure describes A -> C. It does not rely on a stride and has no sgn member.
| [in] | n_c_elts | number of elements in C set |
| [in] | a2b | adjacency A -> B |
| [in] | b2c | adjacency B -> C |
| cs_adjacency_t * cs_adjacency_create | ( | cs_flag_t | flag, |
| int | stride, | ||
| cs_lnum_t | n_elts ) |
Create a cs_adjacency_t structure of size n_elts.
| [in] | flag | metadata related to the new cs_adjacency to create |
| [in] | stride | > 0 if useful otherwise ignored |
| [in] | n_elts | number of entries of the indexed list |
| cs_adjacency_t * cs_adjacency_create_from_i_arrays | ( | cs_lnum_t | n_elts, |
| cs_lnum_t * | idx, | ||
| cs_lnum_t * | ids, | ||
| short int * | sgn ) |
Create a cs_adjacency_t structure sharing arrays scanned with an index.
| [in] | n_elts | number of elements |
| [in] | idx | array of size n_elts + 1 |
| [in] | ids | array of element ids (size = idx[n_elts]) |
| [in] | sgn | array storing the orientation (may be NULL) |
| cs_adjacency_t * cs_adjacency_create_from_s_arrays | ( | cs_lnum_t | n_elts, |
| int | stride, | ||
| cs_lnum_t * | ids, | ||
| short int * | sgn ) |
Create a cs_adjacency_t structure sharing arrays scanned with a stride.
| [in] | n_elts | number of elements |
| [in] | stride | value of the stride |
| [in] | ids | array of element ids (size = stride * n_elts) |
| [in] | sgn | array storing the orientation (may be NULL) |
| void cs_adjacency_destroy | ( | cs_adjacency_t ** | p_adj | ) |
Destroy a cs_adjacency_t structure.
| [in,out] | p_adj | pointer of pointer to a cs_adjacency_t structure |
| void cs_adjacency_dump | ( | const char * | name, |
| FILE * | _f, | ||
| cs_adjacency_t * | adj ) |
Dump a cs_adjacency_t structure to a file or into the standard output.
| [in] | name | name of the dump file. Can be set to NULL |
| [in] | _f | pointer to a FILE structure. Can be set to NULL. |
| [in] | adj | pointer to a cs_adjacency_t structure |
| void cs_adjacency_remove_self_entries | ( | cs_adjacency_t * | adj | ) |
In an indexed list, remove id(s) corresponding to the current index. Useful for instance in order to prepare a matrix structure in MSR storage.
| [in,out] | adj | pointer to the cs_adjacency_t structure to update |
| void cs_adjacency_sort | ( | cs_adjacency_t * | adj | ) |
Sort each sub-list related to an entry in a cs_adjacency_t structure.
| [in] | adj | pointer to a cs_adjacency_t structure |
| cs_adjacency_t * cs_adjacency_transpose | ( | int | n_b_elts, |
| const cs_adjacency_t * | a2b ) |
Create a new cs_adjacency_t structure from a one corresponding to A -> B. The resulting structure deals with B -> A.
| [in] | n_b_elts | size of the set of B elements |
| [in] | a2b | pointer to the A -> B cs_adjacency_t structure |
| const cs_adjacency_t * cs_mesh_adjacencies_cell_faces | ( | void | ) |
Return cell -> face connectivites in mesh adjacencies helper API relative to mesh.
Boundary faces appear first, interior faces second.
This connectivity is built only when first requested, then updated later if needed.
| const cs_adjacency_t * cs_mesh_adjacencies_cell_vertices | ( | void | ) |
Return cell -> vertex connectivites in mesh adjacencies helper API relative to mesh.
This connectivity is built only when first requested, then updated later if needed.
| void cs_mesh_adjacencies_finalize | ( | void | ) |
Finalize mesh adjacencies helper API.
| cs_mesh_adjacencies_t * cs_mesh_adjacencies_get_global | ( | void | ) |
Get non-const pointer to cs_glob_mesh_adacencies.
| void cs_mesh_adjacencies_initialize | ( | void | ) |
Initialize mesh adjacencies helper API.
| void cs_mesh_adjacencies_update_cell_cells_e | ( | void | ) |
Update extended cell -> cell connectivites in mesh adjacencies helper API relative to mesh.
| void cs_mesh_adjacencies_update_cell_i_faces | ( | void | ) |
Ensure presence of cell -> interior face connectivites in mesh adjacencies helper API relative to mesh.
| void cs_mesh_adjacencies_update_device | ( | cs_alloc_mode_t | alloc_mode | ) |
Map some global mesh adjacency arrays for use on device.
More elements may be mapped dependin on which arrays are used in accelerated algorithms.
| [in] | alloc_mode | chosen allocation mode |
| void cs_mesh_adjacencies_update_mesh | ( | void | ) |
Update mesh adjacencies helper API relative to mesh.
| cs_adjacency_t * cs_mesh_adjacency_c2f | ( | const cs_mesh_t * | m, |
| int | boundary_order ) |
Build a cells to faces adjacency structure.
With the boundary_order option set to 0, boundary faces come first, so interior face ids are shifted by the number of boundary faces. With boundary_order set to 1, boundary faces come last, so face ids are shifted by the number of interior faces.
| [in] | m | pointer to a cs_mesh_t structure |
| [in] | boundary_order | boundaries first (0) or last (1) |
| cs_adjacency_t * cs_mesh_adjacency_c2f_boundary | ( | const cs_mesh_t * | m | ) |
Build a cells to boundary faces adjacency structure.
By construction, face ids adjacent to each cell are ordered.
| [in] | m | pointer to a cs_mesh_t structure |
| cs_adjacency_t * cs_mesh_adjacency_c2f_lower | ( | const cs_mesh_t * | m, |
| int | boundary_order ) |
Build a partial cells to faces adjacency structure.
With the boundary_order option set to 0, boundary faces come first, so interior face ids are shifted by the number of boundary faces. With boundary_order set to 1, boundary faces come last, so face ids are shifted by the number of interior faces. With boundary order set to -1, boundary faces are ignored.
Only internal faces as seen from the cell with lowest cell id (out of 2 cells adjacent to that face) are added to the structure, so each face appears only once, not twice. In other words, only the lower part of the corresponding cell-cells adjacency matrix is built.
By construction, face ids adjacent to each cell are ordered.
| [in] | m | pointer to a cs_mesh_t structure |
| [in] | boundary_order | boundaries first (0), last (1), or ignored (-1) |
| cs_adjacency_t * cs_mesh_adjacency_v2v | ( | const cs_mesh_t * | m | ) |
|
extern |