Since the OddPolynomial is a Function, the derivatives
can be obtained as well.
The parameter interface (see
FunctionParam class),
is used to provide an interface to the
Fitting classes.
This class is in general used implicitly by the OddPolynomial
class only.
Makes a polynomial of the given order, with all coeficcients set to
zero.
Make this a copy of other (deep copy).
Destructor
Comparisons.
OddPolynomials are equal if they are the same order
What is the order of the polynomial, i.e. maximum exponent of "x".
Set the which'th coefficient to value.
Prerequisite
Etymology
A 1-dimensional OddPolynomial's parameters.
Synopsis
An OddPolynomial is described by a set of coefficients;
its fundamental operation is evaluating itself at some "x".
The number of coefficients is the order of the polynomial divided
by two, plus one.
Example
OddPolynomial<Float> pf(3); // Third order polynomial - coeffs 0 by default
pf.setCoefficient(0, 1.0);
pf[1] = 2.0; // 2x^3 + 1x^1
pf(2); // == 18
Template Type Argument Requirements (T)
Thrown Exceptions
To Do
Member Description
OddPolynomialParam()
Constructs a first order polynomial, with a coeficcient of 0.0.
explicit OddPolynomialParam(uInt order)
OddPolynomialParam(const OddPolynomialParam<T> &other)
OddPolynomialParam<T> &operator=(const OddPolynomialParam<T> &other)
~OddPolynomialParam()
Bool operator==(const OddPolynomialParam<T> &other) const
Bool operator!=(const OddPolynomialParam<T> &other) const
uInt order() const
T coefficient(uInt which) const
What is the which'th coefficient of the polynomial. For an nth
degree polynomial, which varies between zero and n/2.
const Vector<T> &coefficients() const
Return all the coefficients as a vector.
void setCoefficient(uInt which, const T value)
void setCoefficients(const Vector<T> &coefficients)
Set all the coefficients at once, throw away all existing coefficients.