Polynomials::Legendre Class Reference

Inheritance diagram for Polynomials::Legendre:

Inheritance graph
[legend]

List of all members.

Public Member Functions

 Legendre (const unsigned int p)

Static Public Member Functions

static std::vector< Polynomial
< double > > 
generate_complete_basis (const unsigned int degree)

Static Private Member Functions

static void compute_coefficients (const unsigned int p)
static const std::vector
< double > & 
get_coefficients (const unsigned int k)

Static Private Attributes

static std::vector< const
std::vector< double > * > 
shifted_coefficients
static std::vector< const
std::vector< double > * > 
recursive_coefficients


Detailed Description

Legendre polynomials of arbitrary degree on [0,1].

Constructing a Legendre polynomial of degree p, the coefficients will be computed by the three-term recursion formula. The coefficients are stored in a static data vector to be available when needed next time. Since the recursion is performed for the interval $[-1,1]$, the polynomials are shifted to $[0,1]$ by the scale and shift functions of Polynomial, afterwards.

Author:
Guido Kanschat, 2000

Constructor & Destructor Documentation

Polynomials::Legendre::Legendre ( const unsigned int  p  ) 

Constructor for polynomial of degree p.


Member Function Documentation

static std::vector<Polynomial<double> > Polynomials::Legendre::generate_complete_basis ( const unsigned int  degree  )  [static]

Return a vector of Legendre polynomial objects of degrees zero through degree, which then spans the full space of polynomials up to the given degree. This function may be used to initialize the TensorProductPolynomials and PolynomialSpace classes.

static void Polynomials::Legendre::compute_coefficients ( const unsigned int  p  )  [static, private]

Compute coefficients recursively.

static const std::vector<double>& Polynomials::Legendre::get_coefficients ( const unsigned int  k  )  [static, private]

Get coefficients for constructor. This way, it can use the non-standard constructor of Polynomial.


Member Data Documentation

std::vector<const std::vector<double> *> Polynomials::Legendre::shifted_coefficients [static, private]

Coefficients for the interval $[0,1]$.

std::vector<const std::vector<double> *> Polynomials::Legendre::recursive_coefficients [static, private]

Vector with already computed coefficients. For each degree of the polynomial, we keep one pointer to the list of coefficients; we do so rather than keeping a vector of vectors in order to simplify programming multithread-safe.


The documentation for this class was generated from the following file:

deal.II documentation generated on Sat Aug 15 16:52:47 2009 by doxygen 1.5.9