Rheolef  7.1
an efficient C++ finite element environment
reference_element.cc
Go to the documentation of this file.
1 
22 #include "reference_element.h"
23 #include "rheolef/point.h"
24 
26 
27 namespace rheolef {
28 
29 namespace edge {
30 #include "edge.icc"
31 } // namespace edge
32 
33 namespace triangle {
34 #include "triangle.icc"
35 } // namespace triangle
36 
37 namespace quadrangle {
38 #include "quadrangle.icc"
39 } // namespace quadrangle
40 
41 namespace tetrahedron {
42 #include "tetrahedron.icc"
43 } // namespace tetrahedron
44 
45 namespace prism {
46 #include "prism.icc"
47 } // namespace prism
48 
49 namespace hexahedron {
50 #include "hexahedron.icc"
51 } // namespace hexahedron
52 
54 
55 // ==============================================================================
56 // generic
57 // ==============================================================================
58 void
60 {
61  _x = variant(name);
62  check_macro (_x != max_variant, "undefined reference element `" << name << "'");
63 }
64 Float
66  return hat_K_measure [hat_K.variant()];
67 }
70 {
71  return reference_element_variant (_name, name);
72 }
75 {
76  size_type variant = 0;
77  for (; variant < max_variant; variant++) {
79  return variant_type(variant);
80  }
81  }
82  error_macro ("undefined "<<dim<<"d reference element with "<<n_vertex << " vertices");
83 }
86 {
87  switch (variant) {
88  case reference_element::p: return 0;
89  case reference_element::e: return 0;
90  case reference_element::t: return 3;
91  case reference_element::q: return 4;
92  case reference_element::T: return 6;
93  case reference_element::P: return 9;
94  case reference_element::H: return 12;
95  default: error_macro ("unexpected element variant `"<<variant<<"'"); return 0;
96  }
97 }
100 {
101  switch (variant) {
102  case reference_element::p: return 0;
103  case reference_element::e: return 0;
104  case reference_element::t: return 0;
105  case reference_element::q: return 0;
106  case reference_element::T: return 4;
107  case reference_element::P: return 5;
108  case reference_element::H: return 6;
109  default: error_macro ("unexpected element variant `"<<variant<<"'"); return 0;
110  }
111 }
114 {
115 #define _RHEOLEF_reference_element_case(VARIANT) \
116  case reference_element::VARIANT: \
117  return reference_element_##VARIANT::n_subgeo (subgeo_dim);
118 
119  switch (variant) {
127  default: error_macro ("unexpected element variant `"<<variant<<"'"); return 0;
128  }
129 #undef _RHEOLEF_reference_element_case
130 }
134  size_type order,
135  size_type subgeo_dim,
136  size_type loc_isid)
137 {
138 #define _RHEOLEF_geo_element_auto_case(VARIANT) \
139  case reference_element::VARIANT: \
140  return reference_element_##VARIANT::subgeo_n_node (order, subgeo_dim, loc_isid);
141 
142  switch (variant) {
150  default: error_macro ("unexpected element variant `"<<variant<<"'"); return 0;
151  }
152 #undef _RHEOLEF_geo_element_auto_case
153 }
157  size_type order,
158  size_type subgeo_dim,
159  size_type loc_isid,
160  size_type loc_jsidnod)
161 {
162 #define _RHEOLEF_geo_element_auto_case(VARIANT) \
163  case reference_element::VARIANT: \
164  return reference_element_##VARIANT::subgeo_local_node (order, subgeo_dim, loc_isid, loc_jsidnod);
165 
166  switch (variant) {
174  default: error_macro ("unexpected element variant `"<<variant<<"'"); return 0;
175  }
176 #undef _RHEOLEF_geo_element_auto_case
177 }
181  size_type order,
182  variant_type subgeo_variant)
183 {
184 #define _RHEOLEF_geo_element_auto_case(VARIANT) \
185  case reference_element::VARIANT: \
186  return reference_element_##VARIANT##_first_inod_by_variant (order, subgeo_variant);
187 
188  switch (variant) {
196  default: error_macro ("unexpected element variant `"<<variant<<"'"); return 0;
197  }
198 #undef _RHEOLEF_geo_element_auto_case
199 }
202 {
203  return reference_element_n_node (variant, order);
204 }
205 void
207  size_type order,
208  std::array<size_type,reference_element::max_variant>& sz)
209 {
210  reference_element_init_local_nnode_by_variant (order, sz);
211 }
212 Float
214 {
215 #define _RHEOLEF_geo_element_auto_case(VARIANT) \
216  case reference_element::VARIANT: \
217  return reference_element_##VARIANT::side_measure (loc_isid);
218 
219  switch (variant()) {
227  default: error_macro ("unexpected element variant `"<<variant()<<"'"); return 0;
228  }
229 #undef _RHEOLEF_geo_element_auto_case
230 }
231 void
233 {
234 #define _RHEOLEF_geo_element_auto_case(VARIANT) \
235  case reference_element::VARIANT: \
236  reference_element_##VARIANT::side_normal (loc_isid, hat_n); break;
237 
238  switch (variant()) {
246  default: error_macro ("unexpected element variant `"<<variant()<<"'");
247  }
248 #undef _RHEOLEF_geo_element_auto_case
249 }
250 const point_basic<Float>&
252 {
253 #define _RHEOLEF_geo_element_auto_case(VARIANT) \
254  case reference_element::VARIANT: \
255  return reference_element_##VARIANT::vertex (iloc);
256 
257  static point_basic<Float> dummy;
258  switch (variant()) {
266  default: error_macro ("unexpected element variant `"<<variant()<<"'"); return dummy;
267  }
268 #undef _RHEOLEF_geo_element_auto_case
269 }
270 // ==============================================================================
271 // point
272 // ==============================================================================
275 {
276  return (side_dim == 0) ? 1 : 0;
277 }
280 {
281  return (side_dim == 0) ? 1 : 0;
282 }
285 {
286  return 0;
287 }
288 // edge 0d-lattice for high order elements, i <= 0
289 // convert to local inod geo_element number for rheolef
292 {
293  return reference_element_p_ilat2loc_inod (order, ilat);
294 }
297  size_type order,
298  size_type subgeo_variant)
299 {
300  return reference_element_p_first_inod_by_variant (order, subgeo_variant);
301 }
302 Float
304 {
305  return 0;
306 }
307 void
309 {
310 }
311 const point_basic<Float>&
313 {
314  static point_basic<Float> dummy;
315  return dummy;
316 }
317 // ==============================================================================
318 // edge
319 // ==============================================================================
322 {
323  switch (side_dim) {
324  case 0: return 2;
325  case 1: return 1;
326  default: return 0;
327  }
328 }
331 {
332  switch (side_dim) {
333  case 0: return 1;
334  case 1: return order+1;
335  default: return 0;
336  }
337 }
340 {
341  switch (side_dim) {
342  case 0: return loc_isid;
343  case 1: return loc_jsidnod;
344  default: return 0;
345  }
346 }
347 // edge 1d-lattice (i) for high order elements, i <= order
348 // convert to local inod geo_element number for rheolef
351 {
352  return reference_element_e_ilat2loc_inod (order, ilat);
353 }
356  size_type order,
357  size_type subgeo_variant)
358 {
359  return reference_element_e_first_inod_by_variant (order, subgeo_variant);
360 }
361 Float
363 {
364  return 1;
365 }
366 void
368 {
369  hat_n[0] = (loc_isid == 0) ? -1 : 1;
370 }
371 const point_basic<Float>&
373 {
374  return edge::vertex[iloc];
375 }
376 // ==============================================================================
377 // triangle
378 // ==============================================================================
381 {
382  switch (side_dim) {
383  case 0: return 3;
384  case 1: return 3;
385  case 2: return 1;
386  default: return 0;
387  }
388 }
391 {
392  switch (side_dim) {
393  case 0: return 1;
394  case 1: return order+1;
395  case 2: return ((order+1)*(order+2))/2;
396  default: return 0;
397  }
398 }
401 {
402  switch (side_dim) {
403  case 0: return loc_isid;
404  case 1: if (loc_jsidnod < 2) return (loc_isid + loc_jsidnod) % 3; // edge-node is a vertex
405  else return (order-1)*loc_isid + loc_jsidnod + 1; // edge-node is edge-internal
406  case 2: return loc_jsidnod;
407  default: return 0;
408  }
409 }
410 // triangle lattice (i,j) for high order elements, i+j <= order
411 // convert to local inod geo_element number for rheolef
414 {
415  return reference_element_t_ilat2loc_inod (order, ilat);
416 }
419  size_type order,
420  size_type subgeo_variant)
421 {
422  return reference_element_t_first_inod_by_variant (order, subgeo_variant);
423 }
424 Float
426 {
427  return (loc_isid != 1) ? 1 : sqrt(Float(2.));
428 }
429 void
431 {
432  switch (loc_isid) {
433  case 0: hat_n = point_basic<Float>( 0,-1); break;
434  case 1: hat_n = point_basic<Float>( 1, 1)/sqrt(Float(2)); break;
435  case 2:
436  default: hat_n = point_basic<Float>(-1,0); break;
437  }
438 }
439 const point_basic<Float>&
441 {
442  return triangle::vertex[iloc];
443 }
444 // ==============================================================================
445 // quadrangle
446 // ==============================================================================
449 {
450  switch (side_dim) {
451  case 0: return 4;
452  case 1: return 4;
453  case 2: return 1;
454  default: return 0;
455  }
456 }
459 {
460  switch (side_dim) {
461  case 0: return 1;
462  case 1: return order+1;
463  case 2: return (order+1)*(order+1);
464  default: return 0;
465  }
466 }
469 {
470  switch (side_dim) {
471  case 0: return loc_isid;
472  case 1: if (loc_jsidnod < 2) return (loc_isid + loc_jsidnod) % 4; // edge-node is a vertex
473  else return (order-1)*loc_isid + loc_jsidnod + 2; // edge-node is edge-internal
474  case 2: return loc_jsidnod;
475  default: return 0;
476  }
477 }
478 // quadrangle lattice (i,j) for high order elements, 0 <= i,j <= order
479 // convert to local inod geo_element number for rheolef
482 {
483  return reference_element_q_ilat2loc_inod (order, ilat);
484 }
487  size_type order,
488  size_type subgeo_variant)
489 {
490  return reference_element_q_first_inod_by_variant (order, subgeo_variant);
491 }
492 Float
494 {
495  return 2;
496 }
497 void
499 {
500  switch (loc_isid) {
501  case 0: hat_n = point_basic<Float>( 0,-1); break;
502  case 1: hat_n = point_basic<Float>( 1, 0); break;
503  case 2: hat_n = point_basic<Float>( 0, 1); break;
504  case 3:
505  default: hat_n = point_basic<Float>(-1, 0); break;
506  }
507 }
508 const point_basic<Float>&
510 {
511  return quadrangle::vertex[iloc];
512 }
513 // ==============================================================================
514 // tetra
515 // ==============================================================================
518 {
519  switch (side_dim) {
520  case 0: return 4;
521  case 1: return 6;
522  case 2: return 4;
523  case 3: return 1;
524  default: return 0;
525  }
526 }
529 {
530  switch (side_dim) {
531  case 0: return 1;
532  case 1: return order+1;
533  case 2: return (order+1)*(order+2)/2;
534  case 3: return ((order+1)*(order+2)*(order+3))/6;
535  default: return 0;
536  }
537 }
540 {
541  switch (side_dim) {
542  case 0: return loc_isid;
543  case 1: if (loc_jsidnod < 2) { // edge-node is a vertex
544  if (loc_isid < 3) return (loc_isid + loc_jsidnod) % 3;
545  else return loc_jsidnod == 0 ? loc_isid - 3 : 3;
546  } else { // edge-node is internal to the edge
547  return loc_isid*(order-1) + loc_jsidnod + 2;
548  }
549  case 2: {
550  if (loc_jsidnod < 3) { // face-node is a vertex
551  if (loc_isid == 3) return loc_jsidnod + 1;
552  if (loc_jsidnod == 0) return 0;
553  if (loc_jsidnod == 2) return loc_isid + 1;
554  return ((loc_isid + 1) % 3) + 1;
555  }
556  // face-node is edge-internal(P2) or face-internal(P3) ; volume-internal(P4) impossible
557  size_type last_edge_node_iloc = 3 + 3*(order-1);
558  if (loc_jsidnod < last_edge_node_iloc) { // edge-internal
559 #ifdef TO_CLEAN
560  extern const size_type geo_element_T_fac2edg_idx [4][3];
561  extern const int geo_element_T_fac2edg_orient [4][3];
562 #endif // TO_CLEAN
563  size_type order1 = order - 1; // avoid div by zero compiler error
564  size_type loc_jedg = (loc_jsidnod-3) / order1;
565  size_type loc_kedg = (loc_jsidnod-3) % order1;
566  if (geo_element_T_fac2edg_orient [loc_isid][loc_jedg] < 0) {
567  loc_kedg = order - loc_kedg - 2;
568  }
569  return (order-1)*geo_element_T_fac2edg_idx [loc_isid][loc_jedg] + loc_kedg + 4;
570  }
571  // face-node is face-internal(P3)
572  size_type ij_loc = (loc_jsidnod - last_edge_node_iloc);
573  return 4 + 6*(order-1) + loc_isid*(order-1)*(order-2)/2 + ij_loc;
574  }
575  case 3: return loc_jsidnod;
576  default: return 0;
577  }
578 }
579 // tetrahedron lattice (i,j,k) for high order elements, i+j+k <= order
580 // convert to local inod geo_element number for rheolef
583 {
584  return reference_element_T_ilat2loc_inod (order, ilat);
585 }
588  size_type order,
589  size_type subgeo_variant)
590 {
591  return reference_element_T_first_inod_by_variant (order, subgeo_variant);
592 }
595 {
596  return geo_element_T_fac2edg_idx [loc_iface][loc_iface_jedg];
597 }
598 int
600 {
601  return geo_element_T_fac2edg_orient [loc_iface][loc_iface_jedg];
602 }
603 Float
605 {
606  return (loc_isid != 3) ? 0.5 : sqrt(Float(3.))/2.;
607 }
608 void
610 {
611  // TODO: generate side_normal automatically from tetrahedron.icc, as it depends upon conventions
612  switch (loc_isid) {
613  case 0: hat_n = point_basic<Float>( 0, 0,-1); break;
614  case 1: hat_n = point_basic<Float>(-1, 0, 0); break;
615  case 2: hat_n = point_basic<Float>( 0,-1, 0); break;
616  case 3:
617  default: hat_n = point_basic<Float>( 1, 1, 1)/sqrt(Float(3)); break;
618  }
619 }
620 const point_basic<Float>&
622 {
623  return tetrahedron::vertex[iloc];
624 }
625 // ==============================================================================
626 // prism
627 // ==============================================================================
630 {
631  switch (side_dim) {
632  case 0: return 6;
633  case 1: return 9;
634  case 2: return 5;
635  case 3: return 1;
636  default: return 0;
637  }
638 }
641 {
642  switch (side_dim) {
643  case 0: return 1;
644  case 1: return order+1;
645  case 2: return (loc_isid < 2) ? (order+1)*(order+2)/2 : (order+1)*(order+1);
646  case 3: return ((order+1)*(order+1)*(order+2))/2;
647  default: return 0;
648  }
649 }
652 {
653  switch (side_dim) {
654  case 0: return loc_isid;
655  case 1: if (loc_jsidnod < 2) { // edge-node is a vertex
656  return prism::edge [loc_isid] [loc_jsidnod];
657  } else { // edge-node is internal to the edge
658  return 6 + loc_isid*(order-1) + (loc_jsidnod - 2);
659  }
660  case 2: {
661  size_type n_vert_on_side = (loc_isid < 2) ? 3 : 4;
662  if (loc_jsidnod < n_vert_on_side) { // face-node is a vertex
663  return prism::face [loc_isid] [loc_jsidnod];
664  }
665  // face-node is edge-internal(P2) or face-internal(P3) ; volume-internal is impossible
666  size_type last_edge_node_iloc = n_vert_on_side + n_vert_on_side*(order-1);
667  if (loc_jsidnod < last_edge_node_iloc) { // edge-internal
668 #ifdef TO_CLEAN
669  extern const size_type geo_element_P_fac2edg_idx [5][4];
670  extern const int geo_element_P_fac2edg_orient [5][4];
671 #endif // TO_CLEAN
672  size_type order1 = order - 1; // avoid div by zero compiler error
673  size_type loc_jedg = (loc_jsidnod - n_vert_on_side) / order1;
674  size_type loc_kedg = (loc_jsidnod - n_vert_on_side) % order1;
675  if (geo_element_P_fac2edg_orient [loc_isid][loc_jedg] < 0) {
676  loc_kedg = order - loc_kedg - 2;
677  }
678  return 6 + (order-1)*geo_element_P_fac2edg_idx [loc_isid][loc_jedg] + loc_kedg;
679  }
680  // face-node is face-internal(P3)
681  size_type ij_loc = (loc_jsidnod - last_edge_node_iloc);
682  size_type shift_prev_faces;
683  if (loc_isid < 2) {
684  shift_prev_faces = loc_isid*(order-1)*(order-2)/2;
685  } else {
686  shift_prev_faces = 2*(order-1)*(order-2)/2 + (loc_isid-2)*(order-1)*(order-1);
687  }
688  return 6 + 9*(order-1) + shift_prev_faces + ij_loc;
689  }
690  case 3: return loc_jsidnod;
691  default: return 0;
692  }
693 }
696 {
697  return reference_element_P_ilat2loc_inod (order, ilat);
698 }
701  size_type order,
702  size_type subgeo_variant)
703 {
704  return reference_element_P_first_inod_by_variant (order, subgeo_variant);
705 }
706 Float
708 {
709  if (loc_isid <= 1) return 0.5; // top and bottom faces
710  if (loc_isid == 3) return 2*sqrt(Float(2)); // largest vertical face
711  return 2; // two others vertical faces
712 }
713 void
715 {
716  fatal_macro ("side_normal: not yet on prism");
717 }
718 const point_basic<Float>&
720 {
721  return prism::vertex[iloc];
722 }
723 // ==============================================================================
724 // hexa
725 // ==============================================================================
726 
729 {
730  switch (side_dim) {
731  case 0: return 8;
732  case 1: return 12;
733  case 2: return 6;
734  case 3: return 1;
735  default: return 0;
736  }
737 }
740 {
741  switch (side_dim) {
742  case 0: return 1;
743  case 1: return order+1;
744  case 2: return (order+1)*(order+1);
745  case 3: return (order+1)*(order+1)*(order+1);
746  default: return 0;
747  }
748 }
751 {
752  switch (side_dim) {
753  case 0: return loc_isid;
754  case 1: if (loc_jsidnod < 2) { // edge-node is a vertex
755  if (loc_isid < 4) return (loc_isid + loc_jsidnod) % 4;
756  else if (loc_isid < 8) return loc_isid - 4 + loc_jsidnod*4;
757  else return loc_jsidnod == 0 ? loc_isid - 4 : (loc_isid - 7)%4 + 4;
758  } else { // edge-node is internal to the edge
759  return loc_isid*(order-1) + loc_jsidnod + 6; // TODO : BUG? +8 a la place de +6 ??
760  }
761  case 2: {
762  if (loc_jsidnod < 4) { // face-node is a vertex
763  return hexahedron::face [loc_isid][loc_jsidnod];
764  }
765  // face-node is edge-internal(P2) or face-internal(P2) ; volume-internal(P2) impossible
766  size_type last_edge_node_iloc = 4 + 4*(order-1);
767  if (loc_jsidnod < last_edge_node_iloc) { // edge-internal
768 #ifdef TO_CLEAN
769  extern const size_t geo_element_H_fac2edg_idx [6][4];
770  extern const int geo_element_H_fac2edg_orient [6][4];
771 #endif // TO_CLEAN
772  size_type order1 = order - 1; // avoid div by zero compiler error
773  size_type loc_jedg = (loc_jsidnod-4) / order1;
774  size_type loc_kedg = (loc_jsidnod-4) % order1;
775  if (geo_element_H_fac2edg_orient [loc_isid][loc_jedg] < 0) {
776  loc_kedg = order - loc_kedg - 2;
777  }
778  return (order-1)*geo_element_H_fac2edg_idx [loc_isid][loc_jedg] + loc_kedg + 8;
779  }
780  // face-node is face-internal(P2)
781  return 8 + 12*(order-1) + (order-1)*(order-1)*loc_isid + (loc_jsidnod - last_edge_node_iloc);
782  }
783  case 3: return loc_jsidnod;
784  default: return 0;
785  }
786 }
787 // edge 0d-lattice for high order elements, i <= 0
788 // convert to local inod geo_element number for rheolef
791 {
792  return reference_element_H_ilat2loc_inod (order, ilat);
793 }
796  size_type order,
797  size_type subgeo_variant)
798 {
799  return reference_element_H_first_inod_by_variant (order, subgeo_variant);
800 }
801 Float
803 {
804  return 2;
805 }
806 void
808 {
809  switch (loc_isid) {
810  case 0: hat_n = point_basic<Float>( 0, 0,-1); break;
811  case 1: hat_n = point_basic<Float>(-1, 0, 0); break;
812  case 2: hat_n = point_basic<Float>( 0,-1, 0); break;
813  case 3: hat_n = point_basic<Float>( 0, 0, 1); break;
814  case 4: hat_n = point_basic<Float>( 1, 0, 0); break;
815  case 5:
816  default: hat_n = point_basic<Float>( 0, 1, 0); break;
817  }
818 }
819 const point_basic<Float>&
821 {
822  return hexahedron::vertex[iloc];
823 }
824 // ==============================================================================
825 
826 } // namespace rheolef
see the Float page for the full documentation
see the edge page for the full documentation
see the hexahedron page for the full documentation
see the prism page for the full documentation
see the quadrangle page for the full documentation
static size_type subgeo_n_node(size_type order, size_type side_dim, size_type loc_isid)
point_basic< size_t >::size_type size_type
static size_type n_subgeo(size_type side_dim)
static size_type subgeo_local_node(size_type order, size_type side_dim, size_type loc_isid, size_type loc_jsidnod)
static Float side_measure(size_type loc_isid)
static const point_basic< Float > & vertex(size_type iloc)
static size_type ilat2loc_inod(size_type order, const point_basic< size_type > &ilat)
static void side_normal(size_type loc_isid, point_basic< Float > &hat_n)
static size_type first_inod_by_variant(size_type order, size_type subgeo_variant)
static size_type subgeo_local_node(size_type order, size_type side_dim, size_type loc_isid, size_type loc_jsidnod)
point_basic< size_t >::size_type size_type
static size_type n_subgeo(size_type side_dim)
static size_type first_inod_by_variant(size_type order, size_type subgeo_variant)
static Float side_measure(size_type loc_isid)
static size_type ilat2loc_inod(size_type order, const point_basic< size_type > &ilat)
static const point_basic< Float > & vertex(size_type iloc)
static void side_normal(size_type loc_isid, point_basic< Float > &hat_n)
static size_type subgeo_n_node(size_type order, size_type side_dim, size_type loc_isid)
static size_type subgeo_local_node(size_type order, size_type side_dim, size_type loc_isid, size_type loc_jsidnod)
static size_type face2edge(size_type loc_iface, size_type loc_iface_jedg)
static size_type n_subgeo(size_type side_dim)
static size_type ilat2loc_inod(size_type order, const point_basic< size_type > &ilat)
point_basic< size_t >::size_type size_type
static size_type subgeo_n_node(size_type order, size_type side_dim, size_type loc_isid)
static size_type first_inod_by_variant(size_type order, size_type subgeo_variant)
static int face2edge_orient(size_type loc_iface, size_type loc_iface_jedg)
static Float side_measure(size_type loc_isid)
static const point_basic< Float > & vertex(size_type iloc)
static void side_normal(size_type loc_isid, point_basic< Float > &hat_n)
static size_type n_subgeo(size_type side_dim)
static size_type subgeo_n_node(size_type order, size_type side_dim, size_type loc_isid)
static size_type subgeo_local_node(size_type order, size_type side_dim, size_type loc_isid, size_type loc_jsidnod)
point_basic< size_t >::size_type size_type
static size_type first_inod_by_variant(size_type order, size_type subgeo_variant)
static size_type ilat2loc_inod(size_type order, const point_basic< size_type > &ilat)
static Float side_measure(size_type loc_isid)
static const point_basic< Float > & vertex(size_type iloc)
static void side_normal(size_type loc_isid, point_basic< Float > &hat_n)
static size_type n_subgeo(size_type side_dim)
static size_type ilat2loc_inod(size_type order, const point_basic< size_type > &ilat)
static size_type first_inod_by_variant(size_type order, size_type subgeo_variant)
point_basic< size_t >::size_type size_type
static size_type subgeo_local_node(size_type order, size_type side_dim, size_type loc_isid, size_type loc_jsidnod)
static Float side_measure(size_type loc_isid)
static const point_basic< Float > & vertex(size_type iloc)
static void side_normal(size_type loc_isid, point_basic< Float > &hat_n)
static size_type subgeo_n_node(size_type order, size_type side_dim, size_type loc_isid)
static size_type subgeo_n_node(size_type order, size_type side_dim, size_type loc_isid)
static size_type n_subgeo(size_type side_dim)
static size_type first_inod_by_variant(size_type order, size_type subgeo_variant)
static size_type subgeo_local_node(size_type order, size_type side_dim, size_type loc_isid, size_type loc_jsidnod)
point_basic< size_t >::size_type size_type
static size_type ilat2loc_inod(size_type order, const point_basic< size_type > &ilat)
static Float side_measure(size_type loc_isid)
static const point_basic< Float > & vertex(size_type iloc)
static void side_normal(size_type loc_isid, point_basic< Float > &hat_n)
static size_type subgeo_n_node(size_type order, size_type side_dim, size_type loc_isid)
static size_type first_inod_by_variant(size_type order, size_type subgeo_variant)
static size_type n_subgeo(size_type side_dim)
point_basic< size_t >::size_type size_type
static size_type subgeo_local_node(size_type order, size_type side_dim, size_type loc_isid, size_type loc_jsidnod)
static size_type ilat2loc_inod(size_type order, const point_basic< size_type > &ilat)
static Float side_measure(size_type loc_isid)
static const point_basic< Float > & vertex(size_type iloc)
static void side_normal(size_type loc_isid, point_basic< Float > &hat_n)
see the reference_element page for the full documentation
void side_normal(size_type loc_isid, point_basic< Float > &hat_n) const
const point_basic< Float > & vertex(size_type iloc) const
static const variant_type H
static const variant_type q
static const variant_type e
static size_type subgeo_local_node(variant_type variant, size_type order, size_type subgeo_dim, size_type loc_isid, size_type loc_jsidnod)
static const variant_type max_variant
static size_type n_sub_edge(variant_type variant)
static void init_local_nnode_by_variant(size_type order, std::array< size_type, reference_element::max_variant > &loc_nnod_by_variant)
static const char _name[max_variant]
static const variant_type p
Float side_measure(size_type loc_isid) const
static size_type n_sub_face(variant_type variant)
static const size_type _n_vertex[max_variant]
variant_type variant() const
static size_type first_inod_by_variant(variant_type variant, size_type order, variant_type subgeo_variant)
static size_type subgeo_n_node(variant_type variant, size_type order, size_type subgeo_dim, size_type loc_isid)
std::vector< int >::size_type size_type
static const size_type _dimension[max_variant]
static size_type n_node(variant_type variant, size_type order)
size_type n_subgeo(size_type subgeo_dim) const
static const variant_type T
static const variant_type P
static const variant_type t
double Float
see the Float page for the full documentation
Definition: Float.h:143
static iorheo::force_initialization dummy
Definition: iorheo.cc:147
see the tetrahedron page for the full documentation
see the triangle page for the full documentation
edge - reference element
const point vertex[n_vertex]
Definition: edge.icc:67
const size_t n_vertex
Definition: edge.icc:66
Expr1::float_type T
Definition: field_expr.h:261
check_macro(expr1.have_homogeneous_space(Xh1), "dual(expr1,expr2); expr1 should have homogeneous space. HINT: use dual(interpolate(Xh, expr1),expr2)")
hexahedron - reference element
const size_t face[n_face][4]
Definition: hexahedron.icc:110
const size_t edge[n_edge][2]
Definition: hexahedron.icc:118
This file is part of Rheolef.
Float measure(reference_element hat_K)
prism - reference element
quadrangle - reference element
#define _RHEOLEF_reference_element_case(VARIANT)
#define _RHEOLEF_geo_element_auto_case(VARIANT)
reference_element - reference element
const reference_element::size_type geo_element_T_fac2edg_idx[4][3]
const int geo_element_H_fac2edg_orient[6][4]
const int geo_element_T_fac2edg_orient[4][3]
const reference_element::size_type geo_element_P_fac2edg_idx[5][4]
const reference_element::size_type geo_element_H_fac2edg_idx[6][4]
const int geo_element_P_fac2edg_orient[5][4]
Definition: sphere.icc:25
tetrahedron - reference element
triangle - reference element