Import Geant4 8.0.0 source tree

This commit is contained in:
Gabriele Cosmo
2016-06-09 14:36:02 +02:00
parent d93e1e39a9
commit 8a51e0bc40
5471 changed files with 99628 additions and 55248 deletions
@@ -1,87 +0,0 @@
//
// ********************************************************************
// * DISCLAIMER *
// * *
// * The following disclaimer summarizes all the specific disclaimers *
// * of contributors to this software. The specific disclaimers,which *
// * govern, are listed with their locations in: *
// * http://cern.ch/geant4/license *
// * *
// * 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. *
// * *
// * This code implementation is the intellectual property of the *
// * GEANT4 collaboration. *
// * By copying, distributing or modifying the Program (or any work *
// * based on the Program) you indicate your acceptance of this *
// * statement, and all its terms. *
// ********************************************************************
//
//
// $Id: G4IonC12.cc,v 1.1 2004/05/14 12:29:33 guatelli Exp $
// GEANT4 tag $Name: geant4-07-01 $
//
//
// ----------------------------------------------------------------------
// GEANT 4 class implementation file
//
// History: first implementation, based on object model of
// 4th April 1996, G.Cosmo
// **********************************************************************
// ----------------------------------------------------------------------
#include <fstream>
#include <iomanip>
#include "G4IonC12.hh"
// ######################################################################
// ### IonC12 ###
// ######################################################################
G4IonC12::G4IonC12(
const G4String& aName, G4double mass,
G4double width, G4double charge,
G4int iSpin, G4int iParity,
G4int iConjugation, G4int iIsospin,
G4int iIsospin3, G4int gParity,
const G4String& pType, G4int lepton,
G4int baryon, G4int encoding,
G4bool stable, G4double lifetime,
G4DecayTable *decaytable )
: G4VIon( aName,mass,width,charge,iSpin,iParity,
iConjugation,iIsospin,iIsospin3,gParity,pType,
lepton,baryon,encoding,stable,lifetime,decaytable )
{
}
G4IonC12::~G4IonC12()
{
}
// ......................................................................
// ... static member definitions ...
// ......................................................................
//
// Arguments for constructor are as follows
// name mass width charge
// 2*spin parity C-conjugation
// 2*Isospin 2*Isospin3 G-parity
// type lepton number baryon number PDG encoding
// stable lifetime decay table
G4IonC12 G4IonC12::theIonC12(
"IonC12", 11.1749*GeV, 0.0*MeV, +6.0*eplus,
0, +1, 0,
0, 0, 0,
"static_nucleus", 0, +12, 0,
true, -1.0, 0
);
G4IonC12* G4IonC12::IonC12Definition(){return &theIonC12;}
G4IonC12* G4IonC12::IonC12(){return &theIonC12;}
@@ -1,87 +0,0 @@
//
// ********************************************************************
// * DISCLAIMER *
// * *
// * The following disclaimer summarizes all the specific disclaimers *
// * of contributors to this software. The specific disclaimers,which *
// * govern, are listed with their locations in: *
// * http://cern.ch/geant4/license *
// * *
// * 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. *
// * *
// * This code implementation is the intellectual property of the *
// * GEANT4 collaboration. *
// * By copying, distributing or modifying the Program (or any work *
// * based on the Program) you indicate your acceptance of this *
// * statement, and all its terms. *
// ********************************************************************
//
//
// $Id: G4IonFe52.cc,v 1.1 2004/05/14 12:29:33 guatelli Exp $
// GEANT4 tag $Name: geant4-07-01 $
//
//
// ----------------------------------------------------------------------
// GEANT 4 class implementation file
//
// History: first implementation, based on object model of
// 4th April 1996, G.Cosmo
// **********************************************************************
// ----------------------------------------------------------------------
#include <fstream>
#include <iomanip>
#include "G4IonFe52.hh"
// ######################################################################
// ### IonFe52 ###
// ######################################################################
G4IonFe52::G4IonFe52(
const G4String& aName, G4double mass,
G4double width, G4double charge,
G4int iSpin, G4int iParity,
G4int iConjugation, G4int iIsospin,
G4int iIsospin3, G4int gParity,
const G4String& pType, G4int lepton,
G4int baryon, G4int encoding,
G4bool stable, G4double lifetime,
G4DecayTable *decaytable )
: G4VIon( aName,mass,width,charge,iSpin,iParity,
iConjugation,iIsospin,iIsospin3,gParity,pType,
lepton,baryon,encoding,stable,lifetime,decaytable )
{
}
G4IonFe52::~G4IonFe52()
{
}
// ......................................................................
// ... static member definitions ...
// ......................................................................
//
// Arguments for constructor are as follows
// name mass width charge
// 2*spin parity C-conjugation
// 2*Isospin 2*Isospin3 G-parity
// type lepton number baryon number PDG encoding
// stable lifetime decay table
G4IonFe52 G4IonFe52::theIonFe52(
"IonFe52", 48.3761*GeV, 0.0*MeV, +26.0*eplus,
0, +1, 0,
0, 0, 0,
"static_nucleus", 0, +52, 0,
true, -1.0, 0
);
G4IonFe52* G4IonFe52::IonFe52Definition(){return &theIonFe52;}
G4IonFe52* G4IonFe52::IonFe52(){return &theIonFe52;}
@@ -1,74 +0,0 @@
//
// ********************************************************************
// * DISCLAIMER *
// * *
// * The following disclaimer summarizes all the specific disclaimers *
// * of contributors to this software. The specific disclaimers,which *
// * govern, are listed with their locations in: *
// * http://cern.ch/geant4/license *
// * *
// * 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. *
// * *
// * This code implementation is the intellectual property of the *
// * GEANT4 collaboration. *
// * By copying, distributing or modifying the Program (or any work *
// * based on the Program) you indicate your acceptance of this *
// * statement, and all its terms. *
// ********************************************************************
//
#include <fstream>
#include <iomanip>
#include "G4IonO16.hh"
// ######################################################################
// ### IonO16 ###
// ######################################################################
G4IonO16::G4IonO16(
const G4String& aName, G4double mass,
G4double width, G4double charge,
G4int iSpin, G4int iParity,
G4int iConjugation, G4int iIsospin,
G4int iIsospin3, G4int gParity,
const G4String& pType, G4int lepton,
G4int baryon, G4int encoding,
G4bool stable, G4double lifetime,
G4DecayTable *decaytable )
: G4VIon( aName,mass,width,charge,iSpin,iParity,
iConjugation,iIsospin,iIsospin3,gParity,pType,
lepton,baryon,encoding,stable,lifetime,decaytable )
{
}
G4IonO16::~G4IonO16()
{
}
// ......................................................................
// ... static member definitions ...
// ......................................................................
//
// Arguments for constructor are as follows
// name mass width charge
// 2*spin parity C-conjugation
// 2*Isospin 2*Isospin3 G-parity
// type lepton number baryon number PDG encoding
// stable lifetime decay table
G4IonO16 G4IonO16::theIonO16(
"IonO16", 14.8951*GeV, 0.0*MeV, +8.0*eplus,
0, +1, 0,
0, 0, 0,
"static_nucleus", 0, +16, 0,
true, -1.0, 0
);
G4IonO16* G4IonO16::IonO16Definition(){return &theIonO16;}
G4IonO16* G4IonO16::IonO16(){return &theIonO16;}
@@ -1,87 +0,0 @@
//
// ********************************************************************
// * DISCLAIMER *
// * *
// * The following disclaimer summarizes all the specific disclaimers *
// * of contributors to this software. The specific disclaimers,which *
// * govern, are listed with their locations in: *
// * http://cern.ch/geant4/license *
// * *
// * 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. *
// * *
// * This code implementation is the intellectual property of the *
// * GEANT4 collaboration. *
// * By copying, distributing or modifying the Program (or any work *
// * based on the Program) you indicate your acceptance of this *
// * statement, and all its terms. *
// ********************************************************************
//
//
// $Id: G4IonSi28.cc,v 1.1 2004/05/14 12:29:33 guatelli Exp $
// GEANT4 tag $Name: geant4-07-01 $
//
//
// ----------------------------------------------------------------------
// GEANT 4 class implementation file
//
// History: first implementation, based on object model of
// 4th April 1996, G.Cosmo
// **********************************************************************
// ----------------------------------------------------------------------
#include <fstream>
#include <iomanip>
#include "G4IonSi28.hh"
// ######################################################################
// ### IonSi28 ###
// ######################################################################
G4IonSi28::G4IonSi28(
const G4String& aName, G4double mass,
G4double width, G4double charge,
G4int iSpin, G4int iParity,
G4int iConjugation, G4int iIsospin,
G4int iIsospin3, G4int gParity,
const G4String& pType, G4int lepton,
G4int baryon, G4int encoding,
G4bool stable, G4double lifetime,
G4DecayTable *decaytable )
: G4VIon( aName,mass,width,charge,iSpin,iParity,
iConjugation,iIsospin,iIsospin3,gParity,pType,
lepton,baryon,encoding,stable,lifetime,decaytable )
{
}
G4IonSi28::~G4IonSi28()
{
}
// ......................................................................
// ... static member definitions ...
// ......................................................................
//
// Arguments for constructor are as follows
// name mass width charge
// 2*spin parity C-conjugation
// 2*Isospin 2*Isospin3 G-parity
// type lepton number baryon number PDG encoding
// stable lifetime decay table
G4IonSi28 G4IonSi28::theIonSi28(
"IonSi28", 26.0532*GeV, 0.0*MeV, +14.0*eplus,
0, +1, 0,
0, 0, 0,
"static_nucleus", 0, +28, 0,
true, -1.0, 0
);
G4IonSi28* G4IonSi28::IonSi28Definition(){return &theIonSi28;}
G4IonSi28* G4IonSi28::IonSi28(){return &theIonSi28;}
@@ -26,7 +26,7 @@
// * *
// *******************************
//
// $Id: RemSimAnalysisManager.cc,v 1.8 2005/05/27 14:21:42 guatelli Exp $
// $Id: RemSimAnalysisManager.cc,v 1.9 2005/09/08 06:56:18 guatelli Exp $
//
// Author:Susanna Guatelli, guatelli@ge.infn.it
//
@@ -34,7 +34,7 @@
#include <stdlib.h>
#include <fstream>
#include "RemSimAnalysisManager.hh"
#include "RemSimAnalysisMessenger.hh"
//#include "RemSimAnalysisMessenger.hh"
#include "G4ios.hh"
#include <AIDA/AIDA.h>
#include "G4RunManager.hh"
@@ -51,13 +51,13 @@ RemSimAnalysisManager::RemSimAnalysisManager()
{
aFact = AIDA_createAnalysisFactory();
messenger = new RemSimAnalysisMessenger(this);
// messenger = new RemSimAnalysisMessenger(this);
fileFormat = "hbook";
}
RemSimAnalysisManager::~RemSimAnalysisManager()
{
delete messenger;
//delete messenger;
delete energyShape;
energyShape = 0;
@@ -1,79 +0,0 @@
//
// ********************************************************************
// * DISCLAIMER *
// * *
// * The following disclaimer summarizes all the specific disclaimers *
// * of contributors to this software. The specific disclaimers,which *
// * govern, are listed with their locations in: *
// * http://cern.ch/geant4/license *
// * *
// * 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. *
// * *
// * This code implementation is the intellectual property of the *
// * GEANT4 collaboration. *
// * By copying, distributing or modifying the Program (or any work *
// * based on the Program) you indicate your acceptance of this *
// * statement, and all its terms. *
// ********************************************************************
//
//
// $Id: RemSimAnalysisMessenger.cc
// GEANT4 tag $Name: radioprotection-V07-00-01
//
// Author: Susanna Guatelli (Susanna.Guatelli@ge.infn.it)
//
// History:
// -----------
// 23 Nov 2004 Susanna Guatelli Created
//
// -------------------------------------------------------------------
#ifdef G4ANALYSIS_USE
#include "RemSimAnalysisMessenger.hh"
RemSimAnalysisMessenger::RemSimAnalysisMessenger(RemSimAnalysisManager* analysisManager)
:remsimAnalysis(analysisManager)
{
analysisDir = new G4UIdirectory("/analysis/");
analysisDir->SetGuidance("analysis control.");
outputFileType = new G4UIcmdWithAString("/analysis/formatFile",this);
outputFileType -> SetGuidance("specify the format: hbook or xml");
outputFileType -> SetCandidates("hbook xml");
outputFileType -> SetDefaultValue("hbook");
outputFileType -> AvailableForStates(G4State_Idle);
}
RemSimAnalysisMessenger::~RemSimAnalysisMessenger()
{
delete outputFileType;
delete analysisDir;
}
void RemSimAnalysisMessenger::SetNewValue(G4UIcommand* command,G4String newValue)
{
if(command == outputFileType)
{
remsimAnalysis -> SetFormat(newValue);
}
}
#endif
@@ -1,85 +0,0 @@
//
// ********************************************************************
// * DISCLAIMER *
// * *
// * The following disclaimer summarizes all the specific disclaimers *
// * of contributors to this software. The specific disclaimers,which *
// * govern, are listed with their locations in: *
// * http://cern.ch/geant4/license *
// * *
// * 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. *
// * *
// * This code implementation is the intellectual property of the *
// * GEANT4 collaboration. *
// * By copying, distributing or modifying the Program (or any work *
// * based on the Program) you indicate your acceptance of this *
// * statement, and all its terms. *
// ********************************************************************
//
// **********************************
// * *
// * RemSimBasicGenerator.hh *
// * *
// **********************************
//
// $Id: RemSimBasicGenerator.cc,v 1.7 2005/05/19 13:30:59 guatelli Exp $
//
// Author:Susanna Guatelli, guatelli@ge.infn.it
#include "RemSimBasicGenerator.hh"
#include "RemSimVPrimaryGeneratorFactory.hh"
#include "G4Event.hh"
#include "G4ParticleGun.hh"
#include "G4ParticleTable.hh"
#include "G4ParticleDefinition.hh"
#include "G4ios.hh"
#ifdef G4ANALYSIS_USE
#include "RemSimAnalysisManager.hh"
#endif
RemSimBasicGenerator::RemSimBasicGenerator()
{
G4int n_particle = 1;
particleGun = new G4ParticleGun(n_particle);
G4ParticleTable* particleTable = G4ParticleTable::GetParticleTable();
G4String particleName = "proton";
particleGun -> SetParticleDefinition(particleTable->FindParticle(particleName));
particleGun -> SetParticlePosition(G4ThreeVector(0., 0., -25.*m));
G4ThreeVector v(0.0,0.0,1.0);
particleGun -> SetParticleEnergy(100.*MeV);
particleGun -> SetParticleMomentumDirection(v);
}
RemSimBasicGenerator::~RemSimBasicGenerator()
{
delete particleGun;
}
void RemSimBasicGenerator::GeneratePrimaries(G4Event* anEvent)
{
#ifdef G4ANALYSIS_USE
G4double energy = particleGun -> GetParticleEnergy();
RemSimAnalysisManager* analysis = RemSimAnalysisManager::getInstance();
analysis -> primaryParticleEnergyDistribution(energy/MeV);
#endif
particleGun -> GeneratePrimaryVertex(anEvent);
}
G4double RemSimBasicGenerator:: GetInitialEnergy()
{
G4double primaryParticleEnergy = particleGun -> GetParticleEnergy();
return primaryParticleEnergy;
}
void RemSimBasicGenerator::Read(G4String)
{
G4cout << " Sorry!The basic generator has no option to load the energy spectrum from a data.txt file" << G4endl;
}
@@ -27,8 +27,8 @@
// * *
// ***********************
//
// $Id: RemSimDecay.cc,v 1.2 2004/05/22 12:57:06 guatelli Exp $
// GEANT4 tag $Name: geant4-07-01 $
// $Id: RemSimDecay.cc,v 1.4 2005/12/07 14:41:36 guatelli Exp $
// GEANT4 tag $Name: geant4-08-00 $
//
// Author:Susanna Guatelli, guatelli@ge.infn.it
//
@@ -56,13 +56,14 @@ void RemSimDecay::ConstructProcess()
{
G4ParticleDefinition* particle = theParticleIterator -> value();
G4ProcessManager* pmanager = particle -> GetProcessManager();
if (theDecayProcess -> IsApplicable(*particle))
if (theDecayProcess -> IsApplicable(*particle) && !particle->IsShortLived())
{
G4String name = particle -> GetParticleName();
pmanager -> AddProcess(theDecayProcess);
// set ordering for PostStepDoIt and AtRestDoIt
pmanager -> SetProcessOrdering(theDecayProcess, idxPostStep);
pmanager -> SetProcessOrdering(theDecayProcess, idxAtRest);
}
}
}
@@ -28,7 +28,7 @@
// ***************************
//
// $Id: RemSimDecorator.cc,v 1.5 2004/05/22 12:57:06 guatelli Exp $
// GEANT4 tag $Name: geant4-07-01 $
// GEANT4 tag $Name: geant4-08-00 $
//
// Author:Susanna Guatelli, guatelli@ge.infn.it
//
@@ -27,8 +27,8 @@
// * *
// **************************************
//
// $Id: RemSimDetectorConstruction.cc,v 1.15 2005/05/27 14:20:50 guatelli Exp $
// GEANT4 tag $Name: geant4-07-01 $
// $Id: RemSimDetectorConstruction.cc,v 1.16 2005/09/08 06:56:18 guatelli Exp $
// GEANT4 tag $Name: geant4-08-00 $
//
// Author:Susanna Guatelli, guatelli@ge.infn.it
//
@@ -31,8 +31,8 @@
// *********************************
//
//
// $Id: RemSimDetectorMessenger.cc,v 1.10 2005/05/27 14:21:42 guatelli Exp $
// GEANT4 tag $Name: geant4-07-01 $
// $Id: RemSimDetectorMessenger.cc,v 1.12 2005/12/06 07:47:35 guatelli Exp $
// GEANT4 tag $Name: geant4-08-00 $
//
//
@@ -51,7 +51,7 @@ RemSimDetectorMessenger::RemSimDetectorMessenger( RemSimDetectorConstruction* De
vehicleCmd -> SetGuidance("Assign the geometrical set-up to G4RunManager.");
vehicleCmd -> SetParameterName("choice",true);
vehicleCmd -> SetCandidates("vehicle moon");
vehicleCmd -> AvailableForStates(G4State_Idle);
vehicleCmd -> AvailableForStates(G4State_Idle);
shieldingCmd = new G4UIcmdWithAString("/configuration/AddShielding",this);
shieldingCmd -> SetGuidance("Add shielding layer in vehicle configuration.");
@@ -20,8 +20,8 @@
// * statement, and all its terms. *
// ********************************************************************
//
// $Id: RemSimElectronEEDL.cc,v 1.4 2005/05/19 13:46:29 guatelli Exp $
// GEANT4 tag $Name: geant4-07-01 $
// $Id: RemSimElectronEEDL.cc,v 1.5 2005/09/08 06:56:18 guatelli Exp $
// GEANT4 tag $Name: geant4-08-00 $
//
// Author: Susanna Guatelli, guatelloi@ge.infn.it
@@ -27,8 +27,8 @@
// **********************************
//
//
// $Id: RemSimEventAction.cc,v 1.7 2004/05/27 12:31:31 guatelli Exp $
// GEANT4 tag $Name: geant4-07-01 $
// $Id: RemSimEventAction.cc,v 1.8 2005/09/08 06:56:18 guatelli Exp $
// GEANT4 tag $Name: geant4-08-00 $
//
// Author : Susanna Guatelli, guatelli@ge.infn.it
//
@@ -39,8 +39,8 @@
#include "G4Trajectory.hh"
#include "G4VVisManager.hh"
#include "G4ios.hh"
#include "Randomize.hh"
#include "CLHEP/Random/RandEngine.h"
//##include "Randomize.hh"
//#include "CLHEP/Random/RandEngine.h"
RemSimEventAction::RemSimEventAction():evtNo(-1)
{}
@@ -26,8 +26,8 @@
// * *
// **************************************
//
// $Id: RemSimHadronicBertini.cc,v 1.1 2004/11/23 14:37:47 guatelli Exp $
// GEANT4 tag $Name: geant4-07-01 $
// $Id: RemSimHadronicBertini.cc,v 1.3 2005/09/08 06:56:18 guatelli Exp $
// GEANT4 tag $Name: geant4-08-00 $
//
// Author : Susanna Guatelli, guatelli@ge.infn.it
//
@@ -91,8 +91,7 @@ G4VPhysicsConstructor(name)
QGSP_model = new G4TheoFSGenerator();
theCascade = new G4GeneratorPrecompoundInterface();
theHandler = new G4ExcitationHandler();
thePreEquilib = new G4PreCompoundModel(theHandler);
thePreEquilib = new G4PreCompoundModel(&theHandler);
theCascade -> SetDeExcitation(thePreEquilib);
QGSP_model -> SetTransport(theCascade);
theFragmentation = new G4QGSMFragmentation();
@@ -26,8 +26,8 @@
// * *
// **************************************
//
// $Id: RemSimHadronicBinary.cc,v 1.1 2004/11/23 14:37:47 guatelli Exp $
// GEANT4 tag $Name: geant4-07-01 $
// $Id: RemSimHadronicBinary.cc,v 1.3 2005/09/08 06:56:18 guatelli Exp $
// GEANT4 tag $Name: geant4-08-00 $
//
// Author : Susanna Guatelli, guatelli@ge.infn.it
//
@@ -95,8 +95,8 @@ G4VPhysicsConstructor(name)
QGSP_model = new G4TheoFSGenerator();
theCascade = new G4GeneratorPrecompoundInterface();
theHandler = new G4ExcitationHandler();
thePreEquilib = new G4PreCompoundModel(theHandler);
thePreEquilib = new G4PreCompoundModel(&theHandler);
theCascade -> SetDeExcitation(thePreEquilib);
QGSP_model -> SetTransport(theCascade);
theFragmentation = new G4QGSMFragmentation();
@@ -1,84 +0,0 @@
//
// ********************************************************************
// * DISCLAIMER *
// * *
// * The following disclaimer summarizes all the specific disclaimers *
// * of contributors to this software. The specific disclaimers,which *
// * govern, are listed with their locations in: *
// * http://cern.ch/geant4/license *
// * *
// * 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. *
// * *
// * This code implementation is the intellectual property of the *
// * GEANT4 collaboration. *
// * By copying, distributing or modifying the Program (or any work *
// * based on the Program) you indicate your acceptance of this *
// * statement, and all its terms. *
// ********************************************************************
//
#include "RemSimHit.hh"
#include "G4VVisManager.hh"
#include "G4Circle.hh"
#include "G4Colour.hh"
#include "G4VisAttributes.hh"
#include "G4UnitsTable.hh"
#include "G4ios.hh"
G4Allocator<RemSimHit> RemSimHitAllocator;
RemSimHit::RemSimHit()
{;}
RemSimHit::~RemSimHit()
{;}
RemSimHit::RemSimHit(const RemSimHit &right)
: G4VHit()
{
edep = right.edep;
zID = right.zID;
position = right.position;
}
const RemSimHit& RemSimHit::operator=(const RemSimHit &right)
{
edep = right.edep;
zID = right.zID;
position = right.position;
return *this;
}
G4int RemSimHit::operator==(const RemSimHit &right) const
{
return (this==&right) ? 1 : 0;
}
void RemSimHit::Draw()
{
G4VVisManager* pVVisManager = G4VVisManager::GetConcreteInstance();
if(pVVisManager)
{
G4Circle circle(position);
circle.SetScreenSize(4.);
circle.SetFillStyle(G4Circle::filled);
G4Colour colour(1.,0.,0.);
G4VisAttributes attribs(colour);
circle.SetVisAttributes(attribs);
pVVisManager->Draw(circle);
}
}
void RemSimHit::Print()
{
G4cout<<
"Hit in Astronaut:"
<< G4BestUnit(edep, "Energy")
<< " in position: "
<< G4BestUnit(position, "Length") <<G4endl;
}
@@ -1,228 +0,0 @@
//
// ********************************************************************
// * DISCLAIMER *
// * *
// * The following disclaimer summarizes all the specific disclaimers *
// * of contributors to this software. The specific disclaimers,which *
// * govern, are listed with their locations in: *
// * http://cern.ch/geant4/license *
// * *
// * 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. *
// * *
// * This code implementation is the intellectual property of the *
// * GEANT4 collaboration. *
// * By copying, distributing or modifying the Program (or any work *
// * based on the Program) you indicate your acceptance of this *
// * statement, and all its terms. *
// ********************************************************************
//
// Author : Susanna Guatelli, guatelli@ge.infn.it
//
#include "CLHEP/Random/RandGeneral.h"
#include "RemSimInterplanetarySpaceConfiguration.hh"
#include "RemSimVPrimaryGeneratorFactory.hh"
#include "G4Event.hh"
#include "G4ParticleGun.hh"
#include "G4ParticleTable.hh"
#include "G4ParticleDefinition.hh"
#include "G4ios.hh"
#include "Randomize.hh"
#ifdef G4ANALYSIS_USE
#include "RemSimAnalysisManager.hh"
#endif
#include "RemSimRunAction.hh"
#include <fstream>
#include <strstream>
RemSimInterplanetarySpaceConfiguration::RemSimInterplanetarySpaceConfiguration()
{
G4int n_particle = 1;
particleGun = new G4ParticleGun(n_particle);
moon = false;
G4ParticleTable* particleTable = G4ParticleTable::GetParticleTable();
G4String particleName = "proton";
particleGun -> SetParticleDefinition(particleTable->FindParticle(particleName));
particleGun -> SetParticlePosition(G4ThreeVector(0., 0., -25.*m));
G4ThreeVector v(0.0,0.0,1.0);
particleGun -> SetParticleEnergy(1.*MeV);
particleGun -> SetParticleMomentumDirection(v);
energies = new G4DataVector;
data = new G4DataVector;
}
RemSimInterplanetarySpaceConfiguration::~RemSimInterplanetarySpaceConfiguration()
{
delete data;
delete energies;
delete particleGun;
}
void RemSimInterplanetarySpaceConfiguration::GeneratePrimaries(G4Event* anEvent){
G4double sum = GetPrimaryParticleEnergyDistributionSum();
G4double partSum = 0;
G4int j = 0;
G4double random = sum*G4UniformRand();
while (partSum<random)
{
partSum += (*data)[j];
j++;
}
G4String particleName = particleGun -> GetParticleDefinition() ->
GetParticleName();
G4int n = 0;
if (particleName == "alpha") n = 4;
else {
if (particleName == "IonC12") n = 12;
else
{ if (particleName == "IonSi28") n = 28;
else {
if (particleName == "IonFe52") n = 52;
else {
if (particleName == "IonO16") n = 16;
else {
if (particleName == "proton") n = 1 ;
}
}
}
}
}
particleGun -> SetParticleEnergy((*energies)[j] * n);
#ifdef G4ANALYSIS_USE
G4double energy = particleGun -> GetParticleEnergy();
RemSimAnalysisManager* analysis = RemSimAnalysisManager::getInstance();
analysis -> primaryParticleEnergyDistribution((energy/n) / MeV);
#endif
if (moon == true) MoonConfiguration();
else
{
particleGun -> SetParticlePosition(G4ThreeVector(0., 0., -25.*m));
G4ThreeVector v(0.0,0.0,1.0);
particleGun -> SetParticleMomentumDirection(v);
}
particleGun -> GeneratePrimaryVertex(anEvent);
}
void RemSimInterplanetarySpaceConfiguration:: MoonConfiguration()
{
//Generate the primary particles on a hemisphere with random direction
//position
G4double radius = 25.* m;
G4double angle = pi * G4UniformRand()*rad;
G4double y0 = radius*std::cos(angle);
G4double x0 = 0.*m;
G4double z0 = -radius*std::sin(angle);
if ( z0 < 0. *m)
{
particleGun->SetParticlePosition(G4ThreeVector(x0,y0,z0));
}
//direction
G4double angledir = pi * G4UniformRand()*rad;
if ((angledir> (pi/2.-angle)) && angledir<(3*pi/2.-angle))
{
G4double a,b,c;
b=std::cos(angledir);
a=0.;
c=std::sin(angledir);
G4ThreeVector direction(a,b,c);
particleGun -> SetParticleMomentumDirection(direction);
}
}
G4double RemSimInterplanetarySpaceConfiguration:: GetInitialEnergy()
{
G4double primaryParticleEnergy = particleGun -> GetParticleEnergy();
return primaryParticleEnergy;
}
void RemSimInterplanetarySpaceConfiguration::SetMoon(G4bool value)
{
moon = value;
}
void RemSimInterplanetarySpaceConfiguration::Read(G4String name)
{
ReadData(MeV,name);
G4cout << name << " is the input file!" << G4endl;
}
void RemSimInterplanetarySpaceConfiguration::ReadData(G4double unitE, G4String fileName)
{
char nameChar[100] = {""};
std::ostrstream ost(nameChar, 100, std::ios::out);
ost << fileName;
G4String name(nameChar);
std::ifstream file(fileName);
std::filebuf* lsdp = file.rdbuf();
if (! (lsdp->is_open()) )
{
G4String excep = "RemSimInterplanteraySpaceConfiguration - data file: not found";
G4Exception(excep);
}
G4double a = 0;
G4int k = 1;
do
{
file >> a;
G4int nColumns = 2;
// The file is organized into two columns:
// 1st column is the energy
// 2nd column is the corresponding value
// The file terminates with the pattern: -1 -1
// -2 -2
if (a == -1 || a == -2)
{
}
else
{
if (k%nColumns != 0)
{
G4double e = a * unitE;
energies->push_back(e);
// G4cout<<e<<"energy";
k++;
}
else if (k%nColumns == 0)
{
G4double value = a;
data->push_back(value);
//G4cout<<" "<<a<<"flux"<<G4endl;
k = 1;
}
}
} while (a != -2); // end of file
}
G4double RemSimInterplanetarySpaceConfiguration::GetPrimaryParticleEnergyDistributionSum()
{
G4double sum = 0;
size_t size = data -> size();
for (size_t i = 0; i < size; i++)
{
sum+=(*data)[i];
}
return sum;
}
@@ -20,8 +20,8 @@
// * statement, and all its terms. *
// ********************************************************************
//
// $Id: RemSimIonICRU.cc,v 1.6 2005/05/19 13:46:29 guatelli Exp $
// GEANT4 tag $Name: geant4-07-01 $
// $Id: RemSimIonICRU.cc,v 1.9 2005/12/06 07:47:35 guatelli Exp $
// GEANT4 tag $Name: geant4-08-00 $
//
// Author: Susanna Guatelli, guatelli@ge.infn.it
@@ -51,20 +51,30 @@ void RemSimIonICRU::ConstructProcess()
G4String particleName = particle -> GetParticleName();
G4double charge = particle -> GetPDGCharge();
if (( charge != 0. ) && particleName != "e+" && particleName != "mu+" &&
if (particleName == "proton" || particleName == "GenericIon"
|| particleName == "alpha" )
{
G4hLowEnergyIonisation* ionisation = new G4hLowEnergyIonisation();
G4VProcess* multipleScattering = new G4MultipleScattering();
manager -> AddProcess(multipleScattering, -1,1,1);
manager -> AddProcess(ionisation, -1,2,2);
manager -> AddProcess(new G4StepLimiter(),-1,-1,3);
}
else{
if (( charge != 0. ) && particleName != "e+" && particleName != "mu+" &&
particleName != "e-" && particleName != "mu-")
{
if((!particle -> IsShortLived()) &&
(particle -> GetParticleName() != "chargedgeantino"))
{
G4hLowEnergyIonisation* ionisation = new G4hLowEnergyIonisation();
G4VProcess* multipleScattering = new G4MultipleScattering();
manager -> AddProcess(multipleScattering, -1,1,1);
manager -> AddProcess(ionisation, -1,2,2);
manager -> AddProcess(new G4StepLimiter(),-1,-1,3);
}
}
}
{
if((!particle -> IsShortLived()) &&
(particle -> GetParticleName() != "chargedgeantino"))
{
G4hLowEnergyIonisation* ionisation = new G4hLowEnergyIonisation();
G4VProcess* multipleScattering = new G4MultipleScattering();
manager -> AddProcess(multipleScattering, -1,1,1);
manager -> AddProcess(ionisation, -1,2,2);
manager -> AddProcess(new G4StepLimiter(),-1,-1,3);
}
}
}}
}
@@ -29,15 +29,14 @@
// * *
// *******************************
//
// $Id: RemSimMaterial.cc,v 1.5 2004/05/22 12:57:06 guatelli Exp $
// GEANT4 tag $Name: geant4-07-01 $
// $Id: RemSimMaterial.cc,v 1.6 2005/09/08 06:56:18 guatelli Exp $
// GEANT4 tag $Name: geant4-08-00 $
//
#include "G4MaterialPropertiesTable.hh"
#include "G4MaterialPropertyVector.hh"
#include "globals.hh"
#include "G4MaterialTable.hh"
#include "Randomize.hh"
#include "G4RunManager.hh"
#include "G4Element.hh"
#include "G4ElementTable.hh"
@@ -27,8 +27,8 @@
// * *
// **************************************
//
// $Id: RemSimMoonHabitat.cc,v 1.5 2005/05/27 14:21:42 guatelli Exp $
// GEANT4 tag $Name: geant4-07-01 $
// $Id: RemSimMoonHabitat.cc,v 1.6 2005/09/08 06:56:18 guatelli Exp $
// GEANT4 tag $Name: geant4-08-00 $
//
// Author:Susanna Guatelli, guatelli@ge.infn.it
//
@@ -20,8 +20,8 @@
// * statement, and all its terms. *
// ********************************************************************
//
// $Id: RemSimMuonStandard.cc,v 1.4 2005/05/19 13:46:29 guatelli Exp $
// GEANT4 tag $Name: geant4-07-01 $
// $Id: RemSimMuonStandard.cc,v 1.5 2005/09/08 06:56:18 guatelli Exp $
// GEANT4 tag $Name: geant4-08-00 $
//
// Author:Susanna Guatelli, guatelli@ge.infn.it
//
@@ -19,42 +19,30 @@
// * based on the Program) you indicate your acceptance of this *
// * statement, and all its terms. *
// ********************************************************************
// $Id: HadrontherapyParticles.cc; May 2005
// ----------------------------------------------------------------------------
// GEANT 4 - Hadrontherapy example
// ----------------------------------------------------------------------------
// Code developed by:
//
// $Id: RemSimParticles.cc,v 1.4 2004/05/22 12:57:07 guatelli Exp $
// GEANT4 tag $Name: geant4-07-01 $
//
// Author:Susanna Guatelli, guatelli@ge.infn.it
//
// G.A.P. Cirrone(a)*, F. Di Rosa(a), S. Guatelli(b), G. Russo(a)
//
// (a) Laboratori Nazionali del Sud
// of the National Institute for Nuclear Physics, Catania, Italy
// (b) National Institute for Nuclear Physics Section of Genova, genova, Italy
//
// * cirrone@lns.infn.it
// ----------------------------------------------------------------------------
#include "RemSimParticles.hh"
#include "G4Gamma.hh"
#include "G4Electron.hh"
#include "G4Positron.hh"
#include "G4Proton.hh"
#include "G4Alpha.hh"
#include "G4IonO16.hh"
#include "G4IonC12.hh"
#include "G4IonSi28.hh"
#include "G4IonFe52.hh"
#include "G4ParticleDefinition.hh"
#include "G4ParticleTypes.hh"
#include "G4ParticleTable.hh"
#include "G4LeptonConstructor.hh"
#include "G4BosonConstructor.hh"
#include "G4MesonConstructor.hh"
#include "G4BaryonConstructor.hh"
#include "G4ShortLivedConstructor.hh"
#include "G4IonConstructor.hh"
#include "G4MuonPlus.hh"
#include "G4MuonMinus.hh"
#include "G4TauMinus.hh"
#include "G4TauPlus.hh"
#include "G4NeutrinoTau.hh"
#include "G4AntiNeutrinoTau.hh"
#include "G4NeutrinoMu.hh"
#include "G4AntiNeutrinoMu.hh"
#include "G4NeutrinoE.hh"
#include "G4AntiNeutrinoE.hh"
#include "G4ChargedGeantino.hh"
#include "G4Geantino.hh"
#include "G4PionPlus.hh"
#include "G4PionMinus.hh"
#include "G4PionZero.hh"
RemSimParticles::RemSimParticles(const G4String& name)
: G4VPhysicsConstructor(name)
{ }
@@ -64,47 +52,26 @@ RemSimParticles::~RemSimParticles()
void RemSimParticles::ConstructParticle()
{
G4Gamma::GammaDefinition();
G4Electron::ElectronDefinition();
G4Positron::PositronDefinition();
G4Proton :: ProtonDefinition();
G4Alpha :: AlphaDefinition();
G4IonO16::IonO16Definition();
G4IonC12::IonC12Definition();
G4IonSi28::IonSi28Definition();
G4IonFe52::IonFe52Definition();
// Mu
G4MuonPlus::MuonPlusDefinition();
G4MuonMinus::MuonMinusDefinition();
G4NeutrinoMu::NeutrinoMuDefinition();
G4AntiNeutrinoMu::AntiNeutrinoMuDefinition();
// Tau
G4TauMinus::TauMinusDefinition();
G4TauPlus::TauPlusDefinition();
G4NeutrinoTau::NeutrinoTauDefinition();
G4AntiNeutrinoTau::AntiNeutrinoTauDefinition();
G4NeutrinoE::NeutrinoEDefinition();
G4AntiNeutrinoE::AntiNeutrinoEDefinition();
G4LeptonConstructor lepton;
lepton.ConstructParticle();
G4Geantino::GeantinoDefinition();
G4ChargedGeantino::ChargedGeantinoDefinition();
G4BosonConstructor boson;
boson.ConstructParticle();
G4PionPlus::PionPlusDefinition();
G4PionMinus::PionMinusDefinition();
G4PionZero::PionZeroDefinition();
G4MesonConstructor pMesonConstructor;
pMesonConstructor.ConstructParticle();
G4MesonConstructor meson;
meson.ConstructParticle();
G4BaryonConstructor pBaryonConstructor;
pBaryonConstructor.ConstructParticle();
G4BaryonConstructor baryon;
baryon.ConstructParticle();
G4ShortLivedConstructor pShortLivedConstructor;
pShortLivedConstructor.ConstructParticle();
G4IonConstructor pConstructor;
pConstructor.ConstructParticle();
G4ShortLivedConstructor shortLived;
shortLived.ConstructParticle();
// ******//
// ions //
// ******//
G4Deuteron::DeuteronDefinition();
G4Triton::TritonDefinition();
G4He3::He3Definition();
G4Alpha::AlphaDefinition();
G4GenericIon::GenericIonDefinition();
}
@@ -20,8 +20,8 @@
// * statement, and all its terms. *
// ********************************************************************
//
// $Id: RemSimPhotonEPDL.cc,v 1.5 2005/05/19 13:46:29 guatelli Exp $
// GEANT4 tag $Name: geant4-07-01 $
// $Id: RemSimPhotonEPDL.cc,v 1.6 2005/09/08 06:56:18 guatelli Exp $
// GEANT4 tag $Name: geant4-08-00 $
//
// Author:Susanna Guatelli, guatelli@ge.infn.it
//
@@ -20,8 +20,8 @@
// * statement, and all its terms. *
// ********************************************************************
//
// $Id: RemSimPhysicsList.cc,v 1.8 2004/11/23 15:43:41 guatelli Exp $
// GEANT4 tag $Name: geant4-07-01 $
// $Id: RemSimPhysicsList.cc,v 1.9 2005/09/08 06:56:18 guatelli Exp $
// GEANT4 tag $Name: geant4-08-00 $
//
// Author: Susanna Guatelli
@@ -140,10 +140,11 @@ void RemSimPhysicsList::AddPhysicsList(const G4String& name)
}
}
// Register hadronic process for p and alpha particle, activating the
// Binary model
// // Register hadronic process for p and alpha particle, activating the
// // Binary model
if (name == "hadronic-binary")
if (name == "hadronic-binary")
{
if (hadronicIsRegistered)
{
@@ -163,7 +164,7 @@ void RemSimPhysicsList::AddPhysicsList(const G4String& name)
// Register hadronic process for p and alpha particle, activating the
// Bertini model
if (name == "hadronic-bertini")
if (name == "hadronic-bertini")
{
if (hadronicIsRegistered)
{
@@ -21,7 +21,7 @@
// ********************************************************************
//
// $Id: RemSimPhysicsListMessenger.cc,v 1.3 2004/05/22 12:57:07 guatelli Exp $
// GEANT4 tag $Name: geant4-07-01 $
// GEANT4 tag $Name: geant4-08-00 $
//
// Author: Susanna Guatelli, guatelli@ge.infn.it
@@ -20,8 +20,8 @@
// * statement, and all its terms. *
// ********************************************************************
//
// $Id: RemSimPositronStandard.cc,v 1.4 2005/05/19 13:46:29 guatelli Exp $
// GEANT4 tag $Name: geant4-07-01 $
// $Id: RemSimPositronStandard.cc,v 1.5 2005/09/08 06:56:18 guatelli Exp $
// GEANT4 tag $Name: geant4-08-00 $
//
// Author: Susanna Guatelli, guatelli@ge.infn.it
#include "RemSimPositronStandard.hh"
@@ -21,87 +21,38 @@
// ********************************************************************
//
//
// $Id: RemSimPrimaryGeneratorAction.cc,v 1.11 2005/05/27 14:21:42 guatelli Exp $// Author: Susanna Guatelli, guatelli@ge.infn.it
// $Id: RemSimPrimaryGeneratorAction.cc,v 1.14 2005/12/02 10:08:34 guatelli Exp $// Author: Susanna Guatelli, guatelli@ge.infn.it
#include "RemSimPrimaryGeneratorAction.hh"
#include "RemSimPrimaryGeneratorMessenger.hh"
#include "RemSimBasicGenerator.hh"
#include "RemSimInterplanetarySpaceConfiguration.hh"
#include "RemSimVPrimaryGeneratorFactory.hh"
#ifdef G4ANALYSIS_USE
#include "RemSimAnalysisManager.hh"
#endif
#include "G4Event.hh"
#include "G4ParticleGun.hh"
#include "G4ParticleTable.hh"
#include "G4ParticleDefinition.hh"
#include "globals.hh"
#include "G4GeneralParticleSource.hh"
RemSimPrimaryGeneratorAction::RemSimPrimaryGeneratorAction()
{
value = "Basic";
primaryFactory = new RemSimBasicGenerator();
messenger = new RemSimPrimaryGeneratorMessenger(this);
particleGun = new G4GeneralParticleSource();
}
RemSimPrimaryGeneratorAction::~RemSimPrimaryGeneratorAction()
{
delete messenger;
delete primaryFactory;
delete particleGun;
}
G4double RemSimPrimaryGeneratorAction::GetInitialEnergy()
{
G4double initialEnergy = 0.;
initialEnergy = primaryFactory -> GetInitialEnergy();
return initialEnergy;
G4double primaryParticleEnergy = particleGun -> GetParticleEnergy();
return primaryParticleEnergy;
}
void RemSimPrimaryGeneratorAction::GeneratePrimaries(G4Event* anEvent)
{
if(value == "Interplanetary")
{
primaryFactory -> SetMoon(false);
}
else if(value == "Moon")
{
primaryFactory -> SetMoon(true);
}
#ifdef G4ANALYSIS_USE
G4double energy = particleGun -> GetParticleEnergy();
RemSimAnalysisManager* analysis = RemSimAnalysisManager::getInstance();
analysis -> primaryParticleEnergyDistribution(energy/MeV);
#endif
primaryFactory -> GeneratePrimaries(anEvent);
}
void RemSimPrimaryGeneratorAction::SelectPrimaries(G4String val)
{
value = val;
if(value == "Basic")
G4cout<< "The configuration is the basic generator" <<G4endl;
else if(value == "Interplanetary")
{
G4cout<< "The configuration is the interplanetary space configuration"
<<G4endl;
G4cout<<
"Remember to type /run/data file.txt with the energy spectrum of primary particles!!!" <<G4endl;
delete primaryFactory;
primaryFactory = 0;
primaryFactory = new RemSimInterplanetarySpaceConfiguration();
}
else if (value == "Moon")
{
G4cout<< "The configuration is the Moon Configuration" <<G4endl;
G4cout<<
"Remember to type /run/data file.txt with the energy spectrum of primary particles!!!" <<G4endl;
delete primaryFactory;
primaryFactory =0;
primaryFactory = new RemSimInterplanetarySpaceConfiguration();
}
else G4cout << "This Generator is not defined!" <<G4endl;
}
void RemSimPrimaryGeneratorAction::Read(G4String fileName)
{
primaryFactory -> Read(fileName);
particleGun -> GeneratePrimaryVertex(anEvent);
}
@@ -1,76 +0,0 @@
//
// ********************************************************************
// * DISCLAIMER *
// * *
// * The following disclaimer summarizes all the specific disclaimers *
// * of contributors to this software. The specific disclaimers,which *
// * govern, are listed with their locations in: *
// * http://cern.ch/geant4/license *
// * *
// * 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. *
// * *
// * This code implementation is the intellectual property of the *
// * GEANT4 collaboration. *
// * By copying, distributing or modifying the Program (or any work *
// * based on the Program) you indicate your acceptance of this *
// * statement, and all its terms. *
// ********************************************************************
//
//
// Code developed by: S.Guatelli, guatelli@ge.infn.it
//
// *****************************************
// * *
// * RemSimPrimaryGeneratorMessenger.cc *
// * *
// *****************************************
//
//
// $Id: RemSimPrimaryGeneratorMessenger.cc,v 1.7 2005/05/19 13:30:59 guatelli Exp $
// GEANT4 tag $Name: geant4-07-01 $
//
//
#include "RemSimPrimaryGeneratorMessenger.hh"
#include "RemSimRunAction.hh"
#include "RemSimPrimaryGeneratorAction.hh"
#include "G4UIdirectory.hh"
#include "G4UIcmdWithAString.hh"
#include "G4UIcmdWithAnInteger.hh"
#include "G4UIcmdWithADoubleAndUnit.hh"
#include "G4UIcmdWithoutParameter.hh"
RemSimPrimaryGeneratorMessenger::RemSimPrimaryGeneratorMessenger( RemSimPrimaryGeneratorAction* prim): primary(prim)
{
gunDir = new G4UIdirectory("/gun/");
gunDir->SetGuidance("Select the generation configuration of primary particles.");
fluxCmd = new G4UIcmdWithAString("/gun/generator",this);
fluxCmd -> SetGuidance("Assign the configuration of generation of primary particles.");
fluxCmd -> SetParameterName("choice",true);
fluxCmd -> SetCandidates("Moon Interplanetary Basic");
fluxCmd -> AvailableForStates(G4State_PreInit,G4State_Idle);
dataCmd = new G4UIcmdWithAString("/gun/data",this);
dataCmd -> SetGuidance("Primary particle spectrum");
dataCmd -> SetParameterName("choice",true);
dataCmd -> AvailableForStates(G4State_PreInit,G4State_Idle);
}
RemSimPrimaryGeneratorMessenger::~RemSimPrimaryGeneratorMessenger()
{
delete dataCmd;
delete fluxCmd;
delete gunDir;
}
void RemSimPrimaryGeneratorMessenger::SetNewValue(G4UIcommand* command,G4String newValue)
{
if(command == fluxCmd) primary -> SelectPrimaries(newValue);
if (command == dataCmd) primary -> Read(newValue);
}
@@ -30,7 +30,7 @@
// ************************************
//
// $Id: RemSimROGeometry.cc,v 1.5 2004/05/22 12:57:07 guatelli Exp $
// GEANT4 tag $Name: geant4-07-01 $
// GEANT4 tag $Name: geant4-08-00 $
//
#include "RemSimROGeometry.hh"
#include "RemSimDummySD.hh"
@@ -29,8 +29,8 @@
// Code developed by: S.Guatelli, guatelli@ge.infn.it
//
//
// $Id: RemSimRoofDecorator.cc,v 1.5 2005/05/27 14:21:42 guatelli Exp $
// GEANT4 tag $Name: geant4-07-01 $
// $Id: RemSimRoofDecorator.cc,v 1.6 2005/09/08 06:56:18 guatelli Exp $
// GEANT4 tag $Name: geant4-08-00 $
//
#include "RemSimVGeometryComponent.hh"
#include "RemSimMaterial.hh"
@@ -28,9 +28,8 @@
// *******************************
//
// Code developed by: S.Guatelli, guatelli@ge.infn.it
//
// $Id: RemSimRunAction.cc,v 1.11 2005/05/19 13:30:59 guatelli Exp $
// GEANT4 tag $Name: geant4-07-01 $
// $Id: RemSimRunAction.cc,v 1.13 2005/11/23 08:49:10 guatelli Exp $
// GEANT4 tag $Name: geant4-08-00 $
//
#include "RemSimRunAction.hh"
@@ -43,8 +42,6 @@
#include "G4RunManager.hh"
#include "G4ios.hh"
#include "RemSimRunAction.hh"
#include <fstream>
#include <strstream>
RemSimRunAction::RemSimRunAction()
{
@@ -21,13 +21,12 @@
// ********************************************************************
//
//
// $Id: RemSimSensitiveDetector.cc,v 1.9 2005/05/27 14:21:42 guatelli Exp $
// GEANT4 tag $Name: geant4-07-01 $
// $Id: RemSimSensitiveDetector.cc,v 1.11 2005/11/23 09:22:11 guatelli Exp $
// GEANT4 tag $Name: geant4-08-00 $
//
// Code developed by: S.Guatelli, guatelli@ge.infn.it
//
#include "RemSimSensitiveDetector.hh"
#include "RemSimHit.hh"
#include "G4Step.hh"
#include "G4HCofThisEvent.hh"
#include "G4TouchableHistory.hh"
@@ -39,20 +38,13 @@
RemSimSensitiveDetector::RemSimSensitiveDetector(G4String name)
:G4VSensitiveDetector(name)
{
G4String HCname;
collectionName.insert(HCname="trackerCollection");
}
RemSimSensitiveDetector::~RemSimSensitiveDetector(){;}
void RemSimSensitiveDetector::Initialize(G4HCofThisEvent* HCE)
void RemSimSensitiveDetector::Initialize(G4HCofThisEvent*)
{
static G4int HCID = -1;
trackerCollection = new RemSimHitsCollection
(SensitiveDetectorName,collectionName[0]);
if(HCID<0)
{ HCID = GetCollectionID(0); }
HCE -> AddHitsCollection(HCID,trackerCollection);
}
G4bool RemSimSensitiveDetector::ProcessHits(G4Step* aStep,
@@ -61,24 +53,13 @@ G4bool RemSimSensitiveDetector::ProcessHits(G4Step* aStep,
G4double edep = aStep -> GetTotalEnergyDeposit();
if(edep==0.) return false;
G4int i = ROhist -> GetReplicaNumber();
RemSimHit* newHit = new RemSimHit();
newHit -> SetEdep(edep);
newHit -> SetIndexes(i);
newHit->SetPosition(aStep->GetPreStepPoint()->GetPosition());
trackerCollection -> insert( newHit );
#ifdef G4ANALYSIS_USE
RemSimAnalysisManager* analysis = RemSimAnalysisManager::getInstance();
G4int i = ROhist -> GetReplicaNumber();
// Energy deposit in the phantom
analysis -> energyDepositStore(i,edep/MeV);
// G4cout << "energy deposit:"<< i <<","<< edep/MeV << G4endl;
G4double xx = aStep -> GetPreStepPoint() -> GetPosition().x();
G4double yy = aStep -> GetPreStepPoint() -> GetPosition().y();
//G4double zz = aStep -> GetPreStepPoint() -> GetPosition().z();
// Project the hits of primary and secondary particles
// in the phantom in the plane x, y
@@ -92,7 +73,6 @@ G4bool RemSimSensitiveDetector::ProcessHits(G4Step* aStep,
if(aStep -> GetTrack() -> GetTrackID()!= 1)
analysis -> SecondaryEnergyDeposit(i,edep/MeV);
#endif
return true;
}
@@ -21,7 +21,7 @@
// ********************************************************************
//
// $Id: RemSimShelterSPEDecorator.cc,v 1.2 2004/05/22 12:57:07 guatelli Exp $
// GEANT4 tag $Name: geant4-07-01 $
// GEANT4 tag $Name: geant4-08-00 $
//
// Code developed by: S.Guatelli, guatelli@ge.infn.it
//
@@ -21,7 +21,7 @@
// ********************************************************************
//
// $Id: RemSimShieldingDecorator.cc,v 1.5 2004/05/27 08:36:52 guatelli Exp $
// GEANT4 tag $Name: geant4-07-01 $
// GEANT4 tag $Name: geant4-08-00 $
//
// Code developed by: S.Guatelli, guatelli@ge.infn.it
//
@@ -21,8 +21,8 @@
// ********************************************************************
//
//
// $Id: RemSimSteppingAction.cc,v 1.6 2004/11/23 15:43:41 guatelli Exp $
// GEANT4 tag $Name: geant4-07-01 $
// $Id: RemSimSteppingAction.cc,v 1.7 2005/09/08 06:56:18 guatelli Exp $
// GEANT4 tag $Name: geant4-08-00 $
//
//
// Author: Susanna Guatelli (guatelli@ge.infn.it)
@@ -21,7 +21,7 @@
// ********************************************************************
//
//
//$Id: RemSimSteppingActionMessenger.cc,v 1.3 2004/11/23 15:43:41 guatelli Exp $// GEANT4 tag $Name: geant4-07-01 $
//$Id: RemSimSteppingActionMessenger.cc,v 1.4 2005/09/08 06:56:18 guatelli Exp $// GEANT4 tag $Name: geant4-08-00 $
//
// Code developed by: S.Guatelli, guatelli@ge.infn.it
//
@@ -21,7 +21,7 @@
// ********************************************************************
//
// $Id: RemSimVGeometryComponent.cc,v 1.3 2004/05/22 12:57:07 guatelli Exp $
// GEANT4 tag $Name: geant4-07-01 $
// GEANT4 tag $Name: geant4-08-00 $
//
// Code developed by: S.Guatelli, guatelli@ge.infn.it
//
@@ -1,35 +0,0 @@
//
// ********************************************************************
// * DISCLAIMER *
// * *
// * The following disclaimer summarizes all the specific disclaimers *
// * of contributors to this software. The specific disclaimers,which *
// * govern, are listed with their locations in: *
// * http://cern.ch/geant4/license *
// * *
// * 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. *
// * *
// * This code implementation is the intellectual property of the *
// * GEANT4 collaboration. *
// * By copying, distributing or modifying the Program (or any work *
// * based on the Program) you indicate your acceptance of this *
// * statement, and all its terms. *
// ********************************************************************
//
// $Id: RemSimVPrimaryGeneratorFactory.cc,v 1.5 2004/05/22 12:57:07 guatelli Exp $Name: geant4-07-01 $
//
// Code developed by: S.Guatelli, guatelli@ge.infn.it
//
#include "RemSimVPrimaryGeneratorFactory.hh"
RemSimVPrimaryGeneratorFactory::RemSimVPrimaryGeneratorFactory()
{
}
RemSimVPrimaryGeneratorFactory::~RemSimVPrimaryGeneratorFactory()
{
}
@@ -21,7 +21,7 @@
// ********************************************************************
//
// $Id: RemSimVehicle1.cc,v 1.8 2004/05/27 08:36:52 guatelli Exp $
// GEANT4 tag $Name: geant4-07-01 $
// GEANT4 tag $Name: geant4-08-00 $
//
// Code developed by: S.Guatelli, guatelli@ge.infn.it
//