Import Geant4 9.1.0 source tree

This commit is contained in:
Gabriele Cosmo
2016-06-09 15:37:50 +02:00
parent a8e9364cea
commit 96c8bcd0af
6923 changed files with 198390 additions and 41849 deletions
+21 -2
View File
@@ -24,8 +24,8 @@
// ********************************************************************
//
//
// $Id: G4OpWLS.cc,v 1.8 2006/06/29 21:08:56 gunter Exp $
// GEANT4 tag $Name: geant4-09-00 $
// $Id: G4OpWLS.cc,v 1.9 2007/10/30 03:53:36 gum Exp $
// GEANT4 tag $Name: geant4-09-01 $
//
////////////////////////////////////////////////////////////////////////
// Optical Photon WaveLength Shifting (WLS) Class Implementation
@@ -120,6 +120,25 @@ G4OpWLS::PostStepDoIt(const G4Track& aTrack, const G4Step& aStep)
G4int NumPhotons = 1;
if (aMaterialPropertiesTable->ConstPropertyExists("WLSMEANNUMBERPHOTONS")) {
G4double MeanNumberOfPhotons = aMaterialPropertiesTable->
GetConstProperty("WLSMEANNUMBERPHOTONS");
NumPhotons = G4int(G4Poisson(MeanNumberOfPhotons));
if (NumPhotons <= 0) {
// return unchanged particle and no secondaries
aParticleChange.SetNumberOfSecondaries(0);
return G4VDiscreteProcess::PostStepDoIt(aTrack, aStep);
}
}
aParticleChange.SetNumberOfSecondaries(NumPhotons);
G4int materialIndex = aMaterial->GetIndex();