HArD::Core2D
Hybrid Arbitrary Degree::Core 2D - Library to implement 2D schemes with edge and cell polynomials as unknowns
|
Vector family obtained by tensorization of a scalar family. More...
#include <basis.hpp>
Public Types | |
typedef Eigen::Matrix< double, N, 1 > | FunctionValue |
typedef Eigen::Matrix< double, N, dimspace > | GradientValue |
typedef GradientValue | CurlValue |
typedef double | DivergenceValue |
typedef double | RotorValue |
typedef void | HessianValue |
typedef ScalarFamilyType::GeometricSupport | GeometricSupport |
typedef ScalarFamilyType | AncestorType |
Public Member Functions | |
TensorizedVectorFamily (const ScalarFamilyType &scalar_family) | |
size_t | dimension () const |
Return the dimension of the family. | |
FunctionValue | function (size_t i, const VectorRd &x) const |
Evaluate the i-th basis function at point x. | |
FunctionValue | function (size_t i, size_t iqn, const boost::multi_array< double, 2 > &ancestor_value_quad) const |
Evaluate the i-th basis function at a quadrature point iqn, knowing all the values of ancestor basis functions at the quadrature nodes (provided by eval_quad) | |
GradientValue | gradient (size_t i, const VectorRd &x) const |
Evaluate the gradient of the i-th basis function at point x. | |
GradientValue | gradient (size_t i, size_t iqn, const boost::multi_array< VectorRd, 2 > &ancestor_gradient_quad) const |
Evaluate the gradient of the i-th basis function at a quadrature point iqn, knowing all the gradients of ancestor basis functions at the quadrature nodes (provided by eval_quad) | |
CurlValue | curl (size_t i, const VectorRd &x) const |
Evaluate the curl of the i-th basis function at point x. | |
CurlValue | curl (size_t i, size_t iqn, const boost::multi_array< VectorRd, 2 > &ancestor_gradient_quad) const |
Evaluate the curl of the i-th basis function at a quadrature point iqn, knowing all the gradients of ancestor basis functions at the quadrature nodes (provided by eval_quad) | |
DivergenceValue | divergence (size_t i, const VectorRd &x) const |
Evaluate the divergence of the i-th basis function at point x. | |
DivergenceValue | divergence (size_t i, size_t iqn, const boost::multi_array< VectorRd, 2 > &ancestor_gradient_quad) const |
Evaluate the divergence of the i-th basis function at a quadrature point iqn, knowing all the gradients of ancestor basis functions at the quadrature nodes (provided by eval_quad) | |
RotorValue | rotor (size_t i, const VectorRd &x) const |
Evaluate the scalar rotor of the i-th basis function at point x. | |
RotorValue | rotor (size_t i, size_t iqn, const boost::multi_array< VectorRd, 2 > &ancestor_gradient_quad) const |
Evaluate the scalar rotor of the i-th basis function at a quadrature point iqn, knowing all the gradients of ancestor basis functions at the quadrature nodes (provided by eval_quad) | |
constexpr const ScalarFamilyType & | ancestor () const |
Return the ancestor (family that has been tensorized) | |
size_t | max_degree () const |
Returns the maximum degree of the basis functions. | |
Static Public Attributes | |
static constexpr const TensorRankE | tensorRank = Vector |
static constexpr const bool | hasAncestor = true |
static const bool | hasFunction = ScalarFamilyType::hasFunction |
static const bool | hasGradient = ScalarFamilyType::hasGradient |
static const bool | hasDivergence = ( ScalarFamilyType::hasGradient && N==dimspace ) |
static const bool | hasRotor = ( ScalarFamilyType::hasGradient && N==dimspace ) |
static const bool | hasCurl = ( ScalarFamilyType::hasGradient && N==dimspace ) |
static const bool | hasHessian = false |
Vector family obtained by tensorization of a scalar family.
The tensorization is done the following way: if \((f_1,...,f_r)\) is the family of scalar functions, the tensorized family of rank N is given by (where all vectors are columns of size N):
\(\left(\begin{array}{c}f_1\\0\\\vdots\\0\end{array}\right)\); \(\left(\begin{array}{c}f_2\\0\\\vdots\\0\end{array}\right)\);...; \(\left(\begin{array}{c}f_r\\0\\\vdots\\0\end{array}\right)\); \(\left(\begin{array}{c}0\\f_1\\0\\\vdots\\0\end{array}\right)\); \(\left(\begin{array}{c}0\\f_2\\0\\\vdots\\0\end{array}\right)\);...; \(\left(\begin{array}{c}0\\f_r\\0\\\vdots\\0\end{array}\right)\);...; \(\left(\begin{array}{c}0\\\vdots\\0\\f_1\end{array}\right)\);...; \(\left(\begin{array}{c}0\\\vdots\\0\\f_r\end{array}\right)\)
The gradient values are therefore matrices of size N*r, where the gradients of the scalar functions are put in rows:
\(\left(\begin{array}{c}(\nabla f_1)^t\\0\\\vdots\\0\end{array}\right)\); \(\left(\begin{array}{c}(\nabla f_2)^t\\0\\\vdots\\0\end{array}\right)\);...; \(\left(\begin{array}{c}(\nabla f_r)^t\\0\\\vdots\\0\end{array}\right)\); \(\left(\begin{array}{c}0\\(\nabla f_1)^t\\0\\\vdots\\0\end{array}\right)\); \(\left(\begin{array}{c}0\\(\nabla f_2)^t\\0\\\vdots\\0\end{array}\right)\);...; \(\left(\begin{array}{c}0\\(\nabla f_r)^t\\0\\\vdots\\0\end{array}\right)\);...; \(\left(\begin{array}{c}0\\\vdots\\0\\(\nabla f_1)^t\end{array}\right)\);...; \(\left(\begin{array}{c}0\\\vdots\\0\\(\nabla f_r)^t\end{array}\right)\)