p4est 2.8.7.456-de8c6
p4est is a software library for parallel adaptive mesh refinement.
Loading...
Searching...
No Matches
p8est_tnodes.h
Go to the documentation of this file.
1/*
2 This file is part of p4est.
3 p4est is a C library to manage a collection (a forest) of multiple
4 connected adaptive quadtrees or octrees in parallel.
5
6 Copyright (C) 2010 The University of Texas System
7 Additional copyright (C) 2011 individual authors
8 Written by Carsten Burstedde, Lucas C. Wilcox, and Tobin Isaac
9
10 p4est is free software; you can redistribute it and/or modify
11 it under the terms of the GNU General Public License as published by
12 the Free Software Foundation; either version 2 of the License, or
13 (at your option) any later version.
14
15 p4est is distributed in the hope that it will be useful,
16 but WITHOUT ANY WARRANTY; without even the implied warranty of
17 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 GNU General Public License for more details.
19
20 You should have received a copy of the GNU General Public License
21 along with p4est; if not, write to the Free Software Foundation, Inc.,
22 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
23*/
24
36#ifndef P8EST_TNODES_H
37#define P8EST_TNODES_H
38
39#include <p8est_lnodes.h>
40
41SC_EXTERN_C_BEGIN;
42
44#define P8EST_TNODES_SIMPLEX_CORNERS 4
45
47#define P8EST_TNODES_CUBE_SIMPLICES 6
48
81
88extern const int p8est_tnodes_face_normal[6];
89
94extern const int p8est_tnodes_simplex_reverse[6];
95
98extern const int p8est_tnodes_simplex_edgeswap[6];
99
106int p4est_tnodes_simplex_parent (int p, int c, int k);
107
116 (int p, int kp, int c, int kc);
117
124 (p8est_lnodes_code_t fc, int pc);
125
132
146 p8est_lnodes_t *lnodes);
147
160 p8est_lnodes_t *lnodes);
161
178 p8est_lnodes_t *lnodes);
179
185
190
191SC_EXTERN_C_END;
192
193#endif /* !P8EST_TNODES_H */
int32_t p4est_locidx_t
Typedef for processor-local indexing of quadrants and nodes.
Definition p4est_base.h:106
int64_t p4est_gloidx_t
Typedef for globally unique indexing of quadrants.
Definition p4est_base.h:118
Generate Lobatto node numbers for any degree.
int16_t p8est_lnodes_code_t
The face code encodes the configuration of a hanging quadrant.
Definition p8est_lnodes.h:46
void p8est_tnodes_destroy(p8est_tnodes_t *tnodes)
Free the memory in a conforming tetrahedron mesh structure.
p8est_tnodes_t * p8est_tnodes_new_Q2_P1_ind(p8est_t *p4est, p8est_lnodes_t *lnodes)
Generate a conforming tetrahedron mesh from a Q2 lnodes structure.
const int p8est_tnodes_face_normal[6]
For every simplex number the normal direction of its outside face.
int p8est_tnodes_quadrant_Q2_simplices(p8est_lnodes_code_t fc)
Based on the face code of an element, calculate contained simplices.
struct p8est_tnodes p8est_tnodes_t
Lookup table structure defining a conforming tetrahedral mesh.
p8est_tnodes_t * p8est_tnodes_new_Q1_P1(p8est_t *p4est, p8est_lnodes_t *lnodes)
Generate a conforming tetrahedral mesh from a Q1 lnodes structure.
int p8est_tnodes_simplex_parent_is_valid(int p, int kp, int c, int kc)
Verify that a given child simplex is contained in a parent.
const int p8est_tnodes_simplex_edgeswap[6]
The simplex that shares the face direction and swaps the edge.
size_t p8est_tnodes_memory_used(p8est_tnodes_t *tnodes)
Calculate memory allocated in a tnodes structure.
const int p8est_tnodes_simplex_reverse[6]
The number of the congruent simplex that starts at the antipode.
p8est_tnodes_t * p8est_tnodes_new_Q2_P1(p8est_t *p4est, p8est_lnodes_t *lnodes)
Generate a conforming tetrahedral mesh from a Q2 lnodes structure.
int p8est_tnodes_quadrant_Q1_simplices(p8est_lnodes_code_t fc, int pc)
Based on a face code and the parent's id, calculate simplex count.
The p4est forest datatype.
Definition p4est.h:150
Store a parallel numbering of Lobatto points of a given degree > 0.
Definition p8est_lnodes.h:127
Lookup table structure defining a conforming tetrahedral mesh.
Definition p8est_tnodes.h:51
sc_array_t * simplex_level
Simplex level l as an int8_t, reference volume 2**{-l} / 6.
Definition p8est_tnodes.h:67
int Qdegree
Degree of original lnodes.
Definition p8est_tnodes.h:53
sc_array_t * simplices
Vertex indices of local simplices.
Definition p8est_tnodes.h:69
p4est_locidx_t * local_tcount
Tetrahedron count per process (has mpisize entries).
Definition p8est_tnodes.h:60
int Pdegree
Degree of simplex space.
Definition p8est_tnodes.h:54
p4est_gloidx_t global_tcount
Global tetrahedron count.
Definition p8est_tnodes.h:59
int mpisize
Number of parallel processes.
Definition p8est_tnodes.h:52
p4est_locidx_t * local_element_offset
Offsets into local tetrahedra per element and one beyond.
Definition p8est_tnodes.h:65
p4est_gloidx_t global_toffset
Global tetrahedron offset for the current process.
Definition p8est_tnodes.h:57
sc_array_t * element_bits
For each local element, one or eight bytes of flag bits.
Definition p8est_tnodes.h:78
The p8est forest datatype.
Definition p8est.h:146