BmnRoot
Loading...
Searching...
No Matches
BmnSiProfPoint.cxx
Go to the documentation of this file.
1#include "BmnSiProfPoint.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),
22 fModule(-1)
23{}
24
25BmnSiProfPoint::BmnSiProfPoint(Int_t trackID, Int_t detID,
26 TVector3 posIn, TVector3 posOut,
27 TVector3 momIn, TVector3 momOut,
28 Double_t tof, Double_t length, Double_t eLoss,
29 Int_t isPrimary, Double_t charge, Int_t pdgId)
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),
41 fModule(-1)
42{
43 fX_center = (fX_out + fX)*0.5;
44 fY_center = (fY_out + fY)*0.5;
45 fZ_center = (fZ_out + fZ)*0.5;
46}
47
49
50void BmnSiProfPoint::Print(const Option_t* opt) const {
51 cout << "-I- BmnSiProfPoint: SiProf point for track " << fTrackID << " in detector " << fDetectorID << endl;
52 cout << " Position (In) (" << fX << ", " << fY << ", " << fZ << ") cm" << endl;
53 cout << " Momentum (In) (" << fPx << ", " << fPy << ", " << fPz << ") GeV" << endl;
54 cout << " Time " << fTime << " ns, Length " << fLength << " cm, Energy loss " << fELoss*1.0e06 << " keV" << endl;
55 cout << " StationNum " << fStation << ", ModuleNum " << fModule << endl;
56}
virtual ~BmnSiProfPoint()
virtual void Print(const Option_t *opt) const
STL namespace.