OGS
HexRule20.h
Go to the documentation of this file.
1
11#pragma once
12
13#include "EdgeReturn.h"
14#include "HexRule.h"
15
16namespace MeshLib
17{
18
44class HexRule20 : public HexRule
45{
46public:
48 static const unsigned n_all_nodes = 20u;
49
52
54 constexpr static const unsigned face_nodes[6][8] = {
55 {0, 3, 2, 1, 11, 10, 9, 8}, // Face 0
56 {0, 1, 5, 4, 8, 17, 12, 16}, // Face 1
57 {1, 2, 6, 5, 9, 18, 13, 17}, // Face 2
58 {2, 3, 7, 6, 10, 19, 14, 18}, // Face 3
59 {3, 0, 4, 7, 11, 16, 15, 19}, // Face 4
60 {4, 5, 6, 7, 12, 13, 14, 15} // Face 5
61 };
62
64 constexpr static const unsigned edge_nodes[12][3] = {
65 {0, 1, 8}, // Edge 0
66 {1, 2, 9}, // Edge 1
67 {2, 3, 10}, // Edge 2
68 {0, 3, 11}, // Edge 3
69 {4, 5, 12}, // Edge 4
70 {5, 6, 13}, // Edge 5
71 {6, 7, 14}, // Edge 6
72 {4, 7, 15}, // Edge 7
73 {0, 4, 16}, // Edge 8
74 {1, 5, 17}, // Edge 9
75 {2, 6, 18}, // Edge 10
76 {3, 7, 19} // Edge 11
77 };
78
81
83 static const Element* getFace(const Element* e, unsigned i);
84
86 static unsigned identifyFace(Node const* const* element_nodes,
87 Node const* nodes[3])
88 {
89 return CellRule::identifyFace<HexRule20>(element_nodes, nodes);
90 }
91}; /* class */
92
93} // namespace MeshLib
static unsigned identifyFace(Node const *const *element_nodes, Node const *nodes[ElementRule::dimension])
Returns the ID of a face given an array of nodes.
Definition CellRule.h:39
static constexpr const unsigned edge_nodes[12][3]
Constant: Local node index table for edge.
Definition HexRule20.h:64
static constexpr const unsigned face_nodes[6][8]
Constant: Local node index table for faces.
Definition HexRule20.h:54
static const Element * getFace(const Element *e, unsigned i)
Returns the i-th face of the element.
Definition HexRule20.cpp:23
static const unsigned n_all_nodes
Constant: The number of all nodes for this element.
Definition HexRule20.h:48
static unsigned identifyFace(Node const *const *element_nodes, Node const *nodes[3])
Returns the ID of a face given an array of nodes.
Definition HexRule20.h:86
static const CellType cell_type
Constant: The FEM type of the element.
Definition HexRule20.h:51
Returns quadratic order edge.
Definition EdgeReturn.h:39
CellType
Types of mesh elements supported by OpenGeoSys.
Definition MeshEnums.h:64