File basis.hpp

Enums

enum BasisType

Values:

enumerator DERIVATIVE
enumerator FUNCTION
enumerator INTEGRAL

Functions

template<typename T>
void degree_doubling_chebyshev(std::vector<T> &coeffs, std::vector<T> &result)
template<typename NT>
struct PolynomialBasis

Public Functions

inline PolynomialBasis(BasisType basis_type_)
inline NT operator()(NT t, const NT t0, unsigned int j, const unsigned int ord) const

Public Members

BasisType basis_type
template<typename NT>
struct Polynomial

Public Functions

inline Polynomial(std::vector<NT> coeffs_, BasisType basis_type_)
inline NT operator()(NT t, NT t0, unsigned int j = -1, unsigned int ord = -1)

Public Members

BasisType basis_type
PolynomialBasis<NT> basis
std::vector<NT> coeffs
NT result
unsigned int ord

Public Static Functions

static inline std::vector<NT> convolve(std::vector<NT> const &p, std::vector<NT> const &q)
static inline std::vector<NT> multi_convolve(std::vector<std::vector<NT>> &seq)
template<typename NT, typename bfunc>
struct RationalFunctionBasis

Public Functions

inline RationalFunctionBasis(bfunc num, bfunc grad_num, bfunc den, bfunc grad_den, BasisType basis_type_)
inline NT operator()(NT t, NT t0, unsigned int j, unsigned int ord)

Public Members

bfunc p
bfunc q
bfunc grad_p
bfunc grad_q
NT reg = 1e-6
BasisType basis_type
NT num
NT den
NT grad_num
NT grad_den
template<typename NT, typename VT>
struct LagrangePolynomial

Public Functions

inline LagrangePolynomial()
inline int order() const
inline void set_nodes(VT nodes_)
inline void set_basis(int basis_)
inline void set_coeffs(VT coeffs_)
inline NT operator()(NT t) const

Public Members

VT coeffs
VT nodes
int basis = -1