13#ifndef ROOT_TLinearMinimizer
14#define ROOT_TLinearMinimizer
54 bool SetVariable(
unsigned int ,
const std::string & ,
double ,
double )
override {
return true; }
57 bool SetFixedVariable(
unsigned int ,
const std::string & ,
double )
override;
66 double Edm()
const override {
return 0; }
69 const double *
X()
const override {
return &
fParams.front(); }
72 const double *
MinGradient()
const override {
return nullptr; }
75 unsigned int NCalls()
const override {
return 0; }
79 unsigned int NDim()
const override {
return fDim; }
95 double CovMatrix(
unsigned int i,
unsigned int j)
const override {
101 if (
fCovar.empty())
return 0;
#define ClassDef(name, id)
Abstract Minimizer class, defining the interface for the various minimizer (like Minuit2,...
int fStatus
status of minimizer
double CovMatrix(unsigned int i, unsigned int j) const override
return covariance matrices elements if the variable is fixed the matrix is zero The ordering of the v...
bool ProvidesError() const override
minimizer provides error and error matrix
void SetFunction(const ROOT::Math::IMultiGenFunction &func) override
set the fit model function
double MinValue() const override
return minimum function value
~TLinearMinimizer() override
Destructor (no operations).
bool fRobust
return reference to the objective function virtual const ROOT::Math::IGenFunction & Function() const;
const double * X() const override
return pointer to X values at the minimum
unsigned int NDim() const override
this is <= Function().NDim() which is the total number of variables (free+ constrained ones)
bool SetVariable(unsigned int, const std::string &, double, double) override
set free variable (dummy impl. since there is no need to set variables in the Linear Fitter)
int CovMatrixStatus() const override
return covariance matrix status
const double * Errors() const override
return errors at the minimum
const ROOT::Math::IMultiGradFunction * fObjFunc
bool Minimize() override
method to perform the minimization
double Edm() const override
return expected distance reached from the minimum
std::vector< double > fParams
TLinearMinimizer(int type=0)
Default constructor.
std::vector< double > fCovar
std::vector< double > fErrors
unsigned int NFree() const override
number of free variables (real dimension of the problem) this is <= Function().NDim() which is the to...
const double * MinGradient() const override
return pointer to gradient values at the minimum
unsigned int NCalls() const override
number of function calls to reach the minimum
bool SetFixedVariable(unsigned int, const std::string &, double) override
set fixed variable (override if minimizer supports them )
IGradientFunctionMultiDim IMultiGradFunction
IMultiGenFunctionTempl< double > IMultiGenFunction