Import Geant4 10.7.0.beta source tree

This commit is contained in:
Gabriele Cosmo
2020-06-26 10:23:25 +02:00
parent c02c370437
commit 67ba86d073
1871 changed files with 174422 additions and 131884 deletions
@@ -6,12 +6,19 @@
Hadronic physics-list/constructors/stopping History
-----------------------------------------------
This file should be used to briefly summarize all major modifications
This file should be used to briefly summarize all major modifications
introduced in the code and keeptrack of all tags.
----------------------------------------------------------
* Reverse chronological order (last date on top), please *
----------------------------------------------------------
30-Apr-2020, Ben Morgan (phys-ctor-stopping-V10-06-01)
- Remove obsolete GRANULAR_DEPENDENCIES entries
21-Feb-2020, Vladimir Ivanchenko (phys-ctor-stopping-V10-06-00)
- cleanup of all constructors: fixed names; make all constructor
signatures universal, removed thread local members, added c++11
keywords
22-Oct-2019, Alberto Ribon (phys-ctor-stopping-V10-05-02)
- REAMDE : updated.
@@ -32,7 +39,7 @@ introduced in the code and keeptrack of all tags.
03-Nov-2016, Alberto Ribon (phys-ctor-stopping-V10-02-02)
- Written first draft of the README
16-October-2016, Michel Maire (phys-ctor-stopping-V10-02-01)
- add README
@@ -56,5 +63,5 @@ introduced in the code and keeptrack of all tags.
- Changes needed for MT: now G4VUserPhysicsList is a split class
10-Jan-2013, Gunter Folger (phys-ctor-stopping-V09-06-00)
- new directory structure introduced.
- new directory structure introduced.
constructors/stopping classes
@@ -55,12 +55,6 @@
#include "globals.hh"
#include "G4VPhysicsConstructor.hh"
class G4HadronicAbsorptionBertini;
class G4HadronicAbsorptionFritiof;
class G4MuonMinusCapture;
class G4StoppingPhysics : public G4VPhysicsConstructor {
public:
@@ -68,32 +62,27 @@ public:
G4StoppingPhysics( G4int ver = 1 );
G4StoppingPhysics( const G4String& name,
G4int ver = 1,
G4bool UseMuonMinusCapture=true );
G4int ver = 1,
G4bool UseMuonMinusCapture=true );
virtual ~G4StoppingPhysics();
public:
~G4StoppingPhysics() override;
// This method will be invoked in the Construct() method.
// each particle type will be instantiated
virtual void ConstructParticle();
virtual void ConstructParticle() override;
// This method will be invoked in the Construct() method.
// each physics process will be instantiated and
// registered to the process manager of each particle type
virtual void ConstructProcess();
virtual void ConstructProcess() override;
void SetMuonMinusCapture(G4bool val)
{ useMuonMinusCapture = val; };
private:
//G4MuonMinusCapture* muProcess;
//G4HadronicAbsorptionBertini* hBertiniProcess;
//G4HadronicAbsorptionFritiof* hFritiofProcess;
G4int verbose;
static G4ThreadLocal G4bool wasActivated;
G4bool useMuonMinusCapture;
};
#endif
@@ -50,26 +50,27 @@
#include "globals.hh"
#include "G4VPhysicsConstructor.hh"
class G4StoppingPhysicsFritiofWithBinaryCascade : public G4VPhysicsConstructor {
public:
G4StoppingPhysicsFritiofWithBinaryCascade( G4int ver = 1 );
G4StoppingPhysicsFritiofWithBinaryCascade( const G4String& name, G4int ver = 1,
G4bool UseMuonMinusCapture = true );
virtual ~G4StoppingPhysicsFritiofWithBinaryCascade();
G4bool useMuCapture = true );
~G4StoppingPhysicsFritiofWithBinaryCascade() override;
// This method will be invoked in the Construct() method.
// each particle type will be instantiated
virtual void ConstructParticle();
void ConstructParticle() override;
// This method will be invoked in the Construct() method.
// each physics process will be instantiated and
// registered to the process manager of each particle type
virtual void ConstructProcess();
void ConstructProcess() override;
void SetMuonMinusCapture(G4bool val)
{ useMuonMinusCapture = val; };
private:
G4int verbose;
static G4ThreadLocal G4bool wasActivated;
G4bool useMuonMinusCapture;
};
@@ -106,14 +106,11 @@ GEANT4_DEFINE_MODULE(NAME G4phys_ctor_stopping
G4had_mod_man
G4had_mod_util
G4had_lept_nuclear
G4had_neu_hp
G4had_preequ_exciton
G4had_string_diff
G4had_string_frag
G4had_string_man
G4had_theo_max
G4hadronic_HE
G4hadronic_LE
G4hadronic_bert_cascade
G4hadronic_binary
G4hadronic_coherent_elastic
@@ -57,40 +57,29 @@
#include "G4BaryonConstructor.hh"
#include "G4MuonMinus.hh"
#include "G4PionMinus.hh"
#include "G4BuilderType.hh"
// factory
#include "G4PhysicsConstructorFactory.hh"
//
G4_DECLARE_PHYSCONSTR_FACTORY(G4StoppingPhysics);
G4ThreadLocal G4bool G4StoppingPhysics::wasActivated = false;
G4StoppingPhysics::G4StoppingPhysics( G4int ver ) :
G4StoppingPhysics("stopping", ver)
{}
G4StoppingPhysics::
G4StoppingPhysics( G4int ver ) :
G4VPhysicsConstructor( "stopping" ),
//muProcess( 0 ), hBertiniProcess( 0 ), hFritiofProcess( 0 ),
verbose( ver ),
useMuonMinusCapture( true )
{
if ( verbose > 1 ) G4cout << "### G4StoppingPhysics" << G4endl;
}
G4StoppingPhysics::
G4StoppingPhysics( const G4String& name, G4int ver,
G4bool UseMuonMinusCapture ) :
G4StoppingPhysics::G4StoppingPhysics(const G4String& name, G4int ver,
G4bool useMuCapture) :
G4VPhysicsConstructor( name ),
// muProcess( 0 ), hBertiniProcess( 0 ), hFritiofProcess( 0 ),
verbose( ver ),
useMuonMinusCapture( UseMuonMinusCapture )
useMuonMinusCapture( useMuCapture )
{
SetPhysicsType(bStopping);
if ( verbose > 1 ) G4cout << "### G4StoppingPhysics" << G4endl;
}
G4StoppingPhysics::~G4StoppingPhysics() {}
void G4StoppingPhysics::ConstructParticle() {
// G4cout << "G4StoppingPhysics::ConstructParticle" << G4endl;
G4LeptonConstructor pLeptonConstructor;
@@ -103,21 +92,16 @@ void G4StoppingPhysics::ConstructParticle() {
pBaryonConstructor.ConstructParticle();
}
void G4StoppingPhysics::ConstructProcess() {
if ( verbose > 1 ) G4cout << "### G4StoppingPhysics::ConstructProcess "
<< wasActivated << G4endl;
if ( wasActivated ) return;
wasActivated = true;
<< G4endl;
G4MuonMinusCapture* muProcess;
G4HadronicAbsorptionBertini* hBertiniProcess;
G4HadronicAbsorptionFritiof* hFritiofProcess;
G4MuonMinusCapture* muProcess = nullptr;
G4HadronicAbsorptionBertini* hBertiniProcess = nullptr;
G4HadronicAbsorptionFritiof* hFritiofProcess = nullptr;
if ( useMuonMinusCapture ) {
muProcess = new G4MuonMinusCapture();
} else {
muProcess = 0;
}
hBertiniProcess = new G4HadronicAbsorptionBertini();
@@ -137,13 +121,11 @@ void G4StoppingPhysics::ConstructProcess() {
particle = myParticleIterator->value();
pmanager = particle->GetProcessManager();
if ( particle == G4MuonMinus::MuonMinus() ) {
if ( useMuonMinusCapture ) {
pmanager->AddRestProcess( muProcess );
if ( verbose > 1 ) {
G4cout << "### G4StoppingPhysics added G4MuonMinusCapture for "
<< particle->GetParticleName() << G4endl;
}
if (useMuonMinusCapture && particle == G4MuonMinus::MuonMinus()) {
pmanager->AddRestProcess( muProcess );
if ( verbose > 1 ) {
G4cout << "### G4StoppingPhysics added G4MuonMinusCapture for "
<< particle->GetParticleName() << G4endl;
}
}
@@ -48,30 +48,29 @@
#include "G4BaryonConstructor.hh"
#include "G4MuonMinus.hh"
#include "G4PionMinus.hh"
#include "G4BuilderType.hh"
// factory
#include "G4PhysicsConstructorFactory.hh"
//
G4_DECLARE_PHYSCONSTR_FACTORY( G4StoppingPhysicsFritiofWithBinaryCascade );
G4ThreadLocal G4bool G4StoppingPhysicsFritiofWithBinaryCascade::wasActivated = false;
G4StoppingPhysicsFritiofWithBinaryCascade::
G4StoppingPhysicsFritiofWithBinaryCascade( G4int ver ) :
G4VPhysicsConstructor( "stopping" ), verbose( ver ), useMuonMinusCapture( true ) {
if ( verbose > 1 ) G4cout << "### G4StoppingPhysicsFritiofWithBinaryCascade" << G4endl;
}
G4StoppingPhysicsFritiofWithBinaryCascade("stopping", ver)
{}
G4StoppingPhysicsFritiofWithBinaryCascade::
G4StoppingPhysicsFritiofWithBinaryCascade( const G4String& name, G4int ver,
G4bool UseMuonMinusCapture ) :
G4VPhysicsConstructor( name ), verbose( ver ), useMuonMinusCapture( UseMuonMinusCapture ) {
if ( verbose > 1 ) G4cout << "### G4StoppingPhysicsFritiofWithBinaryCascade" << G4endl;
G4VPhysicsConstructor( name ), verbose( ver ),
useMuonMinusCapture( UseMuonMinusCapture )
{
SetPhysicsType(bStopping);
if(verbose > 1) G4cout << "### G4StoppingPhysicsFritiofWithBinaryCascade"
<< G4endl;
}
G4StoppingPhysicsFritiofWithBinaryCascade::~G4StoppingPhysicsFritiofWithBinaryCascade() {}
@@ -87,14 +86,10 @@ void G4StoppingPhysicsFritiofWithBinaryCascade::ConstructParticle() {
pBaryonConstructor.ConstructParticle();
}
void G4StoppingPhysicsFritiofWithBinaryCascade::ConstructProcess() {
if ( verbose > 1 ) G4cout << "### G4StoppingPhysicsFritiofWithBinaryCascade::ConstructProcess "
<< wasActivated << G4endl;
if ( wasActivated ) return;
wasActivated = true;
if ( verbose > 1 ) G4cout << "### G4StoppingPhysicsFritiofWithBinaryCascade::ConstructProcess " << G4endl;
G4MuonMinusCapture* muProcess = 0;
G4MuonMinusCapture* muProcess = nullptr;
if ( useMuonMinusCapture ) {
muProcess = new G4MuonMinusCapture();
}
@@ -118,12 +113,11 @@ void G4StoppingPhysicsFritiofWithBinaryCascade::ConstructProcess() {
particle = myParticleIterator->value();
pmanager = particle->GetProcessManager();
if ( particle == G4MuonMinus::MuonMinus() ) {
if ( useMuonMinusCapture ) {
pmanager->AddRestProcess( muProcess );
if ( verbose > 1 ) {
G4cout << "### G4MuonMinusCapture added for " << particle->GetParticleName() << G4endl;
}
if (useMuonMinusCapture && particle == G4MuonMinus::MuonMinus() ) {
pmanager->AddRestProcess( muProcess );
if ( verbose > 1 ) {
G4cout << "### G4MuonMinusCapture added for "
<< particle->GetParticleName() << G4endl;
}
}
@@ -132,7 +126,8 @@ void G4StoppingPhysicsFritiofWithBinaryCascade::ConstructProcess() {
( ! particle->IsShortLived() ) ) {
// Use Fritiof/BinaryCascade for: anti-proton and anti-neutron
if ( particle == G4AntiProton::Definition() || particle == G4AntiNeutron::Definition() ) {
if ( particle == G4AntiProton::Definition() ||
particle == G4AntiNeutron::Definition() ) {
if ( hFritiofWithBinaryCascadeProcess->IsApplicable( *particle ) ) {
pmanager->AddRestProcess( hFritiofWithBinaryCascadeProcess );
if ( verbose > 1 ) {
@@ -141,7 +136,8 @@ void G4StoppingPhysicsFritiofWithBinaryCascade::ConstructProcess() {
}
}
// Use Fritiof/Precompound for: anti-lambda, anti-sigma0, anti-sigma+, anti-xi0 and anti-nuclei
// Use Fritiof/Precompound for:
// anti-lambda, anti-sigma0, anti-sigma+, anti-xi0 and anti-nuclei
} else if ( particle == G4AntiLambda::Definition() ||
particle == G4AntiSigmaZero::Definition() ||
particle == G4AntiSigmaPlus::Definition() ||
@@ -177,6 +173,5 @@ void G4StoppingPhysicsFritiofWithBinaryCascade::ConstructProcess() {
}
}
}
} // end of while loop
}