3 #include "TpcSimIonisationTrack.h"
76 Double_t xinit= 0, yinit =0 , zinit = 0;
77 Double_t xfin = 0, yfin = 0, zfin = 0;
80 for(Int_t i = 0; i<npoints; i++){
81 if(
gHarpoDebug>2) Info(
"ProcessTrack",
"Point %d",i);
84 Double_t x0 = point->
GetX();
85 Double_t y0 = point->
GetY();
86 Double_t z0 = point->
GetZ();
87 Double_t t0 = point->
GetT();
93 Double_t length = TMath::Sqrt((x0-xfin)*(x0-xfin) + (y0-yfin)*(y0-yfin) + (z0-zfin)*(z0-zfin));
97 Int_t nElectrons = point->
GetNe();
100 mean += nElectrons*1./length;
102 for(Int_t j = 0; j<nElectrons; j++){
114 Double_t length2 = TMath::Sqrt((xinit-xfin)*(xinit-xfin) + (yinit-yfin)*(yinit-yfin) + (zinit-zfin)*(zinit-zfin));
117 if(npoints && length2){
120 Info(
"ProcessTrack",
"%d electrons / %.3g mm = %.3g e/cm %.3g e/cm",nTot,length2,10*nTot/length2, 10*mean);
131 if(
gHarpoDebug>1) Info(
"StartEvent",
"Reset readout");
135 if(
gHarpoDebug>1) Info(
"StartEvent",
"Reset electronics");
virtual ~HarpoSimChamber()
Int_t ProcessTrack(TpcSimIonisationTrack *tr)
HarpoSimElectronics * fDigi
enum hSimReadoutRegion_ hSimReadoutRegion
Harpo Reader Type.
Int_t DriftElectron(Double_t x0, Double_t y0, Double_t z0, Double_t t0, Double_t &xEnd, Double_t &yEnd, Double_t &zEnd, Double_t &tEnd)
HarpoSimReadout * fReadout
TpcSimIonisationPoint * GetPoint(Int_t i)
A class store HARPO row DCC event data and header. End provide access metods to the row data...
TpcSimDriftChamber * fDriftChamber
Transfer region 2 (between top and bottom GEM)
HarpoSimEvent * ProcessEvent(TpcSimMCEvent *ev)
HarpoSimStrips * ProcessElectron(Double_t x, Double_t y, Double_t t, hSimReadoutRegion region)