|
FreeHEP API Version current |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objecthep.aida.ref.pdf.Variable
hep.aida.ref.pdf.Function
Base function. Any function should extend this class.
| Field Summary |
| Fields inherited from class hep.aida.ref.pdf.Variable |
DEPENDENT, FUNCTION, PARAMETER |
| Constructor Summary | |
Function(String name)
|
|
| Method Summary | |
void |
addFunctionListener(FunctionListener listener)
|
void |
addVariable(Variable v)
Variables Management. |
void |
addVariables(VariableList list)
|
hep.aida.IAnnotation |
annotation()
|
String |
codeletString()
|
int |
dimension()
|
double |
evaluateAnalyticalNormalization(Dependent dep)
|
double |
evaluateAnalyticalVariableGradient(Variable var)
To be overwritten by classes extending Function. |
void |
excludeNormalizationAll()
|
double |
functionMaxValue()
This method is used to generate toy Mc data sets. |
double |
functionValue()
|
double |
functionValue(double[] v)
|
Dependent |
getDependent(int index)
|
Dependent |
getDependent(String parName)
|
Parameter |
getNormalizationParameter()
The normalization Parameter for a function is ALWAYS the last one. |
Parameter |
getParameter(int index)
|
Parameter |
getParameter(String parName)
|
double[] |
gradient()
|
double[] |
gradient(double[] v)
|
boolean |
hasAnalyticalNormalization(Dependent dep)
To be overwritten if Function provides analytical normalization. |
boolean |
hasAnalyticalVariableGradient(Variable var)
To be overwritten by classes extending Function. |
protected boolean |
hasDependent(Dependent dep)
|
protected boolean |
hasParameter(Parameter par)
|
protected boolean |
hasVariable(Variable var)
|
void |
includeNormalizationAll()
|
int |
indexOfParameter(String parName)
|
boolean |
isComposite(Variable var)
|
boolean |
isEqual(hep.aida.IFunction iFunction)
|
boolean |
isNormalized()
|
protected double |
maxValue()
|
String |
normalizationParameter()
|
hep.aida.IRangeSet |
normalizationRange(int i)
|
void |
normalizationRangeChanged()
|
void |
normalize(boolean normalize)
|
protected void |
notifyFunctionChanged(FunctionChangedEvent event)
|
int |
numberOfDependents()
|
int |
numberOfParameters()
|
double |
parameter(String parName)
|
double[] |
parameterGradient()
|
double[] |
parameterGradient(double[] v)
|
String[] |
parameterNames()
|
double[] |
parameters()
|
boolean |
providesGradient()
|
boolean |
providesGradientWithRespectToVariable(Variable var)
|
boolean |
providesNormalization()
|
boolean |
providesParameterGradient()
|
void |
removeFunctionListener(FunctionListener listener)
|
void |
setCodeletString(String str)
|
void |
setNormalizationParamter(Parameter par)
|
void |
setParameter(String parName,
double parValue)
|
void |
setParameters(double[] pars)
|
void |
setTitle(String title)
|
void |
setValue(double value)
Set the current value. |
protected void |
setVariableValue(double value)
|
String |
title()
|
protected void |
updateNormalization()
|
double |
value()
Get the current value. |
double |
value(double[] v)
|
void |
variableChanged(Variable var)
This method is invoked when a variable in the function has changed its value. |
void |
variableChangedName(Variable var)
Method invoked when the Variable's name have changed. |
void |
variableChangedRange(Variable var)
Method invoked when the Variable's range have changed. |
void |
variableChangedUnits(Variable var)
Method invoked when the Variable's Units have changed. |
void |
variableChangedValue(Variable var)
Method invoked when the Variable's value have changed. |
boolean |
variableChangingName(Variable var,
String name)
Method invoked when the Variable's name is about to change. |
boolean |
variableChangingUnits(Variable var,
Units units)
Method invoked when the Variable's Units are about to change. |
boolean |
variableChangingValue(Variable var,
double value)
Method invoked when the Variable's value is about to change. |
String |
variableName(int index)
|
String[] |
variableNames()
|
| Methods inherited from class hep.aida.ref.pdf.Variable |
addVariableListener, name, removeVariableListener, setName, setUnits, type, units |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public Function(String name)
| Method Detail |
public void addVariable(Variable v)
public void addVariables(VariableList list)
protected boolean hasDependent(Dependent dep)
protected boolean hasParameter(Parameter par)
protected boolean hasVariable(Variable var)
public boolean variableChangingUnits(Variable var,
Units units)
VariableListener
variableChangingUnits in interface VariableListenervar - The Variable whose Units are changing.units - The new Units for the Variable.
true if the change is allowed.public void variableChangedUnits(Variable var)
VariableListener
variableChangedUnits in interface VariableListenervar - The Variable whose Units have changed.
public boolean variableChangingValue(Variable var,
double value)
VariableListener
variableChangingValue in interface VariableListenervar - The Variable whose value is changing.value - The new value for the Variable.
true if the change is allowed.public String normalizationParameter()
normalizationParameter in interface hep.aida.IFunctionpublic void variableChanged(Variable var)
public void variableChangedValue(Variable var)
VariableListener
variableChangedValue in interface VariableListenervar - The Variable whose value have changed.
public boolean variableChangingName(Variable var,
String name)
VariableListener
variableChangingName in interface VariableListenervar - The Variable whose name is changing.name - The new name for the Variable.
true if the change is allowed.public void variableChangedName(Variable var)
VariableListener
variableChangedName in interface VariableListenervar - The Variable whose name has changed.public void setValue(double value)
HasValue
setValue in interface HasValuesetValue in class Variablepublic double functionValue()
public double functionMaxValue()
protected void updateNormalization()
public boolean hasAnalyticalNormalization(Dependent dep)
public double evaluateAnalyticalNormalization(Dependent dep)
protected double maxValue()
public double value()
HasValue
value in interface HasValuevalue in class Variablepublic double evaluateAnalyticalVariableGradient(Variable var)
public boolean hasAnalyticalVariableGradient(Variable var)
public boolean providesGradientWithRespectToVariable(Variable var)
public double[] gradient()
public double[] parameterGradient()
public Parameter getParameter(int index)
public Parameter getParameter(String parName)
public int numberOfParameters()
numberOfParameters in interface hep.aida.IFunctionpublic Dependent getDependent(int index)
public Dependent getDependent(String parName)
public int numberOfDependents()
public boolean isComposite(Variable var)
public Parameter getNormalizationParameter()
public void setNormalizationParamter(Parameter par)
public void addFunctionListener(FunctionListener listener)
addFunctionListener in interface FunctionDispatcherpublic void removeFunctionListener(FunctionListener listener)
removeFunctionListener in interface FunctionDispatcherprotected void notifyFunctionChanged(FunctionChangedEvent event)
public void variableChangedRange(Variable var)
VariableListener
variableChangedRange in interface VariableListenervar - The Variable whose range has changed.public void normalizationRangeChanged()
public boolean isNormalized()
isNormalized in interface hep.aida.IModelFunctionpublic void normalize(boolean normalize)
normalize in interface hep.aida.IModelFunctionpublic boolean providesNormalization()
providesNormalization in interface hep.aida.IModelFunctionpublic hep.aida.IAnnotation annotation()
annotation in interface hep.aida.IFunctionpublic String codeletString()
codeletString in interface hep.aida.IFunctionpublic void setCodeletString(String str)
public double value(double[] v)
value in interface hep.aida.IFunctionpublic double[] gradient(double[] v)
gradient in interface hep.aida.IFunctionpublic int dimension()
dimension in interface hep.aida.IFunctionpublic int indexOfParameter(String parName)
indexOfParameter in interface hep.aida.IFunctionpublic double parameter(String parName)
parameter in interface hep.aida.IFunctionpublic String[] parameterNames()
parameterNames in interface hep.aida.IFunctionpublic double[] parameters()
parameters in interface hep.aida.IFunction
public void setParameter(String parName,
double parValue)
throws IllegalArgumentException
setParameter in interface hep.aida.IFunctionIllegalArgumentException
public void setParameters(double[] pars)
throws IllegalArgumentException
setParameters in interface hep.aida.IFunctionIllegalArgumentException
public void setTitle(String title)
throws IllegalArgumentException
setTitle in interface hep.aida.IFunctionIllegalArgumentExceptionpublic String title()
title in interface hep.aida.IFunctionpublic String variableName(int index)
variableName in interface hep.aida.IFunctionpublic String[] variableNames()
variableNames in interface hep.aida.IFunctionpublic double functionValue(double[] v)
public void excludeNormalizationAll()
excludeNormalizationAll in interface hep.aida.IModelFunctionpublic void includeNormalizationAll()
includeNormalizationAll in interface hep.aida.IModelFunctionpublic hep.aida.IRangeSet normalizationRange(int i)
normalizationRange in interface hep.aida.IModelFunctionpublic double[] parameterGradient(double[] v)
parameterGradient in interface hep.aida.IModelFunctionpublic boolean isEqual(hep.aida.IFunction iFunction)
isEqual in interface hep.aida.IFunctionpublic boolean providesGradient()
providesGradient in interface hep.aida.IFunctionpublic boolean providesParameterGradient()
providesParameterGradient in interface hep.aida.IModelFunctionprotected void setVariableValue(double value)
setVariableValue in class Variable
|
FreeHEP API Version current |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||