13#ifndef ROOT_Minuit2_Minuit2Minimizer
14#define ROOT_Minuit2_Minuit2Minimizer
29class ModularFunctionMinimizer;
95 virtual bool SetVariable(
unsigned int ivar,
const std::string &
name,
double val,
double step);
107 virtual bool SetFixedVariable(
unsigned int ,
const std::string & ,
double );
130 virtual std::string
VariableName(
unsigned int ivar)
const;
156 virtual const double *
X()
const {
return &
fValues.front(); }
176 virtual const double *
Errors()
const;
185 virtual double CovMatrix(
unsigned int i,
unsigned int j)
const;
220 virtual double Correlation(
unsigned int i,
unsigned int j)
const;
228 virtual double GlobalCC(
unsigned int i)
const;
237 virtual bool GetMinosError(
unsigned int i,
double &errLow,
double &errUp,
int = 0);
253 virtual bool Scan(
unsigned int i,
unsigned int &nstep,
double *
x,
double *
y,
double xmin = 0,
double xmax = 0);
259 virtual bool Contour(
unsigned int i,
unsigned int j,
unsigned int &npoints,
double *xi,
double *xj);
271 virtual bool Hesse();
306 int RunMinosError(
unsigned int i,
double &errLow,
double &errUp,
int runopt);
Class, describing value, limits and step size of the parameters Provides functionality also to set/re...
Documentation for the abstract class IBaseFunctionMultiDim.
Interface (abstract class) for multi-dimensional functions providing a gradient calculation.
Abstract Minimizer class, defining the interface for the various minimizer (like Minuit2,...
Interface (abstract class) defining the function to be minimized, which has to be implemented by the ...
class holding the full result of the minimization; both internal and external (MnUserParameterState) ...
Minuit2Minimizer class implementing the ROOT::Math::Minimizer interface for Minuit2 minimization algo...
bool ExamineMinimum(const ROOT::Minuit2::FunctionMinimum &min)
examine the minimum result
virtual unsigned int NFree() const
number of free variables (real dimension of the problem) this is <= Function().NDim() which is the to...
const ROOT::Minuit2::MnUserParameterState & State()
return the minimizer state (containing values, step size , etc..)
void SetStorageLevel(int level)
set storage level = 1 : store all iteration states (default) = 0 : store only first and last state to...
Minuit2Minimizer & operator=(const Minuit2Minimizer &rhs)
Assignment operator.
std::vector< double > fValues
virtual bool SetVariableUpperLimit(unsigned int ivar, double upper)
set the upper-limit of an already existing variable
virtual double GlobalCC(unsigned int i) const
get global correlation coefficient for the variable i.
virtual int VariableIndex(const std::string &name) const
get index of variable given a variable given a name return -1 if variable is not found
virtual bool SetVariable(unsigned int ivar, const std::string &name, double val, double step)
set free variable
virtual bool SetFixedVariable(unsigned int, const std::string &, double)
set fixed variable (override if minimizer supports them )
virtual void SetFunction(const ROOT::Math::IMultiGenFunction &func)
set the function to minimize
virtual const ROOT::Minuit2::FCNBase * GetFCN() const
virtual bool ProvidesError() const
minimizer provides error and error matrix
virtual bool SetLowerLimitedVariable(unsigned int ivar, const std::string &name, double val, double step, double lower)
set lower limit variable (override if minimizer supports them )
virtual bool SetLimitedVariable(unsigned int ivar, const std::string &name, double val, double step, double, double)
set upper/lower limited variable (override if minimizer supports them )
virtual bool SetVariableLimits(unsigned int ivar, double lower, double upper)
set the limits of an already existing variable
virtual bool SetVariableValues(const double *val)
set the values of all existing variables (array must be dimensioned to the size of the existing param...
virtual int CovMatrixStatus() const
return the status of the covariance matrix status = -1 : not available (inversion failed or Hesse fai...
virtual double MinValue() const
return minimum function value
virtual void Clear()
reset for consecutive minimizations - implement if needed
virtual double CovMatrix(unsigned int i, unsigned int j) const
return covariance matrix elements if the variable is fixed or const the value is zero The ordering of...
virtual ~Minuit2Minimizer()
Destructor (no operations)
virtual bool ReleaseVariable(unsigned int ivar)
release an existing variable
std::vector< double > fErrors
ROOT::Minuit2::ModularFunctionMinimizer * fMinimizer
virtual const double * MinGradient() const
return pointer to gradient values at the minimum
virtual bool Scan(unsigned int i, unsigned int &nstep, double *x, double *y, double xmin=0, double xmax=0)
scan a parameter i around the minimum.
virtual std::string VariableName(unsigned int ivar) const
get name of variables (override if minimizer support storing of variable names)
virtual unsigned int NDim() const
this is <= Function().NDim() which is the total number of variables (free+ constrained ones)
int RunMinosError(unsigned int i, double &errLow, double &errUp, int runopt)
virtual bool GetCovMatrix(double *cov) const
Fill the passed array with the covariance matrix elements if the variable is fixed or const the value...
virtual bool SetUpperLimitedVariable(unsigned int ivar, const std::string &name, double val, double step, double upper)
set upper limit variable (override if minimizer supports them )
virtual bool Minimize()
method to perform the minimization.
void SetTraceObject(MnTraceObject &obj)
set an object to trace operation for each iteration The object must be a (or inherit from) ROOT::Minu...
virtual bool SetVariableLowerLimit(unsigned int ivar, double lower)
set the lower-limit of an already existing variable
virtual const ROOT::Minuit2::ModularFunctionMinimizer * GetMinimizer() const
void SetMinimizerType(ROOT::Minuit2::EMinimizerType type)
virtual void PrintResults()
return reference to the objective function virtual const ROOT::Math::IGenFunction & Function() const;
virtual bool GetHessianMatrix(double *h) const
Fill the passed array with the Hessian matrix elements The Hessian matrix is the matrix of the second...
virtual unsigned int NCalls() const
number of function calls to reach the minimum
virtual double Edm() const
return expected distance reached from the minimum
ROOT::Minuit2::MnUserParameterState fState
virtual bool GetMinosError(unsigned int i, double &errLow, double &errUp, int=0)
get the minos error for parameter i, return false if Minos failed A minimizaiton must be performed be...
virtual const double * X() const
return pointer to X values at the minimum
virtual bool IsFixedVariable(unsigned int ivar) const
query if an existing variable is fixed (i.e.
virtual void SetMinimizer(ROOT::Minuit2::ModularFunctionMinimizer *m)
virtual const double * Errors() const
return errors at the minimum
virtual bool GetVariableSettings(unsigned int ivar, ROOT::Fit::ParameterSettings &varObj) const
get variable settings in a variable object (like ROOT::Fit::ParamsSettings)
ROOT::Minuit2::FunctionMinimum * fMinimum
virtual bool SetVariableValue(unsigned int ivar, double val)
set variable
ROOT::Minuit2::FCNBase * fMinuitFCN
virtual bool Contour(unsigned int i, unsigned int j, unsigned int &npoints, double *xi, double *xj)
find the contour points (xi,xj) of the function for parameter i and j around the minimum The contour ...
virtual int MinosStatus() const
MINOS status code of last Minos run status & 1 > 0 : invalid lower error status & 2 > 0 : invalid upp...
virtual double Correlation(unsigned int i, unsigned int j) const
return correlation coefficient between variable i and j.
virtual bool SetVariableStepSize(unsigned int ivar, double step)
set the step size of an already existing variable
virtual bool FixVariable(unsigned int ivar)
fix an existing variable
virtual bool Hesse()
perform a full calculation of the Hessian matrix for error calculation If a valid minimum exists the ...
class which holds the external user and/or internal Minuit representation of the parameters and error...
unsigned int NFcn() const
unsigned int VariableParameters() const
Base common class providing the API for all the minimizer Various Minimize methods are provided varyi...
tbb::task_arena is an alias of tbb::interface7::task_arena, which doesn't allow to forward declare tb...