Import Geant4 11.2.0 source tree
This commit is contained in:
@@ -36,11 +36,11 @@
|
||||
class ActionInitialization : public G4VUserActionInitialization
|
||||
{
|
||||
public:
|
||||
ActionInitialization();
|
||||
virtual ~ActionInitialization();
|
||||
ActionInitialization() = default;
|
||||
~ActionInitialization() override = default;
|
||||
|
||||
virtual void BuildForMaster() const;
|
||||
virtual void Build() const;
|
||||
void BuildForMaster() const override;
|
||||
void Build() const override;
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
@@ -39,6 +39,8 @@
|
||||
#include "G4RunManager.hh"
|
||||
#include "G4VUserDetectorConstruction.hh"
|
||||
|
||||
#include <CLHEP/Units/SystemOfUnits.h>
|
||||
|
||||
class DetectorMessenger;
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
@@ -47,7 +49,9 @@ class DetectorConstruction : public G4VUserDetectorConstruction
|
||||
{
|
||||
public:
|
||||
DetectorConstruction();
|
||||
virtual ~DetectorConstruction();
|
||||
~DetectorConstruction() override;
|
||||
|
||||
G4VPhysicalVolume* Construct() override;
|
||||
|
||||
G4VPhysicalVolume* GetTank() { return fTank; }
|
||||
G4double GetTankXSize() { return fTank_x; }
|
||||
@@ -59,7 +63,7 @@ class DetectorConstruction : public G4VUserDetectorConstruction
|
||||
fSurface->SetFinish(finish);
|
||||
G4RunManager::GetRunManager()->GeometryHasBeenModified();
|
||||
}
|
||||
G4OpticalSurfaceFinish GetSurfaceFinish(void)
|
||||
G4OpticalSurfaceFinish GetSurfaceFinish()
|
||||
{
|
||||
return fSurface->GetFinish();
|
||||
}
|
||||
@@ -75,7 +79,7 @@ class DetectorConstruction : public G4VUserDetectorConstruction
|
||||
fSurface->SetModel(model);
|
||||
G4RunManager::GetRunManager()->GeometryHasBeenModified();
|
||||
}
|
||||
G4OpticalSurfaceModel GetSurfaceModel(void) { return fSurface->GetModel(); }
|
||||
G4OpticalSurfaceModel GetSurfaceModel() { return fSurface->GetModel(); }
|
||||
|
||||
void SetSurfaceSigmaAlpha(G4double v);
|
||||
void SetSurfacePolish(G4double v);
|
||||
@@ -106,32 +110,30 @@ class DetectorConstruction : public G4VUserDetectorConstruction
|
||||
void SetTankMaterial(const G4String&);
|
||||
G4Material* GetTankMaterial() const { return fTankMaterial; }
|
||||
|
||||
virtual G4VPhysicalVolume* Construct();
|
||||
|
||||
private:
|
||||
G4double fExpHall_x;
|
||||
G4double fExpHall_y;
|
||||
G4double fExpHall_z;
|
||||
G4double fExpHall_x = 10.*CLHEP::m;
|
||||
G4double fExpHall_y = 10.*CLHEP::m;
|
||||
G4double fExpHall_z = 10.*CLHEP::m;
|
||||
|
||||
G4VPhysicalVolume* fTank;
|
||||
G4VPhysicalVolume* fTank = nullptr;
|
||||
|
||||
G4double fTank_x;
|
||||
G4double fTank_y;
|
||||
G4double fTank_z;
|
||||
G4double fTank_x = 1.*CLHEP::m;
|
||||
G4double fTank_y = 1.*CLHEP::m;
|
||||
G4double fTank_z = 1.*CLHEP::m;
|
||||
|
||||
G4LogicalVolume* fWorld_LV;
|
||||
G4LogicalVolume* fTank_LV;
|
||||
G4LogicalVolume* fWorld_LV = nullptr;
|
||||
G4LogicalVolume* fTank_LV = nullptr;
|
||||
|
||||
G4Material* fWorldMaterial;
|
||||
G4Material* fTankMaterial;
|
||||
G4Material* fWorldMaterial = nullptr;
|
||||
G4Material* fTankMaterial = nullptr;
|
||||
|
||||
G4OpticalSurface* fSurface;
|
||||
G4OpticalSurface* fSurface = nullptr;
|
||||
|
||||
DetectorMessenger* fDetectorMessenger;
|
||||
DetectorMessenger* fDetectorMessenger = nullptr;
|
||||
|
||||
G4MaterialPropertiesTable* fTankMPT;
|
||||
G4MaterialPropertiesTable* fWorldMPT;
|
||||
G4MaterialPropertiesTable* fSurfaceMPT;
|
||||
G4MaterialPropertiesTable* fTankMPT = nullptr;
|
||||
G4MaterialPropertiesTable* fWorldMPT = nullptr;
|
||||
G4MaterialPropertiesTable* fSurfaceMPT = nullptr;
|
||||
};
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
@@ -51,33 +51,32 @@ class DetectorMessenger : public G4UImessenger
|
||||
{
|
||||
public:
|
||||
DetectorMessenger(DetectorConstruction*);
|
||||
~DetectorMessenger();
|
||||
~DetectorMessenger() override;
|
||||
|
||||
virtual void SetNewValue(G4UIcommand*, G4String);
|
||||
void SetNewValue(G4UIcommand*, G4String) override;
|
||||
|
||||
private:
|
||||
DetectorConstruction* fDetector;
|
||||
|
||||
G4UIdirectory* fOpticalDir;
|
||||
DetectorConstruction* fDetector = nullptr;
|
||||
G4UIdirectory* fOpticalDir = nullptr;
|
||||
|
||||
// the surface
|
||||
G4UIcmdWithAString* fSurfaceTypeCmd;
|
||||
G4UIcmdWithAString* fSurfaceFinishCmd;
|
||||
G4UIcmdWithAString* fSurfaceModelCmd;
|
||||
G4UIcmdWithADouble* fSurfaceSigmaAlphaCmd;
|
||||
G4UIcmdWithADouble* fSurfacePolishCmd;
|
||||
G4UIcmdWithAString* fSurfaceMatPropVectorCmd;
|
||||
G4UIcmdWithAString* fSurfaceMatPropConstCmd;
|
||||
G4UIcmdWithAString* fSurfaceTypeCmd = nullptr;
|
||||
G4UIcmdWithAString* fSurfaceFinishCmd = nullptr;
|
||||
G4UIcmdWithAString* fSurfaceModelCmd = nullptr;
|
||||
G4UIcmdWithADouble* fSurfaceSigmaAlphaCmd = nullptr;
|
||||
G4UIcmdWithADouble* fSurfacePolishCmd = nullptr;
|
||||
G4UIcmdWithAString* fSurfaceMatPropVectorCmd = nullptr;
|
||||
G4UIcmdWithAString* fSurfaceMatPropConstCmd = nullptr;
|
||||
|
||||
// the box
|
||||
G4UIcmdWithAString* fTankMatPropVectorCmd;
|
||||
G4UIcmdWithAString* fTankMatPropConstCmd;
|
||||
G4UIcmdWithAString* fTankMaterialCmd;
|
||||
G4UIcmdWithAString* fTankMatPropVectorCmd = nullptr;
|
||||
G4UIcmdWithAString* fTankMatPropConstCmd = nullptr;
|
||||
G4UIcmdWithAString* fTankMaterialCmd = nullptr;
|
||||
|
||||
// the world
|
||||
G4UIcmdWithAString* fWorldMatPropVectorCmd;
|
||||
G4UIcmdWithAString* fWorldMatPropConstCmd;
|
||||
G4UIcmdWithAString* fWorldMaterialCmd;
|
||||
G4UIcmdWithAString* fWorldMatPropVectorCmd = nullptr;
|
||||
G4UIcmdWithAString* fWorldMatPropConstCmd = nullptr;
|
||||
G4UIcmdWithAString* fWorldMaterialCmd = nullptr;
|
||||
};
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
@@ -43,7 +43,7 @@ class HistoManager
|
||||
{
|
||||
public:
|
||||
HistoManager();
|
||||
~HistoManager();
|
||||
~HistoManager() = default;
|
||||
|
||||
private:
|
||||
void Book();
|
||||
|
||||
@@ -46,9 +46,9 @@ class PrimaryGeneratorAction : public G4VUserPrimaryGeneratorAction
|
||||
{
|
||||
public:
|
||||
PrimaryGeneratorAction();
|
||||
virtual ~PrimaryGeneratorAction();
|
||||
~PrimaryGeneratorAction() override;
|
||||
|
||||
virtual void GeneratePrimaries(G4Event*);
|
||||
void GeneratePrimaries(G4Event*) override;
|
||||
|
||||
G4ParticleGun* GetParticleGun() { return fParticleGun; };
|
||||
|
||||
@@ -59,11 +59,11 @@ class PrimaryGeneratorAction : public G4VUserPrimaryGeneratorAction
|
||||
G4double GetPolarization() { return fPolarization; }
|
||||
|
||||
private:
|
||||
G4ParticleGun* fParticleGun;
|
||||
PrimaryGeneratorMessenger* fGunMessenger;
|
||||
G4bool fRandomDirection;
|
||||
G4bool fPolarized;
|
||||
G4double fPolarization;
|
||||
G4ParticleGun* fParticleGun = nullptr;
|
||||
PrimaryGeneratorMessenger* fGunMessenger = nullptr;
|
||||
G4bool fRandomDirection = false;
|
||||
G4bool fPolarized = false;
|
||||
G4double fPolarization = 0.;
|
||||
};
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
@@ -50,15 +50,15 @@ class PrimaryGeneratorMessenger : public G4UImessenger
|
||||
{
|
||||
public:
|
||||
PrimaryGeneratorMessenger(PrimaryGeneratorAction*);
|
||||
virtual ~PrimaryGeneratorMessenger();
|
||||
~PrimaryGeneratorMessenger() override;
|
||||
|
||||
virtual void SetNewValue(G4UIcommand*, G4String);
|
||||
void SetNewValue(G4UIcommand*, G4String) override;
|
||||
|
||||
private:
|
||||
PrimaryGeneratorAction* fPrimaryAction;
|
||||
G4UIdirectory* fGunDir;
|
||||
G4UIcmdWithADoubleAndUnit* fPolarCmd;
|
||||
G4UIcmdWithABool* fRandomDirectionCmd;
|
||||
PrimaryGeneratorAction* fPrimaryAction = nullptr;
|
||||
G4UIdirectory* fGunDir = nullptr;
|
||||
G4UIcmdWithADoubleAndUnit* fPolarCmd = nullptr;
|
||||
G4UIcmdWithABool* fRandomDirectionCmd = nullptr;
|
||||
};
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
@@ -42,7 +42,7 @@ class Run : public G4Run
|
||||
{
|
||||
public:
|
||||
Run();
|
||||
~Run();
|
||||
~Run() override = default;
|
||||
|
||||
void SetPrimary(G4ParticleDefinition* particle, G4double energy,
|
||||
G4bool polarized, G4double polarization);
|
||||
@@ -56,190 +56,190 @@ class Run : public G4Run
|
||||
void AddWLS2EmissionEnergy(G4double en) { fWLS2EmissionEnergy += en; }
|
||||
|
||||
// number of particles
|
||||
void AddCerenkov(void) { fCerenkovCount += 1; }
|
||||
void AddScintillation(void) { fScintCount += 1; }
|
||||
void AddRayleigh(void) { fRayleighCount += 1; }
|
||||
void AddWLSAbsorption(void) { fWLSAbsorptionCount += 1; }
|
||||
void AddWLSEmission(void) { fWLSEmissionCount += 1; }
|
||||
void AddWLS2Absorption(void) { fWLS2AbsorptionCount += 1; }
|
||||
void AddWLS2Emission(void) { fWLS2EmissionCount += 1; }
|
||||
void AddCerenkov() { fCerenkovCount += 1; }
|
||||
void AddScintillation() { fScintCount += 1; }
|
||||
void AddRayleigh() { fRayleighCount += 1; }
|
||||
void AddWLSAbsorption() { fWLSAbsorptionCount += 1; }
|
||||
void AddWLSEmission() { fWLSEmissionCount += 1; }
|
||||
void AddWLS2Absorption() { fWLS2AbsorptionCount += 1; }
|
||||
void AddWLS2Emission() { fWLS2EmissionCount += 1; }
|
||||
|
||||
void AddOpAbsorption(void) { fOpAbsorption += 1; }
|
||||
void AddOpAbsorptionPrior(void) { fOpAbsorptionPrior += 1; }
|
||||
void AddOpAbsorption() { fOpAbsorption += 1; }
|
||||
void AddOpAbsorptionPrior() { fOpAbsorptionPrior += 1; }
|
||||
|
||||
void AddFresnelRefraction(void) { fBoundaryProcs[FresnelRefraction] += 1; }
|
||||
void AddFresnelReflection(void) { fBoundaryProcs[FresnelReflection] += 1; }
|
||||
void AddTransmission(void) { fBoundaryProcs[Transmission] += 1; }
|
||||
void AddTotalInternalReflection(void)
|
||||
void AddFresnelRefraction() { fBoundaryProcs[FresnelRefraction] += 1; }
|
||||
void AddFresnelReflection() { fBoundaryProcs[FresnelReflection] += 1; }
|
||||
void AddTransmission() { fBoundaryProcs[Transmission] += 1; }
|
||||
void AddTotalInternalReflection()
|
||||
{
|
||||
fBoundaryProcs[TotalInternalReflection] += 1;
|
||||
}
|
||||
void AddLambertianReflection(void)
|
||||
void AddLambertianReflection()
|
||||
{
|
||||
fBoundaryProcs[LambertianReflection] += 1;
|
||||
}
|
||||
void AddLobeReflection(void) { fBoundaryProcs[LobeReflection] += 1; }
|
||||
void AddSpikeReflection(void) { fBoundaryProcs[SpikeReflection] += 1; }
|
||||
void AddBackScattering(void) { fBoundaryProcs[BackScattering] += 1; }
|
||||
void AddAbsorption(void) { fBoundaryProcs[Absorption] += 1; }
|
||||
void AddDetection(void) { fBoundaryProcs[Detection] += 1; }
|
||||
void AddNotAtBoundary(void) { fBoundaryProcs[NotAtBoundary] += 1; }
|
||||
void AddSameMaterial(void) { fBoundaryProcs[SameMaterial] += 1; }
|
||||
void AddStepTooSmall(void) { fBoundaryProcs[StepTooSmall] += 1; }
|
||||
void AddNoRINDEX(void) { fBoundaryProcs[NoRINDEX] += 1; }
|
||||
void AddLobeReflection() { fBoundaryProcs[LobeReflection] += 1; }
|
||||
void AddSpikeReflection() { fBoundaryProcs[SpikeReflection] += 1; }
|
||||
void AddBackScattering() { fBoundaryProcs[BackScattering] += 1; }
|
||||
void AddAbsorption() { fBoundaryProcs[Absorption] += 1; }
|
||||
void AddDetection() { fBoundaryProcs[Detection] += 1; }
|
||||
void AddNotAtBoundary() { fBoundaryProcs[NotAtBoundary] += 1; }
|
||||
void AddSameMaterial() { fBoundaryProcs[SameMaterial] += 1; }
|
||||
void AddStepTooSmall() { fBoundaryProcs[StepTooSmall] += 1; }
|
||||
void AddNoRINDEX() { fBoundaryProcs[NoRINDEX] += 1; }
|
||||
|
||||
void AddTotalSurface(void) { fTotalSurface += 1; }
|
||||
void AddPolishedLumirrorAirReflection(void)
|
||||
void AddTotalSurface() { fTotalSurface += 1; }
|
||||
void AddPolishedLumirrorAirReflection()
|
||||
{
|
||||
fBoundaryProcs[PolishedLumirrorAirReflection] += 1;
|
||||
}
|
||||
void AddPolishedLumirrorGlueReflection(void)
|
||||
void AddPolishedLumirrorGlueReflection()
|
||||
{
|
||||
fBoundaryProcs[PolishedLumirrorGlueReflection] += 1;
|
||||
}
|
||||
void AddPolishedAirReflection(void)
|
||||
void AddPolishedAirReflection()
|
||||
{
|
||||
fBoundaryProcs[PolishedAirReflection] += 1;
|
||||
}
|
||||
void AddPolishedTeflonAirReflection(void)
|
||||
void AddPolishedTeflonAirReflection()
|
||||
{
|
||||
fBoundaryProcs[PolishedTeflonAirReflection] += 1;
|
||||
}
|
||||
void AddPolishedTiOAirReflection(void)
|
||||
void AddPolishedTiOAirReflection()
|
||||
{
|
||||
fBoundaryProcs[PolishedTiOAirReflection] += 1;
|
||||
}
|
||||
void AddPolishedTyvekAirReflection(void)
|
||||
void AddPolishedTyvekAirReflection()
|
||||
{
|
||||
fBoundaryProcs[PolishedTyvekAirReflection] += 1;
|
||||
}
|
||||
void AddPolishedVM2000AirReflection(void)
|
||||
void AddPolishedVM2000AirReflection()
|
||||
{
|
||||
fBoundaryProcs[PolishedVM2000AirReflection] += 1;
|
||||
}
|
||||
void AddPolishedVM2000GlueReflection(void)
|
||||
void AddPolishedVM2000GlueReflection()
|
||||
{
|
||||
fBoundaryProcs[PolishedVM2000GlueReflection] += 1;
|
||||
}
|
||||
|
||||
void AddEtchedLumirrorAirReflection(void)
|
||||
void AddEtchedLumirrorAirReflection()
|
||||
{
|
||||
fBoundaryProcs[EtchedLumirrorAirReflection] += 1;
|
||||
}
|
||||
void AddEtchedLumirrorGlueReflection(void)
|
||||
void AddEtchedLumirrorGlueReflection()
|
||||
{
|
||||
fBoundaryProcs[EtchedLumirrorGlueReflection] += 1;
|
||||
}
|
||||
void AddEtchedAirReflection(void)
|
||||
void AddEtchedAirReflection()
|
||||
{
|
||||
fBoundaryProcs[EtchedAirReflection] += 1;
|
||||
}
|
||||
void AddEtchedTeflonAirReflection(void)
|
||||
void AddEtchedTeflonAirReflection()
|
||||
{
|
||||
fBoundaryProcs[EtchedTeflonAirReflection] += 1;
|
||||
}
|
||||
void AddEtchedTiOAirReflection(void)
|
||||
void AddEtchedTiOAirReflection()
|
||||
{
|
||||
fBoundaryProcs[EtchedTiOAirReflection] += 1;
|
||||
}
|
||||
void AddEtchedTyvekAirReflection(void)
|
||||
void AddEtchedTyvekAirReflection()
|
||||
{
|
||||
fBoundaryProcs[EtchedTyvekAirReflection] += 1;
|
||||
}
|
||||
void AddEtchedVM2000AirReflection(void)
|
||||
void AddEtchedVM2000AirReflection()
|
||||
{
|
||||
fBoundaryProcs[EtchedVM2000AirReflection] += 1;
|
||||
}
|
||||
void AddEtchedVM2000GlueReflection(void)
|
||||
void AddEtchedVM2000GlueReflection()
|
||||
{
|
||||
fBoundaryProcs[EtchedVM2000GlueReflection] += 1;
|
||||
}
|
||||
|
||||
void AddGroundLumirrorAirReflection(void)
|
||||
void AddGroundLumirrorAirReflection()
|
||||
{
|
||||
fBoundaryProcs[GroundLumirrorAirReflection] += 1;
|
||||
}
|
||||
void AddGroundLumirrorGlueReflection(void)
|
||||
void AddGroundLumirrorGlueReflection()
|
||||
{
|
||||
fBoundaryProcs[GroundLumirrorGlueReflection] += 1;
|
||||
}
|
||||
void AddGroundAirReflection(void)
|
||||
void AddGroundAirReflection()
|
||||
{
|
||||
fBoundaryProcs[GroundAirReflection] += 1;
|
||||
}
|
||||
void AddGroundTeflonAirReflection(void)
|
||||
void AddGroundTeflonAirReflection()
|
||||
{
|
||||
fBoundaryProcs[GroundTeflonAirReflection] += 1;
|
||||
}
|
||||
void AddGroundTiOAirReflection(void)
|
||||
void AddGroundTiOAirReflection()
|
||||
{
|
||||
fBoundaryProcs[GroundTiOAirReflection] += 1;
|
||||
}
|
||||
void AddGroundTyvekAirReflection(void)
|
||||
void AddGroundTyvekAirReflection()
|
||||
{
|
||||
fBoundaryProcs[GroundTyvekAirReflection] += 1;
|
||||
}
|
||||
void AddGroundVM2000AirReflection(void)
|
||||
void AddGroundVM2000AirReflection()
|
||||
{
|
||||
fBoundaryProcs[GroundVM2000AirReflection] += 1;
|
||||
}
|
||||
void AddGroundVM2000GlueReflection(void)
|
||||
void AddGroundVM2000GlueReflection()
|
||||
{
|
||||
fBoundaryProcs[GroundVM2000GlueReflection] += 1;
|
||||
}
|
||||
|
||||
void AddDichroic(void) { fBoundaryProcs[Dichroic] += 1; }
|
||||
void AddCoatedDielectricRefraction(void)
|
||||
void AddDichroic() { fBoundaryProcs[Dichroic] += 1; }
|
||||
void AddCoatedDielectricRefraction()
|
||||
{
|
||||
fBoundaryProcs[CoatedDielectricRefraction] += 1;
|
||||
}
|
||||
void AddCoatedDielectricReflection(void)
|
||||
void AddCoatedDielectricReflection()
|
||||
{
|
||||
fBoundaryProcs[CoatedDielectricReflection] += 1;
|
||||
}
|
||||
void AddCoatedDielectricFrustratedTransmission(void)
|
||||
void AddCoatedDielectricFrustratedTransmission()
|
||||
{
|
||||
fBoundaryProcs[CoatedDielectricFrustratedTransmission] += 1;
|
||||
}
|
||||
|
||||
virtual void Merge(const G4Run*);
|
||||
void Merge(const G4Run*) override;
|
||||
|
||||
void EndOfRun();
|
||||
|
||||
private:
|
||||
// primary particle
|
||||
G4ParticleDefinition* fParticle;
|
||||
G4double fEkin;
|
||||
G4bool fPolarized;
|
||||
G4double fPolarization;
|
||||
G4ParticleDefinition* fParticle = nullptr;
|
||||
G4double fEkin = -1.;
|
||||
G4bool fPolarized = false;
|
||||
G4double fPolarization = 0.;
|
||||
|
||||
G4double fCerenkovEnergy;
|
||||
G4double fScintEnergy;
|
||||
G4double fWLSAbsorptionEnergy;
|
||||
G4double fWLSEmissionEnergy;
|
||||
G4double fWLS2AbsorptionEnergy;
|
||||
G4double fWLS2EmissionEnergy;
|
||||
G4double fCerenkovEnergy = 0.;
|
||||
G4double fScintEnergy = 0.;
|
||||
G4double fWLSAbsorptionEnergy = 0.;
|
||||
G4double fWLSEmissionEnergy = 0.;
|
||||
G4double fWLS2AbsorptionEnergy = 0.;
|
||||
G4double fWLS2EmissionEnergy = 0.;
|
||||
|
||||
// number of particles
|
||||
G4int fCerenkovCount;
|
||||
G4int fScintCount;
|
||||
G4int fWLSAbsorptionCount;
|
||||
G4int fWLSEmissionCount;
|
||||
G4int fWLS2AbsorptionCount;
|
||||
G4int fWLS2EmissionCount;
|
||||
G4int fCerenkovCount = 0;
|
||||
G4int fScintCount = 0;
|
||||
G4int fWLSAbsorptionCount = 0;
|
||||
G4int fWLSEmissionCount = 0;
|
||||
G4int fWLS2AbsorptionCount = 0;
|
||||
G4int fWLS2EmissionCount = 0;
|
||||
// number of events
|
||||
G4int fRayleighCount;
|
||||
G4int fRayleighCount = 0;
|
||||
|
||||
// non-boundary processes
|
||||
G4int fOpAbsorption;
|
||||
G4int fOpAbsorption = 0;
|
||||
|
||||
// prior to boundary:
|
||||
G4int fOpAbsorptionPrior;
|
||||
G4int fOpAbsorptionPrior = 0;
|
||||
|
||||
// boundary proc
|
||||
std::vector<G4int> fBoundaryProcs;
|
||||
|
||||
G4int fTotalSurface;
|
||||
G4int fTotalSurface = 0;
|
||||
};
|
||||
|
||||
#endif /* Run_h */
|
||||
|
||||
@@ -47,16 +47,16 @@ class RunAction : public G4UserRunAction
|
||||
{
|
||||
public:
|
||||
RunAction(PrimaryGeneratorAction* = nullptr);
|
||||
virtual ~RunAction();
|
||||
~RunAction() override;
|
||||
|
||||
virtual G4Run* GenerateRun();
|
||||
virtual void BeginOfRunAction(const G4Run*);
|
||||
virtual void EndOfRunAction(const G4Run*);
|
||||
G4Run* GenerateRun() override;
|
||||
void BeginOfRunAction(const G4Run*) override;
|
||||
void EndOfRunAction(const G4Run*) override;
|
||||
|
||||
private:
|
||||
Run* fRun;
|
||||
HistoManager* fHistoManager;
|
||||
PrimaryGeneratorAction* fPrimary;
|
||||
Run* fRun = nullptr;
|
||||
HistoManager* fHistoManager = nullptr;
|
||||
PrimaryGeneratorAction* fPrimary = nullptr;
|
||||
};
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
@@ -35,18 +35,27 @@
|
||||
#include "globals.hh"
|
||||
#include "G4UserSteppingAction.hh"
|
||||
|
||||
class SteppingMessenger;
|
||||
|
||||
class SteppingAction : public G4UserSteppingAction
|
||||
{
|
||||
public:
|
||||
SteppingAction();
|
||||
virtual ~SteppingAction();
|
||||
~SteppingAction() override;
|
||||
|
||||
// method from the base class
|
||||
virtual void UserSteppingAction(const G4Step*);
|
||||
void UserSteppingAction(const G4Step*) override;
|
||||
|
||||
inline void SetKillOnSecondSurface(G4bool val) { fKillOnSecondSurface = val; }
|
||||
inline G4bool GetKillOnSecondSurface() { return fKillOnSecondSurface; }
|
||||
|
||||
private:
|
||||
SteppingMessenger* fSteppingMessenger = nullptr;
|
||||
|
||||
G4int fVerbose = 0;
|
||||
size_t fIdxVelocity = 0;
|
||||
|
||||
G4bool fKillOnSecondSurface = false;
|
||||
};
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
@@ -0,0 +1,61 @@
|
||||
//
|
||||
// ********************************************************************
|
||||
// * License and Disclaimer *
|
||||
// * *
|
||||
// * The Geant4 software is copyright of the Copyright Holders of *
|
||||
// * the Geant4 Collaboration. It is provided under the terms and *
|
||||
// * conditions of the Geant4 Software License, included in the file *
|
||||
// * LICENSE and available at http://cern.ch/geant4/license . These *
|
||||
// * include a list of copyright holders. *
|
||||
// * *
|
||||
// * Neither the authors of this software system, nor their employing *
|
||||
// * institutes,nor the agencies providing financial support for this *
|
||||
// * work make any representation or warranty, express or implied, *
|
||||
// * regarding this software system or assume any liability for its *
|
||||
// * use. Please see the license in the file LICENSE and URL above *
|
||||
// * for the full disclaimer and the limitation of liability. *
|
||||
// * *
|
||||
// * This code implementation is the result of the scientific and *
|
||||
// * technical work of the GEANT4 collaboration. *
|
||||
// * By using, copying, modifying or distributing the software (or *
|
||||
// * any work based on the software) you agree to acknowledge its *
|
||||
// * use in resulting scientific publications, and indicate your *
|
||||
// * acceptance of all terms of the Geant4 Software license. *
|
||||
// ********************************************************************
|
||||
//
|
||||
/// \file optical/OpNovice2/include/SteppingMessenger.hh
|
||||
/// \brief Definition of the SteppingMessenger class
|
||||
//
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
#ifndef SteppingMessenger_h
|
||||
#define SteppingMessenger_h 1
|
||||
|
||||
#include "globals.hh"
|
||||
#include "G4UImessenger.hh"
|
||||
|
||||
class SteppingAction;
|
||||
class G4UIdirectory;
|
||||
class G4UIcmdWithABool;
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
class SteppingMessenger : public G4UImessenger
|
||||
{
|
||||
public:
|
||||
SteppingMessenger(SteppingAction*);
|
||||
~SteppingMessenger() override;
|
||||
|
||||
void SetNewValue(G4UIcommand*, G4String) override;
|
||||
|
||||
private:
|
||||
G4UIdirectory* fSteppingDir = nullptr;
|
||||
G4UIcmdWithABool* fKillOnSecondSurfaceCmd = nullptr;
|
||||
SteppingAction* fSteppingAction = nullptr;
|
||||
};
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
#endif
|
||||
@@ -44,8 +44,8 @@ class SteppingVerbose;
|
||||
class SteppingVerbose : public G4SteppingVerbose
|
||||
{
|
||||
public:
|
||||
SteppingVerbose();
|
||||
virtual ~SteppingVerbose();
|
||||
SteppingVerbose() = default;
|
||||
~SteppingVerbose() = default;
|
||||
|
||||
virtual G4VSteppingVerbose* Clone() { return new SteppingVerbose; }
|
||||
|
||||
|
||||
@@ -44,7 +44,7 @@ class TrackInformation : public G4VUserTrackInformation
|
||||
TrackInformation();
|
||||
TrackInformation(const G4Track* aTrack);
|
||||
TrackInformation(const TrackInformation* aTrackInfo);
|
||||
virtual ~TrackInformation();
|
||||
~TrackInformation() override;
|
||||
|
||||
inline void* operator new(size_t);
|
||||
inline void operator delete(void* aTrackInfo);
|
||||
@@ -52,14 +52,17 @@ class TrackInformation : public G4VUserTrackInformation
|
||||
TrackInformation& operator=(const TrackInformation& right);
|
||||
|
||||
void SetSourceTrackInformation(const G4Track* aTrack);
|
||||
virtual void Print() const;
|
||||
void Print() const override;
|
||||
|
||||
public:
|
||||
inline G4bool GetIsFirstTankX() const { return fFirstTankX; }
|
||||
inline void SetIsFirstTankX(G4bool b) { fFirstTankX = b; }
|
||||
|
||||
inline G4int GetReflectionNumber() const { return fReflectionNumber; }
|
||||
inline void IncrementReflectionNumber() { ++fReflectionNumber; }
|
||||
|
||||
private:
|
||||
G4bool fFirstTankX;
|
||||
G4bool fFirstTankX = false;
|
||||
G4int fReflectionNumber = 0;
|
||||
};
|
||||
|
||||
extern G4ThreadLocal G4Allocator<TrackInformation>* aTrackInformationAllocator;
|
||||
|
||||
@@ -38,11 +38,11 @@
|
||||
class TrackingAction : public G4UserTrackingAction
|
||||
{
|
||||
public:
|
||||
TrackingAction();
|
||||
virtual ~TrackingAction(){};
|
||||
TrackingAction() = default;
|
||||
~TrackingAction() override = default;
|
||||
|
||||
virtual void PreUserTrackingAction(const G4Track*);
|
||||
virtual void PostUserTrackingAction(const G4Track*);
|
||||
void PreUserTrackingAction(const G4Track*) override;
|
||||
void PostUserTrackingAction(const G4Track*) override;
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user