Loading [MathJax]/extensions/TeX/newcommand.js
 Reference documentation for deal.II version 9.5.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\}}
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages Concepts
Public Member Functions | Private Member Functions | Private Attributes | List of all members
NonMatching::internal::QuadratureGeneratorImplementation::UpThroughDimensionCreator< dim, spacedim > Class Template Reference

#include <deal.II/non_matching/quadrature_generator.h>

Public Member Functions

 UpThroughDimensionCreator (const hp::QCollection< 1 > &q_collection1D, const AdditionalQGeneratorData &additional_data)
 
void generate (const std::vector< std::reference_wrapper< const Function< dim > > > &level_sets, const BoundingBox< dim > &box, const Quadrature< dim - 1 > &low_dim_quadrature, const unsigned int height_function_direction, QPartitioning< dim > &q_partitioning)
 
void set_1D_quadrature (const unsigned int q_index)
 

Private Member Functions

void create_surface_point (const Point< dim - 1 > &point, const double weight, const std::vector< std::reference_wrapper< const Function< dim > > > &level_sets, const BoundingBox< dim > &box, const unsigned int height_function_direction, ImmersedSurfaceQuadrature< dim > &surface_quadrature)
 

Private Attributes

const SmartPointer< const hp::QCollection< 1 > > q_collection1D
 
const AdditionalQGeneratorData additional_data
 
unsigned int q_index
 
std::vector< Functions::PointRestriction< dim - 1 > > point_restrictions
 
RootFinder root_finder
 
std::vector< double > roots
 

Detailed Description

template<int dim, int spacedim>
class NonMatching::internal::QuadratureGeneratorImplementation::UpThroughDimensionCreator< dim, spacedim >

This class is responsible for creating quadrature points for the dim-dimensional quadrature partitioning from an (dim - 1)-dimensional "indefinite" quadrature (see QPartitioning documentation).

To be precise, let [L, R] be the extents of the box in the height function direction and let I \subset \mathbb{R}^{dim-1} be the lower dimensional indefinite region. This class will create quadrature points over I \times [L, R] \subset \mathbb{R}^{dim} and in the case dim=spacedim, points for the surface quadrature.

For each lower dimensional quadrature point, (x_I, w_I) in the indefinite quadrature, we create several 1d-level set functions by restricting \psi_j to x_I. We then partition the interval [L, R] into [y_0, y_1, ..., y_n], where y_0 = L, y_n = R, and the remaining y_i are the roots of the 1d-level set functions in [L, R]. Since the level set functions change sign between the roots, each interval belong to different regions in the quadrature partitioning.

In each interval, [y_i, y_{i+1}], we distribute points according to the 1d-base quadrature, (x_q, w_q) and take the cartesian product with (x_I, w_I) to create the dim-dimensional quadrature points, (X_q, W_q): X_q = x_I \times (y_i + (y_{i+1} - y_i) x_q), W_q = w_I (y_{i+1} - y_i) w_q.

When dim=spacedim, we have a single level set function, \psi. Since we have fulfilled the implicit function theorem, there is a single root y_1 \in [L, R]. The point, x_s = x_I \times y_1, will be added as a point in the surface quadrature. One can show that the correct weight of this point is

w_s = \frac{\|\nabla \psi(x_s)\|}{|\partial_i \psi(x_s)|} w_I,

where i is the height function direction.

Definition at line 828 of file quadrature_generator.h.

Constructor & Destructor Documentation

◆ UpThroughDimensionCreator()

template<int dim, int spacedim>
NonMatching::internal::QuadratureGeneratorImplementation::UpThroughDimensionCreator< dim, spacedim >::UpThroughDimensionCreator ( const hp::QCollection< 1 > &  q_collection1D,
const AdditionalQGeneratorData additional_data 
)

Constructor. Takes the same parameters as QuadratureGenerator.

Definition at line 709 of file quadrature_generator.cc.

Member Function Documentation

◆ generate()

