4 #include "G4UnitsTable.hh" 15 string hd_msg = Opt.
args[
"LOG_MSG"].args +
" CTOF Hit Process " ;
16 double HIT_VERBOSITY = Opt.
args[
"HIT_VERBOSITY"].arg;
19 HCname =
"CTOF Hit Process";
24 int nsteps = aHit->
GetPos().size();
28 vector<G4double> Edep = aHit->
GetEdep();
29 for(
int s=0; s<nsteps; s++) Etot = Etot + Edep[s];
34 x = y = z = lx = ly = lz = 0;
35 vector<G4ThreeVector> pos = aHit->
GetPos();
36 vector<G4ThreeVector> Lpos = aHit->
GetLPos();
39 for(
int s=0; s<nsteps; s++)
41 x = x + pos[s].x()*Edep[s]/Etot;
42 y = y + pos[s].y()*Edep[s]/Etot;
43 z = z + pos[s].z()*Edep[s]/Etot;
44 lx = lx + Lpos[s].x()*Edep[s]/Etot;
45 ly = ly + Lpos[s].y()*Edep[s]/Etot;
46 lz = lz + Lpos[s].z()*Edep[s]/Etot;
60 vector<G4double> times = aHit->
GetTime();
61 for(
int s=0; s<nsteps; s++) time = time + times[s]/nsteps;
64 double Ene = aHit->
GetE();
66 out.
raws.push_back(Etot);
67 out.
raws.push_back(x);
68 out.
raws.push_back(y);
69 out.
raws.push_back(z);
70 out.
raws.push_back(lx);
71 out.
raws.push_back(ly);
72 out.
raws.push_back(lz);
73 out.
raws.push_back(time);
78 out.
raws.push_back(Ene);
92 cout << hd_msg <<
" paddle: " << paddle <<
" x=" << x/cm <<
" y=" << y/cm <<
" z=" << z/cm << endl;
94 out.
dgtz.push_back(paddle);
102 id[
id.size()-1].id_sharing = 1;
vector< double > raws
Raw information.
vector< identifier > GetId()
string HCname
Hit Collection name.
vector< identifier > identity
Identifier.
vector< G4ThreeVector > GetLPos()
vector< G4ThreeVector > GetPos()
vector< identifier > ProcessID(vector< identifier >, G4Step *, detector, gemc_opts)
Method to calculate new identifier.
vector< double > GetTime()
map< string, opts > args
Options map.
vector< double > GetEdep()
PH_output ProcessHit(MHit *, gemc_opts)
Method to process the hit.
vector< int > dgtz
Digitized information.