Skip to content

Commit

Permalink
release 1.3 code
Browse files Browse the repository at this point in the history
  • Loading branch information
emiliomendozacembranos committed Oct 30, 2024
1 parent 5d07d11 commit 6bf8671
Show file tree
Hide file tree
Showing 219 changed files with 5,180 additions and 6,385 deletions.
10 changes: 10 additions & 0 deletions History
Original file line number Diff line number Diff line change
@@ -1,5 +1,15 @@


================================================================================
March 2022
--------------------------------------------------------------------------------
E. Mendoza
- SaG4n.01.03
+ Due to changes in the Geant4 code, earlier SaG4n versions do not compile
in Geant4.11. SaG4n.01.03 is the same as SaG4n.01.02, but with the changes
needed to be compiled with version Geant4.11.
================================================================================

================================================================================
January 2021
--------------------------------------------------------------------------------
Expand Down
Empty file modified PhysicsListFiles/G4SaG4nParticleHP_include/G4ENDFTapeRead.hh
100755 → 100644
Empty file.
Empty file.
Empty file modified PhysicsListFiles/G4SaG4nParticleHP_include/G4FFGEnumerations.hh
100755 → 100644
Empty file.
Empty file.
Empty file.
Empty file modified PhysicsListFiles/G4SaG4nParticleHP_include/G4FPYNubarValues.hh
100755 → 100644
Empty file.
Empty file modified PhysicsListFiles/G4SaG4nParticleHP_include/G4FPYSamplingOps.hh
100755 → 100644
Empty file.
Empty file.
Empty file.
4 changes: 4 additions & 0 deletions PhysicsListFiles/G4SaG4nParticleHP_include/G4FissionProductYieldDist.hh
100755 → 100644
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,10 @@ private:
/** Initialize is a common function called by all constructors. */
void Initialize( std::istringstream& dataStream );

#ifdef G4MULTITHREADED
static G4Mutex fissprodMutex;
#endif

