1 #ifndef INTREPID_HGRAD_LINE_C1_FEMDEF_HPP 2 #define INTREPID_HGRAD_LINE_C1_FEMDEF_HPP 54 template<
class Scalar,
class ArrayScalar>
56 this -> basisCardinality_ = 2;
57 this -> basisDegree_ = 1;
58 this -> basisCellTopology_ = shards::CellTopology(shards::getCellTopologyData<shards::Line<2> >() );
59 this -> basisType_ = BASIS_FEM_DEFAULT;
60 this -> basisCoordinates_ = COORDINATES_CARTESIAN;
61 this -> basisTagsAreSet_ =
false;
66 template<
class Scalar,
class ArrayScalar>
68 const ArrayScalar & inputPoints,
72 #ifdef HAVE_INTREPID_DEBUG 73 Intrepid::getValues_HGRAD_Args<Scalar, ArrayScalar>(outputValues,
76 this -> getBaseCellTopology(),
77 this -> getCardinality() );
80 int dim0 = inputPoints.dimension(0);
85 switch (operatorType) {
88 for (
int i0 = 0; i0 < dim0; i0++) {
89 x = inputPoints(i0, 0);
92 outputValues(0, i0) = (1.0 - x)/2.0;
93 outputValues(1, i0) = (1.0 + x)/2.0;
101 for (
int i0 = 0; i0 < dim0; i0++) {
102 x = inputPoints(i0,0);
105 outputValues(0, i0, 0) = -0.5;
106 outputValues(1, i0, 0) = 0.5;
111 for (
int i0 = 0; i0 < dim0; i0++) {
114 outputValues(0, i0, 0) = 0.0;
115 outputValues(1, i0, 0) = 0.0;
130 this -> basisCellTopology_.getDimension() );
131 for(
int dofOrd = 0; dofOrd <
this -> basisCardinality_; dofOrd++) {
132 for (
int i0 = 0; i0 < dim0; i0++) {
133 for(
int dkOrd = 0; dkOrd < DkCardinality; dkOrd++){
134 outputValues(dofOrd, i0, dkOrd) = 0.0;
143 ">>> ERROR (Basis_HGRAD_LINE_C1_FEM): Invalid operator type");
147 template<
class Scalar,
class ArrayScalar>
157 int tags[] = { 0, 0, 0, 1,
162 this -> ordinalToTag_,
164 this -> basisCardinality_,
171 template<
class Scalar,
class ArrayScalar>
173 const ArrayScalar & inputPoints,
174 const ArrayScalar & cellVertices,
176 TEUCHOS_TEST_FOR_EXCEPTION( (
true), std::logic_error,
177 ">>> ERROR (Basis_HGRAD_LINE_C1_FEM): FEM Basis calling an FVD member function");
void setOrdinalTagData(std::vector< std::vector< std::vector< int > > > &tagToOrdinal, std::vector< std::vector< int > > &ordinalToTag, const int *tags, const int basisCard, const int tagSize, const int posScDim, const int posScOrd, const int posDfOrd)
Fills ordinalToTag_ and tagToOrdinal_ by basis-specific tag data.
Basis_HGRAD_LINE_C1_FEM()
Constructor.
EOperator
Enumeration of primitive operators available in Intrepid. Primitive operators act on reconstructed fu...
void initializeTags()
Initializes tagToOrdinal_ and ordinalToTag_ lookup arrays.
void getValues(ArrayScalar &outputValues, const ArrayScalar &inputPoints, const EOperator operatorType) const
Evaluation of a FEM basis on a reference Line cell.
int getDkCardinality(const EOperator operatorType, const int spaceDim)
Returns cardinality of Dk, i.e., the number of all derivatives of order k.
int isValidOperator(const EOperator operatorType)
Verifies validity of an operator enum.