17#ifndef __MOMENTUMCONSTRAINT_H
18#define __MOMENTUMCONSTRAINT_H
20#include "analysis/OrcaKinFit/ParticleConstraint.h"
28 namespace OrcaKinFit {
50 virtual double getValue()
const override;
62 virtual int getVarBasis()
const override;
65 void updateCache()
const;
74 mutable bool cachevalid;
87 enum { VAR_BASIS = 0 };
std::vector< double > derivatives
The derivatives.
virtual void getDerivatives(int idim, double der[]) const override
Get first order derivatives.
MomentumConstraint(double efact_=0, double pxfact_=0, double pyfact_=0, double pzfact_=0, double value_=0)
virtual double getValue() const override
Returns the value of the constraint.
virtual bool secondDerivatives(int i, int j, double *derivatives) const override
Second derivatives with respect to the 4-vectors of Fit objects i and j; result false if all derivati...
virtual bool firstDerivatives(int i, double *derivatives) const override
First derivatives with respect to the 4-vector of Fit objects i; result false if all derivatives are ...
virtual void invalidateCache() const override
Invalidates any cached values for the next event.
ParticleConstraint()
Creates an empty ParticleConstraint object.
Abstract base class for different kinds of events.