Import Geant4 10.0.0 source tree
This commit is contained in:
@@ -26,7 +26,7 @@
|
||||
/// \file electromagnetic/TestEm6/src/DetectorConstruction.cc
|
||||
/// \brief Implementation of the DetectorConstruction class
|
||||
//
|
||||
// $Id$
|
||||
// $Id: DetectorConstruction.cc 67268 2013-02-13 11:38:40Z ihrivnac $
|
||||
//
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
@@ -52,7 +52,9 @@
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
DetectorConstruction::DetectorConstruction()
|
||||
:fP_Box(0), fL_Box(0), fBoxSize(500*m), fMaterial(0), fMagField(0)
|
||||
:G4VUserDetectorConstruction(),
|
||||
fP_Box(0), fL_Box(0), fBoxSize(500*m), fMaterial(0), fMagField(0),
|
||||
fUserLimits(0), fDetectorMessenger(0)
|
||||
{
|
||||
DefineMaterials();
|
||||
SetMaterial("Iron");
|
||||
|
||||
@@ -26,7 +26,7 @@
|
||||
/// \file electromagnetic/TestEm6/src/DetectorMessenger.cc
|
||||
/// \brief Implementation of the DetectorMessenger class
|
||||
//
|
||||
// $Id$
|
||||
// $Id: DetectorMessenger.cc 67268 2013-02-13 11:38:40Z ihrivnac $
|
||||
//
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
@@ -42,7 +42,14 @@
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
DetectorMessenger::DetectorMessenger(DetectorConstruction * Det)
|
||||
:fDetector(Det)
|
||||
:G4UImessenger(),fDetector(Det),
|
||||
fTestemDir(0),
|
||||
fDetDir(0),
|
||||
fMaterCmd(0),
|
||||
fSizeCmd(0),
|
||||
fMagFieldCmd(0),
|
||||
fMaxStepCmd(0),
|
||||
fUpdateCmd(0)
|
||||
{
|
||||
fTestemDir = new G4UIdirectory("/testem/");
|
||||
fTestemDir->SetGuidance(" detector control.");
|
||||
|
||||
@@ -26,7 +26,7 @@
|
||||
/// \file electromagnetic/TestEm6/src/EventAction.cc
|
||||
/// \brief Implementation of the EventAction class
|
||||
//
|
||||
// $Id$
|
||||
// $Id: EventAction.cc 67268 2013-02-13 11:38:40Z ihrivnac $
|
||||
//
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
@@ -43,7 +43,7 @@
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
EventAction::EventAction()
|
||||
:fDrawFlag("none"),fPrintModulo(10000),fEventMessenger(0)
|
||||
:G4UserEventAction(),fDrawFlag("none"),fPrintModulo(10000),fEventMessenger(0)
|
||||
{
|
||||
fEventMessenger = new EventActionMessenger(this);
|
||||
}
|
||||
|
||||
@@ -26,7 +26,7 @@
|
||||
/// \file electromagnetic/TestEm6/src/EventActionMessenger.cc
|
||||
/// \brief Implementation of the EventActionMessenger class
|
||||
//
|
||||
// $Id$
|
||||
// $Id: EventActionMessenger.cc 67268 2013-02-13 11:38:40Z ihrivnac $
|
||||
//
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
@@ -41,7 +41,10 @@
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
EventActionMessenger::EventActionMessenger(EventAction* EvAct)
|
||||
:fEventAction(EvAct)
|
||||
:G4UImessenger(),fEventAction(EvAct),
|
||||
fEventDir(0),
|
||||
fDrawCmd(0),
|
||||
fPrintCmd(0)
|
||||
{
|
||||
fEventDir = new G4UIdirectory("/testem/event/");
|
||||
fEventDir->SetGuidance("event control");
|
||||
|
||||
@@ -26,7 +26,7 @@
|
||||
/// \file electromagnetic/TestEm6/src/PhysicsList.cc
|
||||
/// \brief Implementation of the PhysicsList class
|
||||
//
|
||||
// $Id$
|
||||
// $Id: PhysicsList.cc 73716 2013-09-09 10:07:13Z gcosmo $
|
||||
//
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
@@ -71,16 +71,12 @@
|
||||
|
||||
#include "G4ProcessTable.hh"
|
||||
|
||||
#include "G4ComptonScattering.hh"
|
||||
#include "G4GammaConversion.hh"
|
||||
#include "G4PhotoElectricEffect.hh"
|
||||
|
||||
#include "G4SystemOfUnits.hh"
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
PhysicsList::PhysicsList()
|
||||
: G4VUserPhysicsList()
|
||||
: G4VUserPhysicsList(), fMes(0)
|
||||
{
|
||||
defaultCutValue = 1.*km;
|
||||
fMes = new PhysicsListMessenger(this);
|
||||
@@ -180,10 +176,11 @@ void PhysicsList::ConstructEM()
|
||||
|
||||
if (particleName == "gamma") {
|
||||
// gamma allow only gamma -> mu+mu-
|
||||
// pmanager->AddDiscreteProcess(new G4GammaConversionToMuons);
|
||||
// pmanager->AddDiscreteProcess(new G4PhotoElectricEffect);
|
||||
// pmanager->AddDiscreteProcess(new G4ComptonScattering);
|
||||
// pmanager->AddDiscreteProcess(new G4GammaConversion);
|
||||
pmanager->AddDiscreteProcess(new G4GammaConversionToMuons);
|
||||
pmanager->AddDiscreteProcess(new G4PhotoElectricEffect);
|
||||
pmanager->AddDiscreteProcess(new G4ComptonScattering);
|
||||
pmanager->AddDiscreteProcess(new G4GammaConversion);
|
||||
|
||||
} else if (particleName == "e-") {
|
||||
//electron
|
||||
@@ -250,8 +247,8 @@ void PhysicsList::ConstructGeneral()
|
||||
while ((*theParticleIterator)()){
|
||||
G4ParticleDefinition* particle = theParticleIterator->value();
|
||||
G4ProcessManager* pmanager = particle->GetProcessManager();
|
||||
if (theDecayProcess->IsApplicable(*particle) && !particle->IsShortLived()) {
|
||||
pmanager ->AddProcess(theDecayProcess);
|
||||
if (theDecayProcess->IsApplicable(*particle) && !particle->IsShortLived())
|
||||
{ pmanager ->AddProcess(theDecayProcess);
|
||||
// set ordering for PostStepDoIt and AtRestDoIt
|
||||
pmanager ->SetProcessOrdering(theDecayProcess, idxPostStep);
|
||||
pmanager ->SetProcessOrdering(theDecayProcess, idxAtRest);
|
||||
@@ -282,9 +279,12 @@ void PhysicsList::SetCuts()
|
||||
void PhysicsList::SetGammaToMuPairFac(G4double fac)
|
||||
{
|
||||
G4ProcessTable* theProcessTable = G4ProcessTable::GetProcessTable();
|
||||
G4GammaConversionToMuons* theGammaToMuPairProcess = (G4GammaConversionToMuons*) theProcessTable->FindProcess("GammaToMuPair","gamma");
|
||||
if(theGammaToMuPairProcess) theGammaToMuPairProcess->SetCrossSecFactor(fac);
|
||||
else G4cout << "Warning. No process GammaToMuPair found, SetGammaToMuPairFac was ignored" << G4endl;
|
||||
G4GammaConversionToMuons* gammaToMuPairProcess = (G4GammaConversionToMuons*)
|
||||
theProcessTable->FindProcess("GammaToMuPair","gamma");
|
||||
if(gammaToMuPairProcess) gammaToMuPairProcess->SetCrossSecFactor(fac);
|
||||
else G4cout
|
||||
<< "Warning. No process GammaToMuPair found, SetGammaToMuPairFac was ignored"
|
||||
<< G4endl;
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
@@ -292,9 +292,12 @@ void PhysicsList::SetGammaToMuPairFac(G4double fac)
|
||||
void PhysicsList::SetAnnihiToMuPairFac(G4double fac)
|
||||
{
|
||||
G4ProcessTable* theProcessTable = G4ProcessTable::GetProcessTable();
|
||||
G4AnnihiToMuPair* theAnnihiToMuPairProcess = (G4AnnihiToMuPair*) theProcessTable->FindProcess("AnnihiToMuPair","e+");
|
||||
if(theAnnihiToMuPairProcess) theAnnihiToMuPairProcess->SetCrossSecFactor(fac);
|
||||
else G4cout << "Warning. No process AnnihiToMuPair found, SetAnnihiToMuPairFac was ignored" << G4endl;
|
||||
G4AnnihiToMuPair* annihiToMuPairProcess = (G4AnnihiToMuPair*)
|
||||
theProcessTable->FindProcess("AnnihiToMuPair","e+");
|
||||
if(annihiToMuPairProcess) annihiToMuPairProcess->SetCrossSecFactor(fac);
|
||||
else G4cout
|
||||
<< "Warning. No process AnnihiToMuPair found, SetAnnihiToMuPairFac ignored"
|
||||
<< G4endl;
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
@@ -302,9 +305,12 @@ void PhysicsList::SetAnnihiToMuPairFac(G4double fac)
|
||||
void PhysicsList::SetAnnihiToHadronFac(G4double fac)
|
||||
{
|
||||
G4ProcessTable* theProcessTable = G4ProcessTable::GetProcessTable();
|
||||
G4eeToHadrons* eehadProcess = (G4eeToHadrons*) theProcessTable->FindProcess("ee2hadr","e+");
|
||||
G4eeToHadrons* eehadProcess = (G4eeToHadrons*)
|
||||
theProcessTable->FindProcess("ee2hadr","e+");
|
||||
if(eehadProcess) eehadProcess->SetCrossSecFactor(fac);
|
||||
else G4cout << "Warning. No process ee2hadr found, SetAnnihiToHadronFac was ignored" << G4endl;
|
||||
else G4cout
|
||||
<< "Warning. No process ee2hadr found, SetAnnihiToHadronFac was ignored"
|
||||
<< G4endl;
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
@@ -26,7 +26,7 @@
|
||||
/// \file electromagnetic/TestEm6/src/PhysicsListMessenger.cc
|
||||
/// \brief Implementation of the PhysicsListMessenger class
|
||||
//
|
||||
// $Id$
|
||||
// $Id: PhysicsListMessenger.cc 68192 2013-03-18 14:50:18Z maire $
|
||||
//
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
@@ -40,7 +40,11 @@
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
PhysicsListMessenger::PhysicsListMessenger(PhysicsList* physL)
|
||||
:fPhysList(physL)
|
||||
:G4UImessenger(),fPhysList(physL),
|
||||
fPhysDir(0),
|
||||
fGammaToMuPairFacCmd(0),
|
||||
fAnnihiToMuPairFacCmd(0),
|
||||
fAnnihiToHadronFacCmd(0)
|
||||
{
|
||||
fPhysDir = new G4UIdirectory("/testem/phys/");
|
||||
fPhysDir->SetGuidance("physics list commands");
|
||||
@@ -95,7 +99,7 @@ void PhysicsListMessenger::SetNewValue(G4UIcommand* command,
|
||||
|
||||
if( command == fAnnihiToHadronFacCmd)
|
||||
{ fPhysList->SetAnnihiToHadronFac(
|
||||
fAnnihiToHadronFacCmd->GetNewDoubleValue(newValue));}
|
||||
fAnnihiToHadronFacCmd->GetNewDoubleValue(newValue));}
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
@@ -26,7 +26,7 @@
|
||||
/// \file electromagnetic/TestEm6/src/PrimaryGeneratorAction.cc
|
||||
/// \brief Implementation of the PrimaryGeneratorAction class
|
||||
//
|
||||
// $Id$
|
||||
// $Id: PrimaryGeneratorAction.cc 67268 2013-02-13 11:38:40Z ihrivnac $
|
||||
//
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
@@ -47,7 +47,11 @@
|
||||
|
||||
PrimaryGeneratorAction::PrimaryGeneratorAction(
|
||||
DetectorConstruction* DC)
|
||||
:fDetector(DC)
|
||||
:G4VUserPrimaryGeneratorAction(),
|
||||
fParticleGun(0),
|
||||
fDetector(DC),
|
||||
fRndmBeam(0),
|
||||
fGunMessenger(0)
|
||||
{
|
||||
fParticleGun = new G4ParticleGun(1);
|
||||
G4ParticleDefinition* particle
|
||||
@@ -56,8 +60,6 @@ PrimaryGeneratorAction::PrimaryGeneratorAction(
|
||||
fParticleGun->SetParticleEnergy(100*TeV);
|
||||
fParticleGun->SetParticleMomentumDirection(G4ThreeVector(1.,0.,0.));
|
||||
|
||||
fRndmBeam = 0.;
|
||||
|
||||
//create a messenger for this class
|
||||
fGunMessenger = new PrimaryGeneratorMessenger(this);
|
||||
}
|
||||
|
||||
@@ -26,7 +26,7 @@
|
||||
/// \file electromagnetic/TestEm6/src/PrimaryGeneratorMessenger.cc
|
||||
/// \brief Implementation of the PrimaryGeneratorMessenger class
|
||||
//
|
||||
// $Id$
|
||||
// $Id: PrimaryGeneratorMessenger.cc 67268 2013-02-13 11:38:40Z ihrivnac $
|
||||
//
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
@@ -41,7 +41,9 @@
|
||||
|
||||
PrimaryGeneratorMessenger::PrimaryGeneratorMessenger(
|
||||
PrimaryGeneratorAction* Gun)
|
||||
:fAction(Gun)
|
||||
:G4UImessenger(),fAction(Gun),
|
||||
fGunDir(0),
|
||||
fRndmCmd(0)
|
||||
{
|
||||
fGunDir = new G4UIdirectory("/testem/gun/");
|
||||
fGunDir->SetGuidance("gun control");
|
||||
|
||||
@@ -26,7 +26,7 @@
|
||||
/// \file electromagnetic/TestEm6/src/RunAction.cc
|
||||
/// \brief Implementation of the RunAction class
|
||||
//
|
||||
// $Id$
|
||||
// $Id: RunAction.cc 67268 2013-02-13 11:38:40Z ihrivnac $
|
||||
//
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
@@ -41,6 +41,7 @@
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
RunAction::RunAction()
|
||||
: G4UserRunAction(),fProcCounter(0)
|
||||
{
|
||||
// Create analysis manager
|
||||
// The choice of analysis technology is done via selection of a namespace
|
||||
|
||||
@@ -26,7 +26,7 @@
|
||||
/// \file electromagnetic/TestEm6/src/StackingAction.cc
|
||||
/// \brief Implementation of the StackingAction class
|
||||
//
|
||||
// $Id$
|
||||
// $Id: StackingAction.cc 67268 2013-02-13 11:38:40Z ihrivnac $
|
||||
//
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
@@ -38,6 +38,7 @@
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
StackingAction::StackingAction()
|
||||
: G4UserStackingAction()
|
||||
{}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
@@ -26,7 +26,7 @@
|
||||
/// \file electromagnetic/TestEm6/src/SteppingAction.cc
|
||||
/// \brief Implementation of the SteppingAction class
|
||||
//
|
||||
// $Id$
|
||||
// $Id: SteppingAction.cc 67268 2013-02-13 11:38:40Z ihrivnac $
|
||||
//
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
@@ -40,7 +40,7 @@
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
SteppingAction::SteppingAction(RunAction* RuAct)
|
||||
:fRunAction(RuAct)
|
||||
:G4UserSteppingAction(),fRunAction(RuAct)
|
||||
{
|
||||
fMuonMass = G4MuonPlus::MuonPlus()->GetPDGMass();
|
||||
}
|
||||
|
||||
@@ -23,24 +23,26 @@
|
||||
// * acceptance of all terms of the Geant4 Software license. *
|
||||
// ********************************************************************
|
||||
//
|
||||
/// \file electromagnetic/TestEm6/src/SteppingVerbose.cc
|
||||
/// \file radioactivedecay/rdecay01/src/SteppingVerbose.cc
|
||||
/// \brief Implementation of the SteppingVerbose class
|
||||
//
|
||||
//
|
||||
// $Id$
|
||||
// $Id: SteppingVerbose.cc 71646 2013-06-19 15:38:53Z gcosmo $
|
||||
//
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
#include "SteppingVerbose.hh"
|
||||
|
||||
#include "G4SteppingManager.hh"
|
||||
#include "G4ParticleTypes.hh"
|
||||
#include "G4UnitsTable.hh"
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
SteppingVerbose::SteppingVerbose()
|
||||
{}
|
||||
: G4SteppingVerbose()
|
||||
{ }
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
@@ -49,10 +51,46 @@ SteppingVerbose::~SteppingVerbose()
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
void SteppingVerbose::StepInfo()
|
||||
{
|
||||
void SteppingVerbose::TrackingStarted()
|
||||
{
|
||||
CopyState();
|
||||
|
||||
G4int prec = G4cout.precision(3);
|
||||
|
||||
//Step zero
|
||||
//
|
||||
if( verboseLevel > 0 ){
|
||||
G4cout << std::setw( 5) << "Step#" << " "
|
||||
<< std::setw( 6) << "X" << " "
|
||||
<< std::setw( 6) << "Y" << " "
|
||||
<< std::setw( 6) << "Z" << " "
|
||||
<< std::setw( 9) << "KineE" << " "
|
||||
<< std::setw( 9) << "dEStep" << " "
|
||||
<< std::setw(10) << "StepLeng"
|
||||
<< std::setw(10) << "TrakLeng"
|
||||
<< std::setw(10) << "Volume" << " "
|
||||
<< std::setw(10) << "Process" << G4endl;
|
||||
|
||||
G4cout << std::setw(5) << fTrack->GetCurrentStepNumber() << " "
|
||||
<< std::setw(6) << G4BestUnit(fTrack->GetPosition().x(),"Length")
|
||||
<< std::setw(6) << G4BestUnit(fTrack->GetPosition().y(),"Length")
|
||||
<< std::setw(6) << G4BestUnit(fTrack->GetPosition().z(),"Length")
|
||||
<< std::setw(6) << G4BestUnit(fTrack->GetKineticEnergy(),"Energy")
|
||||
<< std::setw(6) << G4BestUnit(fStep->GetTotalEnergyDeposit(),"Energy")
|
||||
<< std::setw(6) << G4BestUnit(fStep->GetStepLength(),"Length")
|
||||
<< std::setw(6) << G4BestUnit(fTrack->GetTrackLength(),"Length")
|
||||
<< std::setw(10) << fTrack->GetVolume()->GetName()
|
||||
<< " initStep" << G4endl;
|
||||
}
|
||||
G4cout.precision(prec);
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
void SteppingVerbose::StepInfo()
|
||||
{
|
||||
CopyState();
|
||||
|
||||
G4int prec = G4cout.precision(3);
|
||||
|
||||
if( verboseLevel >= 1 ){
|
||||
@@ -89,30 +127,27 @@ void SteppingVerbose::StepInfo()
|
||||
G4cout << " " << std::setw(10) << procName;
|
||||
G4cout << G4endl;
|
||||
|
||||
if( verboseLevel == 2 ){
|
||||
G4int tN2ndariesTot = fN2ndariesAtRestDoIt +
|
||||
fN2ndariesAlongStepDoIt +
|
||||
fN2ndariesPostStepDoIt;
|
||||
if(tN2ndariesTot>0){
|
||||
G4cout << "\n :----- List of secondaries ----------------"
|
||||
<< G4endl;
|
||||
if (verboseLevel == 2) {
|
||||
const std::vector<const G4Track*>* secondary
|
||||
= fStep->GetSecondaryInCurrentStep();
|
||||
size_t nbtrk = (*secondary).size();
|
||||
if (nbtrk) {
|
||||
G4cout << "\n :----- List of secondaries ----------------" << G4endl;
|
||||
G4cout.precision(4);
|
||||
for(size_t lp1=(*fSecondary).size()-tN2ndariesTot;
|
||||
lp1<(*fSecondary).size(); lp1++){
|
||||
for (size_t lp=0; lp<(*secondary).size(); lp++) {
|
||||
G4cout << " "
|
||||
<< std::setw(13)
|
||||
<< (*fSecondary)[lp1]->GetDefinition()->GetParticleName()
|
||||
<< (*secondary)[lp]->GetDefinition()->GetParticleName()
|
||||
<< ": energy ="
|
||||
<< std::setw(6)
|
||||
<< G4BestUnit((*fSecondary)[lp1]->GetKineticEnergy(),"Energy")
|
||||
<< G4BestUnit((*secondary)[lp]->GetKineticEnergy(),"Energy")
|
||||
<< " time ="
|
||||
<< std::setw(6)
|
||||
<< G4BestUnit((*fSecondary)[lp1]->GetGlobalTime(),"Time");
|
||||
<< G4BestUnit((*secondary)[lp]->GetGlobalTime(),"Time");
|
||||
G4cout << G4endl;
|
||||
}
|
||||
|
||||
G4cout << " :------------------------------------------\n"
|
||||
<< G4endl;
|
||||
G4cout << " :------------------------------------------\n" << G4endl;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -121,37 +156,3 @@ void SteppingVerbose::StepInfo()
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
void SteppingVerbose::TrackingStarted()
|
||||
{
|
||||
|
||||
CopyState();
|
||||
G4int prec = G4cout.precision(3);
|
||||
if( verboseLevel > 0 ){
|
||||
|
||||
G4cout << std::setw( 5) << "Step#" << " "
|
||||
<< std::setw( 6) << "X" << " "
|
||||
<< std::setw( 6) << "Y" << " "
|
||||
<< std::setw( 6) << "Z" << " "
|
||||
<< std::setw( 9) << "KineE" << " "
|
||||
<< std::setw( 9) << "dEStep" << " "
|
||||
<< std::setw(10) << "StepLeng"
|
||||
<< std::setw(10) << "TrakLeng"
|
||||
<< std::setw(10) << "Volume" << " "
|
||||
<< std::setw(10) << "Process" << G4endl;
|
||||
|
||||
G4cout << std::setw(5) << fTrack->GetCurrentStepNumber() << " "
|
||||
<< std::setw(6) << G4BestUnit(fTrack->GetPosition().x(),"Length")
|
||||
<< std::setw(6) << G4BestUnit(fTrack->GetPosition().y(),"Length")
|
||||
<< std::setw(6) << G4BestUnit(fTrack->GetPosition().z(),"Length")
|
||||
<< std::setw(6) << G4BestUnit(fTrack->GetKineticEnergy(),"Energy")
|
||||
<< std::setw(6) << G4BestUnit(fStep->GetTotalEnergyDeposit(),"Energy")
|
||||
<< std::setw(6) << G4BestUnit(fStep->GetStepLength(),"Length")
|
||||
<< std::setw(6) << G4BestUnit(fTrack->GetTrackLength(),"Length")
|
||||
<< std::setw(10) << fTrack->GetVolume()->GetName()
|
||||
<< " initStep" << G4endl;
|
||||
}
|
||||
G4cout.precision(prec);
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
Reference in New Issue
Block a user