Intrepid2
Intrepid2_HCURL_TRI_In_FEMDef.hpp
Go to the documentation of this file.
1 // @HEADER
2 // ************************************************************************
3 //
4 // Intrepid2 Package
5 // Copyright (2007) Sandia Corporation
6 //
7 // Under terms of Contract DE-AC04-94AL85000, there is a non-exclusive
8 // license for use of this work by or on behalf of the U.S. Government.
9 //
10 // Redistribution and use in source and binary forms, with or without
11 // modification, are permitted provided that the following conditions are
12 // met:
13 //
14 // 1. Redistributions of source code must retain the above copyright
15 // notice, this list of conditions and the following disclaimer.
16 //
17 // 2. Redistributions in binary form must reproduce the above copyright
18 // notice, this list of conditions and the following disclaimer in the
19 // documentation and/or other materials provided with the distribution.
20 //
21 // 3. Neither the name of the Corporation nor the names of the
22 // contributors may be used to endorse or promote products derived from
23 // this software without specific prior written permission.
24 //
25 // THIS SOFTWARE IS PROVIDED BY SANDIA CORPORATION "AS IS" AND ANY
26 // EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
27 // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
28 // PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL SANDIA CORPORATION OR THE
29 // CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
30 // EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
31 // PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
32 // PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
33 // LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
34 // NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
35 // SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
36 //
37 // Questions? Contact Kyungjoo Kim (kyukim@sandia.gov), or
38 // Mauro Perego (mperego@sandia.gov)
39 //
40 // ************************************************************************
41 // @HEADER
42 
49 #ifndef __INTREPID2_HCURL_TRI_IN_FEM_DEF_HPP__
50 #define __INTREPID2_HCURL_TRI_IN_FEM_DEF_HPP__
51 
54 
55 namespace Intrepid2 {
56 
57  // -------------------------------------------------------------------------------------
58 
59  namespace Impl {
60 
61  template<EOperator opType>
62  template<typename outputViewType,
63  typename inputViewType,
64  typename workViewType,
65  typename vinvViewType>
66  KOKKOS_INLINE_FUNCTION
67  void
68  Basis_HCURL_TRI_In_FEM::Serial<opType>::
69  getValues( outputViewType output,
70  const inputViewType input,
71  workViewType work,
72  const vinvViewType coeffs ) {
73 
74  constexpr ordinal_type spaceDim = 2;
75  const ordinal_type
76  cardPn = coeffs.extent(0)/spaceDim,
77  card = coeffs.extent(1),
78  npts = input.extent(0);
79 
80  // compute order
81  ordinal_type order = 0;
82  for (ordinal_type p=0;p<=Parameters::MaxOrder;++p) {
83  if (card == CardinalityHCurlTri(p)) {
84  order = p;
85  break;
86  }
87  }
88 
89  typedef typename Kokkos::DynRankView<typename workViewType::value_type, typename workViewType::memory_space> viewType;
90  auto vcprop = Kokkos::common_view_alloc_prop(work);
91  auto ptr = work.data();
92 
93  switch (opType) {
94  case OPERATOR_VALUE: {
95  const viewType phis(Kokkos::view_wrap(ptr, vcprop), card, npts);
96  workViewType dummyView;
97 
98  Impl::Basis_HGRAD_TRI_Cn_FEM_ORTH::
99  Serial<opType>::getValues(phis, input, dummyView, order);
100 
101  for (ordinal_type i=0;i<card;++i)
102  for (ordinal_type j=0;j<npts;++j)
103  for (ordinal_type d=0;d<spaceDim;++d) {
104  output.access(i,j,d) = 0.0;
105  for (ordinal_type k=0;k<cardPn;++k)
106  output.access(i,j,d) += coeffs(k+d*cardPn,i) * phis(k,j);
107  }
108  break;
109  }
110  case OPERATOR_CURL: {
111  const viewType phis(Kokkos::view_wrap(ptr, vcprop), card, npts, spaceDim);
112  ptr += card*npts*spaceDim*get_dimension_scalar(work);
113  const viewType workView(Kokkos::view_wrap(ptr, vcprop), card, npts, spaceDim+1);
114 
115  Impl::Basis_HGRAD_TRI_Cn_FEM_ORTH::
116  Serial<OPERATOR_GRAD>::getValues(phis, input, workView, order);
117 
118  for (ordinal_type i=0;i<card;++i)
119  for (ordinal_type j=0;j<npts;++j) {
120  output.access(i,j) = 0.0;
121  for (ordinal_type k=0; k<cardPn; ++k)
122  output.access(i,j) += - coeffs(k,i)*phis(k,j,1) // - dy of x component
123  + coeffs(k+cardPn,i)*phis(k,j,0); // dx of y component
124  }
125  break;
126  }
127  default: {
128  INTREPID2_TEST_FOR_ABORT( true,
129  ">>> ERROR (Basis_HCURL_TRI_In_FEM): Operator type not implemented");
130  }
131  }
132  }
133 
134  template<typename SpT, ordinal_type numPtsPerEval,
135  typename outputValueValueType, class ...outputValueProperties,
136  typename inputPointValueType, class ...inputPointProperties,
137  typename vinvValueType, class ...vinvProperties>
138  void
139  Basis_HCURL_TRI_In_FEM::
140  getValues( Kokkos::DynRankView<outputValueValueType,outputValueProperties...> outputValues,
141  const Kokkos::DynRankView<inputPointValueType, inputPointProperties...> inputPoints,
142  const Kokkos::DynRankView<vinvValueType, vinvProperties...> coeffs,
143  const EOperator operatorType) {
144  typedef Kokkos::DynRankView<outputValueValueType,outputValueProperties...> outputValueViewType;
145  typedef Kokkos::DynRankView<inputPointValueType, inputPointProperties...> inputPointViewType;
146  typedef Kokkos::DynRankView<vinvValueType, vinvProperties...> vinvViewType;
147  typedef typename ExecSpace<typename inputPointViewType::execution_space,SpT>::ExecSpaceType ExecSpaceType;
148 
149  // loopSize corresponds to cardinality
150  const auto loopSizeTmp1 = (inputPoints.extent(0)/numPtsPerEval);
151  const auto loopSizeTmp2 = (inputPoints.extent(0)%numPtsPerEval != 0);
152  const auto loopSize = loopSizeTmp1 + loopSizeTmp2;
153  Kokkos::RangePolicy<ExecSpaceType,Kokkos::Schedule<Kokkos::Static> > policy(0, loopSize);
154 
155  typedef typename inputPointViewType::value_type inputPointType;
156 
157  const ordinal_type cardinality = outputValues.extent(0);
158  const ordinal_type spaceDim = 2;
159 
160  auto vcprop = Kokkos::common_view_alloc_prop(inputPoints);
161  typedef typename Kokkos::DynRankView< inputPointType, typename inputPointViewType::memory_space> workViewType;
162 
163  switch (operatorType) {
164  case OPERATOR_VALUE: {
165  workViewType work(Kokkos::view_alloc("Basis_HCURL_TRI_In_FEM::getValues::work", vcprop), cardinality, inputPoints.extent(0));
166  typedef Functor<outputValueViewType,inputPointViewType,vinvViewType, workViewType,
167  OPERATOR_VALUE,numPtsPerEval> FunctorType;
168  Kokkos::parallel_for( policy, FunctorType(outputValues, inputPoints, coeffs, work) );
169  break;
170  }
171  case OPERATOR_CURL: {
172  workViewType work(Kokkos::view_alloc("Basis_HCURL_TRI_In_FEM::getValues::work", vcprop), cardinality*(2*spaceDim+1), inputPoints.extent(0));
173  typedef Functor<outputValueViewType,inputPointViewType,vinvViewType, workViewType,
174  OPERATOR_CURL,numPtsPerEval> FunctorType;
175  Kokkos::parallel_for( policy, FunctorType(outputValues, inputPoints, coeffs, work) );
176  break;
177  }
178  default: {
179  INTREPID2_TEST_FOR_EXCEPTION( true , std::invalid_argument,
180  ">>> ERROR (Basis_HCURL_TRI_In_FEM): Operator type not implemented" );
181  }
182  }
183  }
184  }
185 
186  // -------------------------------------------------------------------------------------
187  template<typename SpT, typename OT, typename PT>
189  Basis_HCURL_TRI_In_FEM( const ordinal_type order,
190  const EPointType pointType ) {
191 
192  constexpr ordinal_type spaceDim = 2;
193  this->basisCardinality_ = CardinalityHCurlTri(order);
194  this->basisDegree_ = order; // small n
195  this->basisCellTopology_ = shards::CellTopology(shards::getCellTopologyData<shards::Triangle<3> >() );
196  this->basisType_ = BASIS_FEM_FIAT;
197  this->basisCoordinates_ = COORDINATES_CARTESIAN;
198 
199  const ordinal_type card = this->basisCardinality_;
200 
201  const ordinal_type cardPn = Intrepid2::getPnCardinality<spaceDim>(order); // dim of (P_{n}) -- smaller space
202  const ordinal_type cardPnm1 = Intrepid2::getPnCardinality<spaceDim>(order-1); // dim of (P_{n-1}) -- smaller space
203  const ordinal_type cardPnm2 = Intrepid2::getPnCardinality<spaceDim>(order-2); // dim of (P_{n-2}) -- smaller space
204  const ordinal_type cardVecPn = spaceDim*cardPn; // dim of (P_{n})^2 -- larger space
205  const ordinal_type cardVecPnm1 = spaceDim*cardPnm1; // dim of (P_{n-1})^2 -- smaller space
206 
207 
208  // Basis-dependent initializations
209  constexpr ordinal_type tagSize = 4; // size of DoF tag, i.e., number of fields in the tag
210  constexpr ordinal_type maxCard = CardinalityHCurlTri(Parameters::MaxOrder);
211  ordinal_type tags[maxCard][tagSize];
212 
213  // points are computed in the host and will be copied
214  Kokkos::DynRankView<scalarType,typename SpT::array_layout,Kokkos::HostSpace>
215  dofCoords("Hcurl::Tri::In::dofCoords", card, spaceDim);
216 
217  Kokkos::DynRankView<scalarType,typename SpT::array_layout,Kokkos::HostSpace>
218  coeffs("Hcurl::Tri::In::coeffs", cardVecPn, card);
219 
220  Kokkos::DynRankView<scalarType,typename SpT::array_layout,Kokkos::HostSpace>
221  dofCoeffs("Hcurl::Tri::In::dofCoeffs", card, spaceDim);
222 
223  // first, need to project the basis for RT space onto the
224  // orthogonal basis of degree n
225  // get coefficients of PkHx
226 
227  const ordinal_type lwork = card*card;
228  Kokkos::DynRankView<scalarType,typename SpT::array_layout,Kokkos::HostSpace>
229  V1("Hcurl::Tri::In::V1", cardVecPn, card);
230 
231  // basis for the space is
232  // { (phi_i,0) }_{i=0}^{cardPnm1-1} ,
233  // { (0,phi_i) }_{i=0}^{cardPnm1-1} ,
234  // { (x,y) \times phi_i}_{i=cardPnm2}^{cardPnm1-1}
235  // { (x,y) \times phi = (y phi , -x \phi)
236  // columns of V1 are expansion of this basis in terms of the basis
237  // for P_{n}^2
238 
239  // these two loops get the first two sets of basis functions
240  for (ordinal_type i=0;i<cardPnm1;i++)
241  for (ordinal_type d=0;d<spaceDim;d++)
242  V1(d*cardPn+i,d*cardPnm1+i) = 1.0;
243 
244 
245  // now I need to integrate { (x,y) \times phi } against the big basis
246  // first, get a cubature rule.
248  Kokkos::DynRankView<scalarType,typename SpT::array_layout,Kokkos::HostSpace> cubPoints("Hcurl::Tri::In::cubPoints", myCub.getNumPoints() , spaceDim );
249  Kokkos::DynRankView<scalarType,typename SpT::array_layout,Kokkos::HostSpace> cubWeights("Hcurl::Tri::In::cubWeights", myCub.getNumPoints() );
250  myCub.getCubature( cubPoints , cubWeights );
251 
252  // tabulate the scalar orthonormal basis at cubature points
253  Kokkos::DynRankView<scalarType,typename SpT::array_layout,Kokkos::HostSpace> phisAtCubPoints("Hcurl::Tri::In::phisAtCubPoints", cardPn , myCub.getNumPoints() );
254  Impl::Basis_HGRAD_TRI_Cn_FEM_ORTH::getValues<Kokkos::HostSpace::execution_space,Parameters::MaxNumPtsPerBasisEval>(phisAtCubPoints, cubPoints, order, OPERATOR_VALUE);
255 
256  // now do the integration
257  for (ordinal_type i=0;i<order;i++) {
258  for (ordinal_type j=0;j<cardPn;j++) { // int (x,y) phi_i \cdot (phi_j,phi_{j+cardPn})
259  for (ordinal_type k=0;k<myCub.getNumPoints();k++) {
260  V1(j,cardVecPnm1+i) -=
261  cubWeights(k) * cubPoints(k,1)
262  * phisAtCubPoints(cardPnm2+i,k)
263  * phisAtCubPoints(j,k);
264  V1(j+cardPn,cardVecPnm1+i) +=
265  cubWeights(k) * cubPoints(k,0)
266  * phisAtCubPoints(cardPnm2+i,k)
267  * phisAtCubPoints(j,k);
268  }
269  }
270  }
271 
272  // next, apply the RT nodes (rows) to the basis for (P_n)^2 (columns)
273  Kokkos::DynRankView<scalarType,typename SpT::array_layout,Kokkos::HostSpace>
274  V2("Hcurl::Tri::In::V2", card ,cardVecPn);
275 
276  const ordinal_type numEdges = this->basisCellTopology_.getEdgeCount();
277 
278  shards::CellTopology edgeTop(shards::getCellTopologyData<shards::Line<2> >() );
279 
280  const int numPtsPerEdge = PointTools::getLatticeSize( edgeTop ,
281  order+1 ,
282  1 );
283 
284  // first numEdges * degree nodes are tangents at each edge
285  // get the points on the line
286  Kokkos::DynRankView<scalarType,typename SpT::array_layout,Kokkos::HostSpace> linePts("Hcurl::Tri::In::linePts", numPtsPerEdge , 1 );
287 
288  // construct lattice
289  const ordinal_type offset = 1;
290  PointTools::getLattice( linePts,
291  edgeTop,
292  order+1, offset,
293  pointType );
294 
295  // holds the image of the line points
296  Kokkos::DynRankView<scalarType,typename SpT::array_layout,Kokkos::HostSpace> edgePts("Hcurl::Tri::In::edgePts", numPtsPerEdge , spaceDim );
297  Kokkos::DynRankView<scalarType,typename SpT::array_layout,Kokkos::HostSpace> phisAtEdgePoints("Hcurl::Tri::In::phisAtEdgePoints", cardPn , numPtsPerEdge );
298  Kokkos::DynRankView<scalarType,typename SpT::array_layout,Kokkos::HostSpace> edgeTan("Hcurl::Tri::In::edgeTan", spaceDim );
299 
300  // these are tangents scaled by the appropriate edge lengths.
301  for (ordinal_type edge=0;edge<numEdges;edge++) { // loop over edges
303  edge ,
304  this->basisCellTopology_ );
305  /* multiply by measure of reference edge so that magnitude of the edgeTan is equal to the edge measure */
306  const scalarType refEdgeMeasure = 2.0;
307  for (ordinal_type j=0;j<spaceDim;j++)
308  edgeTan(j) *= refEdgeMeasure;
309 
311  linePts ,
312  1 ,
313  edge ,
314  this->basisCellTopology_ );
315 
316  Impl::Basis_HGRAD_TRI_Cn_FEM_ORTH::getValues<Kokkos::HostSpace::execution_space,Parameters::MaxNumPtsPerBasisEval>(phisAtEdgePoints , edgePts, order, OPERATOR_VALUE);
317 
318  // loop over points (rows of V2)
319  for (ordinal_type j=0;j<numPtsPerEdge;j++) {
320 
321  const ordinal_type i_card = numPtsPerEdge*edge+j;
322 
323  // loop over orthonormal basis functions (columns of V2)
324  for (ordinal_type k=0;k<cardPn;k++) {
325  V2(i_card,k) = edgeTan(0) * phisAtEdgePoints(k,j);
326  V2(i_card,k+cardPn) = edgeTan(1) * phisAtEdgePoints(k,j);
327  }
328 
329 
330  //save dof coordinates
331  for(ordinal_type k=0; k<spaceDim; ++k) {
332  dofCoords(i_card,k) = edgePts(j,k);
333  dofCoeffs(i_card,k) = edgeTan(k);
334  }
335 
336  tags[i_card][0] = 1; // edge dof
337  tags[i_card][1] = edge; // edge id
338  tags[i_card][2] = j; // local dof id
339  tags[i_card][3] = numPtsPerEdge; // total edge dof
340 
341  }
342 
343 
344  }
345 
346  // remaining nodes are x- and y- components at internal points (this code is same as HDIV).
347  //These are evaluated at the interior of a lattice of degree + 1, For then
348  // the degree == 1 space corresponds classicaly to RT0 and so gets
349  // no internal nodes, and degree == 2 corresponds to RT1 and needs
350  // one internal node per vector component.
351  const ordinal_type numPtsPerCell = PointTools::getLatticeSize( this->basisCellTopology_ ,
352  order + 1 ,
353  1 );
354 
355  if (numPtsPerCell > 0) {
356  Kokkos::DynRankView<scalarType,typename SpT::array_layout,Kokkos::HostSpace>
357  internalPoints( "Hcurl::Tri::In::internalPoints", numPtsPerCell , spaceDim );
358  PointTools::getLattice( internalPoints ,
359  this->basisCellTopology_ ,
360  order + 1 ,
361  1 ,
362  pointType );
363 
364  Kokkos::DynRankView<scalarType,typename SpT::array_layout,Kokkos::HostSpace>
365  phisAtInternalPoints("Hcurl::Tri::In::phisAtInternalPoints", cardPn , numPtsPerCell );
366  Impl::Basis_HGRAD_TRI_Cn_FEM_ORTH::getValues<Kokkos::HostSpace::execution_space,Parameters::MaxNumPtsPerBasisEval>( phisAtInternalPoints , internalPoints , order, OPERATOR_VALUE );
367 
368  // copy values into right positions of V2
369  for (ordinal_type j=0;j<numPtsPerCell;j++) {
370 
371  const ordinal_type i_card = numEdges*order+spaceDim*j;
372 
373  for (ordinal_type k=0;k<cardPn;k++) {
374  // x component
375  V2(i_card,k) = phisAtInternalPoints(k,j);
376  // y component
377  V2(i_card+1,cardPn+k) = phisAtInternalPoints(k,j);
378  }
379 
380  //save dof coordinates
381  for(ordinal_type d=0; d<spaceDim; ++d) {
382  for(ordinal_type dim=0; dim<spaceDim; ++dim) {
383  dofCoords(i_card+d,dim) = internalPoints(j,dim);
384  dofCoeffs(i_card+d,dim) = (d==dim);
385  }
386 
387  tags[i_card+d][0] = spaceDim; // elem dof
388  tags[i_card+d][1] = 0; // elem id
389  tags[i_card+d][2] = spaceDim*j+d; // local dof id
390  tags[i_card+d][3] = spaceDim*numPtsPerCell; // total vert dof
391  }
392  }
393  }
394 
395  // form Vandermonde matrix. Actually, this is the transpose of the VDM,
396  // so we transpose on copy below.
397  Kokkos::DynRankView<scalarType,Kokkos::LayoutLeft,Kokkos::HostSpace>
398  vmat("Hcurl::Tri::In::vmat", card, card),
399  work("Hcurl::Tri::In::work", lwork),
400  ipiv("Hcurl::Tri::In::ipiv", card);
401 
402  //vmat' = V2*V1;
403  for(ordinal_type i=0; i< card; ++i) {
404  for(ordinal_type j=0; j< card; ++j) {
405  scalarType s=0;
406  for(ordinal_type k=0; k< cardVecPn; ++k)
407  s += V2(i,k)*V1(k,j);
408  vmat(i,j) = s;
409  }
410  }
411 
412  ordinal_type info = 0;
413  Teuchos::LAPACK<ordinal_type,scalarType> lapack;
414 
415  lapack.GETRF(card, card,
416  vmat.data(), vmat.stride_1(),
417  (ordinal_type*)ipiv.data(),
418  &info);
419 
420  INTREPID2_TEST_FOR_EXCEPTION( info != 0,
421  std::runtime_error ,
422  ">>> ERROR: (Intrepid2::Basis_HCURL_TRI_In_FEM) lapack.GETRF returns nonzero info." );
423 
424  lapack.GETRI(card,
425  vmat.data(), vmat.stride_1(),
426  (ordinal_type*)ipiv.data(),
427  work.data(), lwork,
428  &info);
429 
430  INTREPID2_TEST_FOR_EXCEPTION( info != 0,
431  std::runtime_error ,
432  ">>> ERROR: (Intrepid2::Basis_HCURL_TRI_In_FEM) lapack.GETRI returns nonzero info." );
433 
434  for (ordinal_type i=0;i<cardVecPn;++i)
435  for (ordinal_type j=0;j<card;++j){
436  scalarType s=0;
437  for(ordinal_type k=0; k< card; ++k)
438  s += V1(i,k)*vmat(k,j);
439  coeffs(i,j) = s;
440  }
441 
442  this->coeffs_ = Kokkos::create_mirror_view(typename SpT::memory_space(), coeffs);
443  Kokkos::deep_copy(this->coeffs_ , coeffs);
444 
445  this->dofCoords_ = Kokkos::create_mirror_view(typename SpT::memory_space(), dofCoords);
446  Kokkos::deep_copy(this->dofCoords_, dofCoords);
447 
448  this->dofCoeffs_ = Kokkos::create_mirror_view(typename SpT::memory_space(), dofCoeffs);
449  Kokkos::deep_copy(this->dofCoeffs_, dofCoeffs);
450 
451 
452  // set tags
453  {
454  // Basis-dependent initializations
455  const ordinal_type posScDim = 0; // position in the tag, counting from 0, of the subcell dim
456  const ordinal_type posScOrd = 1; // position in the tag, counting from 0, of the subcell ordinal
457  const ordinal_type posDfOrd = 2; // position in the tag, counting from 0, of DoF ordinal relative to the subcell
458 
459  ordinal_type_array_1d_host tagView(&tags[0][0], card*tagSize);
460 
461  // Basis-independent function sets tag and enum data in tagToOrdinal_ and ordinalToTag_ arrays:
462  // tags are constructed on host
463  this->setOrdinalTagData(this->tagToOrdinal_,
464  this->ordinalToTag_,
465  tagView,
466  this->basisCardinality_,
467  tagSize,
468  posScDim,
469  posScOrd,
470  posDfOrd);
471  }
472  }
473 } // namespace Intrepid2
474 #endif
static void getReferenceEdgeTangent(Kokkos::DynRankView< refEdgeTangentValueType, refEdgeTangentProperties...> refEdgeTangent, const ordinal_type edgeOrd, const shards::CellTopology parentCell)
Computes constant tangent vectors to edges of 2D or 3D reference cells.
Header file for the Intrepid2::Basis_HGRAD_TRI_Cn_FEM_ORTH class.
Header file for the Intrepid2::CubatureDirectTriDefault class.
Defines direct integration rules on a triangle.
static void getLattice(Kokkos::DynRankView< pointValueType, pointProperties...> points, const shards::CellTopology cellType, const ordinal_type order, const ordinal_type offset=0, const EPointType pointType=POINTTYPE_EQUISPACED)
Computes a lattice of points of a given order on a reference simplex (currently disabled for other ce...
static void mapToReferenceSubcell(Kokkos::DynRankView< refSubcellPointValueType, refSubcellPointProperties...> refSubcellPoints, const Kokkos::DynRankView< paramPointValueType, paramPointProperties...> paramPoints, const ordinal_type subcellDim, const ordinal_type subcellOrd, const shards::CellTopology parentCell)
Computes parameterization maps of 1- and 2-subcells of reference cells.
Basis_HCURL_TRI_In_FEM(const ordinal_type order, const EPointType pointType=POINTTYPE_EQUISPACED)
Constructor.
Kokkos::View< ordinal_type *,typename ExecSpaceType::array_layout, Kokkos::HostSpace > ordinal_type_array_1d_host
View type for 1d host array.
virtual void getCubature(pointViewType cubPoints, weightViewType cubWeights) const
Returns cubature points and weights (return arrays must be pre-sized/pre-allocated).
static constexpr ordinal_type MaxOrder
The maximum reconstruction order.
virtual ordinal_type getNumPoints() const
Returns the number of cubature points.
static ordinal_type getLatticeSize(const shards::CellTopology cellType, const ordinal_type order, const ordinal_type offset=0)
Computes the number of points in a lattice of a given order on a simplex (currently disabled for othe...