org.jscience.mathematics.analysis.polynomials
Class GegenbauerDoublePolynomialFactory

java.lang.Object
  extended by org.jscience.mathematics.analysis.polynomials.OrthogonalDoublePolynomialFactory
      extended by org.jscience.mathematics.analysis.polynomials.GegenbauerDoublePolynomialFactory
All Implemented Interfaces:
OrthogonalPolynomialFactory

public final class GegenbauerDoublePolynomialFactory
extends OrthogonalDoublePolynomialFactory

This class implements Gegenbauer polynomials.

Gegenbauer l (lambda) polynomials can be defined by the following recurrence relations:

  T0(X)   = 1
  T1(X)   = 2lX
  (k+1)Tk+1(X) = 2(k+l)X Tk(X) - (k+2l-1)Tk-1(X)
 


Constructor Summary
GegenbauerDoublePolynomialFactory(double lambda)
           
 
Method Summary
 Polynomial[] getFirstTermsPolynomials()
          Initialize the recurrence coefficients for degree 0 and 1.
 double getLambda()
           
 DoublePolynomial getOrthogonalPolynomial(int degree)
          Simple constructor.
 Field.Member[] getRecurrenceCoefficients(int k)
          Initialize the recurrence coefficients.
 
Methods inherited from class org.jscience.mathematics.analysis.polynomials.OrthogonalDoublePolynomialFactory
getOrthogonalPolynomialCoefficients
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

GegenbauerDoublePolynomialFactory

public GegenbauerDoublePolynomialFactory(double lambda)
Method Detail

getLambda

public double getLambda()

getOrthogonalPolynomial

public DoublePolynomial getOrthogonalPolynomial(int degree)
Simple constructor. Build a degree d Chebyshev polynomial

Specified by:
getOrthogonalPolynomial in interface OrthogonalPolynomialFactory
Specified by:
getOrthogonalPolynomial in class OrthogonalDoublePolynomialFactory
Parameters:
degree - degree of the polynomial
Returns:
DOCUMENT ME!

getFirstTermsPolynomials

public Polynomial[] getFirstTermsPolynomials()
Initialize the recurrence coefficients for degree 0 and 1.

Specified by:
getFirstTermsPolynomials in interface OrthogonalPolynomialFactory
Specified by:
getFirstTermsPolynomials in class OrthogonalDoublePolynomialFactory
Returns:
an array which contains the coefficients for degree 0 and 1

getRecurrenceCoefficients

public Field.Member[] getRecurrenceCoefficients(int k)
Initialize the recurrence coefficients. The recurrence relation is (k+1)Tk+1(X) = 2(k+l)X Tk(X) - (k+2l-1)Tk-1(X)

Specified by:
getRecurrenceCoefficients in interface OrthogonalPolynomialFactory
Specified by:
getRecurrenceCoefficients in class OrthogonalDoublePolynomialFactory
Parameters:
k - index of the current step
Returns:
a double array of 3 elements: b2k = double[0] coefficient to initialize (b2k = a2k / a1k) b3k = double[1] coefficient to initialize (b3k = a3k / a1k) b4k = double[2] coefficient to initialize (b4k = a4k / a1k)