35#ifndef NEKTAR_LIB_UTILIITIES_FOUNDATIONS_BASIS_H
36#define NEKTAR_LIB_UTILIITIES_FOUNDATIONS_BASIS_H
269 inline const std::shared_ptr<NekMatrix<NekDouble>> &
GetD(
275 const std::shared_ptr<NekMatrix<NekDouble>>
GetI(
284 "Interpolation only to other 1d basis");
#define ASSERTL0(condition, msg)
#define NEKERROR(type, msg)
Assert Level 0 – Fundamental assert which is used whether in FULLDEBUG, DEBUG or OPT compilation mode...
#define LIB_UTILITIES_EXPORT
Represents a basis of a given type.
const Array< OneD, const NekDouble > & GetBaryWeights() const
int GetNumModes() const
Return order of basis from the basis specification.
Array< OneD, NekDouble > m_dbdata
Derivative Basis definition.
Basis()=delete
Private default constructor.
int GetTotNumModes() const
Return total number of modes from the basis specification.
const Array< OneD, const NekDouble > & GetBdata() const
Return basis definition array m_bdata.
static std::shared_ptr< Basis > Create(const BasisKey &bkey)
Returns a new instance of a Basis with given BasisKey.
const Array< OneD, const NekDouble > & GetDbdata() const
Return basis definition array m_dbdata.
PointsKey GetPointsKey() const
Return the points specification for the basis.
bool Collocation() const
Determine if basis has collocation properties.
PointsSharedPtr m_points
Set of points.
int GetTotNumPoints() const
Return total number of points from the basis specification.
PointsType GetPointsType() const
Return the type of quadrature.
void GetZW(Array< OneD, const NekDouble > &z, Array< OneD, const NekDouble > &w) const
BasisKey m_basisKey
Basis specification.
const Array< OneD, const NekDouble > & GetZ() const
const BasisKey GetBasisKey() const
Returns the specification for the Basis.
BasisType GetBasisType() const
Return the type of expansion basis.
const std::shared_ptr< NekMatrix< NekDouble > > & GetD(Direction dir=xDir) const
const std::shared_ptr< NekMatrix< NekDouble > > GetI(const Array< OneD, const NekDouble > &x)
int GetNumPoints() const
Return the number of points from the basis specification.
std::shared_ptr< NekMatrix< NekDouble > > CalculateInterpMatrix(const BasisKey &tbasis0)
Calculate the interpolation Matrix for coefficient from one base (m_basisKey) to another (tbasis0)
bool ExactIprodInt() const
Determine if basis has exact integration for inner product.
NekManager< BasisKey, NekMatrix< NekDouble >, BasisKey::opLess > m_InterpManager
virtual ~Basis()
Destructor.
void GenBasis()
Generate appropriate basis and their derivatives.
Array< OneD, NekDouble > m_bdata
Basis definition.
static bool initBasisManager
const Array< OneD, const NekDouble > & GetW() const
const std::shared_ptr< NekMatrix< NekDouble > > GetI(const BasisKey &bkey)
Describes the specification for a Basis.
int GetNumPoints() const
Return points order at which basis is defined.
friend bool operator<(const BasisKey &lhs, const BasisKey &rhs)
friend bool operator==(const BasisKey &x, const BasisKey &y)
Overloaded Operators.
PointsKey m_pointsKey
Points specification.
BasisType GetBasisType() const
Return type of expansion basis.
BasisKey & operator=(const BasisKey &)=default
Assignment operator.
bool SameExp(const BasisKey &x) const
Determine if basis expansion x matches this.
friend bool operator!=(const BasisKey &x, const BasisKey &y)
PointsKey GetPointsKey() const
Return distribution of points.
size_t m_nummodes
Expansion order.
bool SamePoints(const BasisKey &x) const
Determine if quadrature of expansion x matches this.
BasisKey(const BasisType btype, const size_t nummodes, const PointsKey pkey)
Constructor.
int GetTotNumPoints() const
int GetTotNumModes() const
BasisKey(const BasisKey &B)=default
Copy constructor.
int GetNumModes() const
Returns the order of the basis.
PointsType GetPointsType() const
Return type of quadrature.
BasisType m_basistype
Expansion type.
bool Collocation() const
Determine if basis has collocation properties.
bool ExactIprodInt() const
Determine if basis has exact integration for inner product.
Defines a specification for a set of points.
size_t GetPointsDim() const
PointsType GetPointsType() const
size_t GetTotNumPoints() const
size_t GetNumPoints() const
static BasisSharedPtr NullBasisSharedPtr
std::shared_ptr< Basis > BasisSharedPtr
std::shared_ptr< Points< NekDouble > > PointsSharedPtr
static const BasisKey NullBasisKey(eNoBasisType, 0, NullPointsKey)
Defines a null basis with no type or points.
bool operator<(const BasisKey &lhs, const BasisKey &rhs)
bool operator>(const BasisKey &lhs, const BasisKey &rhs)
std::ostream & operator<<(std::ostream &os, const BasisKey &rhs)
static Array< OneD, BasisSharedPtr > NullBasisSharedPtr1DArray
@ eModified_B
Principle Modified Functions .
@ eGauss_Lagrange
Lagrange Polynomials using the Gauss points.
@ eOrtho_A
Principle Orthogonal Functions .
@ eModified_C
Principle Modified Functions .
@ eGLL_Lagrange
Lagrange for SEM basis .
@ eFourierSingleMode
Fourier ModifiedExpansion with just the first mode .
@ eChebyshev
Chebyshev Polynomials.
@ eOrtho_C
Principle Orthogonal Functions .
@ eModifiedPyr_C
Principle Modified Functions.
@ eOrtho_B
Principle Orthogonal Functions .
@ eModified_A
Principle Modified Functions .
@ eFourierHalfModeIm
Fourier Modified expansions with just the imaginary part of the first mode .
@ eFourierHalfModeRe
Fourier Modified expansions with just the real part of the first mode .
@ eOrthoPyr_C
Principle Orthogonal Functions .
@ eFourier
Fourier Expansion .
static const PointsKey NullPointsKey(0, eNoPointsType)
std::vector< double > w(NPUPPER)
std::vector< double > z(NPUPPER)
bool operator()(const BasisKey &lhs, const BasisKey &rhs) const