|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--edu.stanford.multiagent.gamer.ParameterizedObject | +--edu.stanford.multiagent.gamer.functions.Function
An abstract class for single-arity function classes
Field Summary | |
protected double |
dMax
|
protected double |
dMin
|
Fields inherited from class edu.stanford.multiagent.gamer.ParameterizedObject |
parameters |
Constructor Summary | |
Function()
|
Method Summary | |
abstract double |
eval(double x)
Evaluates the function at a single point and return the value |
double |
getDMax()
Returns the maximum value in the domain. |
double |
getDMin()
Returns the minimum value in the domain. |
protected abstract java.lang.String |
getFunctionHelp()
Returns a help string describing the function and the parameters taken by the function |
java.lang.String |
getHelp()
Return the help screen |
void |
initialize()
Calls initialize in the super class ParemeterizedObject which checks parameters |
void |
setDomain(double min,
double max)
Sets the domain range. |
Methods inherited from class edu.stanford.multiagent.gamer.ParameterizedObject |
checkParameters, doGenerate, getBooleanParameter, getDescription, getDoubleParameter, getLongParameter, getParamDescription, getParameter, getParameters, getStringParameter, randomizeParameters, setParameter, setParameter, setParameters, setParameters |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
protected double dMin
protected double dMax
Constructor Detail |
public Function() throws java.lang.Exception
Method Detail |
public java.lang.String getHelp()
getHelp
in class ParameterizedObject
protected abstract java.lang.String getFunctionHelp()
public abstract double eval(double x)
x
- the point at which to evaluate the functionpublic void initialize() throws java.lang.Exception
initialize
in class ParameterizedObject
java.lang.Exception
- if there is a problem with the parameterspublic void setDomain(double min, double max)
min
- minimum value in the domainmax
- maximum value in the domainpublic double getDMin()
public double getDMax()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |