83 if(strcmp(physVol->
GetName(),
"FCALEmModulePhysical")== 0 ||
84 strcmp(physVol->
GetName(),
"F1LArGapPhysical") == 0)
86 EdepFCALEm = EdepFCALEm + Edep;
89 if( (strcmp(physVol->
GetName(),
"FCALHadModulePhysical") == 0) ||
90 (strcmp(physVol->
GetName(),
"CuPlateAPhysical") == 0) ||
91 (strcmp(physVol->
GetName(),
"CuPlateBPhysical") == 0) ||
92 (strcmp(physVol->
GetName(),
"WAbsorberPhysical") == 0) ||
93 (strcmp(physVol->
GetName(),
"F2RodPhysical") == 0) ||
94 (strcmp(physVol->
GetName(),
"F2LArGapPhysical") == 0) )
96 EdepFCALHad = EdepFCALHad + Edep;
108 IDnow = EventNo + 10000*TrackID+ 100000000*ParentID;
122 Secondaries[NSecondaries][2] = PrimaryVertex.
x();
123 Secondaries[NSecondaries][3] = PrimaryVertex.
y();
124 Secondaries[NSecondaries][4] = PrimaryVertex.
z();
125 Secondaries[NSecondaries][5] = (aDynamicParticle->
GetMomentum()).
x();
126 Secondaries[NSecondaries][6] = (aDynamicParticle->
GetMomentum()).
y();
127 Secondaries[NSecondaries][7] = (aDynamicParticle->
GetMomentum()).
z();
129 Secondaries[NSecondaries][9] = aDynamicParticle->
GetTotalEnergy();
142 if(TrackID != 1 && ParentID == 1 && (strcmp(Material,
"Air")==0) && (TrackPos.
z() > 135.*
cm))
148 Distance = PrimaryVertex - SecondaryVertex ;
149 VectorProduct = PrimaryDirection.
cross(SecondaryDirection);
154 VectorProduct = Temp.
cross(PrimaryDirection);
157 VectorProductMagnitude = VectorProduct.
mag();
158 if(VectorProductMagnitude == 0.)
162 VectorProductNorm = (1./VectorProduct.
mag()) * VectorProduct ;
164 DistOfClosestApproach = Distance * VectorProductNorm ;
166 if(std::abs(DistOfClosestApproach) < DCACut)
169 Secondaries[0][0] = NSecondaries;
174 Secondaries[NSecondaries][5] =(aDynamicParticle->
GetMomentum()).
x();
175 Secondaries[NSecondaries][6] = (aDynamicParticle->
GetMomentum()).
y();
176 Secondaries[NSecondaries][7] = (aDynamicParticle->
GetMomentum()).
z();
178 Secondaries[NSecondaries][9] = aDynamicParticle->
GetTotalEnergy();
192 OutOfWorldTracksData[0][0] = NTracks;
200 OutOfWorldTracksData[NTracks][5] = (aDynamicParticle->
GetMomentum()).
x();
201 OutOfWorldTracksData[NTracks][6] = (aDynamicParticle->
GetMomentum()).
y();
202 OutOfWorldTracksData[NTracks][7] = (aDynamicParticle->
GetMomentum()).
z();
206 OutOfWorldTracksData[NTracks][9] = aDynamicParticle->
GetTotalEnergy();
219 EdepFCALEm = EdepFCALHad = 0.;
221 for(
G4int i=0; i<6000; i++)
223 for(
G4int j=0; j<11; j++)
225 OutOfWorldTracksData[i][j] = 0.;
226 Secondaries[i][j] = 0.;
232 return OutOfWorldTracksData[i][j];
236 return Secondaries[i][j];
240 if(strcmp(FCAL,
"FCALEm") == 0) {
243 if(strcmp(FCAL,
"FCALHad") == 0) {
virtual void UserSteppingAction(const G4Step *)
G4ParticleDefinition * GetDefinition() const
G4int GetParentID() const
G4double GetKineticEnergy() const
CLHEP::Hep3Vector G4ThreeVector
G4double GetTotalEnergy() const
G4VPhysicalVolume * GetVolume(G4int depth=0) const
const G4DynamicParticle * GetDynamicParticle() const
virtual ~FCALSteppingAction()
const G4String & GetName() const
G4int GetPDGEncoding() const
G4double GetSecondaries(G4int, G4int)
const G4String & GetParticleName() const
G4VPhysicalVolume * GetNextVolume() const
G4double GetTotalMomentum() const
G4GLOB_DLL std::ostream G4cout
G4int GetCurrentStepNumber() const
const G4String & GetName() const
const G4ThreeVector & GetVertexPosition() const
G4double GetTotalEnergyDeposit() const
G4Material * GetMaterial() const
G4double GetOutOfWorldTracks(G4int, G4int)
G4double GetEdepFCAL(G4String)
const G4VTouchable * GetTouchable() const
Hep3Vector cross(const Hep3Vector &) const
G4Track * GetTrack() const
const G4ThreeVector & GetVertexMomentumDirection() const
G4ThreeVector GetMomentum() const