deal.II version 9.8.0
\(\newcommand{\dealvcentcolon}{\mathrel{\mathop{:}}}\) \(\newcommand{\dealcoloneq}{\dealvcentcolon\mathrel{\mkern-1.2mu}=}\) \(\newcommand{\jump}[1]{\left[\!\left[ #1 \right]\!\right]}\) \(\newcommand{\average}[1]{\left\{\!\left\{ #1 \right\}\!\right\}}\)
Loading...
Searching...
No Matches
qprojector.h
Go to the documentation of this file.
1// -----------------------------------------------------------------------------
2//
3// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception OR LGPL-2.1-or-later
4// Copyright (C) 2005 - 2026 by the deal.II authors
5//
6// This file is part of the deal.II library.
7//
8// Detailed license information governing the source code and contributions
9// can be found in LICENSE.md and CONTRIBUTING.md at the top level directory.
10//
11// -----------------------------------------------------------------------------
12
13#ifndef dealii_qprojector_h
14#define dealii_qprojector_h
15
16
17#include <deal.II/base/config.h>
18
21
23
25
26#ifndef DOXYGEN
27template <int dim>
28class ReferenceCell;
29#endif
30
35
66template <int dim>
68{
69public:
74 using SubQuadrature = Quadrature<dim - 1>;
75
85 "Use the version of this function which takes a combined_orientation "
86 "argument instead.")
87 static void
88 project_to_face(const ReferenceCell<dim> &reference_cell,
89 const SubQuadrature &quadrature,
90 const unsigned int face_no,
91 std::vector<Point<dim>> &q_points);
92
102 "Use the version of this function which takes a combined_orientation "
103 "argument instead.")
104 static Quadrature<dim>
105 project_to_face(const ReferenceCell<dim> &reference_cell,
106 const SubQuadrature &quadrature,
107 const unsigned int face_no);
108
119 "Use the version of project_to_face() which takes a combined_orientation "
120 "argument instead.")
121 static Quadrature<dim>
122 project_to_oriented_face(const ReferenceCell<dim> &reference_cell,
123 const SubQuadrature &quadrature,
124 const unsigned int face_no,
125 const bool face_orientation,
126 const bool face_flip,
127 const bool face_rotation);
128
134 static Quadrature<dim>
135 project_to_face(const ReferenceCell<dim> &reference_cell,
136 const SubQuadrature &quadrature,
137 const unsigned int face_no,
138 const types::geometric_orientation combined_orientation);
139
153 "Use the version of project_to_subface() which takes a "
154 "combined_orientation argument instead.")
155 static void
156 project_to_subface(const ReferenceCell<dim> &reference_cell,
157 const SubQuadrature &quadrature,
158 const unsigned int face_no,
159 const unsigned int subface_no,
160 std::vector<Point<dim>> &q_points,
161 const RefinementCase<dim - 1> &ref_case =
163
181 "Use the version of project_to_subface() which takes a "
182 "combined_orientation argument instead.")
183 static Quadrature<dim>
184 project_to_subface(const ReferenceCell<dim> &reference_cell,
185 const SubQuadrature &quadrature,
186 const unsigned int face_no,
187 const unsigned int subface_no,
188 const RefinementCase<dim - 1> &ref_case =
190
204 "Use the version of project_to_subface() which takes a "
205 "combined_orientation argument instead.")
206 static Quadrature<dim>
207 project_to_oriented_subface(const ReferenceCell<dim> &reference_cell,
208 const SubQuadrature &quadrature,
209 const unsigned int face_no,
210 const unsigned int subface_no,
211 const bool face_orientation,
212 const bool face_flip,
213 const bool face_rotation,
214 const internal::SubfaceCase<dim> ref_case);
215
225 static Quadrature<dim>
226 project_to_subface(const ReferenceCell<dim> &reference_cell,
227 const SubQuadrature &quadrature,
228 const unsigned int face_no,
229 const unsigned int subface_no,
230 const types::geometric_orientation combined_orientation,
231 const RefinementCase<dim - 1> &ref_case);
232
250 static Quadrature<dim>
251 project_to_all_faces(const ReferenceCell<dim> &reference_cell,
252 const hp::QCollection<dim - 1> &quadrature);
253
258 static Quadrature<dim>
259 project_to_all_faces(const ReferenceCell<dim> &reference_cell,
260 const Quadrature<dim - 1> &quadrature);
261
275 static Quadrature<dim>
276 project_to_all_subfaces(const ReferenceCell<dim> &reference_cell,
277 const SubQuadrature &quadrature);
278
291 static Quadrature<dim>
292 project_to_child(const ReferenceCell<dim> &reference_cell,
293 const Quadrature<dim> &quadrature,
294 const unsigned int child_no);
295
307 static Quadrature<dim>
308 project_to_all_children(const ReferenceCell<dim> &reference_cell,
309 const Quadrature<dim> &quadrature);
310
315 static Quadrature<dim>
316 project_to_line(const ReferenceCell<dim> &reference_cell,
317 const Quadrature<1> &quadrature,
318 const Point<dim> &p1,
319 const Point<dim> &p2);
320
333 {
334 public:
341
348 static DataSetDescriptor
349 cell();
350
365 "Use the version of this function which takes a combined_orientation "
366 "argument instead.")
367 static DataSetDescriptor
368 face(const ReferenceCell<dim> &reference_cell,
369 const unsigned int face_no,
370 const bool face_orientation,
371 const bool face_flip,
372 const bool face_rotation,
373 const unsigned int n_quadrature_points);
374
383 static DataSetDescriptor
384 face(const ReferenceCell<dim> &reference_cell,
385 const unsigned int face_no,
386 const types::geometric_orientation combined_orientation,
387 const unsigned int n_quadrature_points);
388
398 "Use the version of this function which takes a combined_orientation "
399 "argument instead.")
400 static DataSetDescriptor
401 face(const ReferenceCell<dim> &reference_cell,
402 const unsigned int face_no,
403 const bool face_orientation,
404 const bool face_flip,
405 const bool face_rotation,
406 const hp::QCollection<dim - 1> &quadrature);
407
414 static DataSetDescriptor
415 face(const ReferenceCell<dim> &reference_cell,
416 const unsigned int face_no,
417 const types::geometric_orientation combined_orientation,
418 const hp::QCollection<dim - 1> &quadrature);
419
436 "Use the version of this function which takes a combined_orientation "
437 "argument instead.")
438 static DataSetDescriptor
439 subface(const ReferenceCell<dim> &reference_cell,
440 const unsigned int face_no,
441 const unsigned int subface_no,
442 const bool face_orientation,
443 const bool face_flip,
444 const bool face_rotation,
445 const unsigned int n_quadrature_points,
446 const internal::SubfaceCase<dim> ref_case =
448
461 static DataSetDescriptor
462 subface(const ReferenceCell<dim> &reference_cell,
463 const unsigned int face_no,
464 const unsigned int subface_no,
465 const types::geometric_orientation combined_orientation,
466 const unsigned int n_quadrature_points,
467 const internal::SubfaceCase<dim> ref_case =
469
476 operator unsigned int() const;
477
478 private:
482 const unsigned int dataset_offset;
483
488 DataSetDescriptor(const unsigned int dataset_offset);
489 };
490};
491
493
494
495// ------------------- inline and template functions ----------------
496
497
498
499template <int dim>
504
505
506template <int dim>
510
511
512
513template <int dim>
519
520
521
522template <int dim>
524{
525 return dataset_offset;
526}
527
528
529
530template <int dim>
532 const ReferenceCell<dim> &reference_cell,
533 const Quadrature<dim - 1> &quadrature)
534{
535 return project_to_all_faces(reference_cell,
536 hp::QCollection<dim - 1>(quadrature));
537}
538
539
540/* -------------- declaration of explicit specializations ------------- */
541
542#ifndef DOXYGEN
543
544
545template <>
546void
548 const Quadrature<0> &,
549 const unsigned int,
550 std::vector<Point<1>> &);
551template <>
552void
554 const Quadrature<1> &quadrature,
555 const unsigned int face_no,
556 std::vector<Point<2>> &q_points);
557template <>
558void
560 const Quadrature<2> &quadrature,
561 const unsigned int face_no,
562 std::vector<Point<3>> &q_points);
563
564template <>
565void
567 const Quadrature<0> &,
568 const unsigned int,
569 const unsigned int,
570 std::vector<Point<1>> &,
571 const RefinementCase<0> &);
572template <>
573void
575 const Quadrature<1> &quadrature,
576 const unsigned int face_no,
577 const unsigned int subface_no,
578 std::vector<Point<2>> &q_points,
579 const RefinementCase<1> &);
580template <>
581void
583 const Quadrature<2> &quadrature,
584 const unsigned int face_no,
585 const unsigned int subface_no,
586 std::vector<Point<3>> &q_points,
587 const RefinementCase<2> &face_ref_case);
588
589
590#endif // DOXYGEN
592
593#endif
Definition point.h:111
Class storing the offset index into a Quadrature rule created by project_to_all_faces() or project_to...
Definition qprojector.h:333
const unsigned int dataset_offset
Definition qprojector.h:482
static DataSetDescriptor cell()
Definition qprojector.h:515
static DataSetDescriptor subface(const ReferenceCell< dim > &reference_cell, const unsigned int face_no, const unsigned int subface_no, const bool face_orientation, const bool face_flip, const bool face_rotation, const unsigned int n_quadrature_points, const internal::SubfaceCase< dim > ref_case=internal::SubfaceCase< dim >::case_isotropic)
static DataSetDescriptor face(const ReferenceCell< dim > &reference_cell, const unsigned int face_no, const bool face_orientation, const bool face_flip, const bool face_rotation, const unsigned int n_quadrature_points)
Class which transforms dim - 1-dimensional quadrature rules to dim-dimensional face quadratures.
Definition qprojector.h:68
static Quadrature< dim > project_to_all_faces(const ReferenceCell< dim > &reference_cell, const hp::QCollection< dim - 1 > &quadrature)
static Quadrature< dim > project_to_oriented_face(const ReferenceCell< dim > &reference_cell, const SubQuadrature &quadrature, const unsigned int face_no, const bool face_orientation, const bool face_flip, const bool face_rotation)
static void project_to_subface(const ReferenceCell< dim > &reference_cell, const SubQuadrature &quadrature, const unsigned int face_no, const unsigned int subface_no, std::vector< Point< dim > > &q_points, const RefinementCase< dim - 1 > &ref_case=RefinementCase< dim - 1 >::isotropic_refinement)
static Quadrature< dim > project_to_all_subfaces(const ReferenceCell< dim > &reference_cell, const SubQuadrature &quadrature)
static void project_to_face(const ReferenceCell< dim > &reference_cell, const SubQuadrature &quadrature, const unsigned int face_no, std::vector< Point< dim > > &q_points)
static Quadrature< dim > project_to_all_children(const ReferenceCell< dim > &reference_cell, const Quadrature< dim > &quadrature)
static Quadrature< dim > project_to_line(const ReferenceCell< dim > &reference_cell, const Quadrature< 1 > &quadrature, const Point< dim > &p1, const Point< dim > &p2)
static Quadrature< dim > project_to_oriented_subface(const ReferenceCell< dim > &reference_cell, const SubQuadrature &quadrature, const unsigned int face_no, const unsigned int subface_no, const bool face_orientation, const bool face_flip, const bool face_rotation, const internal::SubfaceCase< dim > ref_case)
Quadrature< dim - 1 > SubQuadrature
Definition qprojector.h:74
static Quadrature< dim > project_to_child(const ReferenceCell< dim > &reference_cell, const Quadrature< dim > &quadrature, const unsigned int child_no)
#define DEAL_II_NAMESPACE_OPEN
Definition config.h:38
#define DEAL_II_DEPRECATED_WITH_COMMENT(comment)
Definition config.h:287
#define DEAL_II_NAMESPACE_CLOSE
Definition config.h:39
Definition hp.h:115
STL namespace.
Definition types.h:30
std::uint8_t geometric_orientation
Definition types.h:38