Import Geant4 10.3.1 source tree

This commit is contained in:
Gabriele Cosmo
2017-02-28 16:16:20 +01:00
parent a3452e42ac
commit 4597adb7c4
267 changed files with 14761 additions and 24650 deletions
@@ -1,4 +1,4 @@
$Id: History 101863 2016-12-02 12:48:47Z gcosmo $
$Id: History 102586 2017-02-09 09:51:41Z gcosmo $
-------------------------------------------------------------------
=========================================================
@@ -14,6 +14,14 @@ introduced in the code and keeptrack of all tags.
* Reverse chronological order (last date on top), please *
----------------------------------------------------------
23-Dec-2016, Laurent Desorgher (phys-ctor-decay-V10-02-09)
-G4RadioactiveDecayPhysics switch on the storing of all internal conversion data vector
(G4NuclearLevelData::GetInstance()->GetParameters()->SetStoreAllLevels(true)) for
correct gamma deexcitation modeling in radioactive decay.
16-Dec-2016, Vladimir Ivanchenko (phys-ctor-decay-V10-02-08)
- G4RadioactiveDecayPhysics - simplified list of EM parameters.
02-Dec-2016, Vladimir Ivanchenko (phys-ctor-decay-V10-02-07)
- G4RadioactiveDecayPhysics - fixed initialisation (also for the
cases when radioactive decay is registered before EM physics or
@@ -51,13 +51,11 @@ G4RadioactiveDecayPhysics::G4RadioactiveDecayPhysics(G4int)
: G4VPhysicsConstructor("G4RadioactiveDecay")//, theRadioactiveDecay(0)
{
G4EmParameters* param = G4EmParameters::Instance();
param->SetFluo(true);
param->SetAuger(true);
param->SetAugerCascade(true);
param->SetDeexcitationIgnoreCut(true);
param->AddMsc("world","G4RadioactiveDecay");
G4NuclearLevelData::GetInstance()->GetParameters()->SetUseFilesNEW(true);
G4NuclearLevelData::GetInstance()->GetParameters()->SetStoreAllLevels(true);
}
G4RadioactiveDecayPhysics::G4RadioactiveDecayPhysics(const G4String&)
@@ -1,4 +1,4 @@
$Id: History 101864 2016-12-02 12:50:38Z gcosmo $
$Id: History 102543 2017-02-08 14:16:52Z gcosmo $
-------------------------------------------------------------------
=========================================================
@@ -14,6 +14,10 @@ introduced in the code and keeptrack of all tags.
* Reverse chronological order (last date on top), please *
----------------------------------------------------------
19-January-2017 P. Gumplinger (phys-ctor-em-V10-02-39)
- add setCerenkov/ScintillationStackPhotons commands to
G4OpticalPhysicsMessenger and use them in G4OpticalPhysics
02-December-2016 V.Ivanchenko (phys-ctor-em-V10-02-38)
- G4EmModelActivator - added initialisation of atomic deexcitation
for radioactive decay (also for the cases when radioactive
@@ -96,6 +96,9 @@ class G4OpticalPhysics : public G4VPhysicsConstructor
void SetTrackSecondariesFirst(G4OpticalProcessIndex, G4bool );
void SetFiniteRiseTime(G4bool );
void SetCerenkovStackPhotons(G4bool );
void SetScintillationStackPhotons(G4bool );
void SetInvokeSD(G4bool );
private:
@@ -146,6 +149,11 @@ class G4OpticalPhysics : public G4VPhysicsConstructor
/// to call/not call InvokeSD method
G4bool fInvokeSD;
/// option to allow stacking of secondary Cerenkov photons
G4bool fCerenkovStackPhotons;
/// option to allow stacking of secondary Scintillation photons
G4bool fScintillationStackPhotons;
};
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
@@ -65,9 +65,11 @@ class G4UIcommand;
// - /process/optical/setTrackSecondariesFirst proc_name flag
// - /process/optical/defaults/cerenkov/setMaxPhotons val
// - /process/optical/defaults/cerenkov/setMaxBetaChange val
// - /process/optical/defaults/cerenkov/setStackPhotons flag
// - /process/optical/defaults/scintillation/setYieldFactor val
// - /process/optical/defaults/scintillation/setByParticleType val
// - /process/optical/defaults/scintillation/setFiniteRiseTime val
// - /process/optical/defaults/scintillation/setStackPhotons flag
// - /process/optical/defaults/wls/setTimeProfile val
// - /process/optical/defaults/boundary/setInvokeSD flag
@@ -115,6 +117,9 @@ private:
/// setCerenkovMaxBetaChange command
G4UIcmdWithADouble* fSetCerenkovMaxBetaChangeCmd;
/// setStackPhotons command
G4UIcmdWithABool* fSetCerenkovStackPhotonsCmd;
/// setScintillationYieldFactor command
G4UIcmdWithADouble* fSetScintillationYieldFactorCmd;
@@ -124,6 +129,9 @@ private:
/// setScintillationTrackInfo command
G4UIcmdWithABool* fSetScintillationTrackInfoCmd;
/// setStackPhotons command
G4UIcmdWithABool* fSetScintillationStackPhotonsCmd;
// /// setOpticalSurfaceModel command
// G4UIcmdWithAString* fSetOpticalSurfaceModelCmd;
@@ -72,7 +72,9 @@ G4OpticalPhysics::G4OpticalPhysics(G4int verbose, const G4String& name)
fFiniteRiseTime(false),
fScintillationByParticleType(false),
fScintillationTrackInfo(false),
fInvokeSD(true)
fInvokeSD(true),
fCerenkovStackPhotons(true),
fScintillationStackPhotons(true)
{
verboseLevel = verbose;
fMessenger = new G4OpticalPhysicsMessenger(this);
@@ -323,6 +325,7 @@ void G4OpticalPhysics::ConstructProcess()
ScintillationProcess->SetScintillationByParticleType(fScintillationByParticleType);
ScintillationProcess->SetScintillationTrackInfo(fScintillationTrackInfo);
ScintillationProcess->SetTrackSecondariesFirst(fProcessTrackSecondariesFirst[kScintillation]);
ScintillationProcess->SetStackPhotons(fScintillationStackPhotons);
G4EmSaturation* emSaturation = G4LossTableManager::Instance()->EmSaturation();
ScintillationProcess->AddSaturation(emSaturation);
UIhelpers::buildCommands(ScintillationProcess);
@@ -332,6 +335,7 @@ void G4OpticalPhysics::ConstructProcess()
CerenkovProcess->SetMaxNumPhotonsPerStep(fMaxNumPhotons);
CerenkovProcess->SetMaxBetaChangePerStep(fMaxBetaChange);
CerenkovProcess->SetTrackSecondariesFirst(fProcessTrackSecondariesFirst[kCerenkov]);
CerenkovProcess->SetStackPhotons(fCerenkovStackPhotons);
UIhelpers::buildCommands(CerenkovProcess);
OpProcesses[kCerenkov] = CerenkovProcess;
@@ -458,6 +462,16 @@ void G4OpticalPhysics::SetInvokeSD(G4bool invokeSD)
fInvokeSD = invokeSD;
}
void G4OpticalPhysics::SetCerenkovStackPhotons(G4bool stackingFlag)
{
fCerenkovStackPhotons = stackingFlag;
}
void G4OpticalPhysics::SetScintillationStackPhotons(G4bool stackingFlag)
{
fScintillationStackPhotons = stackingFlag;
}
void G4OpticalPhysics::Configure(G4OpticalProcessIndex index, G4bool isUse)
{
// Configure the physics constructor to use/not use a selected process.
@@ -66,9 +66,11 @@ G4OpticalPhysicsMessenger::G4OpticalPhysicsMessenger(
fSetOpProcessVerboseCmd(0),
fSetCerenkovMaxPhotonsCmd(0),
fSetCerenkovMaxBetaChangeCmd(0),
fSetCerenkovStackPhotonsCmd(0),
fSetScintillationYieldFactorCmd(0),
fSetScintillationByParticleTypeCmd(0),
fSetScintillationTrackInfoCmd(0),
fSetScintillationStackPhotonsCmd(0),
fSetWLSTimeProfileCmd(0),
fSetTrackSecondariesFirstCmd(0),
fSetFiniteRiseTimeCmd(0),
@@ -134,6 +136,13 @@ G4OpticalPhysicsMessenger::G4OpticalPhysicsMessenger(
fSetCerenkovMaxBetaChangeCmd->SetRange("CerenkovMaxBetaChange>=0");
fSetCerenkovMaxBetaChangeCmd->AvailableForStates(G4State_PreInit);
fSetCerenkovStackPhotonsCmd = new G4UIcmdWithABool("/process/optical/defaults/cerenkov/setStackPhotons", this);
fSetCerenkovStackPhotonsCmd->SetGuidance("Set default whether or not to stack secondary Cerenkov photons");
fSetCerenkovStackPhotonsCmd->SetGuidance("Note this command is used to set the default value,");
fSetCerenkovStackPhotonsCmd->SetGuidance("if process is not active command will not have effect.");
fSetCerenkovStackPhotonsCmd->SetParameterName("CerenkovStackPhotons", true);
fSetCerenkovStackPhotonsCmd->AvailableForStates(G4State_PreInit);
fSetScintillationYieldFactorCmd = new G4UIcmdWithADouble("/process/optical/defaults/scintillation/setYieldFactor", this);
fSetScintillationYieldFactorCmd->SetGuidance("Set scintillation yield factor");
fSetScintillationYieldFactorCmd->SetGuidance("Note this command is used to set the default value,");
@@ -162,6 +171,13 @@ G4OpticalPhysicsMessenger::G4OpticalPhysicsMessenger(
fSetFiniteRiseTimeCmd->SetParameterName("FiniteRiseTime", false);
fSetFiniteRiseTimeCmd->AvailableForStates(G4State_PreInit);
fSetScintillationStackPhotonsCmd = new G4UIcmdWithABool("/process/optical/defaults/scintillation/setStackPhotons", this);
fSetScintillationStackPhotonsCmd->SetGuidance("Set default whether or not to stack secondary Scintillation photons");
fSetScintillationStackPhotonsCmd->SetGuidance("Note this command is used to set the default value,");
fSetScintillationStackPhotonsCmd->SetGuidance("if process is not active command will not have effect.");
fSetScintillationStackPhotonsCmd->SetParameterName("ScintillationStackPhotons", true);
fSetScintillationStackPhotonsCmd->AvailableForStates(G4State_PreInit);
fSetWLSTimeProfileCmd = new G4UIcmdWithAString("/process/optical/defaults/wls/setTimeProfile", this);
fSetWLSTimeProfileCmd->SetGuidance("Set the WLS time profile (delta or exponential)");
fSetWLSTimeProfileCmd->SetParameterName("WLSTimeProfile", false);
@@ -184,9 +200,11 @@ G4OpticalPhysicsMessenger::~G4OpticalPhysicsMessenger()
delete fSetOpProcessVerboseCmd;
delete fSetCerenkovMaxPhotonsCmd;
delete fSetCerenkovMaxBetaChangeCmd;
delete fSetCerenkovStackPhotonsCmd;
delete fSetScintillationYieldFactorCmd;
delete fSetScintillationByParticleTypeCmd;
delete fSetScintillationTrackInfoCmd;
delete fSetScintillationStackPhotonsCmd;
delete fSetWLSTimeProfileCmd;
delete fSetTrackSecondariesFirstCmd;
delete fSetFiniteRiseTimeCmd;
@@ -266,6 +284,11 @@ void G4OpticalPhysicsMessenger::SetNewValue(G4UIcommand* command,
->SetMaxBetaChangePerStep(
fSetCerenkovMaxBetaChangeCmd->GetNewDoubleValue(newValue));
}
else if (command == fSetCerenkovStackPhotonsCmd) {
fOpticalPhysics
->SetCerenkovStackPhotons(
fSetCerenkovStackPhotonsCmd->GetNewBoolValue(newValue));
}
else if (command == fSetScintillationYieldFactorCmd) {
fOpticalPhysics
->SetScintillationYieldFactor(
@@ -286,6 +309,11 @@ void G4OpticalPhysicsMessenger::SetNewValue(G4UIcommand* command,
->SetFiniteRiseTime(
fSetFiniteRiseTimeCmd->GetNewBoolValue(newValue));
}
else if (command == fSetScintillationStackPhotonsCmd) {
fOpticalPhysics
->SetScintillationStackPhotons(
fSetScintillationStackPhotonsCmd->GetNewBoolValue(newValue));
}
else if (command == fSetWLSTimeProfileCmd) {
fOpticalPhysics->SetWLSTimeProfile(newValue);
}
@@ -1,4 +1,4 @@
$Id: History 101901 2016-12-07 08:38:58Z gcosmo $
$Id: History 102624 2017-02-10 08:22:14Z gcosmo $
-------------------------------------------------------------------
=========================================================
@@ -14,6 +14,11 @@ introduced in the code and keeptrack of all tags.
* Reverse chronological order (last date on top), please *
----------------------------------------------------------
09-Feb-2017, Makoto Asai (phys-ctor-hinelastic-V10-02-11)
- Print-out of the transition energy region between FTFP and BERT
in the physics lists FTFP_BERT_HP and G4HadronPhysicsFTFP_BERT_HP
is made only for the master thread.
07-Dec-2016, Alberto Ribon (phys-ctor-hinelastic-V10-02-10)
- G4HadronPhysicsFTFP_BERT_HP : changed the transition energy region
between FTFP and BERT in the physics list FTFP_BERT_HP to [3, 12] GeV,
@@ -23,7 +23,7 @@
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
// $Id: G4HadronPhysicsFTFP_BERT.cc 101872 2016-12-02 14:02:40Z gcosmo $
// $Id: G4HadronPhysicsFTFP_BERT.cc 102624 2017-02-10 08:22:14Z gcosmo $
//
//---------------------------------------------------------------------------
//
@@ -60,6 +60,7 @@
#include "G4CrossSectionDataSetRegistry.hh"
#include "G4PhysListUtil.hh"
#include "G4Threading.hh"
// factory
#include "G4PhysicsConstructorFactory.hh"
@@ -124,14 +125,16 @@ void G4HadronPhysicsFTFP_BERT::CreateModels()
G4double maxBERT_proton = 12.0 * GeV;
G4double minFTFP_neutron = 3.0 * GeV;
G4double maxBERT_neutron = 12.0 * GeV;
G4cout << G4endl
if(G4Threading::IsMasterThread()) {
G4cout << G4endl
<< " FTFP_BERT : new threshold between BERT and FTFP is over the interval " << G4endl
<< " for pions : " << minFTFP_pion/GeV << " to " << maxBERT_pion/GeV << " GeV" << G4endl
<< " for kaons : " << minFTFP_kaon/GeV << " to " << maxBERT_kaon/GeV << " GeV" << G4endl
<< " for proton : " << minFTFP_proton/GeV << " to " << maxBERT_proton/GeV << " GeV" << G4endl
<< " for neutron : " << minFTFP_neutron/GeV << " to " << maxBERT_neutron/GeV << " GeV" << G4endl
<< G4endl;
}
tpdata->theNeutrons=new G4NeutronBuilder;
tpdata->theFTFPNeutron=new G4FTFPNeutronBuilder(QuasiElastic);
@@ -53,6 +53,7 @@
#include "G4CrossSectionDataSetRegistry.hh"
#include "G4PhysListUtil.hh"
#include "G4Threading.hh"
// factory
#include "G4PhysicsConstructorFactory.hh"
@@ -120,13 +121,15 @@ void G4HadronPhysicsFTFP_BERT_HP::CreateModels()
G4double minFTFP_neutron = 3.0 * GeV;
G4double maxBERT_neutron = 12.0 * GeV;
G4cout << G4endl
if(G4Threading::IsMasterThread()) {
G4cout << G4endl
<< " FTFP_BERT_HP : new threshold between BERT and FTFP is over the interval " << G4endl
<< " for pions : " << minFTFP_pion/GeV << " to " << maxBERT_pion/GeV << " GeV" << G4endl
<< " for kaons : " << minFTFP_kaon/GeV << " to " << maxBERT_kaon/GeV << " GeV" << G4endl
<< " for proton : " << minFTFP_proton/GeV << " to " << maxBERT_proton/GeV << " GeV" << G4endl
<< " for neutron : " << minFTFP_neutron/GeV << " to " << maxBERT_neutron/GeV << " GeV" << G4endl
<< G4endl;
}
tpdata->theNeutrons=new G4NeutronBuilder( true ); // Fission on
tpdata->theFTFPNeutron=new G4FTFPNeutronBuilder(QuasiElastic);
@@ -1,4 +1,4 @@
$Id: History 101161 2016-11-08 08:31:49Z gcosmo $
$Id: History 102622 2017-02-10 08:17:47Z gcosmo $
-------------------------------------------------------------------
=========================================================
@@ -14,6 +14,9 @@ introduced in the code and keeptrack of all tags.
* Reverse chronological order (last date on top), please *
----------------------------------------------------------
09-Feb-2017, M. Asai (phys-ctor-limiters-V10-02-09)
- Print-out of G4NeutronTrackingCut is made only for the master thread.
07-Nov-2016, M. Verderi (phys-ctor-limiters-V10-02-08)
- restore G4FastSimulationPhysics utility.
- requires param-V10-02-01
@@ -23,7 +23,7 @@
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
// $Id: G4NeutronTrackingCut.cc 83417 2014-08-21 15:29:32Z gcosmo $
// $Id: G4NeutronTrackingCut.cc 102622 2017-02-10 08:17:47Z gcosmo $
//
//---------------------------------------------------------------------------
//
@@ -45,6 +45,8 @@
#include "G4NeutronKiller.hh"
#include "G4HadronicProcessStore.hh"
#include "G4Threading.hh"
// factory
#include "G4PhysicsConstructorFactory.hh"
//
@@ -80,7 +82,7 @@ void G4NeutronTrackingCut::ConstructProcess()
G4ParticleDefinition * particle = G4Neutron::Neutron();
G4ProcessManager * pmanager = particle->GetProcessManager();
if(verbose > 0) {
if(verbose > 0 && G4Threading::IsMasterThread()) {
G4String pn = particle->GetParticleName();//Avoid data-race when passing
//this string to G4MTcout
G4cout << "### Adding tracking cuts for " << pn
+6 -1
View File
@@ -1,4 +1,4 @@
$Id: History 99975 2016-10-13 07:23:55Z gcosmo $
$Id: History 102588 2017-02-09 10:00:46Z gcosmo $
-------------------------------------------------------------------
=========================================================
@@ -14,6 +14,11 @@ introduced in the code and keeptrack of all tags.
* Reverse chronological order (last date on top), please *
----------------------------------------------------------
07-February-2017 V.Ivanchenko (phys-lists-V10-02-11)
- G4PhysListFactory - add single scattering EM option (required by
several user groups), one need to add "__SS" to the reference
physics list name
12-October-2016 G.Folger (phys-lists-V10-02-10)
- remove direct use of theParticleIterator, get this from G4ParticleTable.
fix required by clang39 on Windows and MAC
@@ -23,7 +23,7 @@
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
// $Id: G4PhysListFactory.cc 96327 2016-04-06 15:50:53Z gcosmo $
// $Id: G4PhysListFactory.cc 102588 2017-02-09 10:00:46Z gcosmo $
//
//---------------------------------------------------------------------------
//
@@ -67,6 +67,7 @@
#include "G4EmStandardPhysics_option3.hh"
#include "G4EmStandardPhysics_option4.hh"
#include "G4EmStandardPhysicsGS.hh"
#include "G4EmStandardPhysicsSS.hh"
#include "G4EmLivermorePhysics.hh"
#include "G4EmPenelopePhysics.hh"
@@ -84,8 +85,8 @@ G4PhysListFactory::G4PhysListFactory()
listnames_hadr.push_back(ss[i]);
}
nlists_em = 8;
G4String s1[8] = {"","_EMV","_EMX","_EMY","_EMZ","_LIV","_PEN","__GS"};
nlists_em = 9;
G4String s1[9] = {"","_EMV","_EMX","_EMY","_EMZ","_LIV","_PEN","__GS","__SS"};
for(size_t i=0; i<nlists_em; ++i) {
listnames_em.push_back(s1[i]);
}