38 {
40
42
45 "Pointer to element should be given "
46 "when EntPolynomialBaseCtx is constructed "
47 "(use different constructor)");
48
49 int nb_gauss_pts = pts.size2();
50 if (!nb_gauss_pts)
52
53 if (pts.size1() < 1)
54 SETERRQ(
56 "Wrong dimension of pts, should be at least 3 rows with coordinates");
57
60
63 else
66
67 data.
dataOnEntities[MBVERTEX][0].getN(base).resize(nb_gauss_pts, 6,
false);
68 data.
dataOnEntities[MBVERTEX][0].getDiffN(base).resize(nb_gauss_pts, 12,
69 false);
71 (unsigned int)nb_gauss_pts) {
73 "Base functions or nodes has wrong number of integration points "
74 "for base %s",
76 }
77
78 data.
dataOnEntities[MBVERTEX][0].getN(base).resize(nb_gauss_pts, 6,
false);
79 data.
dataOnEntities[MBVERTEX][0].getDiffN(base).resize(nb_gauss_pts, 12,
80 false);
81 N.resize(nb_gauss_pts, 3,
false);
82 diffN.resize(3, 2,
false);
85 &*
diffN.data().begin());
86
87
89 true);
92 SideNumber_multiIndex::nth_index<1>::type::iterator siit3 =
93 side_table.get<1>().find(boost::make_tuple(MBTRI, 3));
94 SideNumber_multiIndex::nth_index<1>::type::iterator siit4 =
95 side_table.get<1>().find(boost::make_tuple(MBTRI, 4));
96 if (siit3 == side_table.get<1>().end())
98 if (siit4 == side_table.get<1>().end())
101 true);
103 true);
104
105 for (int nn = 0; nn < 3; nn++) {
110 for (int gg = 0; gg < nb_gauss_pts; gg++) {
111 double val =
N(gg, nn);
112 double val_x =
diffN(nn, 0);
113 double val_y =
diffN(nn, 1);
115 data.
dataOnEntities[MBVERTEX][0].getDiffN(base)(gg, 2 * nn + 0) = val_x;
116 data.
dataOnEntities[MBVERTEX][0].getDiffN(base)(gg, 2 * nn + 1) = val_y;
118 data.
dataOnEntities[MBVERTEX][0].getDiffN(base)(gg, 6 + 2 * nn + 0) =
119 val_x;
120 data.
dataOnEntities[MBVERTEX][0].getDiffN(base)(gg, 6 + 2 * nn + 1) =
121 val_y;
122 }
123 }
124
128 break;
131 break;
134 break;
137 break;
138 default:
140 }
141
143}
FieldApproximationBase
approximation base
#define MoFEMFunctionReturnHot(a)
Last executable line of each PETSc function used for error handling. Replaces return()
@ L2
field with C-1 continuity
@ HCURL
field with continuous tangents
@ HDIV
field with continuous normal traction
@ MOFEM_DATA_INCONSISTENCY
static const char *const ApproximationBaseNames[]
#define CHKERR
Inline error check.
#define MoFEMFunctionBeginHot
First executable line of each MoFEM function, used for error handling. Final line of MoFEM functions ...
multi_index_container< boost::shared_ptr< SideNumber >, indexed_by< ordered_unique< member< SideNumber, EntityHandle, &SideNumber::ent > >, ordered_non_unique< composite_key< SideNumber, const_mem_fun< SideNumber, EntityType, &SideNumber::getEntType >, member< SideNumber, signed char, &SideNumber::side_number > > > > > SideNumber_multiIndex
SideNumber_multiIndex for SideNumber.
const FieldApproximationBase copyNodeBase
const FieldApproximationBase bAse
data structure for finite element entity
std::array< boost::ptr_vector< EntData >, MBMAXTYPE > dataOnEntities
Class used to pass element data to calculate base functions on flat prism.
const NumeredEntFiniteElement * fePtr
MoFEMErrorCode getValueHcurl(MatrixDouble &pts)
FlatPrismPolynomialBaseCtx * cTx
MoFEMErrorCode getValueHdiv(MatrixDouble &pts)
MoFEMErrorCode getValueH1(MatrixDouble &pts)
const EntityHandle * connPrism
MoFEMErrorCode getValueL2(MatrixDouble &pts)
const EntityHandle * connFace3
const EntityHandle * connFace4
MoFEMErrorCode getInterface(IFACE *&iface) const
Get interface refernce to pointer of interface.
SideNumber_multiIndex & getSideNumberTable() const
EntityHandle getEnt() const