|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectnr.Function
public abstract class Function
A functionoid designed to implement a scalar function of a scalar
| Constructor Summary | |
|---|---|
Function()
|
|
| Method Summary | |
|---|---|
double |
derivative(double x)
Calculates the derivative for this function. |
double |
derivativeCost()
The computational cost of evaluating the derivative. |
abstract double |
eval(double x)
a scalar function of a scalar. |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public Function()
| Method Detail |
|---|
public abstract double eval(double x)
x - the independent variable
public double derivativeCost()
derivative(double) to eval(double). For the most
part this can be ignored.
For the default derivative, derivativeCost = 2 (derivative calls eval twice).
public double derivative(double x)
x - the independent variable
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||