hep.aida.ext
Interface IOptimizer
-
- All Known Implementing Classes:
- AbstractOptimizer, FminOptimizer, JMinuitOptimizer, MinpackOptimizer, UncminOptimizer
public interface IOptimizer
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method and Description booleanacceptsConstraints()Check if this IOptimizer accept constraints.double[][]calculateContour(java.lang.String par1, java.lang.String par2, int npts, double nSigmas)Calculate the contour for two given parameters.booleancanCalculateContours()Check if this IOptimizer can calculate contours.IOptimizerConfigurationconfiguration()Get the IOptimizer configurationjava.lang.String[]listVariableSettings()Get the list of the names of the IVariableSettings defined.voidoptimize()Perform the optimization.voidreset()Reset the function, the domain of constraints and the internal configuration.voidresetVariableSettings()Reset all variable settings.IOptimizerResultresult()Get the optimization results.voidsetConfiguration(IOptimizerConfiguration config)Set the internal configuration of the Optimizer.voidsetConstraints(IDomainConstraint domainConstraint)Set the domain of constraints for the IOptimizer.voidsetFunction(IFunction function)Set the IFunction to be optimized.IVariableSettingsvariableSettings(java.lang.String name)Get the IVariableSettings corresponding to a give variable.
-
-
-
Method Detail
-
setFunction
void setFunction(IFunction function) throws java.lang.IllegalArgumentException
Set the IFunction to be optimized. When setting a function the current configuration is reset.- Parameters:
function- The IFunction to be optimized.- Throws:
java.lang.IllegalArgumentException
-
setConstraints
void setConstraints(IDomainConstraint domainConstraint) throws java.lang.IllegalArgumentException
Set the domain of constraints for the IOptimizer. If a domain of constraints already exists it will be overwritten.- Parameters:
domainConstraint- The domain of constraints.- Throws:
java.lang.IllegalArgumentException
-
optimize
void optimize()
Perform the optimization.
-
result
IOptimizerResult result()
Get the optimization results.- Returns:
- The result.
-
reset
void reset()
Reset the function, the domain of constraints and the internal configuration.
-
configuration
IOptimizerConfiguration configuration()
Get the IOptimizer configuration- Returns:
- The configuration.
-
setConfiguration
void setConfiguration(IOptimizerConfiguration config) throws java.lang.IllegalArgumentException
Set the internal configuration of the Optimizer.- Parameters:
config- The configuration.- Throws:
java.lang.IllegalArgumentException
-
variableSettings
IVariableSettings variableSettings(java.lang.String name)
Get the IVariableSettings corresponding to a give variable. If the IVariableSettings does not exist, a new one is created.- Parameters:
name- The variable's name.- Returns:
- The corresponging IVariableSettings
-
listVariableSettings
java.lang.String[] listVariableSettings()
Get the list of the names of the IVariableSettings defined.- Returns:
- The list of the names.
-
resetVariableSettings
void resetVariableSettings()
Reset all variable settings.
-
acceptsConstraints
boolean acceptsConstraints()
Check if this IOptimizer accept constraints.- Returns:
trueif the IOptimizer accepts contraints.falseotherwise.
-
canCalculateContours
boolean canCalculateContours()
Check if this IOptimizer can calculate contours.- Returns:
trueif the IOptimizer can calculate contours.falseotherwise.
-
calculateContour
double[][] calculateContour(java.lang.String par1, java.lang.String par2, int npts, double nSigmas)Calculate the contour for two given parameters. The number of points and the number of sigmas can also be specified.- Parameters:
par1- The name of the first parameter.par2- The name of the second parameter.npts- The number of points on the contour.nSigmas- The number of sigmas for this contour.- Returns:
- A double array of dimension [2][npts]. For each point on the contour the value of (par1,par2) is returned.
-
-
DMelt 3.0 © DataMelt by jWork.ORG