MarlinKinfit
0.4.0
|
Description of the fit algorithm and interface: More...
#include <OPALFitterGSL.h>
Public Member Functions | |
virtual double | fit () |
virtual int | getError () const |
Return error code. More... | |
virtual double | getProbability () const |
Get the fit probability of the last fit. | |
virtual double | getChi2 () const |
Get the chi**2 of the last fit. | |
virtual int | getDoF () const |
Get the number of degrees of freedom of the last fit. | |
virtual int | getIterations () const |
Get the number of iterations of the last fit. | |
virtual int | getNcon () const |
Get the number of hard constraints of the last fit. | |
virtual int | getNsoft () const |
Get the number of soft constraints of the last fit. | |
virtual int | getNpar () const |
Get the number of all parameters of the last fit. | |
virtual int | getNunm () const |
Get the number of unmeasured parameters of the last fit. | |
virtual bool | initialize () |
virtual void | setDebug (int debuglevel) |
Set the Debug Level. | |
![]() | |
virtual void | addFitObject (BaseFitObject *fitobject_) |
virtual void | addFitObject (BaseFitObject &fitobject_) |
virtual void | addConstraint (BaseConstraint *constraint_) |
virtual void | addConstraint (BaseConstraint &constraint_) |
virtual void | addHardConstraint (BaseHardConstraint *constraint_) |
virtual void | addHardConstraint (BaseHardConstraint &constraint_) |
virtual void | addSoftConstraint (BaseSoftConstraint *constraint_) |
virtual void | addSoftConstraint (BaseSoftConstraint &constraint_) |
virtual std::vector < BaseFitObject * > * | getFitObjects () |
virtual std::vector < BaseHardConstraint * > * | getConstraints () |
virtual std::vector < BaseSoftConstraint * > * | getSoftConstraints () |
virtual void | reset () |
virtual BaseTracer * | getTracer () |
virtual const BaseTracer * | getTracer () const |
virtual void | setTracer (BaseTracer *newTracer) |
virtual void | setTracer (BaseTracer &newTracer) |
virtual const double * | getGlobalCovarianceMatrix (int &idim) const |
virtual double * | getGlobalCovarianceMatrix (int &idim) |
Protected Types | |
enum | { NPARMAX =50, NCONMAX =20, NUNMMAX =20 } |
![]() | |
typedef std::vector < BaseFitObject * > | FitObjectContainer |
typedef std::vector < BaseHardConstraint * > | ConstraintContainer |
typedef std::vector < BaseSoftConstraint * > | SoftConstraintContainer |
typedef FitObjectContainer::iterator | FitObjectIterator |
typedef ConstraintContainer::iterator | ConstraintIterator |
typedef SoftConstraintContainer::iterator | SoftConstraintIterator |
Protected Member Functions | |
virtual bool | updateFitObjects (double etaxi[]) |
![]() | |
BaseFitter (const BaseFitter &rhs) | |
Copy constructor disabled. | |
BaseFitter & | operator= (const BaseFitter &rhs) |
Assignment disabled. | |
Protected Attributes | |
int | npar |
int | nmea |
int | nunm |
int | ncon |
int | ierr |
int | nit |
double | fitprob |
double | chi2 |
![]() | |
FitObjectContainer | fitobjects |
ConstraintContainer | constraints |
SoftConstraintContainer | softconstraints |
int | covDim |
dimension of global covariance matrix | |
double * | cov |
global covariance matrix of last fit problem | |
bool | covValid |
Flag whether global covariance is valid. | |
BaseTracer * | tracer |
Additional Inherited Members | |
![]() | |
std::map< std::string, double > | traceValues |
Description of the fit algorithm and interface:
The OPALFitter object holds a set (fitobjects) of BaseFitObject objects, which represent the objects (particles, jets) whose fourvectors shall be fitted. It also holds a set (constraints) of BaseConstraint objects that represent the constraints (momentum or mass constraints).
OPALFitter::initialize goes over the list of fit objects and determines the number of parameters (measured and unmeasured), and assigns global numbers to them.
OPALFitter::fit first initializes the global parameter numbering using OPALFitter::initialize.
Then it initializes vectors etaxi ( ) and y (
) with the current parameter values.
Next it initializes the matrix Feta that represents
Used methods in OPALFitter::initialize:
Used methods in OPALFitter::updateFitObjects:
Used methods in OPALFitter::fit:
Interaction between Constraints and Particles
The Fitter does not care how the constraints and BaseFitObject objects interact. The constraints are expressed in terms of four-vector components of the BaseFitObjects. A constraint object keeps a set of BaseFitObject objects, and, using the chain rule, calculates its derivatives w.r.t. the global parameters.
|
virtual |
initialize Fetaxi ( = d F / d eta,xi)
Implements BaseFitter.
References BaseFitter::cov, BaseFitter::covDim, BaseFitter::covValid, BaseTracer::finish(), BaseTracer::initialize(), and BaseTracer::step().
|
virtual |
Return error code.
Error code meanings:
Implements BaseFitter.