#include <ortho_poly.h>
Public Member Functions | |
virtual | ~OrthogonalPolynomial () |
virtual destructor | |
virtual double | a (const unsigned int k) const =0 |
virtual double | b (const unsigned int k) const =0 |
double | operator() (const unsigned int n, const double x) const |
Polynomial< double > | assemble (const unsigned int n) const |
double | forwardSummation (const Vector< double > &coeffs, const double x) const |
double | adjointSummation (const Vector< double > &coeffs, const double x) const |
Abstract base class for orthogonal polynomials that fulfill a (homogeneous) three-term recursion of the form
p_k(t) = (t-a_k) * p_{k-1}(t) - b_k * p_{k-2}(t), k=1,2,...
where p_{-1}(t)=0, p_0(t)=1.
Due to the specific shape of the recurrence relation, the p_k will have leading coefficient 1. Moreover, we have
a_k = <tp_{k-1}, p_{k-1}> / <p_{k-1}, p_{k-1}> b_k = <tp_{k-1}, p_{k-2}> / <p_{k-2}, p_{k-2}>
virtual double MathTL::OrthogonalPolynomial::a | ( | const unsigned int | k | ) | const [pure virtual] |
the coefficients a_k
Implemented in MathTL::GenMomentsPolynomial, MathTL::LegendrePolynomial, MathTL::ChebyshevPolynomial, and MathTL::Monomial.
double MathTL::OrthogonalPolynomial::adjointSummation | ( | const Vector< double > & | coeffs, |
const double | x | ||
) | const |
adjoint summation of {k=0}^n * p_k(x) remarks:
Polynomial< double > MathTL::OrthogonalPolynomial::assemble | ( | const unsigned int | n | ) | const |
assemble n-th orthogonal polynomial
virtual double MathTL::OrthogonalPolynomial::b | ( | const unsigned int | k | ) | const [pure virtual] |
the coefficients b_k
Implemented in MathTL::GenMomentsPolynomial, MathTL::LegendrePolynomial, MathTL::ChebyshevPolynomial, and MathTL::Monomial.
double MathTL::OrthogonalPolynomial::forwardSummation | ( | const Vector< double > & | coeffs, |
const double | x | ||
) | const |
(trivial) forward summation of {k=0}^n * p_k(x)
double MathTL::OrthogonalPolynomial::operator() | ( | const unsigned int | n, |
const double | x | ||
) | const |
evaluate n-th orthogonal polynomial at x