public:
// Functions
/** Generates a fission event using default sampling and returns the pointer
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ class G4SaG4nParticleHP2AInelasticFS : public G4SaG4nParticleHPInelasticBaseFS
{
public:

G4SaG4nParticleHP2AInelasticFS(){}
G4SaG4nParticleHP2AInelasticFS();
~G4SaG4nParticleHP2AInelasticFS(){}
void Init (G4double A, G4double Z, G4int M, G4String & dirName, G4String & aFSType, G4ParticleDefinition*);
G4HadFinalState * ApplyYourself(const G4HadProjectile & theTrack);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ class G4SaG4nParticleHP2N2AInelasticFS : public G4SaG4nParticleHPInelasticBaseFS
{
public:

G4SaG4nParticleHP2N2AInelasticFS(){}
G4SaG4nParticleHP2N2AInelasticFS();
~G4SaG4nParticleHP2N2AInelasticFS(){}
void Init (G4double A, G4double Z, G4int M, G4String & dirName, G4String & aFSType, G4ParticleDefinition*);
G4HadFinalState * ApplyYourself(const G4HadProjectile & theTrack);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ class G4SaG4nParticleHP2NAInelasticFS : public G4SaG4nParticleHPInelasticBaseFS
{
public:

G4SaG4nParticleHP2NAInelasticFS(){}
G4SaG4nParticleHP2NAInelasticFS();
~G4SaG4nParticleHP2NAInelasticFS(){}
void Init (G4double A, G4double Z, G4int M, G4String & dirName, G4String & aFSType, G4ParticleDefinition*);
G4HadFinalState * ApplyYourself(const G4HadProjectile & theTrack);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ class G4SaG4nParticleHP2NDInelasticFS : public G4SaG4nParticleHPInelasticBaseFS
{
public:

G4SaG4nParticleHP2NDInelasticFS(){}
G4SaG4nParticleHP2NDInelasticFS();
~G4SaG4nParticleHP2NDInelasticFS(){}
void Init (G4double A, G4double Z, G4int M, G4String & dirName, G4String & aFSType, G4ParticleDefinition*);
G4HadFinalState * ApplyYourself(const G4HadProjectile & theTrack);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ class G4SaG4nParticleHP2NInelasticFS : public G4SaG4nParticleHPInelasticBaseFS
{
public:

G4SaG4nParticleHP2NInelasticFS(){}
G4SaG4nParticleHP2NInelasticFS();
~G4SaG4nParticleHP2NInelasticFS(){}
void Init (G4double A, G4double Z, G4int M, G4String & dirName, G4String & aFSType, G4ParticleDefinition*);
G4HadFinalState * ApplyYourself(const G4HadProjectile & theTrack);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ class G4SaG4nParticleHP2NPInelasticFS : public G4SaG4nParticleHPInelasticBaseFS
{
public:

G4SaG4nParticleHP2NPInelasticFS(){}
G4SaG4nParticleHP2NPInelasticFS();
~G4SaG4nParticleHP2NPInelasticFS(){}
void Init (G4double A, G4double Z, G4int M, G4String & dirName, G4String & aFSType, G4ParticleDefinition*);
G4HadFinalState * ApplyYourself(const G4HadProjectile & theTrack);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ class G4SaG4nParticleHP2PInelasticFS : public G4SaG4nParticleHPInelasticBaseFS
{
public:

G4SaG4nParticleHP2PInelasticFS(){}
G4SaG4nParticleHP2PInelasticFS();
~G4SaG4nParticleHP2PInelasticFS(){}
void Init (G4double A, G4double Z, G4int M, G4String & dirName, G4String & aFSType, G4ParticleDefinition*);
G4HadFinalState * ApplyYourself(const G4HadProjectile & theTrack);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ class G4SaG4nParticleHP3AInelasticFS : public G4SaG4nParticleHPInelasticBaseFS
{
public:

G4SaG4nParticleHP3AInelasticFS(){}
G4SaG4nParticleHP3AInelasticFS();
~G4SaG4nParticleHP3AInelasticFS(){}
void Init (G4double A, G4double Z, G4int M, G4String & dirName, G4String & aFSType, G4ParticleDefinition*);
G4HadFinalState * ApplyYourself(const G4HadProjectile & theTrack);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ class G4SaG4nParticleHP3NAInelasticFS : public G4SaG4nParticleHPInelasticBaseFS
{
public:

G4SaG4nParticleHP3NAInelasticFS(){}
G4SaG4nParticleHP3NAInelasticFS();
~G4SaG4nParticleHP3NAInelasticFS(){}
void Init (G4double A, G4double Z, G4int M, G4String & dirName, G4String & aFSType, G4ParticleDefinition*);
G4HadFinalState * ApplyYourself(const G4HadProjectile & theTrack);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ class G4SaG4nParticleHP3NInelasticFS : public G4SaG4nParticleHPInelasticBaseFS
{
public:

G4SaG4nParticleHP3NInelasticFS(){}
G4SaG4nParticleHP3NInelasticFS();
~G4SaG4nParticleHP3NInelasticFS(){}
void Init (G4double A, G4double Z, G4int M, G4String & dirName, G4String & aFSType, G4ParticleDefinition*);
G4HadFinalState * ApplyYourself(const G4HadProjectile & theTrack);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ class G4SaG4nParticleHP3NPInelasticFS : public G4SaG4nParticleHPInelasticBaseFS
{
public:

G4SaG4nParticleHP3NPInelasticFS(){}
G4SaG4nParticleHP3NPInelasticFS();
~G4SaG4nParticleHP3NPInelasticFS(){}
void Init (G4double A, G4double Z, G4int M, G4String & dirName, G4String & aFSType, G4ParticleDefinition*);
G4HadFinalState * ApplyYourself(const G4HadProjectile & theTrack);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ class G4SaG4nParticleHP4NInelasticFS : public G4SaG4nParticleHPInelasticBaseFS
{
public:

G4SaG4nParticleHP4NInelasticFS(){}
G4SaG4nParticleHP4NInelasticFS();
~G4SaG4nParticleHP4NInelasticFS(){}
void Init (G4double A, G4double Z, G4int M, G4String & dirName, G4String & aFSType, G4ParticleDefinition*);
G4HadFinalState * ApplyYourself(const G4HadProjectile & theTrack);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ class G4SaG4nParticleHPAInelasticFS : public G4SaG4nParticleHPInelasticCompFS
{
public:

G4SaG4nParticleHPAInelasticFS(){}
G4SaG4nParticleHPAInelasticFS();
~G4SaG4nParticleHPAInelasticFS(){}
void Init (G4double A, G4double Z, G4int M, G4String & dirName, G4String & aFSType, G4ParticleDefinition*);
G4HadFinalState * ApplyYourself(const G4HadProjectile & theTrack);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -79,9 +79,6 @@ class G4SaG4nParticleHPCaptureData : public G4VCrossSectionDataSet

void DumpPhysicsTable(const G4ParticleDefinition&);

void IgnoreOnFlightDopplerBroadening(){ onFlightDB = false; };
void EnableOnFlightDopplerBroadening(){ onFlightDB = true; };

public:
G4int GetVerboseLevel() const;
void SetVerboseLevel( G4int );
Expand All @@ -91,7 +88,6 @@ class G4SaG4nParticleHPCaptureData : public G4VCrossSectionDataSet

G4PhysicsTable * theCrossSections;

G4bool onFlightDB;
G4bool instanceOfWorker;

G4double ke_cache;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,12 +43,7 @@ class G4SaG4nParticleHPCaptureFS : public G4SaG4nParticleHPFinalState
{
public:

G4SaG4nParticleHPCaptureFS()
{
hasXsec = false;
hasExactMF6 = false;
targetMass = 0;
}
G4SaG4nParticleHPCaptureFS();

~G4SaG4nParticleHPCaptureFS()
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,9 @@
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
//
// Hadronic Process: Very Low Energy Neutron X-Sections
// original by H.P. Wellisch, TRIUMF, 14-Feb-97
// Builds and has the Cross-section data for one element and channel.
// Hadronic Process: Very Low Energy Neutron X-Sections
// original by H.P. Wellisch, TRIUMF, 14-Feb-97
// Builds and has the Cross-section data for one element and channel.
//
// Bug fixes and workarounds in the destructor, F.W.Jones 06-Jul-1999
// 070612 Fix memory leaking by T. Koi
Expand All @@ -38,29 +36,34 @@
//
#ifndef G4SaG4nParticleHPChannel_h
#define G4SaG4nParticleHPChannel_h 1

#include "globals.hh"
#include "G4SaG4nParticleHPIsoData.hh"
#include "G4SaG4nParticleHPVector.hh"
#include "G4Material.hh"
#include "G4HadProjectile.hh"
//#include "G4NeutronInelasticProcess.hh"
//#include "G4HadronFissionProcess.hh"
//#include "G4HadronElasticProcess.hh"
//#include "G4HadronCaptureProcess.hh"
#include "G4StableIsotopes.hh"
#include "G4SaG4nParticleHPCaptureFS.hh"
#include "G4SaG4nParticleHPFinalState.hh"
#include "G4Element.hh"
#include "G4WendtFissionFragmentGenerator.hh"
#include "G4SaG4nParticleHPManager.hh"

class G4ParticleDefinition;


class G4SaG4nParticleHPChannel
{
public:

G4SaG4nParticleHPChannel(G4ParticleDefinition* projectile)
: wendtFissionGenerator(getenv("G4NEUTRON_HP_USE_WENDT_FISSION_MODEL") == NULL ? NULL : G4WendtFissionFragmentGenerator::GetInstance())
G4SaG4nParticleHPChannel(G4ParticleDefinition* projectile) :
wendtFissionGenerator( G4SaG4nParticleHPManager::GetInstance()->GetUseWendtFissionModel() ?
G4WendtFissionFragmentGenerator::GetInstance() : nullptr )
{
if ( G4SaG4nParticleHPManager::GetInstance()->GetUseWendtFissionModel() ) {
// Make sure both fission fragment models are not active at same time
G4SaG4nParticleHPManager::GetInstance()->SetProduceFissionFragments( false );
}
theProjectile = const_cast<G4ParticleDefinition*>(projectile);
theChannelData = new G4SaG4nParticleHPVector;
theBuffer = 0;
Expand All @@ -72,9 +75,13 @@ public:
theElement = NULL;
}

G4SaG4nParticleHPChannel()
: wendtFissionGenerator(getenv("G4NEUTRON_HP_USE_WENDT_FISSION_MODEL") == NULL ? NULL : G4WendtFissionFragmentGenerator::GetInstance())
G4SaG4nParticleHPChannel() : wendtFissionGenerator( G4SaG4nParticleHPManager::GetInstance()->GetUseWendtFissionModel() ?
G4WendtFissionFragmentGenerator::GetInstance() : nullptr )
{
if ( G4SaG4nParticleHPManager::GetInstance()->GetUseWendtFissionModel() ) {
// Make sure both fission fragment models are not active at same time
G4SaG4nParticleHPManager::GetInstance()->SetProduceFissionFragments( false );
}
theProjectile = G4Neutron::Neutron();
theChannelData = new G4SaG4nParticleHPVector;
theBuffer = 0;
Expand Down Expand Up @@ -106,17 +113,16 @@ public:
//}
// FWJ experiment
//if(active!=0) delete [] active;
// T.K.
if ( theFinalStates != 0 )
{
// T.K.
if ( theFinalStates != 0 )
{
for ( G4int i = 0 ; i < niso ; i++ )
{
delete theFinalStates[i];
}
delete [] theFinalStates;
}
if ( active != 0 ) delete [] active;

}
if ( active != 0 ) delete [] active;
}

G4double GetXsec(G4double energy);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ class G4SaG4nParticleHPContAngularPar

G4double GetEnergy()
{
if( getenv("G4PHPTEST") )
if( std::getenv("G4PHPTEST") )
G4cout << this << " G4SaG4nParticleHPContAngularPar::GetEnergy "
<< theEnergy << " nE " << nEnergies << G4endl;
return theEnergy;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ class G4SaG4nParticleHPD2AInelasticFS : public G4SaG4nParticleHPInelasticBaseFS
{
public:

G4SaG4nParticleHPD2AInelasticFS(){}
G4SaG4nParticleHPD2AInelasticFS();
~G4SaG4nParticleHPD2AInelasticFS(){}
void Init (G4double A, G4double Z, G4int M, G4String & dirName, G4String & aFSType, G4ParticleDefinition*);
G4HadFinalState * ApplyYourself(const G4HadProjectile & theTrack);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ class G4SaG4nParticleHPDAInelasticFS : public G4SaG4nParticleHPInelasticBaseFS
{
public:

G4SaG4nParticleHPDAInelasticFS(){}
G4SaG4nParticleHPDAInelasticFS();
~G4SaG4nParticleHPDAInelasticFS(){}
void Init (G4double A, G4double Z, G4int M, G4String & dirName, G4String & aFSType, G4ParticleDefinition*);
G4HadFinalState * ApplyYourself(const G4HadProjectile & theTrack);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ class G4SaG4nParticleHPDInelasticFS : public G4SaG4nParticleHPInelasticCompFS
{
public:

G4SaG4nParticleHPDInelasticFS(){}
G4SaG4nParticleHPDInelasticFS();
~G4SaG4nParticleHPDInelasticFS(){}
void Init (G4double A, G4double Z, G4int M, G4String & dirName, G4String & aFSType, G4ParticleDefinition*);
G4HadFinalState * ApplyYourself(const G4HadProjectile & theTrack);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,14 +39,7 @@ class G4SaG4nParticleHPDataPoint
G4SaG4nParticleHPDataPoint(){energy = 0; xSec = 0;}
G4SaG4nParticleHPDataPoint(G4double e, G4double x){ energy = e; xSec = x;}

void operator= (const G4SaG4nParticleHPDataPoint & aSet)
{
if(&aSet!=this)
{
energy = aSet.GetEnergy();
xSec = aSet.GetXsection();
}
}
G4SaG4nParticleHPDataPoint & operator= (const G4SaG4nParticleHPDataPoint & aSet) = default;

// ~G4SaG4nParticleHPDataPoint(){}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ class G4SaG4nParticleHPDeExGammas

inline G4SaG4nParticleHPLevel * GetLevel(G4int i)
{
if(getenv("G4PHPTEST")) G4cout << this << " GetLEVEL " << i << " n " << nLevels << G4endl;
if(std::getenv("G4PHPTEST")) G4cout << this << " GetLEVEL " << i << " n " << nLevels << G4endl;
if(i>nLevels-1) return 0;
return theLevels+i;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ class G4SaG4nParticleHPDiscreteTwoBody : public G4VParticleHPEnergyAngular
{
theCoeff = 0;
bCheckDiffCoeffRepr = true;
if ( getenv( "G4PHP_DO_NOT_CHECK_DIFF_COEFF_REPR" ) ) bCheckDiffCoeffRepr = false;
if ( std::getenv( "G4PHP_DO_NOT_CHECK_DIFF_COEFF_REPR" ) ) bCheckDiffCoeffRepr = false;
nEnergy = 0;
}
~G4SaG4nParticleHPDiscreteTwoBody()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ class G4SaG4nParticleHPElastic : public G4HadronicInteraction
~G4SaG4nParticleHPElastic();

G4HadFinalState * ApplyYourself(const G4HadProjectile& aTrack, G4Nucleus& aTargetNucleus);
G4HadFinalState * ApplyYourself(const G4HadProjectile& aTrack, G4Nucleus& aTargetNucleus, G4bool isFromTSL);

virtual const std::pair<G4double, G4double> GetFatalEnergyCheckLevels() const;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -80,17 +80,13 @@ class G4SaG4nParticleHPElasticData : public G4VCrossSectionDataSet
void BuildPhysicsTable(const G4ParticleDefinition&);
void DumpPhysicsTable(const G4ParticleDefinition&);

void IgnoreOnFlightDopplerBroadening(){ onFlightDB = false; };
void EnableOnFlightDopplerBroadening(){ onFlightDB = true; };

void SetVerboseLevel( G4int );
G4int GetVerboseLevel() const;
virtual void CrossSectionDescription(std::ostream&) const;

private:

G4PhysicsTable * theCrossSections;
G4bool onFlightDB;
G4bool instanceOfWorker;

G4double ke_cache;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,17 +47,7 @@ class G4SaG4nParticleHPElasticFS : public G4SaG4nParticleHPFinalState
{
public:

G4SaG4nParticleHPElasticFS()
{
hasXsec = false;
theCoefficients = 0;
theProbArray = 0;

repFlag = 0;
tE_of_repFlag3 = 0.0;
targetMass = 0.0;
frameFlag = 0;
}
G4SaG4nParticleHPElasticFS();
~G4SaG4nParticleHPElasticFS()
{
if(theCoefficients!=0) delete theCoefficients;
Expand Down
Loading

0 comments on commit 6bf8671

Please sign in to comment.