Import Geant4 4.0.0 source tree

This commit is contained in:
Gabriele Cosmo
2016-06-08 16:18:25 +02:00
parent 36c080dca6
commit 921d3b1cda
3990 changed files with 185376 additions and 82884 deletions
+13 -1
View File
@@ -1,4 +1,4 @@
$Id: History,v 1.12 2001/04/03 15:26:42 japost Exp $
$Id: History,v 1.14 2001/10/26 15:27:06 mverderi Exp $
-------------------------------------------------------------------
=========================================================
@@ -16,6 +16,18 @@ committal in the CVS repository !
----------------------------------------------------------
* Reverse chronological order (last date on top), please *
----------------------------------------------------------
Oct 26, 2001 M. Verderi - param-V03-02-00
Fixes to clear warnings produced with gcc-2.95.2:
- loop index, where comparison with method "size()" of
G4std::vector<T>, changed: int -> size_t
- change "if ( a=b ) {..}" by "if ( (a=b) ) {...}"
this makes the compiler sure you want to make an
assignement in the "if" condition
- re-order initialisations of a few variables in constructors
to match the declaration order.
Some warnings still exist, but regard the G4Propagator of geometry.
Apr 3, 2001 J. Apostolakis - param-V03-00-00
- Modified G4FastSimulationManagerProcess call to PropagatorInField ComputeStep
to use new interface with G4FieldTrack (in place of now obsolete interface.)
@@ -21,8 +21,8 @@
// ********************************************************************
//
//
// $Id: G4FastSimulationManager.hh,v 1.6.4.1 2001/06/28 19:15:11 gunter Exp $
// GEANT4 tag $Name: $
// $Id: G4FastSimulationManager.hh,v 1.7 2001/07/11 10:08:23 gunter Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//---------------------------------------------------------------
@@ -21,8 +21,8 @@
// ********************************************************************
//
//
// $Id: G4FastSimulationManagerProcess.hh,v 1.7.4.1 2001/06/28 19:15:11 gunter Exp $
// GEANT4 tag $Name: $
// $Id: G4FastSimulationManagerProcess.hh,v 1.8 2001/07/11 10:08:23 gunter Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//---------------------------------------------------------------
@@ -21,8 +21,8 @@
// ********************************************************************
//
//
// $Id: G4FastSimulationMessenger.hh,v 1.3.4.1 2001/06/28 19:15:11 gunter Exp $
// GEANT4 tag $Name: $
// $Id: G4FastSimulationMessenger.hh,v 1.4 2001/07/11 10:08:23 gunter Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
// GEANT 4 class header file
@@ -21,8 +21,8 @@
// ********************************************************************
//
//
// $Id: G4FastStep.hh,v 1.5.4.1 2001/06/28 19:15:11 gunter Exp $
// GEANT4 tag $Name: $
// $Id: G4FastStep.hh,v 1.6 2001/07/11 10:08:23 gunter Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//---------------------------------------------------------------
@@ -21,8 +21,8 @@
// ********************************************************************
//
//
// $Id: G4FastStep.icc,v 1.2.4.1 2001/06/28 19:15:11 gunter Exp $
// GEANT4 tag $Name: $
// $Id: G4FastStep.icc,v 1.3 2001/07/11 10:08:24 gunter Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
// $id: G4ParticleChange.icc,v 1.6 1998/04/14 02:25:54 kurasige Exp $
@@ -21,8 +21,8 @@
// ********************************************************************
//
//
// $Id: G4FastTrack.hh,v 1.4.4.1 2001/06/28 19:15:11 gunter Exp $
// GEANT4 tag $Name: $
// $Id: G4FastTrack.hh,v 1.5 2001/07/11 10:08:24 gunter Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
// $Id:
//---------------------------------------------------------------
@@ -21,8 +21,8 @@
// ********************************************************************
//
//
// $Id: G4FlavoredParallelWorld.hh,v 1.4.4.1 2001/06/28 19:15:11 gunter Exp $
// GEANT4 tag $Name: $
// $Id: G4FlavoredParallelWorld.hh,v 1.5 2001/07/11 10:08:24 gunter Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//---------------------------------------------------------------
@@ -21,8 +21,8 @@
// ********************************************************************
//
//
// $Id: G4GlobalFastSimulationManager.hh,v 1.7.4.1 2001/06/28 19:15:12 gunter Exp $
// GEANT4 tag $Name: $
// $Id: G4GlobalFastSimulationManager.hh,v 1.8 2001/07/11 10:08:24 gunter Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//---------------------------------------------------------------
@@ -21,8 +21,8 @@
// ********************************************************************
//
//
// $Id: G4VFastSimulationModel.hh,v 1.3.4.1 2001/06/28 19:15:12 gunter Exp $
// GEANT4 tag $Name: $
// $Id: G4VFastSimulationModel.hh,v 1.4 2001/07/11 10:08:24 gunter Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//---------------------------------------------------------------
@@ -21,8 +21,8 @@
// ********************************************************************
//
//
// $Id: G4FastSimulationManager.cc,v 1.4.4.1 2001/06/28 19:15:12 gunter Exp $
// GEANT4 tag $Name: $
// $Id: G4FastSimulationManager.cc,v 1.6 2001/10/26 14:43:36 mverderi Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//---------------------------------------------------------------
//
@@ -82,7 +82,7 @@ G4FastSimulationManager::~G4FastSimulationManager()
G4bool
G4FastSimulationManager::ActivateFastSimulationModel(const G4String& aName)
{
G4int iModel;
size_t iModel;
// If the model is already active, do nothing.
for (iModel=0; iModel<ModelList.size(); iModel++)
@@ -107,7 +107,7 @@ G4FastSimulationManager::InActivateFastSimulationModel(const G4String& aName)
{
// Look for in the ModelList, if found remove from it and keep the pointer
// on the fInactivatedModels list.
for (G4int iModel=0; iModel<ModelList.size(); iModel++)
for (size_t iModel=0; iModel<ModelList.size(); iModel++)
if(ModelList[iModel]->GetName() == aName) {
fInactivatedModels.
push_back (ModelList.removeAt(iModel));
@@ -181,7 +181,7 @@ G4FastSimulationManager::
PostStepGetFastSimulationManagerTrigger(const G4Track& track,
const G4Navigator* theNavigator)
{
G4int iModel;
size_t iModel;
// If particle type changed re-build the fApplicableModelList.
if(fLastCrossedParticle!=track.GetDefinition()) {
@@ -246,7 +246,7 @@ G4bool
G4FastSimulationManager::AtRestGetFastSimulationManagerTrigger(const G4Track& track,
const G4Navigator* theNavigator)
{
G4int iModel;
size_t iModel;
// If particle type changed re-build the fApplicableModelList.
if(fLastCrossedParticle!=track.GetDefinition()) {
@@ -301,10 +301,10 @@ InsertGhostHereIfNecessary(G4VPhysicalVolume* theClone,
// If there are, verifies if at least one model is applicable
// for theParticle.
for (G4int iModel=0; iModel<ModelList.size(); iModel++)
for (size_t iModel=0; iModel<ModelList.size(); iModel++)
if(ModelList[iModel]->IsApplicable(theParticle)) {
// Ok, we find one. Place the ghost(s).
for (G4int ighost=0; ighost<GhostPlacements.size(); ighost++)
for (size_t ighost=0; ighost<GhostPlacements.size(); ighost++)
GhostPhysical=new
G4PVPlacement(*(GhostPlacements[ighost]),
fFastTrack.GetEnvelope()->GetName(),
@@ -328,7 +328,7 @@ G4FastSimulationManager::ListTitle() const
void
G4FastSimulationManager::ListModels() const
{
G4int iModel;
size_t iModel;
G4cout << "Current Models for the ";
ListTitle();
@@ -345,7 +345,7 @@ G4FastSimulationManager::ListModels() const
void
G4FastSimulationManager::ListModels(const G4String& aName) const
{
G4int iModel;
size_t iModel;
G4int titled = 0;
G4ParticleTable* theParticleTable=
G4ParticleTable::GetParticleTable();
@@ -404,7 +404,7 @@ G4FastSimulationManager::ListModels(const G4String& aName) const
void
G4FastSimulationManager::ListModels(const G4ParticleDefinition* aPD) const
{
G4int iModel;
size_t iModel;
G4bool unique=true;
// Active Models
@@ -21,8 +21,8 @@
// ********************************************************************
//
//
// $Id: G4FastSimulationManagerProcess.cc,v 1.5.2.1 2001/06/28 19:15:12 gunter Exp $
// GEANT4 tag $Name: $
// $Id: G4FastSimulationManagerProcess.cc,v 1.7 2001/10/26 14:43:36 mverderi Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//---------------------------------------------------------------
@@ -156,8 +156,8 @@ G4FastSimulationManagerProcess::PostStepGetPhysicalInteractionLength(
//---------------------------------------------
// Normal Dispatcher (for tracking geometry) :
//---------------------------------------------
if(fFastSimulationManager =
track.GetVolume()->GetLogicalVolume()->GetFastSimulationManager())
if( (fFastSimulationManager =
track.GetVolume()->GetLogicalVolume()->GetFastSimulationManager()) )
{
// Yes, so should us trigger a fast simulation model now ?
if(fFastSimulationTrigger =
@@ -216,8 +216,8 @@ G4FastSimulationManagerProcess::PostStepGetPhysicalInteractionLength(
if (!fOutOfGhostWorld)
{
if(fFastSimulationManager =
fGhostTouchable->GetVolume()->GetLogicalVolume()->GetFastSimulationManager())
if( (fFastSimulationManager =
fGhostTouchable->GetVolume()->GetLogicalVolume()->GetFastSimulationManager()) )
{
// Yes, so should us trigger a fast simulation model now ?
if(fFastSimulationTrigger =
@@ -295,11 +295,11 @@ G4VParticleChange* G4FastSimulationManagerProcess::PostStepDoIt(
track.GetPosition(),
track.GetMomentumDirection(),
&fTrackingHistory);
G4VPhysicalVolume* trackingVolume = fTrackingHistory.GetVolume();
// G4VPhysicalVolume* trackingVolume = fTrackingHistory.GetVolume();
G4double trackingSafety(0.0);
G4double trackingLinearDistance =
fTrackingNavigator.ComputeStep(
// G4double trackingLinearDistance =
fTrackingNavigator.ComputeStep(
track.GetPosition(),
track.GetMomentumDirection(),
DBL_MAX,
@@ -489,8 +489,8 @@ G4FastSimulationManagerProcess::AtRestGetPhysicalInteractionLength(
if (!fOutOfGhostWorld)
{
if(fFastSimulationManager =
fGhostTouchable->GetVolume()->GetLogicalVolume()->GetFastSimulationManager())
if( (fFastSimulationManager =
fGhostTouchable->GetVolume()->GetLogicalVolume()->GetFastSimulationManager()) )
{
// Should it trigger a fast simulation model now ?
if(fFastSimulationTrigger =
@@ -21,8 +21,8 @@
// ********************************************************************
//
//
// $Id: G4FastSimulationMessenger.cc,v 1.3.4.1 2001/06/28 19:15:13 gunter Exp $
// GEANT4 tag $Name: $
// $Id: G4FastSimulationMessenger.cc,v 1.4 2001/07/11 10:08:24 gunter Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
#include "G4FastSimulationMessenger.hh"
@@ -21,8 +21,8 @@
// ********************************************************************
//
//
// $Id: G4FastStep.cc,v 1.7.4.1 2001/06/28 19:15:13 gunter Exp $
// GEANT4 tag $Name: $
// $Id: G4FastStep.cc,v 1.9 2001/10/26 14:43:36 mverderi Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//---------------------------------------------------------------
//
@@ -320,10 +320,10 @@ G4Step* G4FastStep::UpdateStepForPostStep(G4Step* pStep)
// pointer to G4ParticleMometum. Also it is a normalized
// momentum vector.
G4StepPoint* pPreStepPoint = pStep->GetPreStepPoint();
// G4StepPoint* pPreStepPoint = pStep->GetPreStepPoint();
G4StepPoint* pPostStepPoint = pStep->GetPostStepPoint();
G4Track* aTrack = pStep->GetTrack();
G4double mass = aTrack->GetDynamicParticle()->GetMass();
// G4double mass = aTrack->GetDynamicParticle()->GetMass();
// update kinetic energy and momentum direction
pPostStepPoint->SetMomentumDirection(theMomentumChange);
@@ -353,10 +353,10 @@ G4Step* G4FastStep::UpdateStepForAtRest(G4Step* pStep)
{
// A physics process always calculates the final state of the particle
G4StepPoint* pPreStepPoint = pStep->GetPreStepPoint();
// G4StepPoint* pPreStepPoint = pStep->GetPreStepPoint();
G4StepPoint* pPostStepPoint = pStep->GetPostStepPoint();
G4Track* aTrack = pStep->GetTrack();
G4double mass = aTrack->GetDynamicParticle()->GetMass();
// G4double mass = aTrack->GetDynamicParticle()->GetMass();
// update kinetic energy and momentum direction
pPostStepPoint->SetMomentumDirection(theMomentumChange);
@@ -21,8 +21,8 @@
// ********************************************************************
//
//
// $Id: G4FastTrack.cc,v 1.4.4.1 2001/06/28 19:15:13 gunter Exp $
// GEANT4 tag $Name: $
// $Id: G4FastTrack.cc,v 1.6 2001/10/26 14:43:37 mverderi Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//---------------------------------------------------------------
//
@@ -47,8 +47,8 @@
//
G4FastTrack::G4FastTrack(G4Envelope *anEnvelope,
G4bool IsUnique) :
fEnvelope(anEnvelope),fEnvelopeSolid(fEnvelope->GetSolid()),
fIsUnique(IsUnique), fAffineTransformationDefined(false)
fAffineTransformationDefined(false), fEnvelope(anEnvelope),
fIsUnique(IsUnique), fEnvelopeSolid(fEnvelope->GetSolid())
{}
// -----------
@@ -21,8 +21,8 @@
// ********************************************************************
//
//
// $Id: G4GlobalFastSimulationManager.cc,v 1.6.4.1 2001/06/28 19:15:13 gunter Exp $
// GEANT4 tag $Name: $
// $Id: G4GlobalFastSimulationManager.cc,v 1.8 2001/10/26 14:43:37 mverderi Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//---------------------------------------------------------------
@@ -118,7 +118,7 @@ void G4GlobalFastSimulationManager::CloseFastSimulation()
G4cout << "Closing FastSimulation\n";
for (G4int iParticle=0; iParticle<theParticleTable->entries(); iParticle++) {
G4bool Needed = false;
for (G4int ifsm=0; ifsm<ManagedManagers.size(); ifsm++)
for (size_t ifsm=0; ifsm<ManagedManagers.size(); ifsm++)
Needed = Needed || ManagedManagers[ifsm]->
InsertGhostHereIfNecessary(aClone,
*(theParticleTable->
@@ -140,7 +140,7 @@ G4VFlavoredParallelWorld*
G4GlobalFastSimulationManager::
GetFlavoredWorldForThis(G4ParticleDefinition* particle)
{
for (G4int ipw=0; ipw<NeededFlavoredWorlds.size(); ipw++)
for (size_t ipw=0; ipw<NeededFlavoredWorlds.size(); ipw++)
if(NeededFlavoredWorlds[ipw]->GetTheParticleType()==particle)
return NeededFlavoredWorlds[ipw];
return 0;
@@ -150,7 +150,7 @@ void
G4GlobalFastSimulationManager::ActivateFastSimulationModel(const G4String& aName)
{
G4bool result = false;
for (G4int ifsm=0; ifsm<ManagedManagers.size(); ifsm++)
for (size_t ifsm=0; ifsm<ManagedManagers.size(); ifsm++)
result = result || ManagedManagers[ifsm]->ActivateFastSimulationModel(aName);
if(result)
G4cout << "Model " << aName << " activated.";
@@ -163,7 +163,7 @@ void
G4GlobalFastSimulationManager::InActivateFastSimulationModel(const G4String& aName)
{
G4bool result = false;
for (G4int ifsm=0; ifsm<ManagedManagers.size(); ifsm++)
for (size_t ifsm=0; ifsm<ManagedManagers.size(); ifsm++)
result = result || ManagedManagers[ifsm]->InActivateFastSimulationModel(aName);
if(result)
G4cout << "Model " << aName << " inactivated.";
@@ -177,14 +177,14 @@ G4GlobalFastSimulationManager::ListEnvelopes(const G4String& aName,
listType theType)
{
if(theType == ISAPPLICABLE) {
for (G4int ifsm=0; ifsm<ManagedManagers.size(); ifsm++)
for (size_t ifsm=0; ifsm<ManagedManagers.size(); ifsm++)
ManagedManagers[ifsm]->ListModels(aName);
return;
}
if(aName == "all") {
G4int titled = 0;
for (G4int ifsm=0; ifsm<ManagedManagers.size(); ifsm++) {
for (size_t ifsm=0; ifsm<ManagedManagers.size(); ifsm++) {
if(theType == NAMES_ONLY) {
if(!(titled++))
G4cout << "Current Envelopes for Fast Simulation:\n";
@@ -196,7 +196,7 @@ G4GlobalFastSimulationManager::ListEnvelopes(const G4String& aName,
}
}
else {
for (G4int ifsm=0; ifsm<ManagedManagers.size(); ifsm++)
for (size_t ifsm=0; ifsm<ManagedManagers.size(); ifsm++)
if(aName == ManagedManagers[ifsm]->
GetEnvelope()->GetName()){
ManagedManagers[ifsm]->ListModels();
@@ -208,7 +208,7 @@ G4GlobalFastSimulationManager::ListEnvelopes(const G4String& aName,
void
G4GlobalFastSimulationManager::ListEnvelopes(const G4ParticleDefinition* aPD)
{
for (G4int ifsm=0; ifsm<ManagedManagers.size(); ifsm++)
for (size_t ifsm=0; ifsm<ManagedManagers.size(); ifsm++)
ManagedManagers[ifsm]->ListModels(aPD);
}
@@ -21,8 +21,8 @@
// ********************************************************************
//
//
// $Id: G4VFastSimulationModel.cc,v 1.4.4.1 2001/06/28 19:15:13 gunter Exp $
// GEANT4 tag $Name: $
// $Id: G4VFastSimulationModel.cc,v 1.5 2001/07/11 10:08:25 gunter Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//---------------------------------------------------------------
//