38 #include "StTrackPairInfo.hh"
39 #include "StMcTrack.hh"
40 #include "StGlobalTrack.h"
41 #include "StTrackDetectorInfo.h"
42 static const char rcsid[] =
"$Id: StTrackPairInfo.cc,v 1.11 2015/03/13 18:44:44 perev Exp $";
46 unsigned int tpcPings,
47 unsigned int svtPings,
48 unsigned int ssdPings,
49 unsigned int ftpcPings)
52 mPartnerMcTrack(mcTrk),
53 mCommonTpcHits(tpcPings),
54 mCommonSvtHits(svtPings),
55 mCommonSsdHits(ssdPings),
56 mCommonFtpcHits(ftpcPings)
59 unsigned short numPoints = rcTrk->detectorInfo()->numberOfPoints(kSvtId);
60 mRatioCommonToTotalHitsSvt =
61 (numPoints) ? static_cast<float>(mCommonSvtHits)/
static_cast<float>(numPoints) : 0;
64 numPoints = rcTrk->detectorInfo()->numberOfPoints(kSsdId);
65 mRatioCommonToTotalHitsSsd =
66 (numPoints) ? static_cast<float>(mCommonSsdHits)/
static_cast<float>(numPoints) : 0;
69 numPoints = rcTrk->detectorInfo()->numberOfPoints(kTpcId);
70 mRatioCommonToTotalHitsTpc =
71 (numPoints) ? static_cast<float>(mCommonTpcHits)/
static_cast<float>(numPoints) : 0;
72 mRatioCommonToTotalHitsFtpc = 0;
75 numPoints = rcTrk->detectorInfo()->numberOfPoints(kFtpcWestId);
76 mRatioCommonToTotalHitsFtpc =
77 (numPoints) ? static_cast<float>(mCommonFtpcHits)/
static_cast<float>(numPoints) : 0;
81 numPoints = rcTrk->detectorInfo()->numberOfPoints(kFtpcEastId);
82 mRatioCommonToTotalHitsFtpc =
83 (numPoints) ? static_cast<float>(mCommonFtpcHits)/
static_cast<float>(numPoints) : 0;
88 StTrackPairInfo::~StTrackPairInfo() { }
90 void StTrackPairInfo::setPartnerMcTrack(
const StMcTrack* val) { mPartnerMcTrack = val; }
92 void StTrackPairInfo::setPartnerTrack(
const StGlobalTrack* val) { mPartnerTrack = val; }
94 void StTrackPairInfo::setCommonTpcHits(
unsigned int val) { mCommonTpcHits = val; }
96 void StTrackPairInfo::setCommonSvtHits(
unsigned int val) { mCommonSvtHits = val; }
97 void StTrackPairInfo::setCommonSsdHits(
unsigned int val) { mCommonSsdHits = val; }
99 void StTrackPairInfo::setCommonFtpcHits(
unsigned int val) { mCommonFtpcHits = val; }
102 return os <<
"Mc: " << v.partnerMcTrack() <<
" Rc: " << v.partnerTrack()
103 <<
" Common Hits in Tpc :" << v.commonTpcHits() <<
"/" << v.percentOfPairedTpcHits()
104 <<
" Svt :" << v.commonSvtHits() <<
"/" << v.percentOfPairedSvtHits()
105 <<
" Ssd :" << v.commonSsdHits() <<
"/" << v.percentOfPairedSsdHits()
106 <<
" Ftpc :" << v.commonFtpcHits() <<
"/" << v.percentOfPairedFtpcHits()
Monte Carlo Track class All information on a simulated track is stored in this class: kinematics...