| Modifier and Type | Field and Description |
|---|---|
int |
constant |
| Constructor and Description |
|---|
Constant(int c) |
| Modifier and Type | Method and Description |
|---|---|
double[] |
derivatives(double... param)
Returns the partial derivatives of this function with
respect to its parameters as an array of
Function |
int |
noOfInputs()
Note that the no of inputs for a constant function does not matter
as it will output the same constant irrespective of the input.
|
static Constant |
op(int c)
Creates a new instance of
Constant |
double |
operate(double... param)
Operates on the given set of inputs and returns the result of
the operation.
|
public static Constant op(int c)
Constantc - the constant output of the new functionConstant instancepublic int noOfInputs()
noOfInputs in interface Functionpublic double operate(double... param)
Functionpublic double[] derivatives(double... param)
FunctionFunctionderivatives in interface Functionparam - point of tangency