org.apache.commons.math.optimization.fitting
Class PolynomialFitter.ParametricPolynomial

java.lang.Object
  extended by org.apache.commons.math.optimization.fitting.PolynomialFitter.ParametricPolynomial
All Implemented Interfaces:
ParametricRealFunction
Enclosing class:
PolynomialFitter

private static class PolynomialFitter.ParametricPolynomial
extends java.lang.Object
implements ParametricRealFunction

Dedicated parametric polynomial class.


Constructor Summary
private PolynomialFitter.ParametricPolynomial()
           
 
Method Summary
 double[] gradient(double x, double[] parameters)
          Compute the gradient of the function with respect to its parameters.
 double value(double x, double[] parameters)
          Compute the value of the function.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PolynomialFitter.ParametricPolynomial

private PolynomialFitter.ParametricPolynomial()
Method Detail

gradient

public double[] gradient(double x,
                         double[] parameters)
                  throws FunctionEvaluationException
Compute the gradient of the function with respect to its parameters.

Specified by:
gradient in interface ParametricRealFunction
Parameters:
x - the point for which the function value should be computed
parameters - function parameters
Returns:
the value
Throws:
FunctionEvaluationException - if the function evaluation fails

value

public double value(double x,
                    double[] parameters)
Compute the value of the function.

Specified by:
value in interface ParametricRealFunction
Parameters:
x - the point for which the function value should be computed
parameters - function parameters
Returns:
the value


Copyright (c) 2003-2009 Apache Software Foundation