17 #include "TClonesArray.h"
18 #include "TMatrixFSym.h"
41 if ( NULL == ioman) { Fatal(
"CbmRichTrackExtrapolationKF::Init",
"RootManager not instantised!");}
46 if ( NULL ==
fEicTracks) {Fatal(
"CbmRichTrackExtrapolationKF::Init",
"No reconstructed Track array!");}
50 TClonesArray* globalTracks,
51 TClonesArray* extrapolatedTrackParams,
55 if ( NULL == extrapolatedTrackParams ) {
56 cout <<
"-E- CbmRichTrackExtrapolationKF::DoExtrapolate: TrackParamArray missing!" << endl;
61 if ( NULL == globalTracks ) {
62 cout <<
"-E- CbmRichTrackExtrapolationKF::DoExtrapolate: Track Array missing!" << endl;
67 TMatrixFSym covMat(5);
68 for(Int_t i=0;i<5;i++)
for(Int_t j=0; j<=i; j++) covMat(i,j) = 0;
69 covMat(0,0) = covMat(1,1) = covMat(2,2) = covMat(3,3) = covMat(4,4) = 1.e-4;
74 Int_t nTracks = globalTracks->GetEntriesFast();
75 for (Int_t iTrack=0; iTrack < nTracks; iTrack++){
77 new((*extrapolatedTrackParams)[iTrack])
FairTrackParam(0.,0.,0.,0.,0.,0.,covMat);
79 if (idSTS < 0 )
continue;
80 CbmStsTrack* pSTStr = (CbmStsTrack*) fStsTracks->At(idSTS);
81 if ( NULL == pSTStr )
continue;
83 CbmStsKFTrackFitter KF;
86 KF.Extrapolate(pSTStr, z, &ExTrack);
88 Int_t Nsts = pSTStr->GetNStsHits();
90 if ( Nsts >= minNofStsHits) {
96 for (Int_t iTrack=0; iTrack < nTracks; iTrack++) {
111 TVector3 x0(0,0,z), u0(1,0,0), v0(0,1,0);
114 Bool_t rc = fPro0->
Propagate(&par, fRes, -211);
116 new((*extrapolatedTrackParams)[iTrack])
119 fRes->
GetQp(), covMat);
128 *(
FairTrackParP*)(extrapolatedTrackParams->At(iTrack)) = *fRes;