00001
00015 #ifndef MCSHOWER_HH
00016 #define MCSHOWER_HH
00017
00018 #include "data_base.hh"
00019
00020 namespace larlight {
00026 class mcshower : public data_base {
00027
00028 public:
00029
00031 mcshower(DATA::DATA_TYPE type=DATA::MCShower);
00032
00034 virtual ~mcshower(){}
00035
00037 mcshower(const mcshower& origin) : data_base(origin),
00038 fMotherPDGID(origin.fMotherPDGID),
00039 fMotherTrackID(origin.fMotherTrackID),
00040 fMotherVtx(origin.fMotherVtx),
00041 fMotherMomentum(origin.fMotherMomentum),
00042 fMotherPhi(origin.fMotherPhi),
00043 fMotherTheta(origin.fMotherTheta),
00044 fMotherAngleU(origin.fMotherAngleU),
00045 fMotherAngleV(origin.fMotherAngleV),
00046 fMotherAngleW(origin.fMotherAngleW),
00047 fDaughterTrackID(origin.fDaughterTrackID),
00048 fDaughterVtx(origin.fDaughterVtx),
00049 fDaughterMomentum(origin.fDaughterMomentum),
00050 fDaughterPhi(origin.fDaughterPhi),
00051 fDaughterTheta(origin.fDaughterTheta),
00052 fDaughterAngleU(origin.fDaughterAngleU),
00053 fDaughterAngleV(origin.fDaughterAngleV),
00054 fDaughterAngleW(origin.fDaughterAngleW),
00055 fChargeU(origin.fChargeU),
00056 fChargeV(origin.fChargeV),
00057 fChargeW(origin.fChargeW),
00058 fEdepVtx(origin.fEdepVtx)
00059 {}
00060
00062 virtual void clear_data();
00063
00064
00065
00067 Int_t MotherPDGID() const { return fMotherPDGID; }
00068
00070 UInt_t MotherTrackID() const { return fMotherTrackID; }
00071
00073 const std::vector<Double_t>& MotherPosition() const { return fMotherVtx; }
00074
00076 const std::vector<Double_t>& MotherMomentum() const { return fMotherMomentum; }
00077
00079 void MotherAngle3D (Double_t &phi, Double_t &theta) const
00080 { phi = fMotherPhi; theta = fMotherTheta;}
00081
00083 Double_t MotherAngle2D(const GEO::View_t view) const;
00084
00086 const std::vector<UInt_t>& DaughterTrackID() const
00087 { return fDaughterTrackID; }
00088
00090 const std::vector<Float_t>& DaughterPosition() const
00091 { return fDaughterVtx; }
00092
00094 const std::vector<Float_t>& DaughterMomentum() const
00095 { return fDaughterMomentum; }
00096
00098 void DaughterAngle3D(Float_t &phi, Float_t &theta) const
00099 { phi = fDaughterPhi; theta = fDaughterTheta; }
00100
00102 Float_t DaughterAngle2D(const GEO::View_t view) const;
00103
00105 Float_t Charge(const GEO::View_t view) const;
00106
00108 const std::vector<std::vector<Float_t> >& DaughterPoints() const
00109 { return fEdepVtx; }
00110
00111
00112
00113
00114 void SetMotherID(Int_t pdgid, UInt_t trackid)
00115 { fMotherPDGID = pdgid; fMotherTrackID = trackid; }
00116
00117 void SetMotherAngles(Double_t phi, Double_t theta, Double_t u, Double_t v, Double_t w)
00118 { fMotherPhi = phi; fMotherTheta = theta; fMotherAngleU = u; fMotherAngleV = v; fMotherAngleW = w; }
00119
00120 void SetMotherPoint(const std::vector<Double_t> &vtx);
00121
00122 void SetMotherMomentum(const std::vector<Double_t> &mom);
00123
00124 void SetDaughterPosition(const std::vector<Float_t> &vtx);
00125
00126 void SetDaughterMomentum(const std::vector<Float_t> &mom);
00127
00128 void SetDaughterTrackList(const std::vector<UInt_t> &list)
00129 { fDaughterTrackID = list; }
00130
00131 void SetDaughterAngles(Double_t phi, Double_t theta, Double_t u, Double_t v, Double_t w)
00132 { fDaughterPhi = phi; fDaughterTheta = theta; fDaughterAngleU = u; fDaughterAngleV = v; fDaughterAngleW = w; }
00133
00134 void SetPlaneCharge(Float_t qU, Float_t qV, Float_t qW)
00135 { fChargeU = qU; fChargeV = qV; fChargeW = qW; }
00136
00137 void AddEdepVtx(const std::vector<Float_t>& vtx);
00138
00139 void SetEdepVtx(const std::vector<std::vector<Float_t> >& vtx);
00140
00141 private:
00142
00143
00144 Int_t fMotherPDGID;
00145 UInt_t fMotherTrackID;
00146 std::vector<Double_t> fMotherVtx;
00147 std::vector<Double_t> fMotherMomentum;
00148
00149 Double_t fMotherPhi;
00151 Double_t fMotherTheta;
00153 Double_t fMotherAngleU;
00155 Double_t fMotherAngleV;
00157 Double_t fMotherAngleW;
00158
00159
00160 std::vector<UInt_t> fDaughterTrackID;
00161 std::vector<Float_t> fDaughterVtx;
00162 std::vector<Float_t> fDaughterMomentum;
00163
00164 Float_t fDaughterPhi;
00166 Float_t fDaughterTheta;
00168 Float_t fDaughterAngleU;
00170 Float_t fDaughterAngleV;
00172 Float_t fDaughterAngleW;
00173
00174
00175 Float_t fChargeU;
00176 Float_t fChargeV;
00177 Float_t fChargeW;
00178
00180 std::vector<std::vector<Float_t> > fEdepVtx;
00181
00183 ClassDef(mcshower,2)
00185
00186 };
00187
00192 class event_mcshower : public std::vector<larlight::mcshower>,
00193 public event_base {
00194
00195 public:
00196
00198 event_mcshower(DATA::DATA_TYPE type=DATA::MCShower);
00199
00201 event_mcshower(const event_mcshower& original) : std::vector<larlight::mcshower>(original),
00202 event_base(original)
00203 {}
00204
00206 ~event_mcshower(){}
00207
00209 virtual void clear_data(){event_base::clear_data(); clear();}
00210
00211 private:
00212
00214 ClassDef(event_mcshower,1)
00216 };
00217
00218 }
00219 #endif
00220