58 enum :
int { dimension = 1,
64 static constexpr double coords[2][3]{ {-1.0, 0.0, 0.0}, { 1.0, 0.0, 0.0} };
67 template<
typename Po
intViewType>
68 KOKKOS_INLINE_FUNCTION
70 checkPointInclusion(
const PointViewType &point,
71 const double threshold) {
72 const double minus_one = -1.0 - threshold, plus_one = 1.0 + threshold;
73 return (minus_one <= point(0) && point(0) <= plus_one);
83 enum :
int { dimension = 1,
89 static constexpr double coords[3][3]{ {-1.0, 0.0, 0.0}, { 1.0, 0.0, 0.0}, { 0.0, 0.0, 0.0} };
91 template<
typename Po
intViewType>
92 KOKKOS_INLINE_FUNCTION
94 checkPointInclusion(
const PointViewType &point,
95 const double threshold) {
96 return base_cell_topology_type::checkPointInclusion(point, threshold);
111 enum :
int { dimension = 2,
117 static constexpr double coords[3][3]{ { 0.0, 0.0, 0.0}, { 1.0, 0.0, 0.0}, { 0.0, 1.0, 0.0} };
119 template<
typename Po
intViewType>
120 KOKKOS_INLINE_FUNCTION
122 checkPointInclusion(
const PointViewType &point,
123 const double threshold) {
124 const double distance = max( max( -point(0), -point(1) ), point(0) + point(1) - 1.0 );
125 return distance < threshold;
135 enum :
int { dimension = 2,
141 static constexpr double coords[4][3]{ { 0.0, 0.0, 0.0}, { 1.0, 0.0, 0.0}, { 0.0, 1.0, 0.0}, { 1.0/3.0, 1.0/3.0, 0.0} };
143 template<
typename Po
intViewType>
144 KOKKOS_INLINE_FUNCTION
146 checkPointInclusion(
const PointViewType &point,
147 const double threshold) {
148 return base_cell_topology_type::checkPointInclusion(point, threshold);
158 enum :
int { dimension = 2,
164 static constexpr double coords[6][3]{ { 0.0, 0.0, 0.0}, { 1.0, 0.0, 0.0}, { 0.0, 1.0, 0.0},
165 { 0.5, 0.0, 0.0}, { 0.5, 0.5, 0.0}, { 0.0, 0.5, 0.0} };
167 template<
typename Po
intViewType>
168 KOKKOS_INLINE_FUNCTION
170 checkPointInclusion(
const PointViewType &point,
171 const double threshold) {
172 return base_cell_topology_type::checkPointInclusion(point, threshold);
187 enum :
int { dimension = 2,
193 static constexpr double coords[4][3]{ {-1.0,-1.0, 0.0}, { 1.0,-1.0, 0.0}, { 1.0, 1.0, 0.0}, {-1.0, 1.0, 0.0} };
195 template<
typename Po
intViewType>
196 KOKKOS_INLINE_FUNCTION
198 checkPointInclusion(
const PointViewType &point,
199 const double threshold) {
200 const double minus_one = -1.0 - threshold, plus_one = 1.0 + threshold;
201 return ((minus_one <= point(0) && point(0) <= plus_one) &&
202 (minus_one <= point(1) && point(1) <= plus_one));
212 enum :
int { dimension = 2,
218 static constexpr double coords[8][3]{ {-1.0,-1.0, 0.0}, { 1.0,-1.0, 0.0}, { 1.0, 1.0, 0.0}, {-1.0, 1.0, 0.0},
219 { 0.0,-1.0, 0.0}, { 1.0, 0.0, 0.0}, { 0.0, 1.0, 0.0}, {-1.0, 0.0, 0.0} };
221 template<
typename Po
intViewType>
222 KOKKOS_INLINE_FUNCTION
224 checkPointInclusion(
const PointViewType &point,
225 const double threshold) {
226 return base_cell_topology_type::checkPointInclusion(point, threshold);
236 enum :
int { dimension = 2,
242 static constexpr double coords[9][3]{ {-1.0,-1.0, 0.0}, { 1.0,-1.0, 0.0}, { 1.0, 1.0, 0.0}, {-1.0, 1.0, 0.0},
243 { 0.0,-1.0, 0.0}, { 1.0, 0.0, 0.0}, { 0.0, 1.0, 0.0}, {-1.0, 0.0, 0.0}, { 0.0, 0.0, 0.0} };
245 template<
typename Po
intViewType>
246 KOKKOS_INLINE_FUNCTION
248 checkPointInclusion(
const PointViewType &point,
249 const double threshold) {
250 return base_cell_topology_type::checkPointInclusion(point, threshold);
265 enum :
int { dimension = 3,
271 static constexpr double coords[4][3]{ { 0.0, 0.0, 0.0}, { 1.0, 0.0, 0.0}, { 0.0, 1.0, 0.0}, { 0.0, 0.0, 1.0} };
273 template<
typename Po
intViewType>
274 KOKKOS_INLINE_FUNCTION
276 checkPointInclusion(
const PointViewType &point,
277 const double threshold) {
278 const double distance = max( max(-point(0),-point(1)),
279 max(-point(2), point(0) + point(1) + point(2) - 1) );
281 return distance < threshold;
291 enum :
int { dimension = 3,
297 static constexpr double coords[8][3]{ { 0.0, 0.0, 0.0}, { 1.0, 0.0, 0.0}, { 0.0, 1.0, 0.0}, { 0.0, 0.0, 1.0},
298 { 1/3, 0.0, 1/3}, { 1/3, 1/3, 1/3}, { 1/3, 1/3, 0.0}, { 0.0, 1/3, 1/3} };
300 template<
typename Po
intViewType>
301 KOKKOS_INLINE_FUNCTION
303 checkPointInclusion(
const PointViewType &point,
304 const double threshold) {
305 return base_cell_topology_type::checkPointInclusion(point, threshold);
315 enum :
int { dimension = 3,
321 static constexpr double coords[10][3]{ { 0.0, 0.0, 0.0}, { 1.0, 0.0, 0.0}, { 0.0, 1.0, 0.0}, { 0.0, 0.0, 1.0},
322 { 0.5, 0.0, 0.0}, { 0.5, 0.5, 0.0}, { 0.0, 0.5, 0.0}, { 0.0, 0.0, 0.5}, { 0.5, 0.0, 0.5}, { 0.0, 0.5, 0.5} };
324 template<
typename Po
intViewType>
325 KOKKOS_INLINE_FUNCTION
327 checkPointInclusion(
const PointViewType &point,
328 const double threshold) {
329 return base_cell_topology_type::checkPointInclusion(point, threshold);
339 enum :
int { dimension = 3,
345 static constexpr double coords[11][3]{ { 0.0, 0.0, 0.0}, { 1.0, 0.0, 0.0}, { 0.0, 1.0, 0.0}, { 0.0, 0.0, 1.0},
346 { 0.5, 0.0, 0.0}, { 0.5, 0.5, 0.0}, { 0.0, 0.5, 0.0}, { 0.0, 0.0, 0.5}, { 0.5, 0.0, 0.5}, { 0.0, 0.5, 0.5} };
348 template<
typename Po
intViewType>
349 KOKKOS_INLINE_FUNCTION
351 checkPointInclusion(
const PointViewType &point,
352 const double threshold) {
353 return base_cell_topology_type::checkPointInclusion(point, threshold);
368 enum :
int { dimension = 3,
374 static constexpr double coords[8][3]{ {-1.0,-1.0,-1.0}, { 1.0,-1.0,-1.0}, { 1.0, 1.0,-1.0}, {-1.0, 1.0,-1.0},
375 {-1.0,-1.0, 1.0}, { 1.0,-1.0, 1.0}, { 1.0, 1.0, 1.0}, {-1.0, 1.0, 1.0} };
377 template<
typename Po
intViewType>
378 KOKKOS_INLINE_FUNCTION
380 checkPointInclusion(
const PointViewType &point,
381 const double threshold) {
382 const double minus_one = -1.0 - threshold, plus_one = 1.0 + threshold;
383 return ((minus_one <= point(0) && point(0) <= plus_one) &&
384 (minus_one <= point(1) && point(1) <= plus_one) &&
385 (minus_one <= point(2) && point(2) <= plus_one));
395 enum :
int { dimension = 3,
401 static constexpr double coords[20][3]{ {-1.0,-1.0,-1.0}, { 1.0,-1.0,-1.0}, { 1.0, 1.0,-1.0}, {-1.0, 1.0,-1.0},
402 {-1.0,-1.0, 1.0}, { 1.0,-1.0, 1.0}, { 1.0, 1.0, 1.0}, {-1.0, 1.0, 1.0},
403 { 0.0,-1.0,-1.0}, { 1.0, 0.0,-1.0}, { 0.0, 1.0,-1.0}, {-1.0, 0.0,-1.0},
404 {-1.0,-1.0, 0.0}, { 1.0,-1.0, 0.0}, { 1.0, 1.0, 0.0}, {-1.0, 1.0, 0.0},
405 { 0.0,-1.0, 1.0}, { 1.0, 0.0, 1.0}, { 0.0, 1.0, 1.0}, {-1.0, 0.0, 1.0} };
407 template<
typename Po
intViewType>
408 KOKKOS_INLINE_FUNCTION
410 checkPointInclusion(
const PointViewType &point,
411 const double threshold) {
412 return base_cell_topology_type::checkPointInclusion(point, threshold);
423 enum :
int { dimension = 3,
429 static constexpr double coords[27][3]{ {-1.0,-1.0,-1.0}, { 1.0,-1.0,-1.0}, { 1.0, 1.0,-1.0}, {-1.0, 1.0,-1.0},
430 {-1.0,-1.0, 1.0}, { 1.0,-1.0, 1.0}, { 1.0, 1.0, 1.0}, {-1.0, 1.0, 1.0},
431 { 0.0,-1.0,-1.0}, { 1.0, 0.0,-1.0}, { 0.0, 1.0,-1.0}, {-1.0, 0.0,-1.0},
432 {-1.0,-1.0, 0.0}, { 1.0,-1.0, 0.0}, { 1.0, 1.0, 0.0}, {-1.0, 1.0, 0.0},
433 { 0.0,-1.0, 1.0}, { 1.0, 0.0, 1.0}, { 0.0, 1.0, 1.0}, {-1.0, 0.0, 1.0},
435 { 0.0, 0.0,-1.0}, { 0.0, 0.0, 1.0}, {-1.0, 0.0, 0.0}, { 1.0, 0.0, 0.0}, {0.0,-1.0, 0.0}, {0.0, 1.0, 0.0} };
437 template<
typename Po
intViewType>
438 KOKKOS_INLINE_FUNCTION
440 checkPointInclusion(
const PointViewType &point,
441 const double threshold) {
442 return base_cell_topology_type::checkPointInclusion(point, threshold);
457 enum :
int { dimension = 3,
463 static constexpr double coords[5][3]{ {-1.0,-1.0, 0.0}, { 1.0,-1.0, 0.0}, { 1.0, 1.0, 0.0}, {-1.0, 1.0, 0.0}, { 0.0, 0.0, 1.0} };
465 template<
typename Po
intViewType>
466 KOKKOS_INLINE_FUNCTION
468 checkPointInclusion(
const PointViewType &point,
469 const double threshold) {
470 const double minus_one = -1.0 - threshold, plus_one = 1.0 + threshold, minus_zero = -threshold;
471 const double left = minus_one + point(2);
472 const double right = plus_one - point(2);
473 return ((left <= point(0) && point(0) <= right) &&
474 (left <= point(1) && point(1) <= right) &&
475 (minus_zero <= point(2) && point(2) <= plus_one));
485 enum :
int { dimension = 3,
491 static constexpr double coords[13][3]{ {-1.0,-1.0, 0.0}, { 1.0,-1.0, 0.0}, { 1.0, 1.0, 0.0}, {-1.0, 1.0, 0.0}, { 0.0, 0.0, 1.0},
492 { 0.0,-1.0, 0.0}, { 1.0, 0.0, 0.0}, { 0.0, 1.0, 0.0}, {-1.0, 0.0, 0.0},
493 {-0.5,-0.5, 0.5}, { 0.5,-0.5, 0.5}, { 0.5, 0.5, 0.5}, {-0.5, 0.5, 0.5} };
495 template<
typename Po
intViewType>
496 KOKKOS_INLINE_FUNCTION
498 checkPointInclusion(
const PointViewType &point,
499 const double threshold) {
500 return base_cell_topology_type::checkPointInclusion(point, threshold);
510 enum :
int { dimension = 3,
516 static constexpr double coords[14][3]{ {-1.0,-1.0, 0.0}, { 1.0,-1.0, 0.0}, { 1.0, 1.0, 0.0}, {-1.0, 1.0, 0.0}, { 0.0, 0.0, 1.0},
517 { 0.0,-1.0, 0.0}, { 1.0, 0.0, 0.0}, { 0.0, 1.0, 0.0}, {-1.0, 0.0, 0.0},
518 {-0.5,-0.5, 0.5}, { 0.5,-0.5, 0.5}, { 0.5, 0.5, 0.5}, {-0.5, 0.5, 0.5}, { 0.0, 0.0, 0.0} };
520 template<
typename Po
intViewType>
521 KOKKOS_INLINE_FUNCTION
523 checkPointInclusion(
const PointViewType &point,
524 const double threshold) {
525 return base_cell_topology_type::checkPointInclusion(point, threshold);
540 enum :
int { dimension = 3,
546 static constexpr double coords[6][3]{ { 0.0, 0.0,-1.0}, { 1.0, 0.0,-1.0}, { 0.0, 1.0,-1.0}, { 0.0, 0.0, 1.0}, { 1.0, 0.0, 1.0}, { 0.0, 1.0, 1.0} };
548 template<
typename Po
intViewType>
549 KOKKOS_INLINE_FUNCTION
551 checkPointInclusion(
const PointViewType &point,
552 const double threshold) {
553 const double minus_one = -1.0 - threshold, plus_one = 1.0 + threshold;
554 const double distance = max( max( -point(0), -point(1) ), point(0) + point(1) - 1 );
555 return (distance < threshold && (minus_one <= point(2) && point(2) <= plus_one));
565 enum :
int { dimension = 3,
571 static constexpr double coords[15][3]{ { 0.0, 0.0,-1.0}, { 1.0, 0.0,-1.0}, { 0.0, 1.0,-1.0}, { 0.0, 0.0, 1.0}, { 1.0, 0.0, 1.0}, { 0.0, 1.0, 1.0},
572 { 0.5, 0.0,-1.0}, { 0.5, 0.5,-1.0}, { 0.0, 0.5,-1.0}, { 0.0, 0.0, 0.0}, { 1.0, 0.0, 0.0}, { 0.0, 1.0, 0.0},
573 { 0.5, 0.0, 1.0}, { 0.5, 0.5, 1.0}, { 0.0, 0.5, 1.0} };
575 template<
typename Po
intViewType>
576 KOKKOS_INLINE_FUNCTION
578 checkPointInclusion(
const PointViewType &point,
579 const double threshold) {
580 return base_cell_topology_type::checkPointInclusion(point, threshold);
590 enum :
int { dimension = 3,
596 static constexpr double coords[18][3]{ { 0.0, 0.0,-1.0}, { 1.0, 0.0,-1.0}, { 0.0, 1.0,-1.0}, { 0.0, 0.0, 1.0}, { 1.0, 0.0, 1.0}, { 0.0, 1.0, 1.0},
597 { 0.5, 0.0,-1.0}, { 0.5, 0.5,-1.0}, { 0.0, 0.5,-1.0}, { 0.0, 0.0, 0.0}, { 1.0, 0.0, 0.0}, { 0.0, 1.0, 0.0},
598 { 0.5, 0.0, 1.0}, { 0.5, 0.5, 1.0}, { 0.0, 0.5, 1.0},
599 { 0.5, 0.0, 0.0}, { 0.5, 0.5, 0.0}, { 0.0, 0.5, 0.0} };
602 template<
typename Po
intViewType>
603 KOKKOS_INLINE_FUNCTION
605 checkPointInclusion(
const PointViewType &point,
606 const double threshold) {
607 return base_cell_topology_type::checkPointInclusion(point, threshold);