BmnRoot 26.10.0-18-g4e3414f9
Software framework of the BM@N experiment
Loading...
Searching...
No Matches
CbmStripHit.cxx
Go to the documentation of this file.
1/**
2 * \file CbmStripHit.h
3 * \author Andrey Lebedev <andrey.lebedev@gsi.de>
4 * \date 2009
5 **/
6
7#include "CbmStripHit.h"
8
9#include "TVector3.h"
10
11#include <sstream>
12using std::endl;
13using std::stringstream;
14
16 : CbmBaseHit()
17 , fU(0.)
18 , fDu(0.)
19 , fPhi(0.)
20 , fDphi(0.)
21{
23}
24
26 Double_t u,
27 Double_t phi,
28 Double_t z,
29 Double_t du,
30 Double_t dphi,
31 Double_t dz,
32 Int_t refId)
33 : CbmBaseHit()
34 , fU(u)
35 , fDu(du)
36 , fPhi(phi)
37 , fDphi(dphi)
38{
40 SetAddress(address);
41 SetZ(z);
42 SetDz(dz);
43 SetRefId(refId);
44}
45
46CbmStripHit::CbmStripHit(Int_t address, const TVector3& pos, const TVector3& err, Int_t refId)
47 : CbmBaseHit()
48 , fU(pos.X())
49 , fDu(err.X())
50 , fPhi(pos.Y())
51 , fDphi(err.Y())
52{
54 SetAddress(address);
55 SetZ(pos.Z());
56 SetDz(err.Z());
57 SetRefId(refId);
58}
59
61
63{
64 stringstream ss;
65 ss << "CbmStripHit: address=" << GetAddress() << " pos=(" << GetU() << "," << GetPhi() << "," << GetZ() << ") err=("
66 << GetDu() << "," << GetDphi() << "," << GetDz() << ") refId=" << GetRefId() << endl;
67 return ss.str();
68}
int Int_t
double Double_t
@ kSTRIPHIT_o
Definition CbmBaseHit.h:18
Double_t GetZ() const
Definition CbmBaseHit.h:50
Double_t GetDz() const
Definition CbmBaseHit.h:51
Int_t GetAddress() const
Definition CbmBaseHit.h:53
void SetRefId(Int_t refId)
Definition CbmBaseHit.h:59
Int_t GetRefId() const
Definition CbmBaseHit.h:52
void SetDz(Double_t dz)
Definition CbmBaseHit.h:58
void SetZ(Double_t z)
Definition CbmBaseHit.h:57
CbmBaseHit()
Default constructor.
void SetAddress(Int_t address)
Definition CbmBaseHit.h:60
void SetType(HitType_o type)
Sets hit type.
Definition CbmBaseHit.h:82
CbmStripHit()
Default constructor.
Double_t fPhi
strip rotation angle [rad]
Definition CbmStripHit.h:79
Double_t fU
U coordinate in the rotated c.s [cm].
Definition CbmStripHit.h:77
Double_t GetDphi() const
Definition CbmStripHit.h:68
Double_t GetPhi() const
Definition CbmStripHit.h:66
Double_t fDphi
strip rotation error [rad]
Definition CbmStripHit.h:80
virtual string ToString() const
Inherited from CbmBaseHit.
Double_t GetU() const
Definition CbmStripHit.h:65
Double_t fDu
U error [cm].
Definition CbmStripHit.h:78
Double_t GetDu() const
Definition CbmStripHit.h:67
virtual ~CbmStripHit()
Destructor.
Double_t Z() const