00001 #ifndef CONSTRAINTFITINPUT_H 00002 #define CONSTRAINTFITINPUT_H 00003 #include "EventPrimitives/EventPrimitives.h" 00004 #include "TLorentzVector.h" 00005 00006 namespace ZMassConstraint 00007 { 00008 class ConstraintFitInput { 00009 00010 00011 public: 00012 00014 ConstraintFitInput() : m_isOK(true) {} 00015 ~ConstraintFitInput() {} 00016 00018 unsigned int getNConstituents() const { return m_particles.size(); } 00019 00021 const TLorentzVector& getConstituentFourVector(int i) const { return m_particles[i]; } 00022 00024 const AmgMatrix(5,5)& getConstituentCovariance(int i) const { return m_covariances[i]; } 00025 00027 void getConstituentCovariancePhiThetaP(int i, AmgMatrix(3,3)& outMatrix) const 00028 { outMatrix = m_covariances[i].block(2, 2, 3, 3); } 00029 00031 const AmgMatrix(5,5)& getCovarianceCartesian(int ipart) const { return m_cartCovariances[ipart]; } 00032 00034 void addConstituent_FourVector_d0z0PhiThetaP(const TLorentzVector& vector, 00035 const AmgMatrix(5,5)& covard0z0PhiThetaP, 00036 const AmgMatrix(5,5)& covarXYZ, 00037 bool isOK) 00038 { m_particles.push_back(vector); m_covariances.push_back(covard0z0PhiThetaP); 00039 m_cartCovariances.push_back(covarXYZ); if (m_isOK) m_isOK = isOK; } 00040 00042 inline bool isOK() { return m_isOK; } 00043 00044 protected: 00045 std::vector<TLorentzVector> m_particles; 00046 std::vector<AmgMatrix(5,5)> m_covariances; 00047 std::vector<AmgMatrix(5,5)> m_cartCovariances; 00048 bool m_isOK; 00049 00050 }; 00051 } 00052 00053 00054 #endif