Import Geant4 10.3.0.beta source tree

This commit is contained in:
Gabriele Cosmo
2016-06-30 14:12:05 +02:00
parent a654a7ab1f
commit 4ec577e5c4
2021 changed files with 100995 additions and 78277 deletions
@@ -26,7 +26,7 @@
/// \file electromagnetic/TestEm5/src/EventAction.cc
/// \brief Implementation of the EventAction class
//
// $Id: EventAction.cc 76464 2013-11-11 10:22:56Z gcosmo $
// $Id: EventAction.cc 95802 2016-02-25 11:00:43Z gcosmo $
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
@@ -81,8 +81,9 @@ void EventAction::EndOfEventAction(const G4Event*)
run->CountTransmit (fTransmitFlag);
run->CountReflect (fReflectFlag);
G4AnalysisManager::Instance()->FillH1(1,fEnergyDeposit);
if (fEnergyDeposit > 0.)
G4AnalysisManager::Instance()->FillH1(1,fEnergyDeposit);
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
@@ -23,7 +23,7 @@
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
// $Id: PhysListEmStandard.cc 85279 2014-10-27 09:19:21Z gcosmo $
// $Id: PhysListEmStandard.cc 96400 2016-04-12 07:26:33Z gcosmo $
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
@@ -58,19 +58,27 @@
#include "G4IonParametrisedLossModel.hh"
#include "G4NuclearStopping.hh"
#include "G4EmProcessOptions.hh"
#include "G4MscStepLimitType.hh"
#include "G4LossTableManager.hh"
#include "G4UAtomicDeexcitation.hh"
#include "G4BuilderType.hh"
#include "G4SystemOfUnits.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
PhysListEmStandard::PhysListEmStandard(const G4String& name)
: G4VPhysicsConstructor(name)
{}
{
G4EmParameters* param = G4EmParameters::Instance();
param->SetDefaults();
param->SetMinEnergy(10*eV);
param->SetMaxEnergy(10*TeV);
param->SetNumberOfBinsPerDecade(10);
param->SetMscStepLimitType(fUseSafetyPlus);
SetPhysicsType(bElectromagnetic);
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
@@ -170,23 +178,6 @@ void PhysListEmStandard::ConstructProcess()
}
}
// Em options
//
// Main options and setting parameters are shown here.
// Several of them have default values.
//
G4EmProcessOptions emOptions;
//physics tables
//
emOptions.SetMinEnergy(10*eV); //default 100 eV
emOptions.SetMaxEnergy(10*TeV); //default 100 TeV
emOptions.SetDEDXBinning(12*10); //default=12*7
emOptions.SetLambdaBinning(12*10); //default=12*7
//multiple coulomb scattering
//
emOptions.SetMscStepLimitation(fUseSafetyPlus); //default=fUseSafety
// Deexcitation
//
@@ -26,7 +26,7 @@
/// \file electromagnetic/TestEm5/src/PhysListEmStandardSSM.cc
/// \brief Implementation of the PhysListEmStandardSSM class
//
// $Id: PhysListEmStandardSSM.cc 91972 2015-08-12 13:48:40Z gcosmo $
// $Id: PhysListEmStandardSSM.cc 96400 2016-04-12 07:26:33Z gcosmo $
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
@@ -57,8 +57,6 @@
#include "G4hIonisation.hh"
#include "G4ionIonisation.hh"
#include "G4EmProcessOptions.hh"
#include "G4SystemOfUnits.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
@@ -152,9 +150,6 @@ void PhysListEmStandardSSM::ConstructProcess()
pmanager->AddDiscreteProcess(new G4CoulombScattering);
}
}
// scattering
G4EmProcessOptions emOptions;
emOptions.SetPolarAngleLimit(0.0);
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
@@ -26,7 +26,7 @@
/// \file electromagnetic/TestEm5/src/PhysicsList.cc
/// \brief Implementation of the PhysicsList class
//
// $Id: PhysicsList.cc 90970 2015-06-12 08:14:00Z gcosmo $
// $Id: PhysicsList.cc 94973 2016-01-12 10:13:56Z gcosmo $
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
@@ -50,6 +50,8 @@
#include "G4EmPenelopePhysics.hh"
#include "G4EmLowEPPhysics.hh"
#include "G4HadronElasticPhysics.hh"
#include "G4Decay.hh"
#include "StepMax.hh"
@@ -74,7 +76,7 @@
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
PhysicsList::PhysicsList() : G4VModularPhysicsList(),
fMessenger(0),fEmPhysicsList(0)
fHadPhysicsList(nullptr)
{
fMessenger = new PhysicsListMessenger(this);
SetVerboseLevel(1);
@@ -99,23 +101,23 @@ PhysicsList::~PhysicsList()
void PhysicsList::ConstructParticle()
{
G4BosonConstructor pBosonConstructor;
pBosonConstructor.ConstructParticle();
G4BosonConstructor pBosonConstructor;
pBosonConstructor.ConstructParticle();
G4LeptonConstructor pLeptonConstructor;
pLeptonConstructor.ConstructParticle();
G4LeptonConstructor pLeptonConstructor;
pLeptonConstructor.ConstructParticle();
G4MesonConstructor pMesonConstructor;
pMesonConstructor.ConstructParticle();
G4MesonConstructor pMesonConstructor;
pMesonConstructor.ConstructParticle();
G4BaryonConstructor pBaryonConstructor;
pBaryonConstructor.ConstructParticle();
G4BaryonConstructor pBaryonConstructor;
pBaryonConstructor.ConstructParticle();
G4IonConstructor pIonConstructor;
pIonConstructor.ConstructParticle();
G4IonConstructor pIonConstructor;
pIonConstructor.ConstructParticle();
G4ShortLivedConstructor pShortLivedConstructor;
pShortLivedConstructor.ConstructParticle();
G4ShortLivedConstructor sLivedConstructor;
sLivedConstructor.ConstructParticle();
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
@@ -124,6 +126,7 @@ void PhysicsList::ConstructProcess()
{
AddTransportation();
fEmPhysicsList->ConstructProcess();
if(fHadPhysicsList) { fHadPhysicsList->ConstructProcess(); }
AddDecay();
AddStepMax();
}
@@ -162,13 +165,13 @@ void PhysicsList::AddStepMax()
theParticleIterator->reset();
while ((*theParticleIterator)()){
G4ParticleDefinition* particle = theParticleIterator->value();
G4ProcessManager* pmanager = particle->GetProcessManager();
G4ParticleDefinition* particle = theParticleIterator->value();
G4ProcessManager* pmanager = particle->GetProcessManager();
if (stepMaxProcess->IsApplicable(*particle) && !particle->IsShortLived())
{
pmanager ->AddDiscreteProcess(stepMaxProcess);
}
if (stepMaxProcess->IsApplicable(*particle) && !particle->IsShortLived())
{
pmanager ->AddDiscreteProcess(stepMaxProcess);
}
}
}
@@ -242,21 +245,24 @@ void PhysicsList::AddPhysicsList(const G4String& name)
delete fEmPhysicsList;
fEmPhysicsList = new G4EmStandardPhysicsGS();
} else if (name == "empenelope"){
} else if (name == "empenelope") {
fEmName = name;
delete fEmPhysicsList;
fEmPhysicsList = new G4EmPenelopePhysics();
} else if (name == "emlowenergy"){
} else if (name == "emlowenergy") {
fEmName = name;
delete fEmPhysicsList;
fEmPhysicsList = new G4EmLowEPPhysics();
} else if (name == "emlivermore"){
} else if (name == "emlivermore") {
fEmName = name;
delete fEmPhysicsList;
fEmPhysicsList = new G4EmLivermorePhysics();
} else if (name == "had_elastic" && !fHadPhysicsList) {
fHadPhysicsList = new G4HadronElasticPhysics();
} else {
G4cout << "PhysicsList::AddPhysicsList: <" << name << ">"