11 #include <analysis/VertexFitting/TreeFitter/RecoComposite.h>
12 #include <analysis/VertexFitting/TreeFitter/FitParams.h>
14 #include <TMatrixFSym.h>
15 #include <Math/Vector3D.h>
17 namespace TreeFitter {
20 :
ParticleBase(particle, mother), m_params(), m_hasEnergy(true)
27 :
ParticleBase(particle, mother, &config), m_params(), m_hasEnergy(true), m_massconstraint(massConstraint)
46 return ErrCode(ErrCode::Status::success) ;
55 m_params = Eigen::Matrix<double, 7, 1>::Zero(7, 1);
65 m_covariance = Eigen::Matrix < double, -1, -1, 0, 7, 7 >::Zero(7, 7);
68 for (
int row = 0; row < 4; ++row) {
69 for (
int col = 0; col <= row; ++col) {
74 for (
int row = 0; row < 3; ++row) {
75 for (
int col = 0; col <= row; ++col) {
90 for (
int row = 0; row < 3; ++row) {
91 p.getH()(row, posindex + row) = -1;
94 for (
int row = 0; row < 4; ++row) {
95 p.getH()(3 + row, momindex + row) = -1;
98 p.getV().triangularView<Eigen::Lower>() =
m_covariance.triangularView<Eigen::Lower>();
100 return ErrCode(ErrCode::Status::success) ;
107 case Constraint::mass:
110 case Constraint::composite:
113 case Constraint::geometric:
Class to store reconstructed particles.
double getEnergy() const
Returns total energy.
ROOT::Math::XYZVector getVertex() const
Returns vertex position (POCA for charged, IP for neutral FS particles)
ROOT::Math::XYZVector getMomentum() const
Returns momentum vector.
TMatrixFSym getMomentumVertexErrorMatrix() const
Returns 7x7 error matrix.
Type
type of constraints the order of these constraints is important: it is the order in which they are ap...
abstract errorocode be aware that the default is success
Class to store and manage fitparams (statevector)
Eigen::Matrix< double, -1, 1, 0, MAX_MATRIX_SIZE, 1 > & getStateVector()
getter for the fit parameters/statevector
base class for all particles
Belle2::Particle * particle() const
get basf2 particle
ErrCode initTau(FitParams &par) const
initialises tau as a length
virtual ErrCode projectMassConstraint(const FitParams &, Projection &) const
project mass constraint abstract
virtual ErrCode projectConstraint(Constraint::Type, const FitParams &, Projection &) const
project constraint.
virtual ErrCode projectGeoConstraint(const FitParams &, Projection &) const
project geometrical constraint
class to store the projected residuals and the corresponding jacobian as well as the covariance matri...
ErrCode projectRecoComposite(const FitParams &fitparams, Projection &p) const
project this particle constraint
void updateParams()
update changed params
virtual ErrCode projectConstraint(Constraint::Type, const FitParams &, Projection &) const override
project this constraint
Eigen::Matrix< double, 7, 1 > m_params
column vector to store the measurement
virtual int momIndex() const override
get momentum index in statevector
Eigen::Matrix< double, -1, -1, 0, 7, 7 > m_covariance
only lower triangle filled!
virtual int type() const override
get ype
virtual ErrCode initParticleWithMother(FitParams &fitparams) override
init particle in case it has a mother
virtual ErrCode initMotherlessParticle(FitParams &fitparams) override
init particle in case it has no mother
virtual int posIndex() const override
get position index in statevectof x,y,z,tau,px,py,pz
RecoComposite(Belle2::Particle *bc, const ParticleBase *mother)
constructor