BmnRoot
Loading...
Searching...
No Matches
BmnCSCPoint.cxx
Go to the documentation of this file.
1#include "BmnCSCPoint.h"
2
3#include <iostream>
4
5using namespace std;
6
8: FairMCPoint(),
9 fIsPrimary(0),
10 fCharge(-1.0),
11 fPdgId(0),
12 fX_out(0.0),
13 fY_out(0.0),
14 fZ_out(0.0),
15 fX_center(0.0),
16 fY_center(0.0),
17 fZ_center(0.0),
18 fPx_out(0.0),
19 fPy_out(0.0),
20 fPz_out(0.0),
21 fStation(-1), fModule(-1)
22{}
23
24BmnCSCPoint::BmnCSCPoint(Int_t trackID, Int_t detID,
25 TVector3 posIn, TVector3 posOut,
26 TVector3 momIn, TVector3 momOut,
27 Double_t tof, Double_t length, Double_t eLoss,
28 Int_t isPrimary, Double_t charge, Int_t pdgId)
29
30: FairMCPoint(trackID, detID, posIn, momIn, tof, length, eLoss),
31 fIsPrimary(isPrimary),
32 fCharge(charge),
33 fPdgId(pdgId),
34 fX_out(posOut.X()),
35 fY_out(posOut.Y()),
36 fZ_out(posOut.Z()),
37 fPx_out(momOut.Px()),
38 fPy_out(momOut.Py()),
39 fPz_out(momOut.Pz()),
40 fStation(-1), fModule(-1)
41{
42 fX_center = (fX_out + fX)*0.5;
43 fY_center = (fY_out + fY)*0.5;
44 fZ_center = (fZ_out + fZ)*0.5;
45}
46
48
49void BmnCSCPoint::Print(const Option_t* opt) const {
50 cout << "-I- BmnCSCPoint: CSC point for track " << fTrackID << " in detector " << fDetectorID << endl;
51 cout << " Position (In) (" << fX << ", " << fY << ", " << fZ << ") cm" << endl;
52 cout << " Momentum (In) (" << fPx << ", " << fPy << ", " << fPz << ") GeV" << endl;
53 cout << " Time " << fTime << " ns, Length " << fLength << " cm, Energy loss " << fELoss*1.0e06 << " keV" << endl;
54 cout << " StationNum " << fStation << ", ModuleNum " << fModule << endl;
55}
virtual void Print(const Option_t *opt) const
Double_t fY_center
Definition BmnCSCPoint.h:71
Int_t fStation
Definition BmnCSCPoint.h:74
virtual ~BmnCSCPoint()
Double_t fZ_center
Definition BmnCSCPoint.h:71
Double_t fY_out
Definition BmnCSCPoint.h:70
Double_t fZ_out
Definition BmnCSCPoint.h:70
Double_t fX_center
Definition BmnCSCPoint.h:71
Double_t fX_out
Definition BmnCSCPoint.h:70
Int_t fModule
Definition BmnCSCPoint.h:75
STL namespace.