SimHit.h
Go to the documentation of this file.
1 ////////////////////////////////////////////////////////////////////////
2 // $Id: SimHit.h,v 1.3 2011-10-19 20:31:56 brebel Exp $
3 //
4 // A SimHit is the detector plane and cell with true energy deposition from
5 // particles from the MC simulation
6 //
7 ////////////////////////////////////////////////////////////////////////
8 
9 #ifndef SIMHIT_H
10 #define SIMHIT_H
11 
12 #include "RecoBase/CellHit.h"
13 #include <vector>
14 
15 namespace cheat {
16 
17  class SimHit : public rb::CellHit
18  {
19 
20  public:
21  SimHit(); // Default constructor
22  ~SimHit();
23 
24  #ifndef __GCCXML__
25  SimHit(const rb::CellHit&);
26 
27  void Print() const;
28 
29  // Getters
30 // unsigned short Plane () const { return fPlane; }
31 // unsigned short Cell () const { return fCell; }
32 // geo::View_t View () const { return fView; }
33  double CoorX () const { return fCoorX; }
34  double CoorY () const { return fCoorY; }
35  double CoorZ () const { return fCoorZ; }
36  double TotE () const { return fTotE; }
37  unsigned short NP () const { return fNP; }
38  std::vector<int>TrID () const { return fTrID; }
39  std::vector<int>PID () const { return fPID; }
40  std::vector<double>EnD () const { return fEnD; }
41  std::vector<double>Tim () const { return fTim; }
42 
43  // Setters
44 // void SetPlane (unsigned short plane ) { fPlane = plane; }
45 // void SetCell (unsigned short cell ) { fCell = cell; }
46 // void SetView (geo::View_t view ) { fView = view; }
47  void SetCoorX (double coorx ) { fCoorX = coorx; }
48  void SetCoorY (double coory ) { fCoorY = coory; }
49  void SetCoorZ (double coorz ) { fCoorZ = coorz; }
50  void SetTotE (double tote ) { fTotE = tote; }
51  void SetNP (unsigned short np ) { fNP = np; }
52  void SetTrID (std::vector<int> TrID ) { fTrID = TrID; }
53  void SetPID (std::vector<int> PID ) { fPID = PID; }
54  void SetEnD (std::vector<double> EnD ) { fEnD = EnD; }
55  void SetTim (std::vector<double> Tim ) { fTim = Tim; }
56 
57 #endif
58  // data members
59  // unsigned short fPlane; ///< plane number
60  // unsigned short fCell; ///< cell number
61  // geo::View_t fView; ///< view (geo::kX or geo::kY)
62  double fCoorX; ///< X coord of hit
63  double fCoorY; ///< Y coord of hit
64  double fCoorZ; ///< Z coord of hit
65  double fTotE; ///< Total Energy dep from all particles
66  unsigned short fNP; ///< size of vectors
67  std::vector<int> fTrID; ///< vector of sim track IDs
68  std::vector<int> fPID; ///< vector of sim particle IDs
69  std::vector<double> fEnD; ///< vector of energy deposits
70  std::vector<double> fTim; ///< vector of times
71 
72  // ClassDef(SimHit, 4); // True Cell Hit
73  };
74 }
75 
76 #endif // SIMHIT_H
77 
78 ////////////////////////////////////////////////////////////////////////
std::vector< int > PID() const
Definition: SimHit.h:39
std::vector< int > TrID() const
Definition: SimHit.h:38
double CoorZ() const
Definition: SimHit.h:35
double fCoorZ
Z coord of hit.
Definition: SimHit.h:64
std::vector< double > Tim() const
Definition: SimHit.h:41
std::vector< int > fPID
vector of sim particle IDs
Definition: SimHit.h:68
void Print() const
std::vector< double > EnD() const
Definition: SimHit.h:40
void SetTotE(double tote)
Definition: SimHit.h:50
double fCoorX
X coord of hit.
Definition: SimHit.h:62
void SetNP(unsigned short np)
Definition: SimHit.h:51
std::vector< double > fTim
vector of times
Definition: SimHit.h:70
double CoorY() const
Definition: SimHit.h:34
void SetCoorZ(double coorz)
Definition: SimHit.h:49
void SetPID(std::vector< int > PID)
Definition: SimHit.h:53
void SetTim(std::vector< double > Tim)
Definition: SimHit.h:55
double CoorX() const
Definition: SimHit.h:33
void SetTrID(std::vector< int > TrID)
Definition: SimHit.h:52
void SetCoorX(double coorx)
Definition: SimHit.h:47
std::vector< double > fEnD
vector of energy deposits
Definition: SimHit.h:69
void SetEnD(std::vector< double > EnD)
Definition: SimHit.h:54
double fCoorY
Y coord of hit.
Definition: SimHit.h:63
A rawdata::RawDigit with channel information decoded.
Definition: CellHit.h:27
code to link reconstructed objects back to the MC truth information
Definition: FillTruth.h:17
double TotE() const
Definition: SimHit.h:36
double fTotE
Total Energy dep from all particles.
Definition: SimHit.h:65
void SetCoorY(double coory)
Definition: SimHit.h:48
unsigned short fNP
size of vectors
Definition: SimHit.h:66
unsigned short NP() const
Definition: SimHit.h:37
std::vector< int > fTrID
vector of sim track IDs
Definition: SimHit.h:67