Import Geant4 1.1.0 source tree

This commit is contained in:
Gabriele Cosmo
2016-06-08 15:34:16 +02:00
parent ca1c8cb059
commit 103bda00c8
2654 changed files with 29719 additions and 20203 deletions
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: ExN05CalorimeterHit.cc,v 1.1.10.1 1999/12/07 20:47:35 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
// $Id: ExN05CalorimeterHit.cc,v 1.2 1999/12/15 14:49:29 gunter Exp $
// GEANT4 tag $Name: geant4-01-01 $
//
#include "ExN05CalorimeterHit.hh"
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: ExN05CalorimeterSD.cc,v 1.1.10.1 1999/12/07 20:47:35 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
// $Id: ExN05CalorimeterSD.cc,v 1.2 1999/12/15 14:49:30 gunter Exp $
// GEANT4 tag $Name: geant4-01-01 $
//
#include "ExN05CalorimeterSD.hh"
@@ -62,13 +62,13 @@ G4bool ExN05CalorimeterSD::ProcessHits(G4Step*aStep,G4TouchableHistory*ROhist)
int icell = CalCollection->insert( calHit );
CellID[copyID] = icell - 1;
if(verboseLevel>0)
{ G4cout << " New Calorimeter Hit on CellID " << copyID << endl; }
{ G4cout << " New Calorimeter Hit on CellID " << copyID << G4endl; }
}
else
{
(*CalCollection)[CellID[copyID]]->AddEdep( edep );
if(verboseLevel>0)
{ G4cout << " Energy added to CellID " << copyID << endl; }
{ G4cout << " Energy added to CellID " << copyID << G4endl; }
}
return true;
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: ExN05DetectorConstruction.cc,v 1.1.10.1 1999/12/07 20:47:36 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
// $Id: ExN05DetectorConstruction.cc,v 1.2 1999/12/15 14:49:30 gunter Exp $
// GEANT4 tag $Name: geant4-01-01 $
//
#include "ExN05DetectorConstruction.hh"
#include "ExN05CalorimeterSD.hh"
@@ -48,7 +48,7 @@ ExN05DetectorConstruction::~ExN05DetectorConstruction()
G4VPhysicalVolume* ExN05DetectorConstruction::Construct()
{
G4cout << "\nExN05DetectorConstruction....\n" << endl;
G4cout << "\nExN05DetectorConstruction....\n" << G4endl;
//--------- Material definition ---------
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: ExN05DetectorMessenger.cc,v 1.1.10.1 1999/12/07 20:47:36 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
// $Id: ExN05DetectorMessenger.cc,v 1.2 1999/12/15 14:49:30 gunter Exp $
// GEANT4 tag $Name: geant4-01-01 $
//
//
@@ -16,13 +16,9 @@
#include "G4UIcmdWithAString.hh"
#include "G4UIcmdWithADoubleAndUnit.hh"
#include "globals.hh"
#include <iomanip.h>
#include "g4std/iomanip"
#ifdef WIN32
# include <Strstrea.h>
#else
# include <strstream.h>
#endif
#include "g4std/strstream"
ExN05DetectorMessenger::ExN05DetectorMessenger(ExN05DetectorConstruction * myDet) : myDetector(myDet)
{
@@ -92,7 +88,7 @@ G4String ExN05DetectorMessenger::GetCurrentValue(G4UIcommand * command)
{
G4String returnValue('\0');
char line[255];
ostrstream os(line,255);
G4std::ostrstream os(line,255);
if( command == SwitchCmd ) {
if ( myDetector->IsUseUserLimits() )returnValue = "on";
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: ExN05EMShowerModel.cc,v 1.1.10.1 1999/12/07 20:47:36 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
// $Id: ExN05EMShowerModel.cc,v 1.2 1999/12/15 14:49:30 gunter Exp $
// GEANT4 tag $Name: geant4-01-01 $
//
#include "ExN05EMShowerModel.hh"
#include "ExN05EnergySpot.hh"
+3 -3
View File
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: ExN05EnergySpot.cc,v 1.1.10.1 1999/12/07 20:47:37 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
// $Id: ExN05EnergySpot.cc,v 1.2 1999/12/15 14:49:30 gunter Exp $
// GEANT4 tag $Name: geant4-01-01 $
//
#include "ExN05EnergySpot.hh"
@@ -65,7 +65,7 @@ void ExN05EnergySpot::Draw(G4Colour *color)
void ExN05EnergySpot::Print()
{
G4cout << " ExN05EnergySpot {E = " << Energy << "; Position = " << Point << " }"<< endl;
G4cout << " ExN05EnergySpot {E = " << Energy << "; Position = " << Point << " }"<< G4endl;
}
+7 -7
View File
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: ExN05EventAction.cc,v 1.2.6.1.2.1 1999/12/07 20:47:37 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
// $Id: ExN05EventAction.cc,v 1.4 1999/12/15 14:49:30 gunter Exp $
// GEANT4 tag $Name: geant4-01-01 $
//
#include "ExN05EventAction.hh"
@@ -53,7 +53,7 @@ void ExN05EventAction::EndOfEventAction(const G4Event* evt )
calorimeterCollID = SDman->GetCollectionID(colNam="CalCollection");
hadCalorimeterCollID = SDman->GetCollectionID(colNam="HadCollection");
G4cout << ">>> Event " << evt->GetEventID() << endl;
G4cout << ">>> Event " << evt->GetEventID() << G4endl;
G4HCofThisEvent * HCE = evt->GetHCofThisEvent();
ExN05CalorimeterHitsCollection* CaloHC = NULL;
@@ -68,24 +68,24 @@ void ExN05EventAction::EndOfEventAction(const G4Event* evt )
{
int n_hit = CaloHC->entries();
G4cout << " " << n_hit
<< " hits are stored in EM ExN05CalorimeterHitsCollection." << endl;
<< " hits are stored in EM ExN05CalorimeterHitsCollection." << G4endl;
G4double totE = 0;
for(int i=0;i<n_hit;i++)
{ totE += (*CaloHC)[i]->GetEdep(); }
G4cout << " Total energy deposition in EM calorimeter crytals : "
<< totE / GeV << " (GeV)" << endl;
<< totE / GeV << " (GeV)" << G4endl;
}
if(HadCaloHC)
{
int n_hit = HadCaloHC->entries();
G4cout << " " << n_hit
<< " hits are stored in HAD ExN05CalorimeterHitsCollection." << endl;
<< " hits are stored in HAD ExN05CalorimeterHitsCollection." << G4endl;
G4double totE = 0;
for(int i=0;i<n_hit;i++)
{ totE += (*HadCaloHC)[i]->GetEdep(); }
G4cout << " Total energy deposition in HAD calorimeter towers : "
<< totE / GeV << " (GeV)" << endl;
<< totE / GeV << " (GeV)" << G4endl;
}
if(drawFlag)
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: ExN05EventActionMessenger.cc,v 1.1.10.1 1999/12/07 20:47:37 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
// $Id: ExN05EventActionMessenger.cc,v 1.2 1999/12/15 14:49:30 gunter Exp $
// GEANT4 tag $Name: geant4-01-01 $
//
#include "ExN05EventActionMessenger.hh"
@@ -32,7 +32,7 @@ void ExN05EventActionMessenger::SetNewValue(G4UIcommand* command, G4String newVa
{
G4int vl;
const char* t = newValues;
istrstream is((char*)t);
G4std::istrstream is((char*)t);
is >> vl;
EventAction->SetDrawFlag(vl!=0);
}
+3 -3
View File
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: ExN05MaxTimeCuts.cc,v 1.1.10.1 1999/12/07 20:47:37 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
// $Id: ExN05MaxTimeCuts.cc,v 1.2 1999/12/15 14:49:30 gunter Exp $
// GEANT4 tag $Name: geant4-01-01 $
//
//
// --------------------------------------------------------------
@@ -31,7 +31,7 @@ ExN05MaxTimeCuts::ExN05MaxTimeCuts(const G4String& aName)
: ExN05SpecialCuts(aName)
{
if (verboseLevel>1) {
G4cout << GetProcessName() << " is created "<< endl;
G4cout << GetProcessName() << " is created "<< G4endl;
}
SetProcessType(fUserDefined);
}
+3 -3
View File
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: ExN05MinEkineCuts.cc,v 1.1.10.1 1999/12/07 20:47:37 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
// $Id: ExN05MinEkineCuts.cc,v 1.2 1999/12/15 14:49:30 gunter Exp $
// GEANT4 tag $Name: geant4-01-01 $
//
//
// --------------------------------------------------------------
@@ -31,7 +31,7 @@ ExN05MinEkineCuts::ExN05MinEkineCuts(const G4String& aName)
: ExN05SpecialCuts(aName)
{
if (verboseLevel>1) {
G4cout << GetProcessName() << " is created "<< endl;
G4cout << GetProcessName() << " is created "<< G4endl;
}
SetProcessType(fUserDefined);
}
+3 -3
View File
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: ExN05MinRangeCuts.cc,v 1.1.10.1 1999/12/07 20:47:37 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
// $Id: ExN05MinRangeCuts.cc,v 1.2 1999/12/15 14:49:31 gunter Exp $
// GEANT4 tag $Name: geant4-01-01 $
//
//
// --------------------------------------------------------------
@@ -31,7 +31,7 @@ ExN05MinRangeCuts::ExN05MinRangeCuts(const G4String& aName)
: ExN05SpecialCuts(aName)
{
if (verboseLevel>1) {
G4cout << GetProcessName() << " is created "<< endl;
G4cout << GetProcessName() << " is created "<< G4endl;
}
SetProcessType(fUserDefined);
}
+3 -3
View File
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: ExN05PhysicsList.cc,v 1.4.6.1 1999/12/07 20:47:37 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
// $Id: ExN05PhysicsList.cc,v 1.5 1999/12/15 14:49:31 gunter Exp $
// GEANT4 tag $Name: geant4-01-01 $
//
//
@@ -22,7 +22,7 @@
#include "G4Material.hh"
#include "G4MaterialTable.hh"
#include "G4ios.hh"
#include <iomanip.h>
#include "g4std/iomanip"
#include "G4FastSimulationManagerProcess.hh"
+8 -8
View File
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: ExN05PiModel.cc,v 1.1.10.1 1999/12/07 20:47:37 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
// $Id: ExN05PiModel.cc,v 1.2 1999/12/15 14:49:31 gunter Exp $
// GEANT4 tag $Name: geant4-01-01 $
//
#include "ExN05PiModel.hh"
@@ -38,10 +38,10 @@ G4bool ExN05PiModel::ModelTrigger(const G4FastTrack& fastTrack) {
// are available at this level via the fastTrack parameter (allowing
// to check distance from boundaries, see below to allow the decision)
//--------------------------------------------------------------
G4cout << "\nExN05PiModel::ModelTrigger() called:" << endl;
G4cout << "--------------------------------" << endl;
G4cout << "\nExN05PiModel::ModelTrigger() called:" << G4endl;
G4cout << "--------------------------------" << G4endl;
G4cout << "(particle is a " << fastTrack.GetPrimaryTrack()->
GetDefinition()->GetParticleName() << " )\n" << endl;
GetDefinition()->GetParticleName() << " )\n" << G4endl;
// -- Examples of available informations:
@@ -49,14 +49,14 @@ G4bool ExN05PiModel::ModelTrigger(const G4FastTrack& fastTrack) {
G4cout << " Track position: " <<
fastTrack.GetPrimaryTrack()->GetPosition() << "(global coord.)" <<
fastTrack.GetPrimaryTrackLocalPosition() << "(in envelope coord.)"
<< endl;
<< G4endl;
// -- direction:
G4cout << " Track direction:" <<
fastTrack.GetPrimaryTrack()->GetMomentum().unit() <<
"(global coord.)" <<
fastTrack.GetPrimaryTrackLocalDirection() << "(in envelope coord.)" <<
endl;
G4endl;
return true;
}
@@ -75,7 +75,7 @@ void ExN05PiModel::DoIt(const G4FastTrack& fastTrack,
// The primary track continues along its direction.
// One secondary (a photon) is added:
//------------------------------------------------
G4cout << " Pion `model' applied\n" << endl;
G4cout << " Pion `model' applied\n" << G4endl;
//------------------------------
// Primary:
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: ExN05PionShowerModel.cc,v 1.1.10.1 1999/12/07 20:47:38 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
// $Id: ExN05PionShowerModel.cc,v 1.2 1999/12/15 14:49:31 gunter Exp $
// GEANT4 tag $Name: geant4-01-01 $
//
#include "ExN05PionShowerModel.hh"
#include "ExN05EnergySpot.hh"
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: ExN05PrimaryGeneratorAction.cc,v 1.1.10.1 1999/12/07 20:47:38 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
// $Id: ExN05PrimaryGeneratorAction.cc,v 1.2 1999/12/15 14:49:31 gunter Exp $
// GEANT4 tag $Name: geant4-01-01 $
//
#include "ExN05PrimaryGeneratorAction.hh"
+8 -6
View File
@@ -5,12 +5,14 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: ExN05RunAction.cc,v 1.3.8.1 1999/12/07 20:47:38 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
// $Id: ExN05RunAction.cc,v 1.5 2000/01/06 15:06:51 gcosmo Exp $
// GEANT4 tag $Name: geant4-01-01 $
//
#include "ExN05RunAction.hh"
// Make this appear first!
#include "G4Timer.hh"
#include "ExN05RunAction.hh"
#include "G4Run.hh"
#include "G4UImanager.hh"
#include "G4ios.hh"
@@ -27,14 +29,14 @@ ExN05RunAction::~ExN05RunAction()
void ExN05RunAction::BeginOfRunAction(const G4Run* aRun)
{
G4cout << "### Run " << aRun->GetRunID() << " start." << endl;
G4cout << "### Run " << aRun->GetRunID() << " start." << G4endl;
// timer->Start();
}
void ExN05RunAction::EndOfRunAction(const G4Run* aRun)
{
timer->Stop();
G4cout << "number of event = " << aRun->GetNumberOfEvent() << endl;
// << " " << *timer << endl;
G4cout << "number of event = " << aRun->GetNumberOfEvent() << G4endl;
// << " " << *timer << G4endl;
}
+3 -3
View File
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: ExN05SpecialCuts.cc,v 1.2.8.1 1999/12/07 20:47:38 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
// $Id: ExN05SpecialCuts.cc,v 1.3 1999/12/15 14:49:31 gunter Exp $
// GEANT4 tag $Name: geant4-01-01 $
//
//
// ------------------------------------------------------------
@@ -27,7 +27,7 @@ ExN05SpecialCuts::ExN05SpecialCuts(const G4String& aName)
: G4VProcess(aName)
{
if (verboseLevel>1) {
G4cout << GetProcessName() << " is created "<< endl;
G4cout << GetProcessName() << " is created "<< G4endl;
}
}
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: ExN05SteppingAction.cc,v 1.2.8.1 1999/12/07 20:47:38 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
// $Id: ExN05SteppingAction.cc,v 1.3 1999/12/15 14:49:31 gunter Exp $
// GEANT4 tag $Name: geant4-01-01 $
//
#include "ExN05SteppingAction.hh"
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: ExN05SteppingActionMessenger.cc,v 1.1.10.1 1999/12/07 20:47:38 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
// $Id: ExN05SteppingActionMessenger.cc,v 1.2 1999/12/15 14:49:31 gunter Exp $
// GEANT4 tag $Name: geant4-01-01 $
//
#include "ExN05SteppingActionMessenger.hh"
@@ -34,7 +34,7 @@ void ExN05SteppingActionMessenger::SetNewValue(G4UIcommand* command, G4String ne
{
G4int vl;
const char* t = newValues;
istrstream is((char*)t);
G4std::istrstream is((char*)t);
is >> vl;
SteppingAction->SetDrawFlag(vl!=0);
}