template<int dim, int spacedim>
void NonMatching::internal::QuadratureGeneratorImplementation::UpThroughDimensionCreator< dim, spacedim >::generate ( const std::vector< std::reference_wrapper< const Function< dim > > > &  level_sets,
const BoundingBox< dim > &  box,
const Quadrature< dim - 1 > &  low_dim_quadrature,
const unsigned int  height_function_direction,
QPartitioning< dim > &  q_partitioning 
)

Create dim-dimensional immersed quadratures from the incoming (dim-1)-dimensional quadratures and add these to q_partitioning.

Definition at line 725 of file quadrature_generator.cc.

◆ set_1D_quadrature()

template<int dim, int spacedim>
void NonMatching::internal::QuadratureGeneratorImplementation::UpThroughDimensionCreator< dim, spacedim >::set_1D_quadrature ( const unsigned int  q_index)

Set which 1d-quadrature in the collection passed to the constructor should be used to create the immersed quadratures.

Definition at line 835 of file quadrature_generator.cc.

◆ create_surface_point()

template<int dim, int spacedim>
void NonMatching::internal::QuadratureGeneratorImplementation::UpThroughDimensionCreator< dim, spacedim >::create_surface_point ( const Point< dim - 1 > &  point,
const double  weight,
const std::vector< std::reference_wrapper< const Function< dim > > > &  level_sets,
const BoundingBox< dim > &  box,
const unsigned int  height_function_direction,
ImmersedSurfaceQuadrature< dim > &  surface_quadrature 
)
private

Create a surface quadrature point from the lower-dimensional point and add it to surface_quadrature.

This function is only called when dim=spacedim and there is a single level set function. At this point there should only be a single root in the interval [L, R]

Definition at line 781 of file quadrature_generator.cc.

Member Data Documentation

◆ q_collection1D

template<int dim, int spacedim>
const SmartPointer<const hp::QCollection<1> > NonMatching::internal::QuadratureGeneratorImplementation::UpThroughDimensionCreator< dim, spacedim >::q_collection1D
private

One dimensional quadrature rules used to create the immersed quadratures.

Definition at line 881 of file quadrature_generator.h.

◆ additional_data

template<int dim, int spacedim>
const AdditionalQGeneratorData NonMatching::internal::QuadratureGeneratorImplementation::UpThroughDimensionCreator< dim, spacedim >::additional_data
private

Stores options/settings for the algorithm.

Definition at line 886 of file quadrature_generator.h.

◆ q_index

template<int dim, int spacedim>
unsigned int NonMatching::internal::QuadratureGeneratorImplementation::UpThroughDimensionCreator< dim, spacedim >::q_index
private

Which quadrature rule in the above collection that is used to create the immersed quadrature rules.

Definition at line 892 of file quadrature_generator.h.

◆ point_restrictions

template<int dim, int spacedim>
std::vector<Functions::PointRestriction<dim - 1> > NonMatching::internal::QuadratureGeneratorImplementation::UpThroughDimensionCreator< dim, spacedim >::point_restrictions
private

1d-functions, that are restrictions of each dim-dimensional level set function passed to generate() to some (dim-1)-dimensional point.

Definition at line 898 of file quadrature_generator.h.

◆ root_finder

template<int dim, int spacedim>
RootFinder NonMatching::internal::QuadratureGeneratorImplementation::UpThroughDimensionCreator< dim, spacedim >::root_finder
private

Class used to find the roots of the above 1d-restictions.

Definition at line 903 of file quadrature_generator.h.

◆ roots

template<int dim, int spacedim>
std::vector<double> NonMatching::internal::QuadratureGeneratorImplementation::UpThroughDimensionCreator< dim, spacedim >::roots
private

The roots of the functions in point_restrictions. This will be the values of the height functions, \{H_i(x_I)\} at some lower dimensional quadrature point, x_I \in \mathbb{R}^{dim-1}.

Definition at line 911 of file quadrature_generator.h.


The documentation for this class was generated from the following files: