2 #ifndef CBM_ANA_JPSI_UTILS_H
3 #define CBM_ANA_JPSI_UTILS_H
13 #include "TDatabasePDG.h"
14 #include "TMCProcess.h"
15 #include "TClonesArray.h"
29 std::vector<CbmStsTrack> stsTracks;
31 stsTracks[0] = *stsTrack;
32 std::vector<L1FieldRegion> vField;
33 std::vector<float> chiPrim;
34 fPFFitter.
GetChiToVertex(stsTracks, vField, chiPrim, kfVertex, 3e6);
35 cand->
fChi2sts = stsTracks[0].GetChiSq() / stsTracks[0].GetNDF();
38 const FairTrackParam* vtxTrack = stsTracks[0].GetParamFirst();
43 cand->
fMass = TDatabasePDG::Instance()->GetParticle(11)->Mass();
44 cand->
fCharge = (vtxTrack->GetQp() > 0) ? 1 : -1;
55 if (mctrack == NULL)
return false;
65 if (mctrack == NULL)
return false;
67 if (pdg != 11)
return false;
74 if (mct1 != NULL && motherPdg == 22 && pdg == 11) {
return true; }
83 if (mctrack == NULL)
return false;
85 if (pdg != 11)
return false;
92 if (mct1 != NULL && motherPdg == 111 && pdg == 11) {
return true; }