30 init(
nullptr, 0.,
nullptr);
55 init(p, M, theCovMatrix);
59 TVector3*
p, Double_t M,
const TMatrixD* theCovMatrix)
62 init(p, M, theCovMatrix);
69 if ( newname.Length() > 0 ) myclone->SetName(newname);
98 if (params ==
nullptr) {
102 if ( params->GetNcols() != 1 || params->GetNrows() !=
_nPar ) {
104 << GetName() <<
"::calc4Vec - Parameter matrix has wrong size.";
108 Double_t
X = (*params)(0,0);
109 Double_t
Y = (*params)(1,0);
110 Double_t
Z = (*params)(2,0);
111 Double_t E = TMath::Sqrt( X*X + Y*Y + Z*Z +
_pini.M2() );
113 TLorentzVector* vec =
new TLorentzVector( X, Y, Z, E );
122 TVector3 vec( pini->Vect() );
131 if ( p ==
nullptr ) {
140 _pini.SetXYZM( 0., 0., 0., M);
152 _pini.SetXYZM( p->x(), p->y(), p->z(), M);
155 _u1.SetXYZ( 1., 0., 0. );
156 _u2.SetXYZ( 0., 1., 0. );
157 _u3.SetXYZ( 0., 0., 1. );
168 TMatrixD* DerivativeMatrix =
new TMatrixD(4,3);
169 (*DerivativeMatrix) *= 0.;
172 (*DerivativeMatrix)(0,0) = 1.;
173 (*DerivativeMatrix)(1,0) = 0.;
174 (*DerivativeMatrix)(2,0) = 0.;
178 (*DerivativeMatrix)(0,1) = 0.;
179 (*DerivativeMatrix)(1,1) = 1.;
180 (*DerivativeMatrix)(2,1) = 0.;
184 (*DerivativeMatrix)(0,2) = 0.;
185 (*DerivativeMatrix)(1,2) = 0.;
186 (*DerivativeMatrix)(2,2) = 1.;
189 return DerivativeMatrix;
197 TVector3
vec3( vec.Vect() );
200 TMatrixD* tparams =
new TMatrixD(
_nPar, 1 );
201 (*tparams)(0,0) =
vec3.x();
202 (*tparams)(1,0) =
vec3.y();
203 (*tparams)(2,0) =
vec3.z();
void init(TVector3 *p, Double_t M, const TMatrixD *theCovMatrix)
TLorentzVector * calc4Vec(const TMatrixD *params) override
~TFitParticleMCCart() override
void setIni4Vec(const TLorentzVector *pini) override
TMatrixD * getDerivative() override
virtual void setCovMatrix(const TMatrixD *theCovMatrix)
TAbsFitParticle * clone(const TString &newname=TString("")) const override
TMatrixD * transform(const TLorentzVector &vec) override