PolyDiM
C++ library for POLYtopal DIscretization Methods
Loading...
Searching...
No Matches
Polydim::Utilities::GBasis_3D Class Referencefinal

#include <GBasis_3D.hpp>

Public Member Functions

Polydim::Utilities::GBasis_Data Compute (const unsigned int polynomial_degree)
 Build the vector polynomial G-basis of a given degree in 3D.
 
std::vector< Eigen::MatrixXd > VanderGBigOPlus (const Polydim::Utilities::GBasis_Data &data, const Eigen::MatrixXd &vander) const
 Evaluate the Vandermonde matrix of the \(\mathcal{G}_k^\oplus\) block.
 
std::vector< std::vector< Eigen::MatrixXd > > VectorDecomposition (const Polydim::Utilities::GBasis_Data &data) const
 Assemble the vector decomposition into a two-block ( \(\nabla\), \(\oplus\)) form.
 

Member Function Documentation

◆ Compute()

GBasis_Data Polydim::Utilities::GBasis_3D::Compute ( const unsigned int  polynomial_degree)

Build the vector polynomial G-basis of a given degree in 3D.

Assembles all quantities needed to represent the vector polynomial space \([\mathbb{P}_k]^3\) through its decomposition \(\mathcal{G}_k^\nabla \oplus \mathcal{G}_k^\oplus\), where \(\mathcal{G}_k^\nabla = \nabla \mathbb{P}_{k+1}\) and \(\mathcal{G}_k^\oplus = \boldsymbol{x} \times [\mathbb{P}_{k-1}]^3\). The \(\mathcal{G}^\oplus\) block is stored in three parts of widths DimFirstBasis, Nkm1 and Nkm1 (total \(\dim\mathcal{G}_k^\oplus = \) DimFirstBasis + 2*Nkm1).

Parameters
polynomial_degreeMaximum polynomial degree \(k\) of the basis.
Returns
A fully populated Polydim::Utilities::GBasis_Data structure (space dimensions, exponent matrix, and the four-block vector-decomposition maps).

◆ VanderGBigOPlus()

vector< MatrixXd > Polydim::Utilities::GBasis_3D::VanderGBigOPlus ( const Polydim::Utilities::GBasis_Data data,
const Eigen::MatrixXd &  vander 
) const

Evaluate the Vandermonde matrix of the \(\mathcal{G}_k^\oplus\) block.

Builds the three Cartesian components (x, y, z) of the Vandermonde matrix of \(\mathcal{G}_k^\oplus = \boldsymbol{x} \times [\mathbb{P}_{k-1}]^3\), evaluated at the points whose scalar monomial values are provided in vander.

Parameters
dataPrecomputed G-basis data (DimFirstBasis and Nkm1 are used here).
vanderVandermonde matrix of the scalar monomial basis evaluated at the evaluation points (one row per point), from which the linear monomials \(x_1, x_2, x_3\) and the \(\mathbb{P}_{k-1}\) monomials are extracted.
Returns
A vector of three Eigen::MatrixXd (x-, y- and z-components), each of size vander.rows() \(\times\) (data.DimFirstBasis + 2*data.Nkm1), forming the Vandermonde matrix of \(\mathcal{G}_k^\oplus\).

◆ VectorDecomposition()

std::vector< std::vector< Eigen::MatrixXd > > Polydim::Utilities::GBasis_3D::VectorDecomposition ( const Polydim::Utilities::GBasis_Data data) const
inline

Assemble the vector decomposition into a two-block ( \(\nabla\), \(\oplus\)) form.

Repackages the internal four-block storage of data into a compact per-component representation. For each of the three Cartesian components, the result holds two matrices: the gradient block \(\mathcal{G}_k^\nabla\) (size \(N_k \times N_{k+1}\)) and the full \(\mathcal{G}_k^\oplus\) block, obtained by horizontally concatenating the three stored sub-blocks into a single \(N_k \times (\text{DimFirstBasis} + 2N_{k-1})\) matrix.

Parameters
dataPrecomputed G-basis data containing the four-block VectorDecomposition.
Returns
A std::vector of three components, each a pair of Eigen::MatrixXd: index 0 is the \(\nabla\) block, index 1 is the assembled \(\oplus\) block.

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