public abstract class AbstractMathematicalFunctionWrapper extends AbstractMathematicalFunction
parameterBounds
Constructor and Description |
---|
AbstractMathematicalFunctionWrapper(AbstractMathematicalFunction originalFunction)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
Matrix |
getBeta()
This method returns the vector of parameters.
|
abstract Matrix |
getGradient()
This method returns a vector that contains the first derivatives of the function with respect to its parameters.
|
abstract Matrix |
getHessian()
This method returns a matrix that contains the second derivatives of the function with respect to its parameters.
|
int |
getNumberOfParameters()
This method returns the number of parameters involved in the function.
|
int |
getNumberOfVariables()
This method returns the number of variables in the function.
|
AbstractMathematicalFunction |
getOriginalFunction()
This method returns the original function.
|
double |
getParameterValue(int parameterIndex)
This method retrieve the parameter defined by the parameterName parameter.
|
abstract java.lang.Double |
getValue()
This method provides the result of the function evaluation.
|
double |
getVariableValue(int variableIndex)
This method returns the value of the variable at index variableIndex
|
void |
setBeta(Matrix beta)
This method sets the vector of parameters.
|
void |
setBounds(int parameterIndex,
ParameterBound bound)
This method sets a bound for a particular parameter
|
void |
setParameterValue(int parameterIndex,
double parameterValue)
This method sets the parameter value.
|
void |
setVariableValue(int variableIndex,
double variableValue)
This method sets the variable value associated with this variable name.
|
void |
setX(Matrix x)
This method sets the vector of explanatory variables.
|
public AbstractMathematicalFunctionWrapper(AbstractMathematicalFunction originalFunction)
originalFunction
- the nested AbstractMathematicalFunction instancepublic AbstractMathematicalFunction getOriginalFunction()
public abstract java.lang.Double getValue()
EvaluableFunction
getValue
in interface EvaluableFunction<java.lang.Double>
getValue
in class AbstractMathematicalFunction
public abstract Matrix getGradient()
DerivableMathematicalFunction
getGradient
in interface DerivableMathematicalFunction
getGradient
in class AbstractMathematicalFunction
public abstract Matrix getHessian()
DerivableMathematicalFunction
getHessian
in interface DerivableMathematicalFunction
getHessian
in class AbstractMathematicalFunction
public void setParameterValue(int parameterIndex, double parameterValue)
AbstractMathematicalFunction
setParameterValue
in class AbstractMathematicalFunction
parameterIndex
- the parameter indexparameterValue
- the parameter valuepublic double getParameterValue(int parameterIndex)
AbstractMathematicalFunction
getParameterValue
in class AbstractMathematicalFunction
parameterIndex
- the index of the parameter to be retrievedpublic void setVariableValue(int variableIndex, double variableValue)
AbstractMathematicalFunction
setVariableValue
in class AbstractMathematicalFunction
variableIndex
- the index of the variablevariableValue
- its value (a double)public double getVariableValue(int variableIndex)
AbstractMathematicalFunction
getVariableValue
in class AbstractMathematicalFunction
variableIndex
- an integerpublic int getNumberOfParameters()
AbstractMathematicalFunction
getNumberOfParameters
in class AbstractMathematicalFunction
public int getNumberOfVariables()
AbstractMathematicalFunction
getNumberOfVariables
in class AbstractMathematicalFunction
public void setX(Matrix x)
AbstractMathematicalFunction
setX
in class AbstractMathematicalFunction
x
- a Matrix instancepublic void setBeta(Matrix beta)
AbstractMathematicalFunction
setBeta
in class AbstractMathematicalFunction
beta
- a Matrix instancepublic Matrix getBeta()
AbstractMathematicalFunction
getBeta
in class AbstractMathematicalFunction
public void setBounds(int parameterIndex, ParameterBound bound)
AbstractMathematicalFunction
setBounds
in class AbstractMathematicalFunction
parameterIndex
- an Integer instance that defines the parameterbound
- a ParameterBound object