95 const ArrayScalar & inputPoints,
96 const EOperator operatorType)
const {
99#ifdef HAVE_INTREPID_DEBUG
100 Intrepid::getValues_HGRAD_Args<Scalar, ArrayScalar>(outputValues,
103 this -> getBaseCellTopology(),
104 this -> getCardinality() );
108 int dim0 = inputPoints.dimension(0);
114 switch (operatorType) {
117 for (
int i0 = 0; i0 < dim0; i0++) {
118 x = inputPoints(i0, 0);
119 y = inputPoints(i0, 1);
122 outputValues(0, i0) = (1.0 - x)*(1.0 - y)/4.0;
123 outputValues(1, i0) = (1.0 + x)*(1.0 - y)/4.0;
124 outputValues(2, i0) = (1.0 + x)*(1.0 + y)/4.0;
125 outputValues(3, i0) = (1.0 - x)*(1.0 + y)/4.0;
131 for (
int i0 = 0; i0 < dim0; i0++) {
132 x = inputPoints(i0,0);
133 y = inputPoints(i0,1);
136 outputValues(0, i0, 0) = -(1.0 - y)/4.0;
137 outputValues(0, i0, 1) = -(1.0 - x)/4.0;
139 outputValues(1, i0, 0) = (1.0 - y)/4.0;
140 outputValues(1, i0, 1) = -(1.0 + x)/4.0;
142 outputValues(2, i0, 0) = (1.0 + y)/4.0;
143 outputValues(2, i0, 1) = (1.0 + x)/4.0;
145 outputValues(3, i0, 0) = -(1.0 + y)/4.0;
146 outputValues(3, i0, 1) = (1.0 - x)/4.0;
151 for (
int i0 = 0; i0 < dim0; i0++) {
152 x = inputPoints(i0,0);
153 y = inputPoints(i0,1);
156 outputValues(0, i0, 0) = -(1.0 - x)/4.0;
157 outputValues(0, i0, 1) = (1.0 - y)/4.0;
159 outputValues(1, i0, 0) = -(1.0 + x)/4.0;
160 outputValues(1, i0, 1) = -(1.0 - y)/4.0;
162 outputValues(2, i0, 0) = (1.0 + x)/4.0;
163 outputValues(2, i0, 1) = -(1.0 + y)/4.0;
165 outputValues(3, i0, 0) = (1.0 - x)/4.0;
166 outputValues(3, i0, 1) = (1.0 + y)/4.0;
171 TEUCHOS_TEST_FOR_EXCEPTION( (operatorType == OPERATOR_DIV), std::invalid_argument,
172 ">>> ERROR (Basis_HGRAD_QUAD_C1_FEM): DIV is invalid operator for rank-0 (scalar) functions in 2D");
176 for (
int i0 = 0; i0 < dim0; i0++) {
179 outputValues(0, i0, 0) = 0.0;
180 outputValues(0, i0, 1) = 0.25;
181 outputValues(0, i0, 2) = 0.0;
183 outputValues(1, i0, 0) = 0.0;
184 outputValues(1, i0, 1) = -0.25;
185 outputValues(1, i0, 2) = 0.0;
187 outputValues(2, i0, 0) = 0.0;
188 outputValues(2, i0, 1) = 0.25;
189 outputValues(2, i0, 2) = 0.0;
191 outputValues(3, i0, 0) = 0.0;
192 outputValues(3, i0, 1) = -0.25;
193 outputValues(3, i0, 2) = 0.0;
208 this -> basisCellTopology_.getDimension() );
209 for(
int dofOrd = 0; dofOrd <
this -> basisCardinality_; dofOrd++) {
210 for (
int i0 = 0; i0 < dim0; i0++) {
211 for(
int dkOrd = 0; dkOrd < DkCardinality; dkOrd++){
212 outputValues(dofOrd, i0, dkOrd) = 0.0;
221 ">>> ERROR (Basis_HGRAD_QUAD_C1_FEM): Invalid operator type");
240#ifdef HAVE_INTREPID_DEBUG
242 TEUCHOS_TEST_FOR_EXCEPTION( !(DofCoords.rank() == 2), std::invalid_argument,
243 ">>> ERROR: (Intrepid::Basis_HGRAD_QUAD_C1_FEM::getDofCoords) rank = 2 required for DofCoords array");
245 TEUCHOS_TEST_FOR_EXCEPTION( !( DofCoords.dimension(0) == this -> basisCardinality_ ), std::invalid_argument,
246 ">>> ERROR: (Intrepid::Basis_HGRAD_QUAD_C1_FEM::getDofCoords) mismatch in number of DoF and 0th dimension of DofCoords array");
248 TEUCHOS_TEST_FOR_EXCEPTION( !( DofCoords.dimension(1) == (
int)(this -> basisCellTopology_.getDimension()) ), std::invalid_argument,
249 ">>> ERROR: (Intrepid::Basis_HGRAD_QUAD_C1_FEM::getDofCoords) incorrect reference cell (1st) dimension in DofCoords array");
252 DofCoords(0,0) = -1.0; DofCoords(0,1) = -1.0;
253 DofCoords(1,0) = 1.0; DofCoords(1,1) = -1.0;
254 DofCoords(2,0) = 1.0; DofCoords(2,1) = 1.0;
255 DofCoords(3,0) = -1.0; DofCoords(3,1) = 1.0;