16#ifndef BasisFunction_included
17#define BasisFunction_included
19#include <Quadrature_base.h>
21#include <Domaine_DG.h>
22#include <Matrice_Dense.h>
23#include <Matrice_Morse.h>
98 Cerr <<
"[DG] indices_glob_elem is incorrectly sized" << finl;
107 void eval_bfunc(
const DoubleTab& coord,
const int& nelem, DoubleTab& fbasis)
const;
130 void orthonormalize(
const int& nelem,
const int& nb_pts_integ, DoubleTab& fbasis)
const;
132 void gramSchmidt(DoubleTab& fbase,
const Quadrature_base& quad,
const int& num_elem,
const int& current_indice,
const int& nb_pts_integ,
const double& volume,
int index);
void eval_grad_bfunc(const Quadrature_base &quad, const int &nelem, DoubleTab &fbasis) const
Evaluates the gradients of all basis functions at the element quadrature points.
void eval_grad_bfunc_on_facets(const Quadrature_base &quad, const int &nelem, const int &num_face, DoubleTab &grad_fbasis) const
Evaluates the gradients of all basis functions of element nelem at the quadrature points of face num_...
void orthonormalize(const int &nelem, const int &nb_pts_integ, DoubleTab &fbasis) const
Applies the pre-computed Gram-Schmidt transition matrix to a raw basis evaluation.
Matrice_Morse transition_matrix_
void eval_bfunc_on_facets(const Quadrature_base &quad, const int &nelem, const int &num_face, DoubleTab &grad_fbasis) const
Evaluates all basis functions of element nelem at the quadrature points of face num_face.
void allocate_transition_matrix()
Allocates the sparsity pattern of the block-diagonal transition matrix.
const DoubleTab & get_eta_elem() const
const IntTab & indices_glob_elem(const int dim=1) const
void eval_bfunc(const Quadrature_base &quad, const int &nelem, DoubleTab &fbasis) const
Evaluates all basis functions at the element quadrature points.
void eval_div_bfunc(const Quadrature_base &quad, const int &nelem, DoubleTab &div_fbasis) const
const DoubleTab & get_eta_facet() const
const int & nb_bfunc() const
void gramSchmidt(DoubleTab &fbase, const Quadrature_base &quad, const int &num_elem, const int ¤t_indice, const int &nb_pts_integ, const double &volume, int index)
Recursively orthonormalizes the local basis using the modified Gram-Schmidt process.
void initialize(const Domaine_DG &dom, const int &order, const bool &gram_schmidt)
Initializes the basis function object for a given DG domain and polynomial order.
void build_transition_matrix()
Computes and stores the Gram-Schmidt orthonormalization coefficients.
const int & get_default_quadrature_order() const
IntTab indices_glob_elem_3D_
const int & get_order() const
IntTab indices_glob_elem_2D_
void compute_stab_param()
Computes the SIP penalty stabilization parameters eta_elem and eta_facet.
const Matrice_Dense eval_invMassMatrix(const Quadrature_base &quad, const int &nelem) const
Computes the inverse of the local L2 mass matrix for element nelem.
IntTab indices_glob_elem_
const Matrice_Dense build_local_mass_matrix(const Quadrature_base &quad, const int nelem) const
Computes the local L2 mass matrix M_ij = integral of phi_i * phi_j on element nelem.
void eval_div_bfunc_on_facets(const Quadrature_base &quad, const int &nelem, const int &num_face, DoubleTab &div_fbasis) const
Evaluates the divergence of the basis functions at the quadrature points of face num_face.
Classe Matrice_Morse Represente une matrice M (creuse), non necessairement carree.