v0.8.23
CoreDataStructures.hpp
Go to the documentation of this file.
1 /** \file CoreDataStructures.hpp
2  * \brief Myltindex containers, data structures and other low-level functions
3  */
4 
5 /* MoFEM is free software: you can redistribute it and/or modify it under
6  * the terms of the GNU Lesser General Public License as published by the
7  * Free Software Foundation, either version 3 of the License, or (at your
8  * option) any later version.
9  *
10  * MoFEM is distributed in the hope that it will be useful, but WITHOUT
11  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
12  * FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
13  * License for more details.
14  *
15  * You should have received a copy of the GNU Lesser General Public
16  * License along with MoFEM. If not, see <http://www.gnu.org/licenses/>
17  */
18 
19 #ifndef __DATASTRUCTURES_HPP__
20 #define __DATASTRUCTURES_HPP__
21 
22 namespace MoFEM {
23 
24 const int prism_adj_edges[] = {6, 7, 8, -1, -1, -1, 0, 1, 2};
25 const int prism_edges_conn[6][2] = {{0, 1}, {1, 2}, {2, 0},
26  {3, 4}, {4, 5}, {5, 3}};
27 
28 inline int fNBENTITY_GENERIC(int P) {
29  (void)P;
30  return 0;
31 }
32 inline int fNBENTITYSET_NOFIELD(int P) {
33  (void)P;
34  return 1;
35 }
36 //
37 inline int fNBVERTEX_L2(int P) {
38  (void)P;
39  return 0;
40 }
41 inline int fNBVOLUMETET_L2(int P) { return NBVOLUMETET_L2(P); }
42 inline int fNBFACETRI_L2(int P) { return NBFACETRI_L2(P); }
43 inline int fNBEDGE_L2(int P) { return NBEDGE_L2(P); }
44 
45 /// number of approx. functions for H1 space on vertex
46 inline int fNBVERTEX_H1(int P) { return (P == 1) ? 1 : 0; }
47 /// number of approx. functions for H1 space on edge
48 inline int fNBEDGE_H1(int P) { return NBEDGE_H1(P); }
49 /// number of approx. functions for H1 space on face
50 inline int fNBFACETRI_H1(int P) { return NBFACETRI_H1(P); }
51 inline int fNBFACEQUAD_H1(int P) { return NBFACEQUAD_H1(P); }
52 /// number of approx. functions for H1 space on volume
53 inline int fNBVOLUMETET_H1(int P) { return NBVOLUMETET_H1(P); }
54 inline int fNBVOLUMEPRISM_H1(int P) { return NBVOLUMEPRISM_H1(P); }
55 
56 /// number of approx. functions for HCURL space on vertex
57 inline int fNBVERTEX_HCURL(int P) {
58  (void)P;
59  return 0;
60 }
61 inline int fNBEDGE_AINSWORTH_HCURL(int P) { return NBEDGE_AINSWORTH_HCURL(P); }
62 inline int fNBFACETRI_AINSWORTH_HCURL(int P) {
63  return NBFACETRI_AINSWORTH_HCURL(P);
64 }
65 inline int fNBVOLUMETET_AINSWORTH_HCURL(int P) {
67 }
68 
69 inline int fNBEDGE_DEMKOWICZ_HCURL(int P) { return NBEDGE_DEMKOWICZ_HCURL(P); }
70 inline int fNBFACETRI_DEMKOWICZ_HCURL(int P) {
71  return NBFACETRI_DEMKOWICZ_HCURL(P);
72 }
73 inline int fNBVOLUMETET_DEMKOWICZ_HCURL(int P) {
75 }
76 
77 /// \brief number of approx. functions for HDIV space on vertex
78 ///
79 /// zero number of digrees of freedom on vertex for that space
80 inline int fNBVERTEX_HDIV(int P) {
81  (void)P;
82  return 0;
83 }
84 /// number of approx. functions for HDIV space on edge
85 inline int fNBEDGE_HDIV(int P) {
86  (void)P;
87  return NBEDGE_HDIV(P);
88 }
89 /// number of approx. functions for HDIV space on face
90 inline int fNBFACETRI_AINSWORTH_HDIV(int P) {
91  return NBFACETRI_AINSWORTH_HDIV(P);
92 }
93 /// number of approx. functions for HDIV space on volume
94 inline int fNBVOLUMETET_AINSWORTH_HDIV(int P) {
96 }
97 
98 inline int fNBFACETRI_DEMKOWICZ_HDIV(int P) {
99  return NBFACETRI_DEMKOWICZ_HDIV(P);
100 }
101 /// number of approx. functions for HDIV space on volume
102 inline int fNBVOLUMETET_DEMKOWICZ_HDIV(int P) {
103  return NBVOLUMETET_DEMKOWICZ_HDIV(P);
104 }
105 
106 /** \brief Test MoAB entity handle if has structure as is assumed by MoFEM
107  */
108 MoFEMErrorCode test_moab(Interface &moab, const EntityHandle ent);
109 
110 } // namespace MoFEM
111 
112 #endif //__DATASTRUCTURES_HPP__
int fNBFACETRI_AINSWORTH_HDIV(int P)
number of approx. functions for HDIV space on face
const int prism_adj_edges[]
int fNBVERTEX_L2(int P)
#define NBVOLUMETET_L2(P)
Number of base functions on tetrahedron for L2 space.
#define NBEDGE_H1(P)
Numer of base function on edge for H1 space.
int fNBEDGE_DEMKOWICZ_HCURL(int P)
#define NBVOLUMETET_H1(P)
Number of base functions on tetrahedron fro H1 space.
int fNBEDGE_H1(int P)
number of approx. functions for H1 space on edge
int fNBENTITY_GENERIC(int P)
int fNBFACETRI_AINSWORTH_HCURL(int P)
int fNBVOLUMEPRISM_H1(int P)
MoFEMErrorCode test_moab(Interface &moab, const EntityHandle ent)
Test MoAB entity handle if has structure as is assumed by MoFEM.
int fNBVOLUMETET_L2(int P)
int fNBFACETRI_DEMKOWICZ_HDIV(int P)
implementation of Data Operators for Forces and Sources
Definition: Common.hpp:21
int fNBEDGE_AINSWORTH_HCURL(int P)
int fNBVOLUMETET_H1(int P)
number of approx. functions for H1 space on volume
int fNBVOLUMETET_DEMKOWICZ_HCURL(int P)
const int prism_edges_conn[6][2]
#define NBFACETRI_DEMKOWICZ_HDIV(P)
int fNBFACEQUAD_H1(int P)
int fNBVOLUMETET_DEMKOWICZ_HDIV(int P)
number of approx. functions for HDIV space on volume
#define NBFACEQUAD_H1(P)
Number of base functions on quad for H1 space.
#define NBEDGE_AINSWORTH_HCURL(P)
int fNBEDGE_L2(int P)
PetscErrorCode MoFEMErrorCode
MoFEM/PETSc error code.
Definition: Exceptions.hpp:66
#define NBEDGE_L2(P)
Number of base functions on edge fro L2 space.
#define NBFACETRI_L2(P)
Number of base functions on triangle for L2 space.
#define NBFACETRI_H1(P)
Number of base function on triangle for H1 space.
int fNBFACETRI_DEMKOWICZ_HCURL(int P)
#define NBVOLUMETET_DEMKOWICZ_HDIV(P)
#define NBFACETRI_DEMKOWICZ_HCURL(P)
#define NBEDGE_DEMKOWICZ_HCURL(P)
int fNBFACETRI_H1(int P)
number of approx. functions for H1 space on face
#define NBVOLUMETET_AINSWORTH_HDIV(P)
int fNBVERTEX_HCURL(int P)
number of approx. functions for HCURL space on vertex
int fNBVOLUMETET_AINSWORTH_HCURL(int P)
#define NBVOLUMETET_AINSWORTH_HCURL(P)
#define NBVOLUMEPRISM_H1(P)
Number of base functions on prism for H1 space.
#define NBFACETRI_AINSWORTH_HCURL(P)
int fNBVERTEX_H1(int P)
number of approx. functions for H1 space on vertex
#define NBEDGE_HDIV(P)
#define NBFACETRI_AINSWORTH_HDIV(P)
int fNBFACETRI_L2(int P)
int fNBENTITYSET_NOFIELD(int P)
int fNBVERTEX_HDIV(int P)
number of approx. functions for HDIV space on vertex
#define NBVOLUMETET_DEMKOWICZ_HCURL(P)
int fNBVOLUMETET_AINSWORTH_HDIV(int P)
number of approx. functions for HDIV space on volume
int fNBEDGE_HDIV(int P)
number of approx. functions for HDIV space on edge