Import Geant4 10.3.1 source tree
This commit is contained in:
@@ -1,26 +0,0 @@
|
||||
#
|
||||
# This file permits to customize, with commands,
|
||||
# the icon menu bar of the G4UIQt sessions not yet implemented other UI drivers (geant4-09-05-ref-09)
|
||||
# It has no effect with G4UIterminal.
|
||||
|
||||
# open/save icons
|
||||
/gui/addIcon "Open macro file" open /control/execute
|
||||
/gui/addIcon "Save viewer state" save /vis/viewer/save
|
||||
|
||||
# Cursors style icons
|
||||
/gui/addIcon "Move" move
|
||||
/gui/addIcon "Pick" pick
|
||||
/gui/addIcon "Zoom out" zoom_out
|
||||
/gui/addIcon "Zoom in" zoom_in
|
||||
/gui/addIcon "Rotate" rotate
|
||||
|
||||
# Surface Style icons
|
||||
# Surface Style icons
|
||||
/gui/addIcon "Hidden line removal" hidden_line_removal
|
||||
/gui/addIcon "Hidden line and hidden surface removal" hidden_line_and_surface_removal
|
||||
/gui/addIcon "Surfaces" solid
|
||||
/gui/addIcon "Wireframe" wireframe
|
||||
|
||||
# Perspective/Ortho icons
|
||||
/gui/addIcon "Perspective" perspective
|
||||
/gui/addIcon "Orthographic" ortho
|
||||
@@ -1,93 +0,0 @@
|
||||
//
|
||||
// ********************************************************************
|
||||
// * 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 field/field03/include/F03PhysicsList.hh
|
||||
/// \brief Definition of the F03PhysicsList class
|
||||
//
|
||||
//
|
||||
// $Id: F03PhysicsList.hh 77795 2013-11-28 09:55:34Z gcosmo $
|
||||
//
|
||||
//
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
#ifndef F03PhysicsList_h
|
||||
#define F03PhysicsList_h 1
|
||||
|
||||
#include "G4VUserPhysicsList.hh"
|
||||
|
||||
class F03DetectorConstruction;
|
||||
class F03PhysicsListMessenger;
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
class F03PhysicsList: public G4VUserPhysicsList
|
||||
{
|
||||
public:
|
||||
F03PhysicsList( F03DetectorConstruction*);
|
||||
virtual ~F03PhysicsList();
|
||||
|
||||
protected:
|
||||
// Construct particle and physics
|
||||
virtual void ConstructParticle();
|
||||
virtual void ConstructProcess();
|
||||
|
||||
void SetCuts();
|
||||
|
||||
protected:
|
||||
// these methods construct particles
|
||||
void ConstructBosons();
|
||||
void ConstructLeptons();
|
||||
void ConstructMesons();
|
||||
void ConstructBarions();
|
||||
|
||||
protected:
|
||||
|
||||
// these methods construct physics processes and register them
|
||||
|
||||
void ConstructGeneral();
|
||||
void ConstructEM();
|
||||
|
||||
public:
|
||||
|
||||
void SetGammaCut(G4double);
|
||||
void SetElectronCut(G4double);
|
||||
|
||||
void SetMaxStep(G4double);
|
||||
|
||||
public:
|
||||
|
||||
G4double fMaxChargedStep;
|
||||
|
||||
private:
|
||||
|
||||
G4double fCutForGamma;
|
||||
G4double fCutForElectron;
|
||||
|
||||
F03DetectorConstruction* fDet;
|
||||
F03PhysicsListMessenger* fPhysicsListMessenger;
|
||||
};
|
||||
|
||||
#endif
|
||||
@@ -1,65 +0,0 @@
|
||||
//
|
||||
// ********************************************************************
|
||||
// * 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 field/field03/include/F03PhysicsListMessenger.hh
|
||||
/// \brief Definition of the F03PhysicsListMessenger class
|
||||
//
|
||||
//
|
||||
// $Id: F03PhysicsListMessenger.hh 76602 2013-11-13 08:33:35Z gcosmo $
|
||||
//
|
||||
//
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
#ifndef F03PhysicsListMessenger_h
|
||||
#define F03PhysicsListMessenger_h 1
|
||||
|
||||
#include "G4UImessenger.hh"
|
||||
|
||||
class F03PhysicsList;
|
||||
class G4UIcmdWithoutParameter;
|
||||
class G4UIcmdWithADouble;
|
||||
class G4UIcmdWithADoubleAndUnit;
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
class F03PhysicsListMessenger: public G4UImessenger
|
||||
{
|
||||
public:
|
||||
F03PhysicsListMessenger(F03PhysicsList*);
|
||||
virtual ~F03PhysicsListMessenger();
|
||||
|
||||
virtual void SetNewValue(G4UIcommand*, G4String);
|
||||
|
||||
private:
|
||||
F03PhysicsList* fF03List;
|
||||
|
||||
G4UIcmdWithADoubleAndUnit* fSetMaxStepCmd;
|
||||
|
||||
G4UIcmdWithADoubleAndUnit* fCutGCmd;
|
||||
G4UIcmdWithADoubleAndUnit* fCutECmd;
|
||||
};
|
||||
|
||||
#endif
|
||||
@@ -1,127 +0,0 @@
|
||||
//
|
||||
// ********************************************************************
|
||||
// * 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 field/field03/include/F03StepCut.hh
|
||||
/// \brief Definition of the F03StepCut class
|
||||
//
|
||||
//
|
||||
// $Id: F03StepCut.hh 76602 2013-11-13 08:33:35Z gcosmo $
|
||||
//
|
||||
//
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
#ifndef F03StepCut_h
|
||||
#define F03StepCut_h 1
|
||||
|
||||
#include "G4VDiscreteProcess.hh"
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
class F03StepCut : public G4VDiscreteProcess
|
||||
{
|
||||
public:
|
||||
|
||||
F03StepCut(const G4String& processName ="UserStepCut" );
|
||||
F03StepCut(F03StepCut &);
|
||||
|
||||
virtual ~F03StepCut();
|
||||
|
||||
virtual G4double PostStepGetPhysicalInteractionLength(
|
||||
const G4Track& track,
|
||||
G4double previousStepSize,
|
||||
G4ForceCondition* condition
|
||||
);
|
||||
|
||||
virtual G4VParticleChange* PostStepDoIt(
|
||||
const G4Track&,
|
||||
const G4Step&
|
||||
);
|
||||
|
||||
void SetMaxStep(G4double);
|
||||
|
||||
protected:
|
||||
|
||||
// it is not needed here !
|
||||
virtual G4double GetMeanFreePath(const G4Track& aTrack,
|
||||
G4double previousStepSize,
|
||||
G4ForceCondition* condition
|
||||
);
|
||||
|
||||
private:
|
||||
|
||||
// hide assignment operator as private
|
||||
F03StepCut & operator=(const F03StepCut &right);
|
||||
|
||||
private:
|
||||
|
||||
G4double fMaxChargedStep;
|
||||
};
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
// inlined function members implementation
|
||||
|
||||
inline G4double F03StepCut::PostStepGetPhysicalInteractionLength(
|
||||
const G4Track& aTrack,
|
||||
G4double,
|
||||
G4ForceCondition* condition)
|
||||
{
|
||||
// condition is set to "Not Forced"
|
||||
*condition = NotForced;
|
||||
|
||||
G4double proposedStep = DBL_MAX;
|
||||
|
||||
if((fMaxChargedStep > 0.) &&
|
||||
(aTrack.GetVolume() != 0) &&
|
||||
(aTrack.GetVolume()->GetName() == "Absorber") &&
|
||||
(aTrack.GetDynamicParticle()->GetDefinition()->GetPDGCharge() != 0.))
|
||||
proposedStep = fMaxChargedStep;
|
||||
|
||||
return proposedStep;
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
inline G4VParticleChange* F03StepCut::PostStepDoIt(
|
||||
const G4Track& aTrack,
|
||||
const G4Step&
|
||||
)
|
||||
{
|
||||
// do nothing
|
||||
aParticleChange.Initialize(aTrack);
|
||||
return &aParticleChange;
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
inline G4double F03StepCut::GetMeanFreePath(const G4Track&,
|
||||
G4double,
|
||||
G4ForceCondition*)
|
||||
{
|
||||
return 0.;
|
||||
}
|
||||
|
||||
#endif
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 14 KiB |
@@ -1,341 +0,0 @@
|
||||
//
|
||||
// ********************************************************************
|
||||
// * 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 field/field03/src/F03PhysicsList.cc
|
||||
/// \brief Implementation of the F03PhysicsList class
|
||||
//
|
||||
//
|
||||
// $Id: F03PhysicsList.cc 77795 2013-11-28 09:55:34Z gcosmo $
|
||||
//
|
||||
//
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
#include "G4Timer.hh"
|
||||
|
||||
#include "F03PhysicsList.hh"
|
||||
#include "F03DetectorConstruction.hh"
|
||||
#include "F03PhysicsListMessenger.hh"
|
||||
|
||||
#include "G4ProcessManager.hh"
|
||||
#include "G4ProcessVector.hh"
|
||||
#include "G4ParticleTypes.hh"
|
||||
#include "G4ParticleTable.hh"
|
||||
#include "G4Material.hh"
|
||||
#include "G4EnergyLossTables.hh"
|
||||
#include "G4UnitsTable.hh"
|
||||
#include "G4SystemOfUnits.hh"
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
F03PhysicsList::F03PhysicsList(F03DetectorConstruction* p)
|
||||
: G4VUserPhysicsList(), fMaxChargedStep(DBL_MAX)
|
||||
{
|
||||
fDet = p;
|
||||
|
||||
defaultCutValue = 1.000*mm;
|
||||
|
||||
fCutForGamma = defaultCutValue;
|
||||
fCutForElectron = defaultCutValue;
|
||||
|
||||
SetVerboseLevel(1);
|
||||
fPhysicsListMessenger = new F03PhysicsListMessenger(this);
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
F03PhysicsList::~F03PhysicsList()
|
||||
{
|
||||
delete fPhysicsListMessenger;
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
void F03PhysicsList::ConstructParticle()
|
||||
{
|
||||
// In this method, static member functions should be called
|
||||
// for all particles which you want to use.
|
||||
// This ensures that objects of these particle types will be
|
||||
// created in the program.
|
||||
|
||||
ConstructBosons();
|
||||
ConstructLeptons();
|
||||
ConstructMesons();
|
||||
ConstructBarions();
|
||||
|
||||
G4GenericIon::GenericIonDefinition();
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
void F03PhysicsList::ConstructBosons()
|
||||
{
|
||||
// gamma
|
||||
|
||||
G4Gamma::GammaDefinition();
|
||||
|
||||
// charged geantino
|
||||
|
||||
G4ChargedGeantino::ChargedGeantinoDefinition();
|
||||
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
void F03PhysicsList::ConstructLeptons()
|
||||
{
|
||||
// leptons
|
||||
|
||||
G4Electron::ElectronDefinition();
|
||||
G4Positron::PositronDefinition();
|
||||
G4MuonPlus::MuonPlusDefinition();
|
||||
G4MuonMinus::MuonMinusDefinition();
|
||||
|
||||
G4NeutrinoE::NeutrinoEDefinition();
|
||||
G4AntiNeutrinoE::AntiNeutrinoEDefinition();
|
||||
G4NeutrinoMu::NeutrinoMuDefinition();
|
||||
G4AntiNeutrinoMu::AntiNeutrinoMuDefinition();
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
void F03PhysicsList::ConstructMesons()
|
||||
{
|
||||
// mesons
|
||||
|
||||
G4PionPlus::PionPlusDefinition();
|
||||
G4PionMinus::PionMinusDefinition();
|
||||
G4PionZero::PionZeroDefinition();
|
||||
G4KaonPlus::KaonPlusDefinition();
|
||||
G4KaonMinus::KaonMinusDefinition();
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
void F03PhysicsList::ConstructBarions()
|
||||
{
|
||||
// barions
|
||||
|
||||
G4Proton::ProtonDefinition();
|
||||
G4AntiProton::AntiProtonDefinition();
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
void F03PhysicsList::ConstructProcess()
|
||||
{
|
||||
AddTransportation();
|
||||
|
||||
ConstructEM();
|
||||
ConstructGeneral();
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
#include "G4ComptonScattering.hh"
|
||||
#include "G4GammaConversion.hh"
|
||||
#include "G4PhotoElectricEffect.hh"
|
||||
|
||||
#include "G4eMultipleScattering.hh"
|
||||
#include "G4MuMultipleScattering.hh"
|
||||
#include "G4hMultipleScattering.hh"
|
||||
|
||||
#include "G4eIonisation.hh"
|
||||
#include "G4eBremsstrahlung.hh"
|
||||
#include "G4eplusAnnihilation.hh"
|
||||
|
||||
#include "G4MuIonisation.hh"
|
||||
#include "G4MuBremsstrahlung.hh"
|
||||
#include "G4MuPairProduction.hh"
|
||||
|
||||
#include "G4hIonisation.hh"
|
||||
|
||||
#include "F03StepCut.hh"
|
||||
|
||||
void F03PhysicsList::ConstructEM()
|
||||
{
|
||||
theParticleIterator->reset();
|
||||
|
||||
while( (*theParticleIterator)() )
|
||||
{
|
||||
G4ParticleDefinition* particle = theParticleIterator->value();
|
||||
G4ProcessManager* pmanager = particle->GetProcessManager();
|
||||
G4String particleName = particle->GetParticleName();
|
||||
|
||||
if (particleName == "gamma")
|
||||
{
|
||||
// Construct processes for gamma
|
||||
|
||||
G4PhotoElectricEffect* fPhotoElectricEffect = new G4PhotoElectricEffect();
|
||||
G4ComptonScattering* fComptonScattering = new G4ComptonScattering();
|
||||
G4GammaConversion* fGammaConversion = new G4GammaConversion();
|
||||
|
||||
pmanager->AddDiscreteProcess(fPhotoElectricEffect);
|
||||
pmanager->AddDiscreteProcess(fComptonScattering);
|
||||
|
||||
pmanager->AddDiscreteProcess(fGammaConversion);
|
||||
}
|
||||
else if (particleName == "e-")
|
||||
{
|
||||
// Construct processes for electron
|
||||
|
||||
G4eIonisation* feminusIonisation = new G4eIonisation();
|
||||
G4eBremsstrahlung* feminusBremsstrahlung = new G4eBremsstrahlung();
|
||||
F03StepCut* feminusStepCut = new F03StepCut();
|
||||
feminusStepCut->SetMaxStep(fMaxChargedStep);
|
||||
|
||||
pmanager->AddProcess(feminusIonisation,-1,2,2);
|
||||
pmanager->AddProcess(feminusBremsstrahlung,-1,-1,3);
|
||||
pmanager->AddProcess(feminusStepCut,-1,-1,4);
|
||||
}
|
||||
else if (particleName == "e+")
|
||||
{
|
||||
// Construct processes for positron
|
||||
|
||||
G4eIonisation* feplusIonisation = new G4eIonisation();
|
||||
G4eBremsstrahlung* feplusBremsstrahlung = new G4eBremsstrahlung();
|
||||
F03StepCut* feplusStepCut = new F03StepCut();
|
||||
feplusStepCut->SetMaxStep(fMaxChargedStep);
|
||||
|
||||
pmanager->AddProcess(feplusIonisation,-1,2,2);
|
||||
pmanager->AddProcess(feplusBremsstrahlung,-1,-1,3);
|
||||
pmanager->AddProcess(feplusStepCut,-1,-1,5);
|
||||
}
|
||||
else if( particleName == "mu+" || particleName == "mu-" )
|
||||
{
|
||||
// Construct processes for muon+
|
||||
|
||||
F03StepCut* muonStepCut = new F03StepCut();
|
||||
muonStepCut->SetMaxStep(fMaxChargedStep);
|
||||
G4MuIonisation* muIonisation = new G4MuIonisation();
|
||||
|
||||
pmanager->AddProcess(new G4MuMultipleScattering(),-1,1,1);
|
||||
pmanager->AddProcess(muIonisation,-1,2,2);
|
||||
pmanager->AddProcess(new G4MuBremsstrahlung(),-1,-1,3);
|
||||
pmanager->AddProcess(new G4MuPairProduction(),-1,-1,4);
|
||||
pmanager->AddProcess(muonStepCut,-1,-1,3);
|
||||
}
|
||||
else if ( particleName == "proton"
|
||||
|| particleName == "antiproton"
|
||||
|| particleName == "pi+"
|
||||
|| particleName == "pi-"
|
||||
|| particleName == "kaon+"
|
||||
|| particleName == "kaon-"
|
||||
)
|
||||
{
|
||||
F03StepCut* theHadronStepCut = new F03StepCut();
|
||||
theHadronStepCut->SetMaxStep(10*mm);
|
||||
|
||||
G4hIonisation* thehIonisation = new G4hIonisation();
|
||||
G4hMultipleScattering* thehMultipleScattering =
|
||||
new G4hMultipleScattering();
|
||||
|
||||
pmanager->AddProcess(thehMultipleScattering,-1,1,1);
|
||||
pmanager->AddProcess(thehIonisation,-1,2,2);
|
||||
pmanager->AddProcess(theHadronStepCut,-1,-1,3);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
#include "G4Decay.hh"
|
||||
|
||||
void F03PhysicsList::ConstructGeneral()
|
||||
{
|
||||
// Add Decay Process
|
||||
|
||||
G4Decay* theDecayProcess = new G4Decay();
|
||||
theParticleIterator->reset();
|
||||
|
||||
while( (*theParticleIterator)() )
|
||||
{
|
||||
G4ParticleDefinition* particle = theParticleIterator->value();
|
||||
G4ProcessManager* pmanager = particle->GetProcessManager();
|
||||
|
||||
if (theDecayProcess->IsApplicable(*particle))
|
||||
{
|
||||
pmanager ->AddProcess(theDecayProcess);
|
||||
|
||||
// set ordering for PostStepDoIt and AtRestDoIt
|
||||
|
||||
pmanager ->SetProcessOrdering(theDecayProcess, idxPostStep);
|
||||
pmanager ->SetProcessOrdering(theDecayProcess, idxAtRest);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
void F03PhysicsList::SetCuts()
|
||||
{
|
||||
G4Timer theTimer;
|
||||
theTimer.Start();
|
||||
if (verboseLevel >0)
|
||||
{
|
||||
G4cout << "F03PhysicsList::SetCuts:";
|
||||
G4cout << "CutLength : " << G4BestUnit(defaultCutValue,"Length") << G4endl;
|
||||
}
|
||||
// set cut values for gamma at first and for e- second and next for e+,
|
||||
// because some processes for e+/e- need cut values for gamma
|
||||
SetCutValue(fCutForGamma,"gamma");
|
||||
|
||||
SetCutValue(fCutForElectron,"e-");
|
||||
SetCutValue(fCutForElectron,"e+");
|
||||
|
||||
if (verboseLevel>1) DumpCutValuesTable();
|
||||
|
||||
theTimer.Stop();
|
||||
G4cout.precision(6);
|
||||
G4cout << G4endl;
|
||||
G4cout << "total time(SetCuts)=" << theTimer.GetUserElapsed()
|
||||
<< " s " <<G4endl;
|
||||
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
void F03PhysicsList::SetGammaCut(G4double val)
|
||||
{
|
||||
fCutForGamma = val;
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
void F03PhysicsList::SetElectronCut(G4double val)
|
||||
{
|
||||
fCutForElectron = val;
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
void F03PhysicsList::SetMaxStep(G4double step)
|
||||
{
|
||||
fMaxChargedStep = step;
|
||||
G4cout << " MaxChargedStep=" << fMaxChargedStep << G4endl;
|
||||
G4cout << G4endl;
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
@@ -1,88 +0,0 @@
|
||||
//
|
||||
// ********************************************************************
|
||||
// * 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 field/field03/src/F03PhysicsListMessenger.cc
|
||||
/// \brief Implementation of the F03PhysicsListMessenger class
|
||||
//
|
||||
//
|
||||
// $Id: F03PhysicsListMessenger.cc 76602 2013-11-13 08:33:35Z gcosmo $
|
||||
//
|
||||
//
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
#include "F03PhysicsListMessenger.hh"
|
||||
|
||||
#include "F03PhysicsList.hh"
|
||||
#include "G4UIcmdWithADoubleAndUnit.hh"
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
F03PhysicsListMessenger::F03PhysicsListMessenger(F03PhysicsList * List)
|
||||
: fF03List(List)
|
||||
{
|
||||
fCutGCmd = new G4UIcmdWithADoubleAndUnit("/calor/cutG",this);
|
||||
fCutGCmd->SetGuidance("Set cut values by RANGE for Gamma.");
|
||||
fCutGCmd->SetParameterName("range",true);
|
||||
fCutGCmd->SetDefaultValue(1.);
|
||||
fCutGCmd->SetDefaultUnit("mm");
|
||||
fCutGCmd->AvailableForStates(G4State_Idle);
|
||||
|
||||
fCutECmd = new G4UIcmdWithADoubleAndUnit("/calor/cutE",this);
|
||||
fCutECmd->SetGuidance("Set cut values by RANGE for e- e+.");
|
||||
fCutECmd->SetParameterName("range",true);
|
||||
fCutECmd->SetDefaultValue(1.);
|
||||
fCutECmd->SetDefaultUnit("mm");
|
||||
fCutECmd->AvailableForStates(G4State_Idle);
|
||||
|
||||
fSetMaxStepCmd = new G4UIcmdWithADoubleAndUnit("/step/setMaxStep",this);
|
||||
fSetMaxStepCmd->SetGuidance("Set max. step length in the detector");
|
||||
fSetMaxStepCmd->SetParameterName("mxStep",true);
|
||||
fSetMaxStepCmd->SetDefaultUnit("mm");
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
F03PhysicsListMessenger::~F03PhysicsListMessenger()
|
||||
{
|
||||
delete fSetMaxStepCmd;
|
||||
delete fCutGCmd;
|
||||
delete fCutECmd;
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
void F03PhysicsListMessenger::SetNewValue(G4UIcommand* command,
|
||||
G4String newValue)
|
||||
{
|
||||
if(command == fCutGCmd)
|
||||
{fF03List->SetGammaCut(fCutGCmd->GetNewDoubleValue(newValue));}
|
||||
if(command == fCutECmd)
|
||||
{fF03List->SetElectronCut(fCutECmd->GetNewDoubleValue(newValue));}
|
||||
if(command == fSetMaxStepCmd)
|
||||
{fF03List->SetMaxStep(fSetMaxStepCmd->GetNewDoubleValue(newValue));}
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
@@ -1,71 +0,0 @@
|
||||
//
|
||||
// ********************************************************************
|
||||
// * 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 field/field03/src/F03StepCut.cc
|
||||
/// \brief Implementation of the F03StepCut class
|
||||
//
|
||||
//
|
||||
// $Id: F03StepCut.cc 76602 2013-11-13 08:33:35Z gcosmo $
|
||||
//
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
#include "F03StepCut.hh"
|
||||
|
||||
#include "G4Step.hh"
|
||||
#include "G4UserLimits.hh"
|
||||
#include "G4VParticleChange.hh"
|
||||
#include "G4EnergyLossTables.hh"
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
F03StepCut::F03StepCut(const G4String& aName)
|
||||
: G4VDiscreteProcess(aName),
|
||||
fMaxChargedStep(DBL_MAX)
|
||||
{
|
||||
if (verboseLevel>0) {
|
||||
G4cout << GetProcessName() << " is created "<< G4endl;
|
||||
}
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
F03StepCut::~F03StepCut()
|
||||
{}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
F03StepCut::F03StepCut(F03StepCut& right)
|
||||
: G4VDiscreteProcess(right)
|
||||
{}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
void F03StepCut::SetMaxStep(G4double step)
|
||||
{
|
||||
fMaxChargedStep = step;
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
Reference in New Issue
Block a user