Extension of the FCNBase for the Fumili method.
Fumili applies only to minimization problems used for fitting. The method is based on a linearization of the model function negleting second derivatives. User needs to provide the model function. The figure-of-merit describing the difference between the model function and the actual measurements has to be implemented by the user in a subclass of FumiliFCNBase. For an example see the FumiliChi2FCN and FumiliStandardChi2FCN classes.
Definition at line 46 of file FumiliFCNBase.h.
Public Member Functions | |
FumiliFCNBase () | |
Default Constructor. | |
FumiliFCNBase (unsigned int npar) | |
Constructor which initializes the class with the function provided by the user for modeling the data. | |
~FumiliFCNBase () override | |
virtual unsigned int | Dimension () |
return number of function variable (parameters) , i.e. | |
virtual void | EvaluateAll (std::vector< double > const &par)=0 |
Evaluate function Value, Gradient and Hessian using Fumili approximation, for values of parameters p The result is cached inside and is return from the FumiliFCNBase::Value , FumiliFCNBase::Gradient and FumiliFCNBase::Hessian methods. | |
virtual const std::vector< double > & | Gradient () const |
Return cached Value of function Gradient estimated previously using the FumiliFCNBase::EvaluateAll method. | |
std::vector< double > | Gradient (std::vector< double > const &) const override |
bool | HasGradient () const override |
std::vector< double > | Hessian (std::vector< double > const &) const override |
Return Value of the i-th j-th element of the Hessian matrix estimated previously using the FumiliFCNBase::EvaluateAll method. | |
virtual double | Hessian (unsigned int row, unsigned int col) const |
virtual double | Value () const |
Return cached Value of objective function estimated previously using the FumiliFCNBase::EvaluateAll method. | |
Public Member Functions inherited from ROOT::Minuit2::FCNBase | |
virtual double | ErrorDef () const |
Error definition of the function. | |
virtual std::vector< double > | G2 (std::vector< double > const &) const |
return second derivatives (diagonal of the Hessian matrix) | |
virtual std::vector< double > | GradientWithPrevResult (std::vector< double > const ¶meters, double *, double *, double *) const |
virtual GradientParameterSpace | gradParameterSpace () const |
virtual bool | HasG2 () const |
virtual bool | HasHessian () const |
double | operator() (std::vector< double > const &v) const override=0 |
The meaning of the vector of parameters is of course defined by the user, who uses the values of those parameters to calculate their function Value. | |
virtual void | SetErrorDef (double) |
add interface to set dynamically a new error definition Re-implement this function if needed. | |
virtual double | Up () const =0 |
Error definition of the function. | |
Public Member Functions inherited from ROOT::Minuit2::GenericFunction | |
virtual | ~GenericFunction () |
Protected Member Functions | |
std::vector< double > & | Gradient () |
std::vector< double > & | Hessian () |
virtual void | InitAndReset (unsigned int npar) |
initialize and reset values of gradien and Hessian | |
void | SetFCNValue (double value) |
Private Attributes | |
std::vector< double > | fGradient |
std::vector< double > | fHessian |
unsigned int | fNumberOfParameters |
double | fValue |
#include <Minuit2/FumiliFCNBase.h>
|
inline |
Default Constructor.
Need in this case to create when implementing EvaluateAll the Gradient and Hessian vectors with the right size
Definition at line 54 of file FumiliFCNBase.h.
|
inline |
Constructor which initializes the class with the function provided by the user for modeling the data.
npar | the number of parameters |
Definition at line 67 of file FumiliFCNBase.h.
|
inlineoverride |
Definition at line 75 of file FumiliFCNBase.h.
|
inlinevirtual |
return number of function variable (parameters) , i.e.
function dimension
Definition at line 124 of file FumiliFCNBase.h.
|
pure virtual |
Evaluate function Value, Gradient and Hessian using Fumili approximation, for values of parameters p The result is cached inside and is return from the FumiliFCNBase::Value , FumiliFCNBase::Gradient and FumiliFCNBase::Hessian methods.
par | vector of parameters |
Implemented in ROOT::Minuit2::FumiliStandardChi2FCN, ROOT::Minuit2::FumiliStandardMaximumLikelihoodFCN, and ROOT::Minuit2::FumiliFCNAdapter< Function >.
|
inlineprotected |
Definition at line 141 of file FumiliFCNBase.h.
|
inlinevirtual |
Return cached Value of function Gradient estimated previously using the FumiliFCNBase::EvaluateAll method.
Definition at line 100 of file FumiliFCNBase.h.
|
inlineoverridevirtual |
Reimplemented from ROOT::Minuit2::FCNBase.
Definition at line 101 of file FumiliFCNBase.h.
|
inlineoverridevirtual |
Reimplemented from ROOT::Minuit2::FCNBase.
Definition at line 56 of file FumiliFCNBase.h.
|
inlineprotected |
Definition at line 143 of file FumiliFCNBase.h.
|
inlineoverridevirtual |
Return Value of the i-th j-th element of the Hessian matrix estimated previously using the FumiliFCNBase::EvaluateAll method.
row | row Index of the matrix |
col | col Index of the matrix |
Reimplemented from ROOT::Minuit2::FCNBase.
Definition at line 110 of file FumiliFCNBase.h.
|
inlinevirtual |
Definition at line 111 of file FumiliFCNBase.h.
|
inlineprotectedvirtual |
initialize and reset values of gradien and Hessian
Definition at line 131 of file FumiliFCNBase.h.
|
inlineprotected |
Definition at line 139 of file FumiliFCNBase.h.
|
inlinevirtual |
Return cached Value of objective function estimated previously using the FumiliFCNBase::EvaluateAll method.
Definition at line 94 of file FumiliFCNBase.h.
|
private |
Definition at line 148 of file FumiliFCNBase.h.
|
private |
Definition at line 149 of file FumiliFCNBase.h.
|
private |
Definition at line 146 of file FumiliFCNBase.h.
|
private |
Definition at line 147 of file FumiliFCNBase.h.