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
+2 -2
View File
@@ -21,8 +21,8 @@
// ********************************************************************
//
//
// $Id: exampleN01.cc,v 1.2.4.2 2001/06/28 20:18:47 gunter Exp $
// GEANT4 tag $Name: $
// $Id: exampleN01.cc,v 1.3 2001/07/11 09:58:16 gunter Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
// --------------------------------------------------------------
+3 -3
View File
@@ -1,6 +1,6 @@
**********************************************
Geant4 version $Name: geant4-03-01-ref-01 $
(06-Apr-2001)
Geant4 version $Name: geant4-04-00 $
(14-Dec-2001)
Copyright : Geant4 Collaboration
**********************************************
Start Run processing.
@@ -193,5 +193,5 @@ Terminate current event processing.
Run terminated.
Run Summary
Number of events processed : 3
User=0.04s Real=0.06s Sys=0s
User=0.02s Real=0.06s Sys=0.04s
G4 kernel has come to Quit state.
@@ -21,13 +21,14 @@
// ********************************************************************
//
//
// $Id: ExN01DetectorConstruction.hh,v 1.2.4.1 2001/06/28 19:07:26 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN01DetectorConstruction.hh,v 1.4 2001/11/05 08:24:50 gcosmo Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
#ifndef ExN01DetectorConstruction_H
#define ExN01DetectorConstruction_H 1
class G4LogicalVolume;
class G4VPhysicalVolume;
#include "G4VUserDetectorConstruction.hh"
@@ -35,12 +36,27 @@ class G4VPhysicalVolume;
class ExN01DetectorConstruction : public G4VUserDetectorConstruction
{
public:
ExN01DetectorConstruction();
~ExN01DetectorConstruction();
public:
G4VPhysicalVolume* Construct();
G4VPhysicalVolume* Construct();
private:
// Logical volumes
//
G4LogicalVolume* experimentalHall_log;
G4LogicalVolume* tracker_log;
G4LogicalVolume* calorimeterBlock_log;
G4LogicalVolume* calorimeterLayer_log;
// Physical volumes
//
G4VPhysicalVolume* experimentalHall_phys;
G4VPhysicalVolume* calorimeterLayer_phys;
G4VPhysicalVolume* calorimeterBlock_phys;
G4VPhysicalVolume* tracker_phys;
};
#endif
@@ -21,8 +21,8 @@
// ********************************************************************
//
//
// $Id: ExN01PhysicsList.hh,v 1.3.4.1 2001/06/28 19:07:26 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN01PhysicsList.hh,v 1.4 2001/07/11 09:58:16 gunter Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//
@@ -21,8 +21,8 @@
// ********************************************************************
//
//
// $Id: ExN01PrimaryGeneratorAction.hh,v 1.2.4.1 2001/06/28 19:07:26 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN01PrimaryGeneratorAction.hh,v 1.3 2001/07/11 09:58:16 gunter Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
#ifndef ExN01PrimaryGeneratorAction_h
@@ -21,8 +21,8 @@
// ********************************************************************
//
//
// $Id: ExN01DetectorConstruction.cc,v 1.2.4.1 2001/06/28 19:07:27 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN01DetectorConstruction.cc,v 1.4 2001/11/05 08:24:50 gcosmo Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
#include "ExN01DetectorConstruction.hh"
@@ -36,10 +36,23 @@
#include "globals.hh"
ExN01DetectorConstruction::ExN01DetectorConstruction()
: experimentalHall_log(0), tracker_log(0),
calorimeterBlock_log(0), calorimeterLayer_log(0),
experimentalHall_phys(0), calorimeterLayer_phys(0),
calorimeterBlock_phys(0), tracker_phys(0)
{;}
ExN01DetectorConstruction::~ExN01DetectorConstruction()
{;}
{
delete calorimeterLayer_log;
delete calorimeterBlock_log;
delete tracker_log;
delete experimentalHall_log;
delete tracker_phys;
delete calorimeterBlock_phys;
delete calorimeterLayer_phys;
delete experimentalHall_phys;
}
G4VPhysicalVolume* ExN01DetectorConstruction::Construct()
{
@@ -73,11 +86,10 @@ G4VPhysicalVolume* ExN01DetectorConstruction::Construct()
G4double expHall_z = 1.0*m;
G4Box* experimentalHall_box
= new G4Box("expHall_box",expHall_x,expHall_y,expHall_z);
G4LogicalVolume* experimentalHall_log
= new G4LogicalVolume(experimentalHall_box,Ar,"expHall_log",0,0,0);
G4VPhysicalVolume* experimentalHall_phys
= new G4PVPlacement(0,G4ThreeVector(),"expHall",
experimentalHall_log,0,false,0);
experimentalHall_log = new G4LogicalVolume(experimentalHall_box,
Ar,"expHall_log",0,0,0);
experimentalHall_phys = new G4PVPlacement(0,G4ThreeVector(),"expHall",
experimentalHall_log,0,false,0);
//------------------------------ a tracker tube
@@ -86,17 +98,14 @@ G4VPhysicalVolume* ExN01DetectorConstruction::Construct()
G4double hightOfTheTube = 50.*cm;
G4double startAngleOfTheTube = 0.*deg;
G4double spanningAngleOfTheTube = 360.*deg;
G4Tubs* tracker_tube
= new G4Tubs("tracker_tube",innerRadiusOfTheTube,
outerRadiusOfTheTube,hightOfTheTube,
startAngleOfTheTube,spanningAngleOfTheTube);
G4LogicalVolume* tracker_log
= new G4LogicalVolume(tracker_tube,Al,"tracker_log",0,0,0);
G4Tubs* tracker_tube = new G4Tubs("tracker_tube",innerRadiusOfTheTube,
outerRadiusOfTheTube,hightOfTheTube,
startAngleOfTheTube,spanningAngleOfTheTube);
tracker_log = new G4LogicalVolume(tracker_tube,Al,"tracker_log",0,0,0);
G4double trackerPos_x = -1.0*m;
G4double trackerPos_y = 0.*m;
G4double trackerPos_z = 0.*m;
G4VPhysicalVolume* tracker_phys
= new G4PVPlacement(0,
tracker_phys = new G4PVPlacement(0,
G4ThreeVector(trackerPos_x,trackerPos_y,trackerPos_z),
tracker_log,"tracker",experimentalHall_log,false,0);
@@ -105,15 +114,14 @@ G4VPhysicalVolume* ExN01DetectorConstruction::Construct()
G4double block_x = 1.0*m;
G4double block_y = 50.0*cm;
G4double block_z = 50.0*cm;
G4Box* calorimeterBlock_box
= new G4Box("calBlock_box",block_x,block_y,block_z);
G4LogicalVolume* calorimeterBlock_log
= new G4LogicalVolume(calorimeterBlock_box,Pb,"caloBlock_log",0,0,0);
G4Box* calorimeterBlock_box = new G4Box("calBlock_box",block_x,
block_y,block_z);
calorimeterBlock_log = new G4LogicalVolume(calorimeterBlock_box,
Pb,"caloBlock_log",0,0,0);
G4double blockPos_x = 1.0*m;
G4double blockPos_y = 0.0*m;
G4double blockPos_z = 0.0*m;
G4VPhysicalVolume* calorimeterBlock_phys
= new G4PVPlacement(0,
calorimeterBlock_phys = new G4PVPlacement(0,
G4ThreeVector(blockPos_x,blockPos_y,blockPos_z),
calorimeterBlock_log,"caloBlock",experimentalHall_log,false,0);
@@ -122,17 +130,16 @@ G4VPhysicalVolume* ExN01DetectorConstruction::Construct()
G4double calo_x = 1.*cm;
G4double calo_y = 40.*cm;
G4double calo_z = 40.*cm;
G4Box* calorimeterLayer_box
= new G4Box("caloLayer_box",calo_x,calo_y,calo_z);
G4LogicalVolume* calorimeterLayer_log
= new G4LogicalVolume(calorimeterLayer_box,Al,"caloLayer_log",0,0,0);
G4Box* calorimeterLayer_box = new G4Box("caloLayer_box",
calo_x,calo_y,calo_z);
calorimeterLayer_log = new G4LogicalVolume(calorimeterLayer_box,
Al,"caloLayer_log",0,0,0);
for(G4int i=0;i<19;i++) // loop for 19 layers
{
G4double caloPos_x = (i-9)*10.*cm;
G4double caloPos_y = 0.0*m;
G4double caloPos_z = 0.0*m;
G4VPhysicalVolume* calorimeterLayer_phys
= new G4PVPlacement(0,
calorimeterLayer_phys = new G4PVPlacement(0,
G4ThreeVector(caloPos_x,caloPos_y,caloPos_z),
calorimeterLayer_log,"caloLayer",calorimeterBlock_log,false,i);
}
+2 -2
View File
@@ -21,8 +21,8 @@
// ********************************************************************
//
//
// $Id: ExN01PhysicsList.cc,v 1.3.4.1 2001/06/28 19:07:27 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN01PhysicsList.cc,v 1.4 2001/07/11 09:58:16 gunter Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
@@ -21,8 +21,8 @@
// ********************************************************************
//
//
// $Id: ExN01PrimaryGeneratorAction.cc,v 1.2.4.1 2001/06/28 19:07:27 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN01PrimaryGeneratorAction.cc,v 1.3 2001/07/11 09:58:16 gunter Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
#include "ExN01PrimaryGeneratorAction.hh"
+24 -1
View File
@@ -1,4 +1,4 @@
$Id: History,v 1.17 2001/02/20 11:57:29 stesting Exp $
$Id: History,v 1.24 2001/11/27 15:52:53 maire Exp $
-------------------------------------------------------------------
=========================================================
@@ -14,6 +14,29 @@ track of all tags.
----------------------------------------------------------
* Reverse chronological order (last date on top), please *
----------------------------------------------------------
27-11-01 mma (exampleN02-V03-02-04)
- vis.mac: /vis/viewer/set/viewpointThetaPhi
19-11-01 John (exampleN02-V03-02-03)
- Updated ExN02VisManager.cc for new graphics systems and defaults.
07-11-01 Satoshi (exampleN02-V03-02-02)
- vis.mac: /vis/viewer/refresh + /vis/viewer/update is replaced
with their equivalent command /vis/viewer/flush.
24-10-01 mma (exampleN02-V03-02-01)
- initInter.mac renamed vis.mac
19-10-01 Steve O'Neale (examples-V03-02-00)
- Update reference output
11-10-01 mma (exampleN02-V03-02-00)
- adapted to new visualisation commands (initInter and EventAction)
- 80 columns max everywhere
12-07-01 mma
- DetectorMessenger: setField, help: magnetic field in X dirction
20-02-01 S.O'Neale (exampleN02-V03-00-03) update reference outputs following
materials-V03-00-04 (tagset 268)
+5 -5
View File
@@ -1,4 +1,4 @@
$Id: README,v 1.4 2000/12/04 16:24:03 maire Exp $
$Id: README,v 1.5 2001/10/24 12:20:42 maire Exp $
-------------------------------------------------------------------
=========================================================
@@ -98,11 +98,11 @@ $Id: README,v 1.4 2000/12/04 16:24:03 maire Exp $
5- VISUALIZATION
The Visualization Manager is set in the main().
The initialisation of the drawing is done via a set of /vis commands
in the macro initInter.mac. This macro is automatically read from
the main in case of interactive running mode.
The initialisation of the drawing is done via a set of /vis/ commands
in the macro vis.mac. This macro is automatically read from
the main when running in interactive mode.
The tracks are automatically drawn at the end of event, and erased at
The tracks are automatically drawn at the end of event and erased at
the beginning of the next run.
The visualization (with OpenGL driver) assumes two things:
+7 -7
View File
@@ -21,12 +21,12 @@
// ********************************************************************
//
//
// $Id: exampleN02.cc,v 1.4.4.1 2001/06/28 19:07:27 gunter Exp $
// GEANT4 tag $Name: $
// $Id: exampleN02.cc,v 1.7 2001/10/24 12:20:42 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#include "ExN02DetectorConstruction.hh"
#include "ExN02PhysicsList.hh"
@@ -45,7 +45,7 @@
#include "ExN02VisManager.hh"
#endif
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
int main(int argc,char** argv) {
@@ -89,7 +89,7 @@ int main(int argc,char** argv) {
session = new G4UIterminal();
#endif
UI->ApplyCommand("/control/execute initInter.mac");
UI->ApplyCommand("/control/execute vis.mac");
session->SessionStart();
delete session;
}
@@ -109,5 +109,5 @@ int main(int argc,char** argv) {
return 0;
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
+1 -1
View File
@@ -1,5 +1,5 @@
**********************************************
Geant4 version $Name: geant4-03-00-ref-03 $
Geant4 version $Name: geant4-04-00 $
(15-Dec-2000)
Copyright : Geant4 Collaboration
**********************************************
File diff suppressed because it is too large Load Diff
@@ -21,16 +21,16 @@
// ********************************************************************
//
//
// $Id: ExN02ChamberParameterisation.hh,v 1.3.4.1 2001/06/28 19:07:27 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN02ChamberParameterisation.hh,v 1.5 2001/10/11 12:32:35 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
// A parameterisation that describes a series of boxes along Z
// The boxes have equal width, & their lengths are a linear equation.
// They are spaced an equal distance apart, starting from given location.
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#ifndef ExN02ChamberParameterisation_H
#define ExN02ChamberParameterisation_H 1
@@ -41,7 +41,7 @@
class G4VPhysicalVolume;
class G4Box;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
class ExN02ChamberParameterisation : public G4VPVParameterisation
{
@@ -53,7 +53,8 @@ class ExN02ChamberParameterisation : public G4VPVParameterisation
G4double widthChamber,
G4double lengthInitial,
G4double lengthFinal );
virtual
~ExN02ChamberParameterisation();
void ComputeTransformation (const G4int copyNo,
@@ -73,6 +74,8 @@ class ExN02ChamberParameterisation : public G4VPVParameterisation
G4double fHalfLengthIncr; // The Increment for the half-length
};
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#endif
@@ -21,11 +21,11 @@
// ********************************************************************
//
//
// $Id: ExN02DetectorConstruction.hh,v 1.3.4.1 2001/06/28 19:07:28 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN02DetectorConstruction.hh,v 1.6 2001/11/05 08:24:50 gcosmo Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#ifndef ExN02DetectorConstruction_h
#define ExN02DetectorConstruction_h 1
@@ -40,7 +40,7 @@ class G4VPhysicalVolume;
class G4Material;
class ExN02DetectorMessenger;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
class ExN02DetectorConstruction : public G4VUserDetectorConstruction
{
@@ -64,28 +64,28 @@ class ExN02DetectorConstruction : public G4VUserDetectorConstruction
void SetMagField(G4double);
private:
G4Box* solidWorld; //pointer to the solid enveloppe
G4LogicalVolume* logicWorld; //pointer to the logical enveloppe
G4VPhysicalVolume* physiWorld; //pointer to the physical enveloppe
G4Box* solidWorld; // pointer to the solid envelope
G4LogicalVolume* logicWorld; // pointer to the logical envelope
G4VPhysicalVolume* physiWorld; // pointer to the physical envelope
G4Box* solidTarget; //pointer to the solid Target
G4LogicalVolume* logicTarget; //pointer to the logical Target
G4VPhysicalVolume* physiTarget; //pointer to the physical Target
G4Box* solidTarget; // pointer to the solid Target
G4LogicalVolume* logicTarget; // pointer to the logical Target
G4VPhysicalVolume* physiTarget; // pointer to the physical Target
G4Box* solidTracker; //pointer to the solid Tracker
G4LogicalVolume* logicTracker; //pointer to the logical Tracker
G4VPhysicalVolume* physiTracker; //pointer to the physical Tracker
G4Box* solidTracker; // pointer to the solid Tracker
G4LogicalVolume* logicTracker; // pointer to the logical Tracker
G4VPhysicalVolume* physiTracker; // pointer to the physical Tracker
G4Box* solidChamber; //pointer to the solid Chamber
G4LogicalVolume* logicChamber; //pointer to the logical Chamber
G4VPhysicalVolume* physiChamber; //pointer to the physical Chamber
G4Box* solidChamber; // pointer to the solid Chamber
G4LogicalVolume* logicChamber; // pointer to the logical Chamber
G4VPhysicalVolume* physiChamber; // pointer to the physical Chamber
G4Material* TargetMater; //pointer to the target material
G4Material* ChamberMater; //pointer to the chamber material
ExN02MagneticField* fpMagField; //pointer to the magnetic field
G4Material* TargetMater; // pointer to the target material
G4Material* ChamberMater; // pointer to the chamber material
ExN02MagneticField* fpMagField; // pointer to the magnetic field
ExN02DetectorMessenger* detectorMessenger; //pointer to the Messenger
ExN02DetectorMessenger* detectorMessenger; // pointer to the Messenger
G4double fWorldLength; // Full length of the world volume
G4double fTargetLength; // Full length of Target
@@ -95,5 +95,6 @@ class ExN02DetectorConstruction : public G4VUserDetectorConstruction
G4double ChamberSpacing; // distance between chambers
};
#endif
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#endif
@@ -21,11 +21,11 @@
// ********************************************************************
//
//
// $Id: ExN02DetectorMessenger.hh,v 1.3.4.1 2001/06/28 19:07:28 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN02DetectorMessenger.hh,v 1.5 2001/10/11 12:32:35 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#ifndef ExN02DetectorMessenger_h
#define ExN02DetectorMessenger_h 1
@@ -38,7 +38,7 @@ class G4UIdirectory;
class G4UIcmdWithAString;
class G4UIcmdWithADoubleAndUnit;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
class ExN02DetectorMessenger: public G4UImessenger
{
@@ -57,5 +57,7 @@ class ExN02DetectorMessenger: public G4UImessenger
G4UIcmdWithADoubleAndUnit* FieldCmd;
};
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#endif
@@ -21,11 +21,11 @@
// ********************************************************************
//
//
// $Id: ExN02EventAction.hh,v 1.4.4.1 2001/06/28 19:07:28 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN02EventAction.hh,v 1.6 2001/10/11 12:32:35 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#ifndef ExN02EventAction_h
#define ExN02EventAction_h 1
@@ -34,7 +34,7 @@
class G4Event;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
class ExN02EventAction : public G4UserEventAction
{
@@ -47,6 +47,8 @@ class ExN02EventAction : public G4UserEventAction
void EndOfEventAction(const G4Event*);
};
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#endif
@@ -21,15 +21,15 @@
// ********************************************************************
//
//
// $Id: ExN02MagneticField.hh,v 1.3.4.1 2001/06/28 19:07:28 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN02MagneticField.hh,v 1.5 2001/10/11 12:32:35 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
// A class for control of the Magnetic Field of the detector.
// The field is assumed to be uniform.
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#ifndef ExN02MagneticField_H
#define ExN02MagneticField_H
@@ -38,7 +38,7 @@
class G4FieldManager;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
class ExN02MagneticField: public G4UniformMagField
@@ -61,4 +61,6 @@ class ExN02MagneticField: public G4UniformMagField
G4FieldManager* GetGlobalFieldManager(); // static
};
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#endif
@@ -21,11 +21,11 @@
// ********************************************************************
//
//
// $Id: ExN02PhysicsList.hh,v 1.7.4.1 2001/06/28 19:07:28 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN02PhysicsList.hh,v 1.9 2001/10/11 12:32:35 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#ifndef ExN02PhysicsList_h
#define ExN02PhysicsList_h 1
@@ -33,7 +33,7 @@
#include "G4VUserPhysicsList.hh"
#include "globals.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
class ExN02PhysicsList: public G4VUserPhysicsList
{
@@ -62,6 +62,8 @@ class ExN02PhysicsList: public G4VUserPhysicsList
void ConstructEM();
};
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#endif
@@ -21,11 +21,11 @@
// ********************************************************************
//
//
// $Id: ExN02PrimaryGeneratorAction.hh,v 1.3.4.1 2001/06/28 19:07:28 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN02PrimaryGeneratorAction.hh,v 1.5 2001/10/11 12:32:35 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#ifndef ExN02PrimaryGeneratorAction_h
#define ExN02PrimaryGeneratorAction_h 1
@@ -36,7 +36,7 @@ class ExN02DetectorConstruction;
class G4ParticleGun;
class G4Event;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
class ExN02PrimaryGeneratorAction : public G4VUserPrimaryGeneratorAction
{
@@ -52,6 +52,8 @@ class ExN02PrimaryGeneratorAction : public G4VUserPrimaryGeneratorAction
ExN02DetectorConstruction* myDetector;
};
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#endif
@@ -21,11 +21,11 @@
// ********************************************************************
//
//
// $Id: ExN02RunAction.hh,v 1.4.4.1 2001/06/28 19:07:28 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN02RunAction.hh,v 1.6 2001/10/11 12:32:36 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#ifndef ExN02RunAction_h
#define ExN02RunAction_h 1
@@ -33,7 +33,7 @@
#include "G4UserRunAction.hh"
#include "globals.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
class G4Run;
@@ -48,6 +48,8 @@ class ExN02RunAction : public G4UserRunAction
void EndOfRunAction(const G4Run*);
};
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#endif
@@ -21,18 +21,18 @@
// ********************************************************************
//
//
// $Id: ExN02SteppingAction.hh,v 1.4.4.1 2001/06/28 19:07:29 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN02SteppingAction.hh,v 1.6 2001/10/11 12:32:36 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#ifndef ExN02SteppingAction_h
#define ExN02SteppingAction_h 1
#include "G4UserSteppingAction.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
class ExN02SteppingAction : public G4UserSteppingAction
{
@@ -43,4 +43,6 @@ class ExN02SteppingAction : public G4UserSteppingAction
void UserSteppingAction(const G4Step*);
};
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#endif
@@ -21,15 +21,15 @@
// ********************************************************************
//
//
// $Id: ExN02SteppingVerbose.hh,v 1.4.4.1 2001/06/28 19:07:29 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN02SteppingVerbose.hh,v 1.6 2001/10/11 12:32:36 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
// This class manages the verbose outputs in G4SteppingManager.
// It inherits from G4SteppingVerbose.
// It shows how to extract informations during the tracking of a particle.
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
class ExN02SteppingVerbose;
@@ -38,11 +38,11 @@ class ExN02SteppingVerbose;
#include "G4SteppingVerbose.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
class ExN02SteppingVerbose : public G4SteppingVerbose {
public:
class ExN02SteppingVerbose : public G4SteppingVerbose
{
public:
ExN02SteppingVerbose();
~ExN02SteppingVerbose();
@@ -52,4 +52,6 @@ public:
};
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#endif
@@ -21,11 +21,11 @@
// ********************************************************************
//
//
// $Id: ExN02TrackerHit.hh,v 1.3.4.1 2001/06/28 19:07:29 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN02TrackerHit.hh,v 1.5 2001/10/11 12:32:36 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#ifndef ExN02TrackerHit_h
#define ExN02TrackerHit_h 1
@@ -35,7 +35,7 @@
#include "G4Allocator.hh"
#include "G4ThreeVector.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
class ExN02TrackerHit : public G4VHit
{
@@ -73,13 +73,13 @@ class ExN02TrackerHit : public G4VHit
G4ThreeVector pos;
};
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
typedef G4THitsCollection<ExN02TrackerHit> ExN02TrackerHitsCollection;
extern G4Allocator<ExN02TrackerHit> ExN02TrackerHitAllocator;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
inline void* ExN02TrackerHit::operator new(size_t)
{
@@ -88,14 +88,14 @@ inline void* ExN02TrackerHit::operator new(size_t)
return aHit;
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
inline void ExN02TrackerHit::operator delete(void *aHit)
{
ExN02TrackerHitAllocator.FreeSingle((ExN02TrackerHit*) aHit);
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#endif
@@ -21,11 +21,11 @@
// ********************************************************************
//
//
// $Id: ExN02TrackerSD.hh,v 1.3.4.1 2001/06/28 19:07:29 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN02TrackerSD.hh,v 1.5 2001/10/11 12:32:36 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#ifndef ExN02TrackerSD_h
#define ExN02TrackerSD_h 1
@@ -36,11 +36,10 @@
class G4Step;
class G4HCofThisEvent;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
class ExN02TrackerSD : public G4VSensitiveDetector
{
public:
ExN02TrackerSD(G4String);
~ExN02TrackerSD();
@@ -54,5 +53,7 @@ class ExN02TrackerSD : public G4VSensitiveDetector
};
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#endif
@@ -21,13 +21,13 @@
// ********************************************************************
//
//
// $Id: ExN02VisManager.hh,v 1.3.4.1 2001/06/28 19:07:30 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN02VisManager.hh,v 1.5 2001/10/11 12:32:36 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
// Example Visualization Manager implementing virtual function
// RegisterGraphicsSystems. Exploits C-pre-processor variables
@@ -42,7 +42,7 @@
// G4VisManager* myVisManager = new MyVisManager;
// myVisManager -> RegisterGraphicsSystem (new MyGraphicsSystem);
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#ifndef ExN02VisManager_h
#define ExN02VisManager_h 1
@@ -51,7 +51,7 @@
#include "G4VisManager.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
class ExN02VisManager: public G4VisManager {
@@ -65,6 +65,8 @@ private:
};
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#endif
#endif
@@ -21,11 +21,11 @@
// ********************************************************************
//
//
// $Id: ExN02ChamberParameterisation.cc,v 1.4.2.1 2001/06/28 19:07:30 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN02ChamberParameterisation.cc,v 1.6 2001/10/11 12:32:36 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#include "ExN02ChamberParameterisation.hh"
@@ -33,7 +33,7 @@
#include "G4ThreeVector.hh"
#include "G4Box.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN02ChamberParameterisation::ExN02ChamberParameterisation(
G4int NoChambers,
@@ -51,20 +51,19 @@ ExN02ChamberParameterisation::ExN02ChamberParameterisation(
// fHalfLengthLast = lengthFinal;
if( NoChambers > 0 ){
fHalfLengthIncr = 0.5 * (lengthFinal-lengthInitial)/NoChambers;
if( spacingZ < widthChamber ) {
G4Exception( "ExN02ChamberParameterisation construction: Width > Spacing" );
if (spacingZ < widthChamber) {
G4Exception("ExN02ChamberParameterisation construction: Width>Spacing");
}
}
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN02ChamberParameterisation::~ExN02ChamberParameterisation()
{}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN02ChamberParameterisation::ComputeTransformation
(const G4int copyNo, G4VPhysicalVolume* physVol) const
@@ -75,7 +74,7 @@ void ExN02ChamberParameterisation::ComputeTransformation
physVol->SetRotation(0);
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN02ChamberParameterisation::ComputeDimensions
(G4Box& trackerChamber, const G4int copyNo,
@@ -87,4 +86,4 @@ void ExN02ChamberParameterisation::ComputeDimensions
trackerChamber.SetZHalfLength(fHalfWidth);
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
@@ -21,11 +21,11 @@
// ********************************************************************
//
//
// $Id: ExN02DetectorConstruction.cc,v 1.6.2.1 2001/06/28 19:07:30 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN02DetectorConstruction.cc,v 1.10 2001/11/05 08:24:50 gcosmo Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#include "ExN02DetectorConstruction.hh"
#include "ExN02DetectorMessenger.hh"
@@ -40,21 +40,21 @@
#include "G4PVParameterised.hh"
#include "G4SDManager.hh"
///#include "G4UserLimits.hh"
#include "G4UserLimits.hh"
#include "G4VisAttributes.hh"
#include "G4Colour.hh"
#include "G4ios.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN02DetectorConstruction::ExN02DetectorConstruction()
:solidWorld(NULL), logicWorld(NULL), physiWorld(NULL),
solidTarget(NULL), logicTarget(NULL), physiTarget(NULL),
solidTracker(NULL),logicTracker(NULL),physiTracker(NULL),
solidChamber(NULL),logicChamber(NULL),physiChamber(NULL),
TargetMater(NULL), ChamberMater(NULL),fpMagField(NULL),
:solidWorld(0), logicWorld(0), physiWorld(0),
solidTarget(0), logicTarget(0), physiTarget(0),
solidTracker(0),logicTracker(0),physiTracker(0),
solidChamber(0),logicChamber(0),physiChamber(0),
TargetMater(0), ChamberMater(0),fpMagField(0),
fWorldLength(0.), fTargetLength(0.), fTrackerLength(0.),
NbOfChambers(0) , ChamberWidth(0.), ChamberSpacing(0.)
{
@@ -62,15 +62,15 @@ ExN02DetectorConstruction::ExN02DetectorConstruction()
detectorMessenger = new ExN02DetectorMessenger(this);
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN02DetectorConstruction::~ExN02DetectorConstruction()
{
{
delete fpMagField;
delete detectorMessenger;
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
G4VPhysicalVolume* ExN02DetectorConstruction::Construct()
{
@@ -91,11 +91,6 @@ G4VPhysicalVolume* ExN02DetectorConstruction::Construct()
Air->AddElement(elN, .7);
Air->AddElement(elO, .3);
//Al
a = 26.98*g/mole;
density = 2.7*g/cm3;
G4Material* Aluminium = new G4Material(name="Al", z=13., a, density);
//Pb
a = 207.19*g/mole;
density = 11.35*g/cm3;
@@ -119,8 +114,8 @@ G4VPhysicalVolume* ExN02DetectorConstruction::Construct()
ChamberWidth = 20*cm;
ChamberSpacing = 80*cm;
fTrackerLength = (NbOfChambers+1)*ChamberSpacing; // Full length of the Tracker
fTargetLength = 5.0 * cm; // Full length of the Target
fTrackerLength = (NbOfChambers+1)*ChamberSpacing; // Full length of Tracker
fTargetLength = 5.0 * cm; // Full length of Target
TargetMater = Pb;
ChamberMater = Xenon;
@@ -138,14 +133,14 @@ G4VPhysicalVolume* ExN02DetectorConstruction::Construct()
G4double HalfWorldLength = 0.5*fWorldLength;
solidWorld= new G4Box("World",HalfWorldLength,HalfWorldLength,HalfWorldLength);
logicWorld= new G4LogicalVolume( solidWorld, Air, "World", 0, 0, 0);
solidWorld= new G4Box("world",HalfWorldLength,HalfWorldLength,HalfWorldLength);
logicWorld= new G4LogicalVolume( solidWorld, Air, "World", 0, 0, 0);
// Must place the World Physical volume unrotated at (0,0,0).
//
physiWorld = new G4PVPlacement(0, // no rotation
G4ThreeVector(), // at (0,0,0)
"WorldPV", // its name
"World", // its name
logicWorld, // its logical volume
0, // its mother volume
false, // no boolean operations
@@ -157,11 +152,11 @@ G4VPhysicalVolume* ExN02DetectorConstruction::Construct()
G4ThreeVector positionTarget = G4ThreeVector(0,0,-(targetSize+trackerSize));
solidTarget = new G4Box("TargetSolid",targetSize,targetSize,targetSize);
logicTarget = new G4LogicalVolume(solidTarget,TargetMater,"TargetLV",0,0,0);
solidTarget = new G4Box("target",targetSize,targetSize,targetSize);
logicTarget = new G4LogicalVolume(solidTarget,TargetMater,"Target",0,0,0);
physiTarget = new G4PVPlacement(0, // no rotation
positionTarget, // at (x,y,z)
"TargetPV", // its name
"Target", // its name
logicTarget, // its logical volume
physiWorld, // its mother volume
false, // no boolean operations
@@ -176,7 +171,7 @@ G4VPhysicalVolume* ExN02DetectorConstruction::Construct()
G4ThreeVector positionTracker = G4ThreeVector(0,0,0);
solidTracker = new G4Box("Tracker",trackerSize,trackerSize,trackerSize);
solidTracker = new G4Box("tracker",trackerSize,trackerSize,trackerSize);
logicTracker = new G4LogicalVolume(solidTracker , Air, "Tracker",0,0,0);
physiTracker = new G4PVPlacement(0, // no rotation
positionTracker, // at (x,y,z)
@@ -246,19 +241,19 @@ G4VPhysicalVolume* ExN02DetectorConstruction::Construct()
//--------- example of User Limits -------------------------------
//below is an example of how to set tracking constraints in a given
//logical volume(see also in N02PhysicsList how to setup the process
//G4UserSpecialCuts).
//set a max Step length in the tracker region
///G4double maxStep = 0.5*ChamberWidth, maxLength = 2*fTrackerLength;
///G4double maxTime = 0.1*ns, minEkin = 10*MeV;
///logicTracker->SetUserLimits(new G4UserLimits(maxStep,maxLength,maxTime,
/// minEkin));
// below is an example of how to set tracking constraints in a given
// logical volume(see also in N02PhysicsList how to setup the process
// G4UserSpecialCuts).
// Sets a max Step length in the tracker region
// G4double maxStep = 0.5*ChamberWidth, maxLength = 2*fTrackerLength;
// G4double maxTime = 0.1*ns, minEkin = 10*MeV;
// logicTracker->SetUserLimits(new G4UserLimits(maxStep,maxLength,maxTime,
// minEkin));
return physiWorld;
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN02DetectorConstruction::setTargetMaterial(G4String materialName)
{
@@ -272,7 +267,7 @@ void ExN02DetectorConstruction::setTargetMaterial(G4String materialName)
}
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN02DetectorConstruction::setChamberMaterial(G4String materialName)
{
@@ -286,11 +281,11 @@ void ExN02DetectorConstruction::setChamberMaterial(G4String materialName)
}
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN02DetectorConstruction::SetMagField(G4double fieldValue)
{
fpMagField->SetFieldValue(fieldValue);
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
@@ -21,11 +21,11 @@
// ********************************************************************
//
//
// $Id: ExN02DetectorMessenger.cc,v 1.3.4.1 2001/06/28 19:07:30 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN02DetectorMessenger.cc,v 1.6 2001/10/11 12:32:37 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#include "ExN02DetectorMessenger.hh"
@@ -35,9 +35,9 @@
#include "G4UIcmdWithADoubleAndUnit.hh"
#include "globals.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN02DetectorMessenger::ExN02DetectorMessenger(ExN02DetectorConstruction * myDet)
ExN02DetectorMessenger::ExN02DetectorMessenger(ExN02DetectorConstruction* myDet)
:myDetector(myDet)
{
@@ -56,14 +56,14 @@ ExN02DetectorMessenger::ExN02DetectorMessenger(ExN02DetectorConstruction * myDet
FieldCmd = new G4UIcmdWithADoubleAndUnit("/mydet/setField",this);
FieldCmd->SetGuidance("Define magnetic field.");
FieldCmd->SetGuidance("Magnetic field will be in Z direction.");
FieldCmd->SetParameterName("Bz",false);
FieldCmd->SetGuidance("Magnetic field will be in X direction.");
FieldCmd->SetParameterName("Bx",false);
FieldCmd->SetDefaultUnit("tesla");
FieldCmd->SetUnitCategory("Magnetic flux density");
FieldCmd->AvailableForStates(PreInit,Idle);
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN02DetectorMessenger::~ExN02DetectorMessenger()
{
@@ -73,18 +73,18 @@ ExN02DetectorMessenger::~ExN02DetectorMessenger()
delete mydetDir;
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN02DetectorMessenger::SetNewValue(G4UIcommand * command,G4String newValues)
void ExN02DetectorMessenger::SetNewValue(G4UIcommand* command,G4String newValue)
{
if( command == TargMatCmd )
{ myDetector->setTargetMaterial(newValues);}
{ myDetector->setTargetMaterial(newValue);}
if( command == ChamMatCmd )
{ myDetector->setChamberMaterial(newValues);}
{ myDetector->setChamberMaterial(newValue);}
if( command == FieldCmd )
{ myDetector->SetMagField(FieldCmd->GetNewDoubleValue(newValues));}
{ myDetector->SetMagField(FieldCmd->GetNewDoubleValue(newValue));}
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
+29 -15
View File
@@ -21,11 +21,11 @@
// ********************************************************************
//
//
// $Id: ExN02EventAction.cc,v 1.5.4.1 2001/06/28 19:07:30 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN02EventAction.cc,v 1.7 2001/10/11 12:32:37 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#include "ExN02EventAction.hh"
@@ -33,40 +33,54 @@
#include "G4EventManager.hh"
#include "G4TrajectoryContainer.hh"
#include "G4Trajectory.hh"
#include "G4VVisManager.hh"
#include "G4ios.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN02EventAction::ExN02EventAction()
{}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN02EventAction::~ExN02EventAction()
{}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN02EventAction::BeginOfEventAction(const G4Event*)
{}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN02EventAction::EndOfEventAction(const G4Event* evt)
{
G4int event_id = evt->GetEventID();
G4TrajectoryContainer * trajectoryContainer = evt->GetTrajectoryContainer();
// get number of stored trajectories
//
G4TrajectoryContainer* trajectoryContainer = evt->GetTrajectoryContainer();
G4int n_trajectories = 0;
if (trajectoryContainer) n_trajectories = trajectoryContainer->entries();
if (event_id < 100 || event_id%100 == 0) {
G4cout << ">>> Event " << evt->GetEventID() << G4endl;
// periodic printing
//
if (event_id < 100 || event_id%100 == 0) {
G4cout << ">>> Event " << evt->GetEventID() << G4endl;
G4cout << " " << n_trajectories
<< " trajectories stored in this event." << G4endl;
}
// extract the trajectories and draw them
//
if (G4VVisManager::GetConcreteInstance())
{
for (G4int i=0; i<n_trajectories; i++)
{ G4Trajectory* trj = (G4Trajectory*)
((*(evt->GetTrajectoryContainer()))[i]);
trj->DrawTrajectory(50);
}
}
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
+12 -11
View File
@@ -21,18 +21,18 @@
// ********************************************************************
//
//
// $Id: ExN02MagneticField.cc,v 1.4.4.1 2001/06/28 19:07:30 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN02MagneticField.cc,v 1.6 2001/10/11 12:32:37 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
// User Field class implementation.
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#include "ExN02MagneticField.hh"
#include "G4FieldManager.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN02MagneticField::ExN02MagneticField()
: G4UniformMagField(G4ThreeVector())
@@ -41,7 +41,7 @@ ExN02MagneticField::ExN02MagneticField()
GetGlobalFieldManager()->CreateChordFinder(this);
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN02MagneticField::ExN02MagneticField(G4ThreeVector fieldVector)
: G4UniformMagField(fieldVector)
@@ -50,7 +50,7 @@ ExN02MagneticField::ExN02MagneticField(G4ThreeVector fieldVector)
GetGlobalFieldManager()->CreateChordFinder(this);
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
// Set the value of the Global Field to fieldValue along X
//
@@ -59,7 +59,7 @@ void ExN02MagneticField::SetFieldValue(G4double fieldValue)
G4UniformMagField::SetFieldValue(G4ThreeVector(fieldValue,0,0));
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
// Set the value of the Global Field
//
@@ -80,14 +80,14 @@ void ExN02MagneticField::SetFieldValue(G4ThreeVector fieldVector)
}
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN02MagneticField::~ExN02MagneticField()
{
// GetGlobalFieldManager()->SetDetectorField(0);
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#include "G4TransportationManager.hh"
@@ -95,4 +95,5 @@ G4FieldManager* ExN02MagneticField::GetGlobalFieldManager()
{
return G4TransportationManager::GetTransportationManager()->GetFieldManager();
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
+18 -18
View File
@@ -21,11 +21,11 @@
// ********************************************************************
//
//
// $Id: ExN02PhysicsList.cc,v 1.9.2.1 2001/06/28 19:07:30 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN02PhysicsList.cc,v 1.12 2001/10/11 12:32:37 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#include "globals.hh"
#include "ExN02PhysicsList.hh"
@@ -40,7 +40,7 @@
#include "G4ios.hh"
#include "g4std/iomanip"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN02PhysicsList::ExN02PhysicsList(): G4VUserPhysicsList()
{
@@ -48,12 +48,12 @@ ExN02PhysicsList::ExN02PhysicsList(): G4VUserPhysicsList()
SetVerboseLevel(1);
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN02PhysicsList::~ExN02PhysicsList()
{}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN02PhysicsList::ConstructParticle()
{
@@ -69,7 +69,7 @@ void ExN02PhysicsList::ConstructParticle()
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN02PhysicsList::ConstructBosons()
{
@@ -81,7 +81,7 @@ void ExN02PhysicsList::ConstructBosons()
G4Gamma::GammaDefinition();
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN02PhysicsList::ConstructLeptons()
{
@@ -100,7 +100,7 @@ void ExN02PhysicsList::ConstructLeptons()
G4AntiNeutrinoMu::AntiNeutrinoMuDefinition();
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN02PhysicsList::ConstructMesons()
{
@@ -119,7 +119,7 @@ void ExN02PhysicsList::ConstructMesons()
G4KaonZeroShort::KaonZeroShortDefinition();
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN02PhysicsList::ConstructBaryons()
{
@@ -131,7 +131,7 @@ void ExN02PhysicsList::ConstructBaryons()
G4AntiNeutron::AntiNeutronDefinition();
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN02PhysicsList::ConstructProcess()
{
@@ -140,7 +140,7 @@ void ExN02PhysicsList::ConstructProcess()
ConstructGeneral();
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#include "G4ComptonScattering.hh"
#include "G4GammaConversion.hh"
@@ -158,9 +158,9 @@ void ExN02PhysicsList::ConstructProcess()
#include "G4hIonisation.hh"
////#include "G4UserSpecialCuts.hh"
#include "G4UserSpecialCuts.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN02PhysicsList::ConstructEM()
{
@@ -274,7 +274,7 @@ void ExN02PhysicsList::ConstructEM()
}
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#include "G4Decay.hh"
void ExN02PhysicsList::ConstructGeneral()
@@ -294,7 +294,7 @@ void ExN02PhysicsList::ConstructGeneral()
}
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN02PhysicsList::SetCuts()
{
@@ -306,5 +306,5 @@ void ExN02PhysicsList::SetCuts()
if (verboseLevel>0) DumpCutValuesTable();
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
@@ -21,11 +21,11 @@
// ********************************************************************
//
//
// $Id: ExN02PrimaryGeneratorAction.cc,v 1.3.4.1 2001/06/28 19:07:31 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN02PrimaryGeneratorAction.cc,v 1.5 2001/10/11 12:32:37 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#include "ExN02PrimaryGeneratorAction.hh"
#include "ExN02DetectorConstruction.hh"
@@ -36,9 +36,10 @@
#include "G4ParticleDefinition.hh"
#include "globals.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN02PrimaryGeneratorAction::ExN02PrimaryGeneratorAction(ExN02DetectorConstruction* myDC)
ExN02PrimaryGeneratorAction::ExN02PrimaryGeneratorAction(
ExN02DetectorConstruction* myDC)
:myDetector(myDC)
{
G4int n_particle = 1;
@@ -54,14 +55,14 @@ ExN02PrimaryGeneratorAction::ExN02PrimaryGeneratorAction(ExN02DetectorConstructi
particleGun->SetParticleEnergy(3.0*GeV);
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN02PrimaryGeneratorAction::~ExN02PrimaryGeneratorAction()
{
delete particleGun;
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN02PrimaryGeneratorAction::GeneratePrimaries(G4Event* anEvent)
{
@@ -71,5 +72,5 @@ void ExN02PrimaryGeneratorAction::GeneratePrimaries(G4Event* anEvent)
particleGun->GeneratePrimaryVertex(anEvent);
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
+13 -15
View File
@@ -21,11 +21,11 @@
// ********************************************************************
//
//
// $Id: ExN02RunAction.cc,v 1.4.4.1 2001/06/28 19:07:31 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN02RunAction.cc,v 1.6 2001/10/11 12:32:37 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#include "ExN02RunAction.hh"
@@ -34,17 +34,17 @@
#include "G4VVisManager.hh"
#include "G4ios.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN02RunAction::ExN02RunAction()
{}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN02RunAction::~ExN02RunAction()
{}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN02RunAction::BeginOfRunAction(const G4Run* aRun)
{
@@ -57,19 +57,17 @@ void ExN02RunAction::BeginOfRunAction(const G4Run* aRun)
}
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN02RunAction::EndOfRunAction(const G4Run*)
{
G4VVisManager* pVVisManager = G4VVisManager::GetConcreteInstance();
if(G4VVisManager::GetConcreteInstance())
{
G4UImanager::GetUIpointer()->ApplyCommand("/vis/viewer/update");
}
if (G4VVisManager::GetConcreteInstance())
{
G4UImanager::GetUIpointer()->ApplyCommand("/vis/viewer/update");
}
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
+8 -10
View File
@@ -21,27 +21,25 @@
// ********************************************************************
//
//
// $Id: ExN02SteppingAction.cc,v 1.4.4.1 2001/06/28 19:07:31 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN02SteppingAction.cc,v 1.7 2001/11/05 08:24:50 gcosmo Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#include "ExN02SteppingAction.hh"
#include "G4SteppingManager.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN02SteppingAction::ExN02SteppingAction()
{ }
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN02SteppingAction::UserSteppingAction(const G4Step* aStep)
void ExN02SteppingAction::UserSteppingAction(const G4Step*)
{
const G4VPhysicalVolume* currentVolume =
aStep->GetPreStepPoint()->GetPhysicalVolume();
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
+27 -27
View File
@@ -21,28 +21,28 @@
// ********************************************************************
//
//
// $Id: ExN02SteppingVerbose.cc,v 1.6.2.1 2001/06/28 19:07:31 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN02SteppingVerbose.cc,v 1.8 2001/10/11 12:32:38 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#include "ExN02SteppingVerbose.hh"
#include "G4SteppingManager.hh"
#include "G4UnitsTable.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN02SteppingVerbose::ExN02SteppingVerbose()
{}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN02SteppingVerbose::~ExN02SteppingVerbose()
{}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN02SteppingVerbose::StepInfo()
{
@@ -66,14 +66,14 @@ void ExN02SteppingVerbose::StepInfo()
<< G4std::setw(10) << "Process" << G4endl;
}
G4cout << G4std::setw( 5) << fTrack->GetCurrentStepNumber() << " "
<< G4std::setw( 6) << G4BestUnit(fTrack->GetPosition().x(),"Length")
<< G4std::setw( 6) << G4BestUnit(fTrack->GetPosition().y(),"Length")
<< G4std::setw( 6) << G4BestUnit(fTrack->GetPosition().z(),"Length")
<< G4std::setw( 6) << G4BestUnit(fTrack->GetKineticEnergy(),"Energy")
<< G4std::setw( 6) << G4BestUnit(fStep->GetTotalEnergyDeposit(),"Energy")
<< G4std::setw( 6) << G4BestUnit(fStep->GetStepLength(),"Length")
<< G4std::setw( 6) << G4BestUnit(fTrack->GetTrackLength(),"Length");
G4cout << G4std::setw(5) << fTrack->GetCurrentStepNumber() << " "
<< G4std::setw(6) << G4BestUnit(fTrack->GetPosition().x(),"Length")
<< G4std::setw(6) << G4BestUnit(fTrack->GetPosition().y(),"Length")
<< G4std::setw(6) << G4BestUnit(fTrack->GetPosition().z(),"Length")
<< G4std::setw(6) << G4BestUnit(fTrack->GetKineticEnergy(),"Energy")
<< G4std::setw(6) << G4BestUnit(fStep->GetTotalEnergyDeposit(),"Energy")
<< G4std::setw(6) << G4BestUnit(fStep->GetStepLength(),"Length")
<< G4std::setw(6) << G4BestUnit(fTrack->GetTrackLength(),"Length");
// if( fStepStatus != fWorldBoundary){
if( fTrack->GetNextVolume() != 0 ) {
@@ -84,7 +84,7 @@ void ExN02SteppingVerbose::StepInfo()
if(fStep->GetPostStepPoint()->GetProcessDefinedStep() != NULL){
G4cout << " "
<< G4std::setw(10) << fStep->GetPostStepPoint()->GetProcessDefinedStep()
<< G4std::setw(10) << fStep->GetPostStepPoint()->GetProcessDefinedStep()
->GetProcessName();
} else {
G4cout << " UserLimit";
@@ -107,7 +107,7 @@ void ExN02SteppingVerbose::StepInfo()
<< " ---------------"
<< G4endl;
for(G4int lp1=(*fSecondary).size()-tN2ndariesTot;
for(size_t lp1=(*fSecondary).size()-tN2ndariesTot;
lp1<(*fSecondary).size(); lp1++){
G4cout << " : "
<< G4std::setw(6)
@@ -134,7 +134,7 @@ void ExN02SteppingVerbose::StepInfo()
G4cout.precision(prec);
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN02SteppingVerbose::TrackingStarted()
{
@@ -154,14 +154,14 @@ G4int prec = G4cout.precision(3);
<< G4std::setw(10) << "Volume" << " "
<< G4std::setw(10) << "Process" << G4endl;
G4cout << G4std::setw( 5) << fTrack->GetCurrentStepNumber() << " "
<< G4std::setw( 6) << G4BestUnit(fTrack->GetPosition().x(),"Length")
<< G4std::setw( 6) << G4BestUnit(fTrack->GetPosition().y(),"Length")
<< G4std::setw( 6) << G4BestUnit(fTrack->GetPosition().z(),"Length")
<< G4std::setw( 6) << G4BestUnit(fTrack->GetKineticEnergy(),"Energy")
<< G4std::setw( 6) << G4BestUnit(fStep->GetTotalEnergyDeposit(),"Energy")
<< G4std::setw( 6) << G4BestUnit(fStep->GetStepLength(),"Length")
<< G4std::setw( 6) << G4BestUnit(fTrack->GetTrackLength(),"Length");
G4cout << G4std::setw(5) << fTrack->GetCurrentStepNumber() << " "
<< G4std::setw(6) << G4BestUnit(fTrack->GetPosition().x(),"Length")
<< G4std::setw(6) << G4BestUnit(fTrack->GetPosition().y(),"Length")
<< G4std::setw(6) << G4BestUnit(fTrack->GetPosition().z(),"Length")
<< G4std::setw(6) << G4BestUnit(fTrack->GetKineticEnergy(),"Energy")
<< G4std::setw(6) << G4BestUnit(fStep->GetTotalEnergyDeposit(),"Energy")
<< G4std::setw(6) << G4BestUnit(fStep->GetStepLength(),"Length")
<< G4std::setw(6) << G4BestUnit(fTrack->GetTrackLength(),"Length");
if(fTrack->GetNextVolume()){
G4cout << G4std::setw(10) << fTrack->GetVolume()->GetName();
@@ -173,4 +173,4 @@ G4int prec = G4cout.precision(3);
G4cout.precision(prec);
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
+12 -12
View File
@@ -21,11 +21,11 @@
// ********************************************************************
//
//
// $Id: ExN02TrackerHit.cc,v 1.4.4.1 2001/06/28 19:07:31 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN02TrackerHit.cc,v 1.6 2001/10/11 12:32:38 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#include "ExN02TrackerHit.hh"
#include "G4UnitsTable.hh"
@@ -36,15 +36,15 @@
G4Allocator<ExN02TrackerHit> ExN02TrackerHitAllocator;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN02TrackerHit::ExN02TrackerHit() {}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN02TrackerHit::~ExN02TrackerHit() {}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN02TrackerHit::ExN02TrackerHit(const ExN02TrackerHit& right)
{
@@ -54,7 +54,7 @@ ExN02TrackerHit::ExN02TrackerHit(const ExN02TrackerHit& right)
pos = right.pos;
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
const ExN02TrackerHit& ExN02TrackerHit::operator=(const ExN02TrackerHit& right)
{
@@ -65,14 +65,14 @@ const ExN02TrackerHit& ExN02TrackerHit::operator=(const ExN02TrackerHit& right)
return *this;
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
int ExN02TrackerHit::operator==(const ExN02TrackerHit& right) const
{
return 0;
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN02TrackerHit::Draw()
{
@@ -89,7 +89,7 @@ void ExN02TrackerHit::Draw()
}
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN02TrackerHit::Print()
{
@@ -98,5 +98,5 @@ void ExN02TrackerHit::Print()
<< " position: " << G4BestUnit(pos,"Length") << G4endl;
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
+12 -11
View File
@@ -21,11 +21,11 @@
// ********************************************************************
//
//
// $Id: ExN02TrackerSD.cc,v 1.3.4.1 2001/06/28 19:07:31 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN02TrackerSD.cc,v 1.5 2001/10/11 12:32:38 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#include "ExN02TrackerSD.hh"
#include "G4HCofThisEvent.hh"
@@ -34,7 +34,7 @@
#include "G4SDManager.hh"
#include "G4ios.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN02TrackerSD::ExN02TrackerSD(G4String name)
:G4VSensitiveDetector(name)
@@ -43,11 +43,11 @@ ExN02TrackerSD::ExN02TrackerSD(G4String name)
collectionName.insert(HCname="trackerCollection");
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN02TrackerSD::~ExN02TrackerSD(){ }
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN02TrackerSD::Initialize(G4HCofThisEvent* HCE)
{
@@ -59,7 +59,7 @@ void ExN02TrackerSD::Initialize(G4HCofThisEvent* HCE)
HCE->AddHitsCollection( HCID, trackerCollection );
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
G4bool ExN02TrackerSD::ProcessHits(G4Step* aStep,G4TouchableHistory* ROhist)
{
@@ -69,7 +69,8 @@ G4bool ExN02TrackerSD::ProcessHits(G4Step* aStep,G4TouchableHistory* ROhist)
ExN02TrackerHit* newHit = new ExN02TrackerHit();
newHit->SetTrackID (aStep->GetTrack()->GetTrackID());
newHit->SetChamberNb(aStep->GetPreStepPoint()->GetTouchable()->GetReplicaNumber());
newHit->SetChamberNb(aStep->GetPreStepPoint()->GetTouchable()
->GetReplicaNumber());
newHit->SetEdep (edep);
newHit->SetPos (aStep->GetPostStepPoint()->GetPosition());
trackerCollection->insert( newHit );
@@ -80,7 +81,7 @@ G4bool ExN02TrackerSD::ProcessHits(G4Step* aStep,G4TouchableHistory* ROhist)
return true;
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN02TrackerSD::EndOfEvent(G4HCofThisEvent* HCE)
{
@@ -92,5 +93,5 @@ void ExN02TrackerSD::EndOfEvent(G4HCofThisEvent* HCE)
}
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
+29 -25
View File
@@ -21,14 +21,14 @@
// ********************************************************************
//
//
// $Id: ExN02VisManager.cc,v 1.3.4.1 2001/06/28 19:07:31 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN02VisManager.cc,v 1.7 2001/11/15 13:09:54 johna Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
// John Allison 24th January 1998.
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#ifdef G4VIS_USE
@@ -36,14 +36,21 @@
// Supported drivers...
// Not needing external packages or libraries...
#include "G4ASCIITree.hh"
#include "G4DAWNFILE.hh"
#include "G4GAGTree.hh"
#include "G4HepRepFile.hh"
#include "G4RayTracer.hh"
#include "G4VRML1File.hh"
#include "G4VRML2File.hh"
// Needing external packages or libraries...
#ifdef G4VIS_USE_DAWN
#include "G4FukuiRenderer.hh"
#endif
#ifdef G4VIS_USE_DAWNFILE
#include "G4DAWNFILE.hh"
#endif
#ifdef G4VIS_USE_OPACS
#include "G4Wo.hh"
#include "G4Xo.hh"
@@ -77,27 +84,29 @@
#include "G4VRML2.hh"
#endif
#ifdef G4VIS_USE_VRMLFILE
#include "G4VRML1File.hh"
#include "G4VRML2File.hh"
#endif
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN02VisManager::ExN02VisManager () {}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN02VisManager::RegisterGraphicsSystems () {
// Graphics Systems not needing external packages or libraries...
RegisterGraphicsSystem (new G4ASCIITree);
RegisterGraphicsSystem (new G4DAWNFILE);
RegisterGraphicsSystem (new G4GAGTree);
RegisterGraphicsSystem (new G4HepRepFile);
RegisterGraphicsSystem (new G4RayTracer);
RegisterGraphicsSystem (new G4VRML1File);
RegisterGraphicsSystem (new G4VRML2File);
// Graphics systems needing external packages or libraries...
#ifdef G4VIS_USE_DAWN
RegisterGraphicsSystem (new G4FukuiRenderer);
#endif
#ifdef G4VIS_USE_DAWNFILE
RegisterGraphicsSystem (new G4DAWNFILE);
#endif
#ifdef G4VIS_USE_OPACS
RegisterGraphicsSystem (new G4Wo);
RegisterGraphicsSystem (new G4Xo);
@@ -131,11 +140,6 @@ void ExN02VisManager::RegisterGraphicsSystems () {
RegisterGraphicsSystem (new G4VRML2);
#endif
#ifdef G4VIS_USE_VRMLFILE
RegisterGraphicsSystem (new G4VRML1File);
RegisterGraphicsSystem (new G4VRML2File);
#endif
if (fVerbose > 0) {
G4cout <<
"\nYou have successfully chosen to use the following graphics systems."
@@ -146,4 +150,4 @@ void ExN02VisManager::RegisterGraphicsSystems () {
#endif
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
@@ -15,15 +15,17 @@
# (Edit the next line(s) to choose another graphic system)
#
/vis/open OGLIX
#/vis/open DAWNFILE
#
####/vis/open DAWNFILE
#
# draw scene
#
/vis/camera/zoom 1.4
/vis/camera/viewpoint 90 180
/vis/drawVolume
/vis/viewer/set/viewpointThetaPhi 90 180 deg
/vis/viewer/zoom 1.4
/vis/viewer/flush
#
# for drawing the tracks
# (if too many tracks cause core dump => storeTrajectory 0)
/tracking/storeTrajectory 1
/vis/scene/add/trajectories
/vis/scene/endOfEventAction accumulate
+42 -1
View File
@@ -1,4 +1,4 @@
$Id: History,v 1.36 2001/06/21 06:28:03 stanaka Exp $
$Id: History,v 1.46 2001/11/27 11:10:31 maire Exp $
--------------------------------------------------
=========================================================
@@ -14,6 +14,47 @@ track of all tags.
----------------------------------------------------------
* Reverse chronological order (last date on top), please *
----------------------------------------------------------
27-11-01 mma (exampleN03-V03-02-07)
- DetectorConstruction: Vacuum is the default material.
- newgeom.mac: a box of 40 cm of water.
19-11-01 John (exampleN03-V03-02-06)
- Updated ExN03VisManager.cc for new graphics systems and defaults.
14-11-01 Satoshi Tanaka (exampleN03-V03-02-05)
- exN03Vis8.mac : Batch visualization with the DAWNFILE driver
- exN03Vis9.mac : Multi-page PostScript file generation (old exN03Vis8.mac)
07-11-01 Satoshi (exampleN03-V03-02-04a)
- /vis/viewer/viewpointThetaPhi ==> /vis/viewer/set/viewpointThetaPhi
07-11-01 Satoshi (exampleN03-V03-02-04)
- visTutor/exN03VisXX.mac's are rewritten with /vis/viewer/flush.
- Some refinements of command sequences and comments.
- Note that /vis/flushAll's are described but commented out.
07-11-01 Satoshi (exampleN03-V03-02-03)
- vis.mac: /vis/viewer/refresh + /vis/viewer/update is replaced
with their equivalent command /vis/viewer/flush.
24-10-01 mma (exampleN03-V03-02-02)
- initInter.mac renamed vis.mac : OpenGL and DAWNFILE opened simultaneously.
19-10-01 Steve O'Neale (examples-V03-02-00)
- Update reference output
10-10-01 mma (exampleN03-V03-02-01)
- /vis/scene/endOfEventAction accumulate
/vis/viewer/zoom (in newgeom.mac)
- 80 columns everywhere
18-09-01 Satoshi Tanaka (exampleN03-V03-02-00)
- Updation for automatic visualization at Hebden Bridge mini-workshop.
- /vis/viewer/flush and /vis/flushAll are not included yet.
(To be included in the next tag.)
- /vis/drawTree may still require /vis/scene/notifyHandlers.
(John Allison will revise the /vis/drawTree command soon.)
21-06-01 Satoshi Tanaka (exampleN03-V03-00-02)
- visTutor/*.mac updated
+5 -5
View File
@@ -1,4 +1,4 @@
$Id: README,v 1.6 2000/11/21 11:43:31 maire Exp $
$Id: README,v 1.8 2001/11/27 11:10:31 maire Exp $
-------------------------------------------------------------------
=========================================================
@@ -58,7 +58,7 @@ $Id: README,v 1.6 2000/11/21 11:43:31 maire Exp $
In this example a CalorHit is defined as a set of 4 informations per
layer :
- the total energy deposit in the absorber plate,
- the total tracklength of all charged particles in the absorber plate,
- the total tracklength of all charged particles in the absorber plate,
- the total energy deposit in the detection gap,
- the total tracklength of all charged particles in the detection gap.
@@ -74,8 +74,8 @@ $Id: README,v 1.6 2000/11/21 11:43:31 maire Exp $
4- VISUALIZATION
The Visualization Manager is set in the main().
The initialisation of the drawing is done via a set of /vis commands
in the macro initInter.mac. This macro is automatically read from
The initialisation of the drawing is done via a set of /vis/ commands
in the macro vis.mac. This macro is automatically read from
the main in case of interactive running mode.
The detector has a default view which is a longitudinal view of the
@@ -83,7 +83,7 @@ $Id: README,v 1.6 2000/11/21 11:43:31 maire Exp $
The tracks are drawn at the end of event, and erased at the end of run.
Optionaly one can choose to draw all particles, only the charged,
or neutral or none. This command is defined in EventActionMessenger class.
or neutral or none. This command is build in EventActionMessenger class.
NB 1: the visualization (with OpenGL driver) assumes two things:
1- the visualisation & interfaces categories have been compiled
+4 -4
View File
@@ -21,8 +21,8 @@
// ********************************************************************
//
//
// $Id: exampleN03.cc,v 1.13.4.2 2001/06/28 20:18:47 gunter Exp $
// GEANT4 tag $Name: $
// $Id: exampleN03.cc,v 1.15 2001/10/24 11:45:06 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
// --------------------------------------------------------------
@@ -109,10 +109,10 @@ int main(int argc,char** argv) {
if (session) // Define UI session for interactive mode.
{
// G4UIterminal is a (dumb) terminal.
UI->ApplyCommand("/control/execute initInter.mac");
UI->ApplyCommand("/control/execute vis.mac");
#ifdef G4UI_USE_XM
// Customize the G4UIXm menubar with a macro file :
UI->ApplyCommand("/control/execute gui.mac");
UI->ApplyCommand("/control/execute visTutor/gui.mac");
#endif
session->SessionStart();
delete session;
+55 -41
View File
@@ -1,10 +1,23 @@
**********************************************
Geant4 version $Name: geant4-03-01-ref-01 $
(06-Apr-2001)
Geant4 version $Name: geant4-04-00 $
(14-Dec-2001)
Copyright : Geant4 Collaboration
**********************************************
Visualization Manager instantiating...
Visualization Manager initialising...
Registering graphics systems...
***** Table : Nb of materials = 13 *****
You have successfully chosen to use the following graphics systems.
Current available graphics systems are:
ASCIITree (ATree)
DAWNFILE (DAWNFILE)
GAGTree (GAGTree)
G4HepRepFile (HepRepFile)
RayTracer (RayTracer)
VRML1FILE (VRML1FILE)
VRML2FILE (VRML2FILE)
***** Table : Nb of materials = 12 *****
Material: Aluminium density: 2.700 g/cm3 temperature: 273.15 K pressure: 1.00 atm RadLength: 8.893 cm
---> Element: Aluminium Z = 13.0 N = 27.0 A = 26.98 g/mole fractionMass: 100.00 % Abundance 100.00 %
@@ -12,9 +25,6 @@
Material: liquidArgon density: 1.390 g/cm3 temperature: 273.15 K pressure: 1.00 atm RadLength: 14.065 cm
---> Element: liquidArgon Z = 18.0 N = 40.0 A = 39.95 g/mole fractionMass: 100.00 % Abundance 100.00 %
Material: Copper density: 8.960 g/cm3 temperature: 273.15 K pressure: 1.00 atm RadLength: 1.436 cm
---> Element: Copper Z = 29.0 N = 63.5 A = 63.55 g/mole fractionMass: 100.00 % Abundance 100.00 %
Material: Lead density: 11.350 g/cm3 temperature: 273.15 K pressure: 1.00 atm RadLength: 5.612 mm
---> Element: Lead Z = 82.0 N = 207.2 A = 207.19 g/mole fractionMass: 100.00 % Abundance 100.00 %
@@ -64,11 +74,11 @@ ExN03PhysicsList::SetCuts:CutLength : 1 mm
conv: Total cross sections from a parametrisation. Good description from 1.5 MeV to 100 GeV for all Z.
e+e- energies according Bethe-Heitler
PhysicsTables from 1 MeV to 1e+02 GeV in 100 bins.
PhysicsTables from 1.022 MeV to 100 GeV in 100 bins.
compt: Total cross sections from a parametrisation. Good description from 10 KeV to (100/Z) GeV.
Scattered gamma energy according Klein-Nishina.
PhysicsTables from 10 keV to 1e+02 GeV in 100 bins.
Scattered gamma energy according Klein-Nishina.
PhysicsTables from 10 keV to 100 GeV in 100 bins.
phot: Total cross sections from a parametrisation. Good description from 10 KeV to 50 MeV for all Z
Sandia crossSection below 50 KeV
@@ -77,56 +87,67 @@ phot: Total cross sections from a parametrisation. Good description from 10 KeV
msc: Tables of transport mean free paths.
New model of MSC , computes the lateral
displacement of the particle , too.
PhysicsTables from 1e+02 eV to 1e+02 TeV in 100 bins.
PhysicsTables from 100 eV to 100 TeV in 100 bins.
eIoni: delta cross sections from Moller+Bhabha. Good description from 1 KeV to 100 GeV.
delta ray energy sampled from differential Xsection.
PhysicsTables from 1 keV to 1e+02 TeV in 100 bins.
PhysicsTables from 1 keV to 100 TeV in 100 bins.
eBrem: Total cross sections from a NEW parametrisation based on the EEDL data library.
Good description from 1 KeV to 100 GeV.
log scale extrapolation above 100 GeV
Gamma energy sampled from a parametrised formula.
PhysicsTables from 1 keV to 1e+02 TeV in 100 bins.
PhysicsTables from 1 keV to 100 TeV in 100 bins.
annihil: Total cross section from Heilter formula (annihilation into 2 photons).
annihil: Total cross section from Heilter formula(annihilation into 2 photons).
gamma energies sampled according Heitler
PhysicsTables from 10 keV to 10 TeV in 100 bins.
hIoni: Knock-on electron cross sections .
Good description above the mean excitation energy.
delta ray energy sampled from differential Xsection.
PhysicsTables from 1 keV to 1e+02 TeV in 100 bins.
PhysicsTables from 1 keV to 100 TeV in 100 bins.
msc: Tables of transport mean free paths.
New model of MSC , computes the lateral
displacement of the particle , too.
PhysicsTables from 1e+02 eV to 1e+02 TeV in 100 bins.
PhysicsTables from 100 eV to 100 TeV in 100 bins.
MuIoni: knock-on electron cross sections .
Good description above the mean excitation energy.
MuIoni: Knock-on electron cross sections .
Good description above the mean excitation energy.
delta ray energy sampled from differential Xsection.
PhysicsTables from 1 keV to 1e+03 PeV in 150 bins.
PhysicsTables from 1 keV to 1000 PeV in 150 bins.
msc: Tables of transport mean free paths.
New model of MSC , computes the lateral
displacement of the particle , too.
PhysicsTables from 1e+02 eV to 1e+02 TeV in 100 bins.
PhysicsTables from 100 eV to 100 TeV in 100 bins.
MuBrems: theoretical cross section
Good description up to 1000 PeV.
PhysicsTables from 1 keV to 1e+03 PeV in 150 bins.
PhysicsTables from 1 keV to 1000 PeV in 150 bins.
MuPairProd: theoretical cross sections
Good description up to 1000 PeV.
PhysicsTables from 1 keV to 1e+03 PeV in 150 bins.
PhysicsTables from 1 keV to 1000 PeV in 150 bins.
============= The cut Energy ==============================
gamma e-
Cut in range 1 mm 1 mm
Cut in range
Aluminium 1 mm 1 mm
liquidArgon 1 mm 1 mm
Lead 1 mm 1 mm
Water 1 mm 1 mm
Scintillator 1 mm 1 mm
quartz 1 mm 1 mm
Air 1 mm 1 mm
Aerogel 1 mm 1 mm
CarbonicGas 1 mm 1 mm
WaterSteam 1 mm 1 mm
Galactic 1 mm 1 mm
Beam 1 mm 1 mm
Cut in energy
Aluminium 6.89 keV 597 keV
liquidArgon 6.18 keV 343 keV
Copper 24.6 keV 1.4 MeV
Lead 101 keV 1.38 MeV
Water 2.9 keV 347 keV
Scintillator 2.37 keV 356 keV
@@ -138,7 +159,6 @@ Cut in energy
Galactic 990 eV 990 eV
Beam 990 eV 990 eV
===================================================
# e+ 300MeV
### Run 0 start.
---> Begin of event: 0
@@ -148,35 +168,27 @@ Cut in energy
Current couple of seeds = 9876, 54321
----------------------------------------
---> End of event: 0
Absorber: total energy: 2.8e+02 MeV total track length: 17 cm
Gap: total energy: 8.2 MeV total track length: 4.1 cm
Absorber: total energy: 269.904 MeV total track length: 19.1751 cm
Gap: total energy: 14.6003 MeV total track length: 7.40188 cm
9 hits are stored in ExN03CalorHitsCollection.
#
# list the existing physics processes
Transportation, hIoni, msc, eIoni
eBrem, annihil, conv, compt
phot, MuIoni, MuBrems, MuPairProd
Decay
#
# switch off MultipleScattering
### Run 1 start.
---> Begin of event: 0
--------- Ranecu engine status ---------
Initial seed (index) = 0
Current couple of seeds = 1007375238, 624422740
Current couple of seeds = 1748430878, 543225391
----------------------------------------
---> End of event: 0
Absorber: total energy: 2.7e+02 MeV total track length: 15 cm
Gap: total energy: 19 MeV total track length: 9.9 cm
Absorber: total energy: 279.35 MeV total track length: 19.6094 cm
Gap: total energy: 15.0617 MeV total track length: 7.74823 cm
10 hits are stored in ExN03CalorHitsCollection.
#
# switch on MultipleScattering
#
# change detector parameter
------------------------------------------------------------
---> The calorimeter is 10 layers of: [ 10mm of Aluminium + 5mm of liquidArgon ]
@@ -195,10 +207,12 @@ Cut in energy
--------- Ranecu engine status ---------
Initial seed (index) = 0
Current couple of seeds = 1472867459, 1074604418
Current couple of seeds = 1715683464, 1760201142
----------------------------------------
---> End of event: 0
Absorber: total energy: 4.1e+02 MeV total track length: 95 cm
Gap: total energy: 81 MeV total track length: 2.2 m
Absorber: total energy: 333.094 MeV total track length: 79.5857 cm
Gap: total energy: 68.1459 MeV total track length: 1.88635 m
25 hits are stored in ExN03CalorHitsCollection.
23 hits are stored in ExN03CalorHitsCollection.
Graphics systems deleted.
Visualization Manager deleting...
+31 -30
View File
@@ -21,13 +21,13 @@
// ********************************************************************
//
//
// $Id: ExN03CalorHit.hh,v 1.2.4.1 2001/06/28 19:07:31 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN03CalorHit.hh,v 1.4 2001/10/10 14:58:11 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#ifndef ExN03CalorHit_h
#define ExN03CalorHit_h 1
@@ -36,48 +36,47 @@
#include "G4THitsCollection.hh"
#include "G4Allocator.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
class ExN03CalorHit : public G4VHit
{
public:
public:
ExN03CalorHit();
~ExN03CalorHit();
ExN03CalorHit(const ExN03CalorHit&);
const ExN03CalorHit& operator=(const ExN03CalorHit&);
int operator==(const ExN03CalorHit&) const;
ExN03CalorHit();
~ExN03CalorHit();
ExN03CalorHit(const ExN03CalorHit&);
const ExN03CalorHit& operator=(const ExN03CalorHit&);
int operator==(const ExN03CalorHit&) const;
inline void* operator new(size_t);
inline void operator delete(void*);
inline void* operator new(size_t);
inline void operator delete(void*);
void Draw();
void Print();
void Draw();
void Print();
public:
public:
void AddAbs(G4double de, G4double dl) {EdepAbs += de; TrackLengthAbs += dl;};
void AddGap(G4double de, G4double dl) {EdepGap += de; TrackLengthGap += dl;};
void AddAbs(G4double de, G4double dl) {EdepAbs += de; TrackLengthAbs += dl;};
void AddGap(G4double de, G4double dl) {EdepGap += de; TrackLengthGap += dl;};
G4double GetEdepAbs() { return EdepAbs; };
G4double GetTrakAbs() { return TrackLengthAbs; };
G4double GetEdepGap() { return EdepGap; };
G4double GetTrakGap() { return TrackLengthGap; };
private:
G4double GetEdepAbs() { return EdepAbs; };
G4double GetTrakAbs() { return TrackLengthAbs; };
G4double GetEdepGap() { return EdepGap; };
G4double GetTrakGap() { return TrackLengthGap; };
private:
G4double EdepAbs, TrackLengthAbs;
G4double EdepGap, TrackLengthGap;
G4double EdepAbs, TrackLengthAbs;
G4double EdepGap, TrackLengthGap;
};
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
typedef G4THitsCollection<ExN03CalorHit> ExN03CalorHitsCollection;
extern G4Allocator<ExN03CalorHit> ExN03CalorHitAllocator;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
inline void* ExN03CalorHit::operator new(size_t)
{
@@ -86,13 +85,15 @@ inline void* ExN03CalorHit::operator new(size_t)
return aHit;
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
inline void ExN03CalorHit::operator delete(void* aHit)
{
ExN03CalorHitAllocator.FreeSingle((ExN03CalorHit*) aHit);
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#endif
@@ -21,8 +21,8 @@
// ********************************************************************
//
//
// $Id: ExN03CalorimeterSD.hh,v 1.2.4.1 2001/06/28 19:07:32 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN03CalorimeterSD.hh,v 1.3 2001/07/11 09:58:21 gunter Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
@@ -21,13 +21,13 @@
// ********************************************************************
//
//
// $Id: ExN03DetectorConstruction.hh,v 1.2.4.1 2001/06/28 19:07:32 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN03DetectorConstruction.hh,v 1.4 2001/10/10 14:58:11 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#ifndef ExN03DetectorConstruction_h
#define ExN03DetectorConstruction_h 1
@@ -43,7 +43,7 @@ class G4UniformMagField;
class ExN03DetectorMessenger;
class ExN03CalorimeterSD;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
class ExN03DetectorConstruction : public G4VUserDetectorConstruction
{
@@ -141,7 +141,7 @@ class ExN03DetectorConstruction : public G4VUserDetectorConstruction
G4VPhysicalVolume* ConstructCalorimeter();
};
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
inline void ExN03DetectorConstruction::ComputeCalorParameters()
{
@@ -152,5 +152,7 @@ inline void ExN03DetectorConstruction::ComputeCalorParameters()
WorldSizeX = 1.2*CalorThickness; WorldSizeYZ = 1.2*CalorSizeYZ;
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#endif
@@ -21,13 +21,13 @@
// ********************************************************************
//
//
// $Id: ExN03DetectorMessenger.hh,v 1.2.4.1 2001/06/28 19:07:32 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN03DetectorMessenger.hh,v 1.4 2001/10/10 14:58:11 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#ifndef ExN03DetectorMessenger_h
#define ExN03DetectorMessenger_h 1
@@ -42,7 +42,7 @@ class G4UIcmdWithAnInteger;
class G4UIcmdWithADoubleAndUnit;
class G4UIcmdWithoutParameter;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
class ExN03DetectorMessenger: public G4UImessenger
{
@@ -66,5 +66,7 @@ class ExN03DetectorMessenger: public G4UImessenger
G4UIcmdWithoutParameter* UpdateCmd;
};
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#endif
@@ -21,13 +21,13 @@
// ********************************************************************
//
//
// $Id: ExN03EventAction.hh,v 1.4.4.1 2001/06/28 19:07:32 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN03EventAction.hh,v 1.6 2001/10/10 14:58:11 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#ifndef ExN03EventAction_h
#define ExN03EventAction_h 1
@@ -37,7 +37,7 @@
class ExN03EventActionMessenger;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
class ExN03EventAction : public G4UserEventAction
{
@@ -59,6 +59,8 @@ class ExN03EventAction : public G4UserEventAction
ExN03EventActionMessenger* eventMessenger;
};
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#endif
@@ -21,13 +21,13 @@
// ********************************************************************
//
//
// $Id: ExN03EventActionMessenger.hh,v 1.3.4.1 2001/06/28 19:07:32 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN03EventActionMessenger.hh,v 1.5 2001/10/10 14:58:11 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#ifndef ExN03EventActionMessenger_h
#define ExN03EventActionMessenger_h 1
@@ -39,7 +39,7 @@ class ExN03EventAction;
class G4UIcmdWithAString;
class G4UIcmdWithAnInteger;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
class ExN03EventActionMessenger: public G4UImessenger
{
@@ -55,4 +55,6 @@ class ExN03EventActionMessenger: public G4UImessenger
G4UIcmdWithAnInteger* PrintCmd;
};
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#endif
@@ -21,13 +21,13 @@
// ********************************************************************
//
//
// $Id: ExN03PhysicsList.hh,v 1.6.4.1 2001/06/28 19:07:32 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN03PhysicsList.hh,v 1.8 2001/10/10 14:58:11 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#ifndef ExN03PhysicsList_h
#define ExN03PhysicsList_h 1
@@ -35,7 +35,7 @@
#include "G4VUserPhysicsList.hh"
#include "globals.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
class ExN03PhysicsList: public G4VUserPhysicsList
{
@@ -78,6 +78,8 @@ class ExN03PhysicsList: public G4VUserPhysicsList
G4double currentDefaultCut;
};
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#endif
@@ -21,13 +21,13 @@
// ********************************************************************
//
//
// $Id: ExN03PrimaryGeneratorAction.hh,v 1.2.4.1 2001/06/28 19:07:32 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN03PrimaryGeneratorAction.hh,v 1.4 2001/10/10 14:58:11 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#ifndef ExN03PrimaryGeneratorAction_h
#define ExN03PrimaryGeneratorAction_h 1
@@ -40,7 +40,7 @@ class G4Event;
class ExN03DetectorConstruction;
class ExN03PrimaryGeneratorMessenger;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
class ExN03PrimaryGeneratorAction : public G4VUserPrimaryGeneratorAction
{
@@ -53,13 +53,15 @@ class ExN03PrimaryGeneratorAction : public G4VUserPrimaryGeneratorAction
void SetRndmFlag(G4String val) { rndmFlag = val;}
private:
G4ParticleGun* particleGun; //pointer a to G4 service class
G4ParticleGun* particleGun; //pointer a to G4 class
ExN03DetectorConstruction* ExN03Detector; //pointer to the geometry
ExN03PrimaryGeneratorMessenger* gunMessenger; //messenger of this class
G4String rndmFlag; //flag for a random impact point
G4String rndmFlag; //flag for a rndm impact point
};
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#endif
@@ -21,13 +21,13 @@
// ********************************************************************
//
//
// $Id: ExN03PrimaryGeneratorMessenger.hh,v 1.2.4.1 2001/06/28 19:07:32 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN03PrimaryGeneratorMessenger.hh,v 1.4 2001/10/10 14:58:11 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#ifndef ExN03PrimaryGeneratorMessenger_h
#define ExN03PrimaryGeneratorMessenger_h 1
@@ -38,7 +38,7 @@
class ExN03PrimaryGeneratorAction;
class G4UIcmdWithAString;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
class ExN03PrimaryGeneratorMessenger: public G4UImessenger
{
@@ -53,5 +53,7 @@ class ExN03PrimaryGeneratorMessenger: public G4UImessenger
G4UIcmdWithAString* RndmCmd;
};
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#endif
@@ -21,13 +21,13 @@
// ********************************************************************
//
//
// $Id: ExN03RunAction.hh,v 1.4.4.1 2001/06/28 19:07:32 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN03RunAction.hh,v 1.6 2001/10/10 14:58:11 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#ifndef ExN03RunAction_h
#define ExN03RunAction_h 1
@@ -35,7 +35,7 @@
#include "G4UserRunAction.hh"
#include "globals.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
class G4Run;
@@ -51,5 +51,7 @@ class ExN03RunAction : public G4UserRunAction
};
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#endif
@@ -21,20 +21,20 @@
// ********************************************************************
//
//
// $Id: ExN03SteppingAction.hh,v 1.4.4.1 2001/06/28 19:07:32 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN03SteppingAction.hh,v 1.6 2001/10/10 14:58:11 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#ifndef ExN03SteppingAction_h
#define ExN03SteppingAction_h 1
#include "G4UserSteppingAction.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
class ExN03SteppingAction : public G4UserSteppingAction
{
@@ -45,4 +45,6 @@ class ExN03SteppingAction : public G4UserSteppingAction
void UserSteppingAction(const G4Step*);
};
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#endif
@@ -21,12 +21,12 @@
// ********************************************************************
//
//
// $Id: ExN03SteppingVerbose.hh,v 1.4.2.1 2001/06/28 19:07:32 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN03SteppingVerbose.hh,v 1.6 2001/10/10 14:58:11 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
class ExN03SteppingVerbose;
@@ -35,7 +35,7 @@ class ExN03SteppingVerbose;
#include "G4SteppingVerbose.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
class ExN03SteppingVerbose : public G4SteppingVerbose
{
@@ -49,4 +49,6 @@ class ExN03SteppingVerbose : public G4SteppingVerbose
};
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#endif
@@ -21,13 +21,13 @@
// ********************************************************************
//
//
// $Id: ExN03VisManager.hh,v 1.3.4.1 2001/06/28 19:07:32 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN03VisManager.hh,v 1.5 2001/10/10 14:58:11 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
// Example Visualization Manager implementing virtual function
// RegisterGraphicsSystems. Exploits C-pre-processor variables
@@ -42,7 +42,7 @@
// G4VisManager* myVisManager = new MyVisManager;
// myVisManager -> RegisterGraphicsSystem (new MyGraphicsSystem);
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#ifndef ExN03VisManager_h
#define ExN03VisManager_h 1
@@ -51,7 +51,7 @@
#include "G4VisManager.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
class ExN03VisManager: public G4VisManager {
@@ -65,6 +65,8 @@ private:
};
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#endif
#endif
+5 -8
View File
@@ -1,4 +1,3 @@
#
# Example of interactive redefinition
# of the geometry
#
@@ -10,18 +9,16 @@
#
/calor/setNbOfLayers 1
#
/calor/setAbsMat Aluminium
/calor/setAbsThick 10. cm
/calor/setAbsMat Water
/calor/setAbsThick 40 cm
#
/calor/setGapMat Air
/calor/setGapThick 0.1 cm
/calor/setGapThick 0 cm
#
/calor/setSizeYZ 10. cm
/calor/setSizeYZ 40 cm
#
/calor/update
#
/calor/setField 3 tesla
#
/vis/camera/zoom 1.3
/vis/drawVolume
/vis/viewer/zoom 1.3
+15 -15
View File
@@ -21,19 +21,19 @@
// ********************************************************************
//
//
// $Id: ExN03CalorHit.cc,v 1.2.4.1 2001/06/28 19:07:32 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN03CalorHit.cc,v 1.4 2001/10/10 14:58:12 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#include "ExN03CalorHit.hh"
G4Allocator<ExN03CalorHit> ExN03CalorHitAllocator;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN03CalorHit::ExN03CalorHit()
{
@@ -41,12 +41,12 @@ ExN03CalorHit::ExN03CalorHit()
EdepGap = 0.; TrackLengthGap = 0.;
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN03CalorHit::~ExN03CalorHit()
{;}
{}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN03CalorHit::ExN03CalorHit(const ExN03CalorHit& right)
{
@@ -54,7 +54,7 @@ ExN03CalorHit::ExN03CalorHit(const ExN03CalorHit& right)
EdepGap = right.EdepGap; TrackLengthGap = right.TrackLengthGap;
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
const ExN03CalorHit& ExN03CalorHit::operator=(const ExN03CalorHit& right)
{
@@ -63,22 +63,22 @@ const ExN03CalorHit& ExN03CalorHit::operator=(const ExN03CalorHit& right)
return *this;
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
int ExN03CalorHit::operator==(const ExN03CalorHit& right) const
{
return 0;
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN03CalorHit::Draw()
{;}
{}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN03CalorHit::Print()
{;}
{}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
+14 -14
View File
@@ -21,13 +21,13 @@
// ********************************************************************
//
//
// $Id: ExN03CalorimeterSD.cc,v 1.3.4.1 2001/06/28 19:07:32 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN03CalorimeterSD.cc,v 1.5 2001/10/10 14:58:12 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#include "ExN03CalorimeterSD.hh"
@@ -42,7 +42,7 @@
#include "G4ios.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN03CalorimeterSD::ExN03CalorimeterSD(G4String name,
ExN03DetectorConstruction* det)
@@ -52,14 +52,14 @@ ExN03CalorimeterSD::ExN03CalorimeterSD(G4String name,
HitID = new G4int[500];
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN03CalorimeterSD::~ExN03CalorimeterSD()
{
delete [] HitID;
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN03CalorimeterSD::Initialize(G4HCofThisEvent*HCE)
{
@@ -68,7 +68,7 @@ void ExN03CalorimeterSD::Initialize(G4HCofThisEvent*HCE)
for (G4int j=0;j<Detector->GetNbOfLayers();j++) {HitID[j] = -1;};
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
G4bool ExN03CalorimeterSD::ProcessHits(G4Step* aStep,G4TouchableHistory* ROhist)
{
@@ -86,7 +86,7 @@ G4bool ExN03CalorimeterSD::ProcessHits(G4Step* aStep,G4TouchableHistory* ROhist)
G4VPhysicalVolume* physVol = theTouchable->GetVolume();
//theTouchable->MoveUpHistory();
G4int LayerNumber = 0;
if (Detector->GetNbOfLayers()>1) LayerNumber=theTouchable->GetReplicaNumber(1);
if(Detector->GetNbOfLayers()>1) LayerNumber=theTouchable->GetReplicaNumber(1);
if (HitID[LayerNumber]==-1)
{
@@ -110,7 +110,7 @@ G4bool ExN03CalorimeterSD::ProcessHits(G4Step* aStep,G4TouchableHistory* ROhist)
return true;
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN03CalorimeterSD::EndOfEvent(G4HCofThisEvent* HCE)
{
@@ -120,20 +120,20 @@ void ExN03CalorimeterSD::EndOfEvent(G4HCofThisEvent* HCE)
HCE->AddHitsCollection(HCID,CalCollection);
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN03CalorimeterSD::clear()
{}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN03CalorimeterSD::DrawAll()
{}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN03CalorimeterSD::PrintAll()
{}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
@@ -21,13 +21,13 @@
// ********************************************************************
//
//
// $Id: ExN03DetectorConstruction.cc,v 1.4.4.1 2001/06/28 19:07:33 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN03DetectorConstruction.cc,v 1.10 2001/11/27 11:37:37 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#include "ExN03DetectorConstruction.hh"
#include "ExN03DetectorMessenger.hh"
@@ -50,16 +50,16 @@
#include "G4ios.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN03DetectorConstruction::ExN03DetectorConstruction()
:solidWorld(NULL),logicWorld(NULL),physiWorld(NULL),
solidCalor(NULL),logicCalor(NULL),physiCalor(NULL),
solidLayer(NULL),logicLayer(NULL),physiLayer(NULL),
solidAbsorber(NULL),logicAbsorber(NULL),physiAbsorber(NULL),
solidGap (NULL),logicGap (NULL),physiGap (NULL),
AbsorberMaterial(NULL),GapMaterial(NULL),defaultMaterial(NULL),
magField(NULL),calorimeterSD(NULL)
:AbsorberMaterial(0),GapMaterial(0),defaultMaterial(0),
solidWorld(0),logicWorld(0),physiWorld(0),
solidCalor(0),logicCalor(0),physiCalor(0),
solidLayer(0),logicLayer(0),physiLayer(0),
solidAbsorber(0),logicAbsorber(0),physiAbsorber(0),
solidGap (0),logicGap (0),physiGap (0),
magField(0),calorimeterSD(0)
{
// default parameter values of the calorimeter
AbsorberThickness = 10.*mm;
@@ -72,12 +72,12 @@ ExN03DetectorConstruction::ExN03DetectorConstruction()
detectorMessenger = new ExN03DetectorMessenger(this);
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN03DetectorConstruction::~ExN03DetectorConstruction()
{ delete detectorMessenger;}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
G4VPhysicalVolume* ExN03DetectorConstruction::Construct()
{
@@ -85,7 +85,7 @@ G4VPhysicalVolume* ExN03DetectorConstruction::Construct()
return ConstructCalorimeter();
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN03DetectorConstruction::DefineMaterials()
{
@@ -119,9 +119,6 @@ G4Element* O = new G4Element(name="Oxygen" ,symbol="O" , z= 8., a);
a = 28.09*g/mole;
G4Element* Si = new G4Element(name="Silicon",symbol="Si" , z= 14., a);
a = 55.85*g/mole;
G4Element* Fe = new G4Element(name="Iron" ,symbol="Fe", z=26., a);
//
// define an Element from isotopes, by relative abundance
//
@@ -129,7 +126,7 @@ G4Element* Fe = new G4Element(name="Iron" ,symbol="Fe", z=26., a);
G4Isotope* U5 = new G4Isotope(name="U235", iz=92, n=235, a=235.01*g/mole);
G4Isotope* U8 = new G4Isotope(name="U238", iz=92, n=238, a=238.03*g/mole);
G4Element* U = new G4Element(name="enriched Uranium", symbol="U", ncomponents=2);
G4Element* U = new G4Element(name="enriched Uranium",symbol="U",ncomponents=2);
U->AddIsotope(U5, abundance= 90.*perCent);
U->AddIsotope(U8, abundance= 10.*perCent);
@@ -137,18 +134,12 @@ U->AddIsotope(U8, abundance= 10.*perCent);
// define simple materials
//
density = 2.700*g/cm3;
a = 26.98*g/mole;
G4Material* Al = new G4Material(name="Aluminium", z=13., a, density);
new G4Material(name="Aluminium", z=13., a=26.98*g/mole, density=2.700*g/cm3);
density = 1.390*g/cm3;
a = 39.95*g/mole;
G4Material* lAr = new G4Material(name="liquidArgon", z=18., a, density);
density = 8.960*g/cm3;
a = 63.55*g/mole;
G4Material* Cu = new G4Material(name="Copper" , z=29., a, density);
density = 11.35*g/cm3;
a = 207.19*g/mole;
G4Material* Pb = new G4Material(name="Lead" , z=82., a, density);
@@ -214,11 +205,11 @@ steam->AddMaterial(H2O, fractionmass=1.);
// examples of vacuum
//
density = universe_mean_density; //from PhysicalConstants.h
density = universe_mean_density;
pressure = 3.e-18*pascal;
temperature = 2.73*kelvin;
new G4Material(name="Galactic", z=1., a=1.01*g/mole, density,
kStateGas,temperature,pressure);
G4Material* Vacuum = new G4Material(name="Galactic", z=1., a=1.01*g/mole,
density,kStateGas,temperature,pressure);
density = 1.e-5*g/cm3;
pressure = 2.e-2*bar;
@@ -232,10 +223,10 @@ G4cout << *(G4Material::GetMaterialTable()) << G4endl;
//default materials of the calorimeter
AbsorberMaterial = Pb;
GapMaterial = lAr;
defaultMaterial = Air;
defaultMaterial = Vacuum;
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
G4VPhysicalVolume* ExN03DetectorConstruction::ConstructCalorimeter()
{
@@ -256,15 +247,15 @@ G4VPhysicalVolume* ExN03DetectorConstruction::ConstructCalorimeter()
G4ThreeVector(), //at (0,0,0)
"World", //its name
logicWorld, //its logical volume
NULL, //its mother volume
0, //its mother volume
false, //no boolean operation
0); //copy number
//
// Calorimeter
//
solidCalor=NULL; logicCalor=NULL; physiCalor=NULL;
solidLayer=NULL; logicLayer=NULL; physiLayer=NULL;
solidCalor=0; logicCalor=0; physiCalor=0;
solidLayer=0; logicLayer=0; physiLayer=0;
if (CalorThickness > 0.)
{ solidCalor = new G4Box("Calorimeter", //its name
@@ -311,7 +302,7 @@ G4VPhysicalVolume* ExN03DetectorConstruction::ConstructCalorimeter()
//
// Absorber
//
solidAbsorber=NULL; logicAbsorber=NULL; physiAbsorber=NULL;
solidAbsorber=0; logicAbsorber=0; physiAbsorber=0;
if (AbsorberThickness > 0.)
{ solidAbsorber = new G4Box("Absorber", //its name
@@ -334,7 +325,7 @@ G4VPhysicalVolume* ExN03DetectorConstruction::ConstructCalorimeter()
//
// Gap
//
solidGap=NULL; logicGap=NULL; physiGap=NULL;
solidGap=0; logicGap=0; physiGap=0;
if (GapThickness > 0.)
{ solidGap = new G4Box("Gap",
@@ -383,7 +374,7 @@ G4VPhysicalVolume* ExN03DetectorConstruction::ConstructCalorimeter()
return physiWorld;
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN03DetectorConstruction::PrintCalorParameters()
{
@@ -395,7 +386,7 @@ void ExN03DetectorConstruction::PrintCalorParameters()
<< "\n------------------------------------------------------------\n";
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN03DetectorConstruction::SetAbsorberMaterial(G4String materialChoice)
{
@@ -408,7 +399,7 @@ void ExN03DetectorConstruction::SetAbsorberMaterial(G4String materialChoice)
}
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN03DetectorConstruction::SetGapMaterial(G4String materialChoice)
{
@@ -421,7 +412,7 @@ void ExN03DetectorConstruction::SetGapMaterial(G4String materialChoice)
}
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN03DetectorConstruction::SetAbsorberThickness(G4double val)
{
@@ -429,7 +420,7 @@ void ExN03DetectorConstruction::SetAbsorberThickness(G4double val)
AbsorberThickness = val;
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN03DetectorConstruction::SetGapThickness(G4double val)
{
@@ -437,7 +428,7 @@ void ExN03DetectorConstruction::SetGapThickness(G4double val)
GapThickness = val;
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN03DetectorConstruction::SetCalorSizeYZ(G4double val)
{
@@ -445,14 +436,14 @@ void ExN03DetectorConstruction::SetCalorSizeYZ(G4double val)
CalorSizeYZ = val;
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN03DetectorConstruction::SetNbOfLayers(G4int val)
{
NbOfLayers = val;
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN03DetectorConstruction::SetMagField(G4double fieldValue)
{
@@ -467,16 +458,16 @@ void ExN03DetectorConstruction::SetMagField(G4double fieldValue)
fieldMgr->SetDetectorField(magField);
fieldMgr->CreateChordFinder(magField);
} else {
magField = NULL;
magField = 0;
fieldMgr->SetDetectorField(magField);
}
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN03DetectorConstruction::UpdateGeometry()
{
G4RunManager::GetRunManager()->DefineWorldVolume(ConstructCalorimeter());
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
@@ -21,13 +21,13 @@
// ********************************************************************
//
//
// $Id: ExN03DetectorMessenger.cc,v 1.3.4.1 2001/06/28 19:07:33 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN03DetectorMessenger.cc,v 1.5 2001/10/10 14:58:12 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#include "ExN03DetectorMessenger.hh"
@@ -38,9 +38,10 @@
#include "G4UIcmdWithADoubleAndUnit.hh"
#include "G4UIcmdWithoutParameter.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN03DetectorMessenger::ExN03DetectorMessenger(ExN03DetectorConstruction * ExN03Det)
ExN03DetectorMessenger::ExN03DetectorMessenger(
ExN03DetectorConstruction* ExN03Det)
:ExN03Detector(ExN03Det)
{
ExN03detDir = new G4UIdirectory("/calor/");
@@ -97,7 +98,7 @@ ExN03DetectorMessenger::ExN03DetectorMessenger(ExN03DetectorConstruction * ExN03
MagFieldCmd->AvailableForStates(Idle);
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN03DetectorMessenger::~ExN03DetectorMessenger()
{
@@ -109,7 +110,7 @@ ExN03DetectorMessenger::~ExN03DetectorMessenger()
delete ExN03detDir;
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN03DetectorMessenger::SetNewValue(G4UIcommand* command,G4String newValue)
{
@@ -120,7 +121,8 @@ void ExN03DetectorMessenger::SetNewValue(G4UIcommand* command,G4String newValue)
{ ExN03Detector->SetGapMaterial(newValue);}
if( command == AbsThickCmd )
{ ExN03Detector->SetAbsorberThickness(AbsThickCmd->GetNewDoubleValue(newValue));}
{ ExN03Detector->SetAbsorberThickness(AbsThickCmd
->GetNewDoubleValue(newValue));}
if( command == GapThickCmd )
{ ExN03Detector->SetGapThickness(GapThickCmd->GetNewDoubleValue(newValue));}
@@ -138,4 +140,4 @@ void ExN03DetectorMessenger::SetNewValue(G4UIcommand* command,G4String newValue)
{ ExN03Detector->SetMagField(MagFieldCmd->GetNewDoubleValue(newValue));}
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
+27 -22
View File
@@ -21,13 +21,13 @@
// ********************************************************************
//
//
// $Id: ExN03EventAction.cc,v 1.12.2.1 2001/06/28 19:07:33 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN03EventAction.cc,v 1.15 2001/11/05 08:24:51 gcosmo Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#include "ExN03EventAction.hh"
@@ -46,23 +46,23 @@
#include "G4ios.hh"
#include "G4UnitsTable.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN03EventAction::ExN03EventAction()
:calorimeterCollID(-1),drawFlag("all"),eventMessenger(NULL),
printModulo(1)
:calorimeterCollID(-1),drawFlag("all"),printModulo(1),
eventMessenger(0)
{
eventMessenger = new ExN03EventActionMessenger(this);
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN03EventAction::~ExN03EventAction()
{
delete eventMessenger;
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN03EventAction::BeginOfEventAction(const G4Event* evt)
{
@@ -81,7 +81,7 @@ void ExN03EventAction::BeginOfEventAction(const G4Event* evt)
}
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN03EventAction::EndOfEventAction(const G4Event* evt)
{
@@ -91,7 +91,7 @@ void ExN03EventAction::EndOfEventAction(const G4Event* evt)
// track length) in all absorbers and in all gaps
G4HCofThisEvent* HCE = evt->GetHCofThisEvent();
ExN03CalorHitsCollection* CHC = NULL;
ExN03CalorHitsCollection* CHC = 0;
G4int n_hit = 0;
G4double totEAbs=0, totLAbs=0, totEGap=0, totLGap=0;
@@ -115,34 +115,39 @@ void ExN03EventAction::EndOfEventAction(const G4Event* evt)
G4cout << "---> End of event: " << evtNb << G4endl;
G4cout
<< " Absorber: total energy: " << G4std::setw(7) << G4BestUnit(totEAbs,"Energy")
<< " total track length: " << G4std::setw(7) << G4BestUnit(totLAbs,"Length")
<< " Absorber: total energy: " << G4std::setw(7)
<< G4BestUnit(totEAbs,"Energy")
<< " total track length: " << G4std::setw(7)
<< G4BestUnit(totLAbs,"Length")
<< G4endl
<< " Gap: total energy: " << G4std::setw(7) << G4BestUnit(totEGap,"Energy")
<< " total track length: " << G4std::setw(7) << G4BestUnit(totLGap,"Length")
<< " Gap: total energy: " << G4std::setw(7)
<< G4BestUnit(totEGap,"Energy")
<< " total track length: " << G4std::setw(7)
<< G4BestUnit(totLGap,"Length")
<< G4endl;
G4cout << "\n " << n_hit
<< " hits are stored in ExN03CalorHitsCollection." << G4endl;
<< " hits are stored in ExN03CalorHitsCollection." << G4endl;
}
// extract the trajectories and draw them
if (G4VVisManager::GetConcreteInstance())
{
G4TrajectoryContainer * trajectoryContainer = evt->GetTrajectoryContainer();
G4TrajectoryContainer* trajectoryContainer = evt->GetTrajectoryContainer();
G4int n_trajectories = 0;
if (trajectoryContainer) n_trajectories = trajectoryContainer->entries();
for (G4int i=0; i<n_trajectories; i++)
{ G4Trajectory* trj = (G4Trajectory*)((*(evt->GetTrajectoryContainer()))[i]);
{ G4Trajectory* trj = (G4Trajectory*)
((*(evt->GetTrajectoryContainer()))[i]);
if (drawFlag == "all") trj->DrawTrajectory(50);
else if ((drawFlag == "charged")&&(trj->GetCharge() != 0.))
trj->DrawTrajectory(50);
else if ((drawFlag == "neutral")&&(trj->GetCharge() == 0.))
trj->DrawTrajectory(50);
trj->DrawTrajectory(50);
}
}
}
}
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
@@ -21,13 +21,13 @@
// ********************************************************************
//
//
// $Id: ExN03EventActionMessenger.cc,v 1.4.4.1 2001/06/28 19:07:33 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN03EventActionMessenger.cc,v 1.6 2001/10/10 14:58:12 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#include "ExN03EventActionMessenger.hh"
@@ -36,7 +36,7 @@
#include "G4UIcmdWithAnInteger.hh"
#include "globals.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN03EventActionMessenger::ExN03EventActionMessenger(ExN03EventAction* EvAct)
:eventAction(EvAct)
@@ -56,7 +56,7 @@ ExN03EventActionMessenger::ExN03EventActionMessenger(ExN03EventAction* EvAct)
PrintCmd->AvailableForStates(Idle);
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN03EventActionMessenger::~ExN03EventActionMessenger()
{
@@ -64,15 +64,16 @@ ExN03EventActionMessenger::~ExN03EventActionMessenger()
delete PrintCmd;
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN03EventActionMessenger::SetNewValue(G4UIcommand * command,G4String newValue)
void ExN03EventActionMessenger::SetNewValue(
G4UIcommand* command,G4String newValue)
{
if(command == DrawCmd)
{eventAction->SetDrawFlag(newValue);}
if(command == PrintCmd)
{eventAction->SetPrintModulo(PrintCmd->GetNewIntValue(newValue));}
{eventAction->SetPrintModulo(PrintCmd->GetNewIntValue(newValue));}
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
+20 -29
View File
@@ -21,13 +21,13 @@
// ********************************************************************
//
//
// $Id: ExN03PhysicsList.cc,v 1.9.4.1 2001/06/28 19:07:33 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN03PhysicsList.cc,v 1.11 2001/10/10 14:58:12 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#include "ExN03PhysicsList.hh"
@@ -40,7 +40,7 @@
#include "G4Material.hh"
#include "G4ios.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN03PhysicsList::ExN03PhysicsList(): G4VUserPhysicsList()
{
@@ -52,12 +52,12 @@ ExN03PhysicsList::ExN03PhysicsList(): G4VUserPhysicsList()
SetVerboseLevel(1);
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN03PhysicsList::~ExN03PhysicsList()
{}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN03PhysicsList::ConstructParticle()
{
@@ -72,7 +72,7 @@ void ExN03PhysicsList::ConstructParticle()
ConstructBaryons();
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN03PhysicsList::ConstructBosons()
{
@@ -86,7 +86,8 @@ void ExN03PhysicsList::ConstructBosons()
// optical photon
G4OpticalPhoton::OpticalPhotonDefinition();
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN03PhysicsList::ConstructLeptons()
{
@@ -102,7 +103,7 @@ void ExN03PhysicsList::ConstructLeptons()
G4AntiNeutrinoMu::AntiNeutrinoMuDefinition();
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN03PhysicsList::ConstructMesons()
{
@@ -120,7 +121,7 @@ void ExN03PhysicsList::ConstructMesons()
G4KaonZeroShort::KaonZeroShortDefinition();
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN03PhysicsList::ConstructBaryons()
{
@@ -132,7 +133,7 @@ void ExN03PhysicsList::ConstructBaryons()
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN03PhysicsList::ConstructProcess()
{
@@ -141,7 +142,7 @@ void ExN03PhysicsList::ConstructProcess()
ConstructGeneral();
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#include "G4ComptonScattering.hh"
#include "G4GammaConversion.hh"
@@ -159,7 +160,7 @@ void ExN03PhysicsList::ConstructProcess()
#include "G4hIonisation.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN03PhysicsList::ConstructEM()
{
@@ -267,7 +268,7 @@ void ExN03PhysicsList::ConstructEM()
}
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#include "G4Decay.hh"
@@ -288,7 +289,7 @@ void ExN03PhysicsList::ConstructGeneral()
}
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN03PhysicsList::SetCuts()
{
@@ -303,7 +304,7 @@ void ExN03PhysicsList::SetCuts()
if (verboseLevel >0){
G4cout << "ExN03PhysicsList::SetCuts:";
G4cout << "CutLength : " << G4BestUnit(defaultCutValue,"Length") << G4endl;
G4cout << "CutLength : " << G4BestUnit(defaultCutValue,"Length") << G4endl;
}
// set cut values for gamma at first and for e- second and next for e+,
@@ -322,7 +323,7 @@ void ExN03PhysicsList::SetCuts()
if (verboseLevel>0) DumpCutValuesTable();
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN03PhysicsList::SetCutForGamma(G4double cut)
@@ -358,15 +359,5 @@ G4double ExN03PhysicsList::GetCutForProton() const
return cutForProton;
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
@@ -21,13 +21,13 @@
// ********************************************************************
//
//
// $Id: ExN03PrimaryGeneratorAction.cc,v 1.3.4.1 2001/06/28 19:07:33 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN03PrimaryGeneratorAction.cc,v 1.5 2001/10/10 14:58:12 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#include "ExN03PrimaryGeneratorAction.hh"
@@ -40,10 +40,10 @@
#include "G4ParticleDefinition.hh"
#include "Randomize.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN03PrimaryGeneratorAction::ExN03PrimaryGeneratorAction(
ExN03DetectorConstruction* ExN03DC)
ExN03DetectorConstruction* ExN03DC)
:ExN03Detector(ExN03DC),rndmFlag("off")
{
G4int n_particle = 1;
@@ -66,7 +66,7 @@ ExN03PrimaryGeneratorAction::ExN03PrimaryGeneratorAction(
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN03PrimaryGeneratorAction::~ExN03PrimaryGeneratorAction()
{
@@ -74,7 +74,7 @@ ExN03PrimaryGeneratorAction::~ExN03PrimaryGeneratorAction()
delete gunMessenger;
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN03PrimaryGeneratorAction::GeneratePrimaries(G4Event* anEvent)
{
@@ -91,5 +91,5 @@ void ExN03PrimaryGeneratorAction::GeneratePrimaries(G4Event* anEvent)
particleGun->GeneratePrimaryVertex(anEvent);
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
@@ -21,22 +21,23 @@
// ********************************************************************
//
//
// $Id: ExN03PrimaryGeneratorMessenger.cc,v 1.3.4.1 2001/06/28 19:07:33 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN03PrimaryGeneratorMessenger.cc,v 1.5 2001/10/10 14:58:12 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#include "ExN03PrimaryGeneratorMessenger.hh"
#include "ExN03PrimaryGeneratorAction.hh"
#include "G4UIcmdWithAString.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN03PrimaryGeneratorMessenger::ExN03PrimaryGeneratorMessenger(ExN03PrimaryGeneratorAction* ExN03Gun)
ExN03PrimaryGeneratorMessenger::ExN03PrimaryGeneratorMessenger(
ExN03PrimaryGeneratorAction* ExN03Gun)
:ExN03Action(ExN03Gun)
{
RndmCmd = new G4UIcmdWithAString("/gun/random",this);
@@ -48,20 +49,21 @@ ExN03PrimaryGeneratorMessenger::ExN03PrimaryGeneratorMessenger(ExN03PrimaryGener
RndmCmd->AvailableForStates(PreInit,Idle);
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN03PrimaryGeneratorMessenger::~ExN03PrimaryGeneratorMessenger()
{
delete RndmCmd;
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN03PrimaryGeneratorMessenger::SetNewValue(G4UIcommand * command,G4String newValue)
void ExN03PrimaryGeneratorMessenger::SetNewValue(
G4UIcommand* command, G4String newValue)
{
if( command == RndmCmd )
{ ExN03Action->SetRndmFlag(newValue);}
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
+10 -11
View File
@@ -21,13 +21,13 @@
// ********************************************************************
//
//
// $Id: ExN03RunAction.cc,v 1.7.4.1 2001/06/28 19:07:33 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN03RunAction.cc,v 1.9 2001/10/10 14:58:12 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#include "ExN03RunAction.hh"
@@ -36,18 +36,17 @@
#include "G4VVisManager.hh"
#include "G4ios.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN03RunAction::ExN03RunAction()
{
}
{}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN03RunAction::~ExN03RunAction()
{}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN03RunAction::BeginOfRunAction(const G4Run* aRun)
{
@@ -61,7 +60,7 @@ void ExN03RunAction::BeginOfRunAction(const G4Run* aRun)
}
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN03RunAction::EndOfRunAction(const G4Run* )
{
@@ -70,4 +69,4 @@ void ExN03RunAction::EndOfRunAction(const G4Run* )
}
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
@@ -21,32 +21,32 @@
// ********************************************************************
//
//
// $Id: ExN03SteppingAction.cc,v 1.3.4.1 2001/06/28 19:07:33 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN03SteppingAction.cc,v 1.5 2001/10/10 14:58:13 maire Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#include "ExN03SteppingAction.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN03SteppingAction::ExN03SteppingAction()
{ }
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN03SteppingAction::~ExN03SteppingAction()
{ }
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN03SteppingAction::UserSteppingAction(const G4Step*)
{ }
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
+30 -29
View File
@@ -21,28 +21,28 @@
// ********************************************************************
//
//
// $Id: ExN03SteppingVerbose.cc,v 1.5.2.1 2001/06/28 19:07:33 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN03SteppingVerbose.cc,v 1.8 2001/11/05 08:24:51 gcosmo Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#include "ExN03SteppingVerbose.hh"
#include "G4SteppingManager.hh"
#include "G4UnitsTable.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN03SteppingVerbose::ExN03SteppingVerbose()
{}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN03SteppingVerbose::~ExN03SteppingVerbose()
{}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN03SteppingVerbose::StepInfo()
{
@@ -66,14 +66,14 @@ void ExN03SteppingVerbose::StepInfo()
<< G4std::setw(10) << "Process" << G4endl;
}
G4cout << G4std::setw( 5) << fTrack->GetCurrentStepNumber() << " "
<< G4std::setw( 6) << G4BestUnit(fTrack->GetPosition().x(),"Length")
<< G4std::setw( 6) << G4BestUnit(fTrack->GetPosition().y(),"Length")
<< G4std::setw( 6) << G4BestUnit(fTrack->GetPosition().z(),"Length")
<< G4std::setw( 6) << G4BestUnit(fTrack->GetKineticEnergy(),"Energy")
<< G4std::setw( 6) << G4BestUnit(fStep->GetTotalEnergyDeposit(),"Energy")
<< G4std::setw( 6) << G4BestUnit(fStep->GetStepLength(),"Length")
<< G4std::setw( 6) << G4BestUnit(fTrack->GetTrackLength(),"Length");
G4cout << G4std::setw(5) << fTrack->GetCurrentStepNumber() << " "
<< G4std::setw(6) << G4BestUnit(fTrack->GetPosition().x(),"Length")
<< G4std::setw(6) << G4BestUnit(fTrack->GetPosition().y(),"Length")
<< G4std::setw(6) << G4BestUnit(fTrack->GetPosition().z(),"Length")
<< G4std::setw(6) << G4BestUnit(fTrack->GetKineticEnergy(),"Energy")
<< G4std::setw(6) << G4BestUnit(fStep->GetTotalEnergyDeposit(),"Energy")
<< G4std::setw(6) << G4BestUnit(fStep->GetStepLength(),"Length")
<< G4std::setw(6) << G4BestUnit(fTrack->GetTrackLength(),"Length");
// if( fStepStatus != fWorldBoundary){
if( fTrack->GetNextVolume() != 0 ) {
@@ -82,10 +82,11 @@ void ExN03SteppingVerbose::StepInfo()
G4cout << G4std::setw(10) << "OutOfWorld";
}
if(fStep->GetPostStepPoint()->GetProcessDefinedStep() != NULL){
if(fStep->GetPostStepPoint()->GetProcessDefinedStep() != 0){
G4cout << " "
<< G4std::setw(10) << fStep->GetPostStepPoint()->GetProcessDefinedStep()
->GetProcessName();
<< G4std::setw(10)
<< fStep->GetPostStepPoint()->GetProcessDefinedStep()
->GetProcessName();
} else {
G4cout << " UserLimit";
}
@@ -107,7 +108,7 @@ void ExN03SteppingVerbose::StepInfo()
<< " ---------------"
<< G4endl;
for(G4int lp1=(*fSecondary).size()-tN2ndariesTot;
for(size_t lp1=(*fSecondary).size()-tN2ndariesTot;
lp1<(*fSecondary).size(); lp1++){
G4cout << " : "
<< G4std::setw(6)
@@ -134,7 +135,7 @@ void ExN03SteppingVerbose::StepInfo()
G4cout.precision(prec);
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN03SteppingVerbose::TrackingStarted()
{
@@ -154,14 +155,14 @@ G4int prec = G4cout.precision(3);
<< G4std::setw(10) << "Volume" << " "
<< G4std::setw(10) << "Process" << G4endl;
G4cout << G4std::setw( 5) << fTrack->GetCurrentStepNumber() << " "
<< G4std::setw( 6) << G4BestUnit(fTrack->GetPosition().x(),"Length")
<< G4std::setw( 6) << G4BestUnit(fTrack->GetPosition().y(),"Length")
<< G4std::setw( 6) << G4BestUnit(fTrack->GetPosition().z(),"Length")
<< G4std::setw( 6) << G4BestUnit(fTrack->GetKineticEnergy(),"Energy")
<< G4std::setw( 6) << G4BestUnit(fStep->GetTotalEnergyDeposit(),"Energy")
<< G4std::setw( 6) << G4BestUnit(fStep->GetStepLength(),"Length")
<< G4std::setw( 6) << G4BestUnit(fTrack->GetTrackLength(),"Length");
G4cout << G4std::setw( 5) << fTrack->GetCurrentStepNumber() << " "
<< G4std::setw( 6) << G4BestUnit(fTrack->GetPosition().x(),"Length")
<< G4std::setw( 6) << G4BestUnit(fTrack->GetPosition().y(),"Length")
<< G4std::setw( 6) << G4BestUnit(fTrack->GetPosition().z(),"Length")
<< G4std::setw( 6) << G4BestUnit(fTrack->GetKineticEnergy(),"Energy")
<< G4std::setw( 6) << G4BestUnit(fStep->GetTotalEnergyDeposit(),"Energy")
<< G4std::setw( 6) << G4BestUnit(fStep->GetStepLength(),"Length")
<< G4std::setw( 6) << G4BestUnit(fTrack->GetTrackLength(),"Length");
if(fTrack->GetNextVolume()){
G4cout << G4std::setw(10) << fTrack->GetVolume()->GetName();
@@ -173,4 +174,4 @@ G4int prec = G4cout.precision(3);
G4cout.precision(prec);
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
+25 -37
View File
@@ -21,14 +21,14 @@
// ********************************************************************
//
//
// $Id: ExN03VisManager.cc,v 1.5.2.1 2001/06/28 19:07:33 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN03VisManager.cc,v 1.8 2001/11/15 13:09:56 johna Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
// John Allison 24th January 1998.
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#ifdef G4VIS_USE
@@ -36,18 +36,21 @@
// Supported drivers...
#ifdef G4VIS_USE_ASCIITREE
// Not needing external packages or libraries...
#include "G4ASCIITree.hh"
#endif
#include "G4DAWNFILE.hh"
#include "G4GAGTree.hh"
#include "G4HepRepFile.hh"
#include "G4RayTracer.hh"
#include "G4VRML1File.hh"
#include "G4VRML2File.hh"
// Needing external packages or libraries...
#ifdef G4VIS_USE_DAWN
#include "G4FukuiRenderer.hh"
#endif
#ifdef G4VIS_USE_DAWNFILE
#include "G4DAWNFILE.hh"
#endif
#ifdef G4VIS_USE_OPACS
#include "G4Wo.hh"
#include "G4Xo.hh"
@@ -76,40 +79,34 @@
#include "G4OpenInventorWin32.hh"
#endif
#ifdef G4VIS_USE_RAYTRACER
#include "G4RayTracer.hh"
#endif
#ifdef G4VIS_USE_VRML
#include "G4VRML1.hh"
#include "G4VRML2.hh"
#endif
#ifdef G4VIS_USE_VRMLFILE
#include "G4VRML1File.hh"
#include "G4VRML2File.hh"
#endif
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
ExN03VisManager::ExN03VisManager () {}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
void ExN03VisManager::RegisterGraphicsSystems () {
#ifdef G4VIS_USE_ASCIITREE
// Graphics Systems not needing external packages or libraries...
RegisterGraphicsSystem (new G4ASCIITree);
#endif
RegisterGraphicsSystem (new G4DAWNFILE);
RegisterGraphicsSystem (new G4GAGTree);
RegisterGraphicsSystem (new G4HepRepFile);
RegisterGraphicsSystem (new G4RayTracer);
RegisterGraphicsSystem (new G4VRML1File);
RegisterGraphicsSystem (new G4VRML2File);
// Graphics systems needing external packages or libraries...
#ifdef G4VIS_USE_DAWN
RegisterGraphicsSystem (new G4FukuiRenderer);
#endif
#ifdef G4VIS_USE_DAWNFILE
RegisterGraphicsSystem (new G4DAWNFILE);
#endif
#ifdef G4VIS_USE_OPACS
RegisterGraphicsSystem (new G4Wo);
RegisterGraphicsSystem (new G4Xo);
@@ -138,20 +135,11 @@ void ExN03VisManager::RegisterGraphicsSystems () {
RegisterGraphicsSystem (new G4OpenInventorWin32);
#endif
#ifdef G4VIS_USE_RAYTRACER
RegisterGraphicsSystem (new G4RayTracer);
#endif
#ifdef G4VIS_USE_VRML
RegisterGraphicsSystem (new G4VRML1);
RegisterGraphicsSystem (new G4VRML2);
#endif
#ifdef G4VIS_USE_VRMLFILE
RegisterGraphicsSystem (new G4VRML1File);
RegisterGraphicsSystem (new G4VRML2File);
#endif
if (fVerbose > 0) {
G4cout <<
"\nYou have successfully chosen to use the following graphics systems."
@@ -162,4 +150,4 @@ void ExN03VisManager::RegisterGraphicsSystems () {
#endif
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
@@ -1,6 +1,6 @@
#
# Macro file for the initialization phase of "exampleN03.cc"
# when runing in interactive mode
# when running in interactive mode
#
# Sets some default verbose
#
@@ -15,14 +15,13 @@
# Create a scene handler for a specific graphics system
# (Edit the next line(s) to choose another graphic system)
#
/vis/open DAWNFILE
/vis/open OGLIX
#/vis/open DAWNFILE
#
# draw scene
#
/vis/drawVolume
/vis/viewer/update
/vis/viewer/flush
#
# for drawing the tracks
# (if too many tracks cause core dump => storeTrajectory 0)
#
/tracking/storeTrajectory 1
/vis/scene/endOfEventAction accumulate
+22
View File
@@ -0,0 +1,22 @@
====================================
examples/novice/N03/visTutor/History
====================================
14-11-01 Satoshi Tanaka (exN03VisTutor-V03-02-02)
- exN03Vis8.mac : Batch visualization with the DAWNFILE driver
- exN03Vis9.mac : Multi-page PostScript file generation (old exN03Vis8.mac)
08-11-01 Satoshi Tanaka (exN03VisTutor-V03-02-01a)
- /vis/viewer/viewpointThetaPhi ==> /vis/viewer/set/viewpointThetaPhi
07-11-01 Satoshi Tanaka (exN03VisTutor-V03-02-01)
- Macros are rewritten with /vis/viewer/flush
- Comments are updated.
18-09-01 Satoshi Tanaka (exN03VisTutor-V03-02-00)
- Updation for automatic visualization at Hebden Bridge mini-workshop.
- /vis/viewer/flush and /vis/flushAll are not included yet.
(To be included in the next tag.)
- /vis/drawTree may still require /vis/scene/notifyHandlers.
(John Allison will revise the /vis/drawTree command soon.)
+5 -12
View File
@@ -4,6 +4,7 @@
# AUTHOR(S): Satoshi Tanaka #
# #
# DATE: #
# Sept 08-09, 2001 (at Hebden Bridge, UK) #
# June 20, 2001 #
# #
# CONTENTS: A macro to demonstrate ASCII DTREE #
@@ -16,12 +17,12 @@
# #
# ENVIRONMENTAL VARIABLES (C-MACROS) FOR INSTALLATION: #
# #
# % setenv G4VIS_BUILD_ASCIITREE_DRIVER 1 #
# * Unnecessary #
# #
# ENVIRONMENTAL VARIABLES (C-MACROS) FOR COMPILATION: #
# (See geant4/source/visualization/README for details.) #
# #
# % setenv G4VIS_USE_ASCIITREE 1 #
# * Unnecessary #
# #
# VERBOSE LEVEL: #
# #
@@ -35,16 +36,8 @@
# #
# ADDITIONAL NOTES: #
# * The geometry tree is displayed in the stdout. #
# #
# * The compound command #
# "/vis/drawTree [<physical-volume-name>] [<system>]" #
# is equivalent to the following set of commands: #
# /vis/open system #
# /vis/drawVolume PV-name #
# #
# The PV-name "world" is always means the world volume, #
# whatever its real name, e.g., "World" in example N03, is. #
# #
# * The compound command to visualize geometry tree: #
# /vis/drawTree [<physical-volume-name>] [<system>] #
#######################################################################
# Draw the whole geometry tree
+13 -17
View File
@@ -4,6 +4,7 @@
# AUTHOR(S): Satoshi Tanaka #
# #
# DATE: #
# Sept 08-09, 2001 (at Hebden Bridge, UK) #
# June 20, 2001 #
# #
# CONTENTS: A macro to demonstrate GAG DTREE #
@@ -17,12 +18,12 @@
# #
# ENVIRONMENTAL VARIABLES (C-MACROS) FOR INSTALLATION: #
# #
# % setenv G4VIS_BUILD_GAGTREE_DRIVER 1 #
# * Unnecessary #
# #
# ENVIRONMENTAL VARIABLES (C-MACROS) FOR COMPILATION: #
# (See geant4/source/visualization/README for details.) #
# #
# % setenv G4VIS_USE_GAGTREE 1 #
# * Unnecessary #
# #
# VERBOSE LEVEL: #
# #
@@ -35,33 +36,28 @@
# >= 2: prints solid name and type. #
# #
# ADDITIONAL NOTES: #
# * The geometry tree is displayed in the stdout. #
# #
# * The compound command #
# "/vis/drawTree [<physical-volume-name>] [<system>]" #
# is equivalent to the following set of commands: #
# /vis/open system #
# /vis/drawVolume PV-name #
# #
# The PV-name "world" is always means the world volume, #
# whatever its real name, e.g., "World" in example N03, is. #
# #
# * The geometry tree is displayed in GAG windows stdout. #
# (If you are using the G4 character terminals, the tree is #
# displayed in stdout.) #
# * The compound command to visualize geometry tree: #
# /vis/drawTree [<physical-volume-name>] [<system>] #
#######################################################################
# Draw the whole geometry tree
/vis/drawTree world GAGTree
# Note: "!" means the default argument, i.e., "world"
/vis/drawTree ! GAGTree
# Draw a part of tree
/vis/drawTree Gap GAGTree
# Change the level to display details
/vis/GAGTree/verbose 1
/vis/drawTree world GAGTree
/vis/drawTree ! GAGTree
# Change the level to display details
/vis/GAGTree/verbose 2
/vis/drawTree world GAGTree
/vis/drawTree ! GAGTree
# Change the level to display details
/vis/GAGTree/verbose 10
/vis/drawTree world GAGTree
/vis/drawTree ! GAGTree
+16 -27
View File
@@ -4,6 +4,8 @@
# AUTHOR(S): Satoshi Tanaka #
# #
# DATE: #
# Nov 07, 2001 #
# Sept 08-09, 2001 (at Hebden Bridge, UK) #
# June 20, 2001 #
# November 26, 2000 #
# October 17, 2000 #
@@ -27,13 +29,11 @@
# #
# % setenv OGLHOME ... (e.g. /usr/X11R6) #
# % setenv G4VIS_BUILD_OPENGLX_DRIVER 1 #
# % setenv G4VIS_BUILD_DAWNFILE_DRIVER 1 #
# #
# ENVIRONMENTAL VARIABLES (C-MACROS) FOR COMPILATION: #
# (See geant4/source/visualization/README for details.) #
# #
# % setenv G4VIS_USE_OPENGLX 1 #
# % setenv G4VIS_USE_DAWNFILE 1 #
# #
# ADDITIONAL NOTES: #
# The compound command "/vis/open <vis-driver-name>" #
@@ -48,12 +48,6 @@
# /vis/scene/create #
# /vis/scene/add/volume $1 #
# /vis/sceneHandler/attach #
# /vis/viewer/refresh #
# #
# WARNING: You should execute "/vis/viewer/update" after #
# "/vis/drawVolume" in order to complete visualization #
# when you use post-processin visualization drivers #
# such as the DAWNFILE, VRMLFILE, OpenGL Motif drivers. #
# #
#######################################################################
@@ -64,14 +58,22 @@
# Invoke the OGLIX driver
/vis/open OGLIX
#/vis/open DAWNFILE
# Set camera
/vis/viewer/reset
/vis/viewer/viewpointThetaPhi 70 20
/vis/viewer/set/viewpointThetaPhi 70 20
# Visualize of the whole detector geometry
# Create an empty scene and add the detector geometry to it
/vis/drawVolume
/vis/viewer/update
# The following command "flush"
# the action of the current viewer.
# They are required for the post-processing drivers
# such as DAWNFILE, VRMLFILE, HepRep drivers, etc.
# For OpenGL drivers, these commands are not required
# but harmless even if they are described.
/vis/viewer/flush
#########################################################
# Visualization of events with the DAWNFILE driver
@@ -79,11 +81,6 @@
# * Each visualized view is saved to a file "g4_XX.eps"
# with the "vectorized" PostScript format.
#
# * In order to make the file "g4_XX.eps" printable,
# append the "showpage" PostScript command to the file.
# You can do it with the 4th page of the DAWN GUI panel
# or by editing the EPS file by hand.
#
# * Set an environmental variable if you wish to
# skip DAWN GUI:
# % setenv G4DAWNFILE_VIEWER "dawn -d"
@@ -92,11 +89,8 @@
# Invoke the DAWNFILE driver
/vis/open DAWNFILE
# Create a new scene
/vis/scene/create
# Add the world volume to the current scene
/vis/scene/add/volume
/vis/drawVolume
# Add trajectories to the current scene
# Note: This command is not necessary in exampleN03,
@@ -104,16 +98,11 @@
# described in the event action.
#/vis/scene/add/trajectories
# Attach the current scene handler
# to the current scene (omitable)
/vis/sceneHandler/attach
# Set camera
/vis/viewer/reset
/vis/viewer/zoom 1.5
/vis/viewer/viewpointThetaPhi 70 20
/vis/viewer/set/viewpointThetaPhi 70 20
# Visualize events added to the current scene
/tracking/storeTrajectory 1
/run/beamOn 10
/run/beamOn 3
+54 -53
View File
@@ -4,6 +4,8 @@
# AUTHOR(S): Satoshi Tanaka #
# #
# DATE: #
# Nov 07, 2001 #
# Sept 08-09, 2001 (at Hebden Bridge, UK) #
# June 20, 2001 #
# November 26, 2000 #
# October 17, 2000 #
@@ -26,13 +28,11 @@
# #
# % setenv OGLHOME ... (e.g. /usr/X11R6) #
# % setenv G4VIS_BUILD_OPENGLX_DRIVER 1 #
# % setenv G4VIS_BUILD_DAWNFILE_DRIVER 1 #
# #
# ENVIRONMENTAL VARIABLES (C-MACROS) FOR COMPILATION: #
# (See geant4/source/visualization/README for details.) #
# #
# % setenv G4VIS_USE_OPENGLX 1 #
# % setenv G4VIS_USE_DAWNFILE 1 #
# #
# ADDITIONAL NOTES: #
# The compound command "/vis/open <vis-driver-name>" #
@@ -47,12 +47,6 @@
# /vis/scene/create #
# /vis/scene/add/volume $1 #
# /vis/sceneHandler/attach #
# /vis/viewer/refresh #
# #
# WARNING: You should execute "/vis/viewer/update" after #
# "/vis/drawVolume" in order to complete visualization #
# when you use post-processin visualization drivers #
# such as the DAWNFILE, VRMLFILE, OpenGL Motif drivers. #
# #
#######################################################################
@@ -64,32 +58,23 @@
# Invoke the OGLSX driver
/vis/open OGLSX
# Visualize the detector geometry
# with the defalut camera parameters
/vis/viewer/reset
/vis/drawVolume
/vis/viewer/update
# Slide show (spinning) of the view visualized above.
# Draw 60 frames with steps of 3 degrees.
/vis/viewer/reset
/vis/viewer/viewpointThetaPhi 20 20
/vis/viewer/zoom 0.8
/vis/camera/spin 60 3
# Bird's-eye view of the detector geometry
#
# viewpoint : (theta,phi) = (20*deg, 70*deg),
# zoom factor: 0.8 of the full screen size
# coordinate axes:
# x-axis:red, y-axis:green, z-axis:blue
# origin: (0,0,0), length: 500
#
/vis/viewer/reset
/vis/viewer/viewpointThetaPhi 20 70
/vis/viewer/set/viewpointThetaPhi 20 70
/vis/viewer/zoom 0.8
/vis/drawVolume
/vis/viewer/update
# The following two commands "flush"
# the action of the current viewer.
# They are required for the post-processing drivers
# such as DAWNFILE, VRMLFILE, HepRep drivers, etc.
# For OpenGL drivers, these commands are not required
# but harmless even if they are described.
/vis/viewer/flush
##########################################################
# Visualization with the DAWNFILE driver
@@ -97,11 +82,6 @@
# * Each visualized view is saved to a file "g4_XX.eps"
# with the "vectorized" PostScript format.
#
# * In order to make the file "g4_XX.eps" printable,
# append the "showpage" PostScript command to the file.
# You can do it with the 4th page of the DAWN GUI panel
# or by editing the EPS file by hand.
#
# * Set an environmental variable if you wish to
# skip DAWN GUI:
# % setenv G4DAWNFILE_VIEWER "dawn -d"
@@ -116,31 +96,45 @@
# coordinate axes:
# x-axis:red, y-axis:green, z-axis:blue
# origin: (0,0,0), length: 500
# Scale: length = 10 cm, Orientation = z, color = red,
# placing_algorithm = manual,
# center = (-2.5 cm , -5 cm, 0 cm)
#
/vis/viewer/reset
/vis/viewer/zoom 1.1
/vis/viewer/viewpointThetaPhi 35 35
/vis/scene/create
/vis/scene/add/volume Absorber
/vis/scene/add/axes 0 0 0 500
/vis/scene/add/text 0 0 0 mm 40 -100 -120 Absorber
/vis/sceneHandler/attach
/vis/viewer/refresh
/vis/viewer/set/viewpointThetaPhi 35 35
/vis/drawVolume Absorber
/vis/scene/add/axes 0 0 0 500 mm
/vis/scene/add/text 0 0 0 mm 40 -100 -140 Absorber
/vis/scene/add/scale 10 cm z 1 0 0 manual -2.5 -5 0 cm
# "Flush the action of all the existing viewers.
# Note: You should execute these commands, e.g.,
# when the current scene is modified.
/vis/scene/notifyHandlers
/vis/viewer/update
# FOR FUTURE UPDATION
#/vis/viewer/flushAll
# Bird's-eye view of a detector component (Gap)
/vis/viewer/reset
/vis/viewer/zoom 1.1
/vis/viewer/viewpointThetaPhi 35 35
/vis/scene/create
/vis/scene/add/volume Gap
/vis/scene/add/axes 0 0 0 500
/vis/scene/add/text 0 0 0 mm 50 -100 -120 Gap
/vis/sceneHandler/attach
/vis/viewer/refresh
/vis/viewer/set/viewpointThetaPhi 35 35
/vis/drawVolume Gap
/vis/scene/add/axes 0 0 0 500 mm
/vis/scene/add/text 0 0 0 mm 50 -100 -140 Gap
/vis/scene/add/scale 10 cm z 1 0 0 manual -2.5 -5 0 cm
# "Flush the action of all the existing viewers.
/vis/scene/notifyHandlers
/vis/viewer/update
# Bird's-eye view of the whole detector components
# FOR FUTURE UPDATION
#/vis/viewer/flushAll
# Bird's-eye view of the whole detector components (world)
# * The argument "world" of the command
# "/vis/scene/add/volume" is omittable.
# * "/vis/viewer/set/culling false" makes the invisible
@@ -149,15 +143,22 @@
# in ExN03DetectorConstruction.cc.)
/vis/viewer/reset
/vis/viewer/zoom 1.1
/vis/viewer/viewpointThetaPhi 35 35
/vis/viewer/set/viewpointThetaPhi 35 35
/vis/viewer/set/culling global false
/vis/scene/create
/vis/scene/add/volume
/vis/scene/add/axes 0 0 0 500
/vis/scene/add/text 0 0 0 mm 50 -100 -190 World
/vis/sceneHandler/attach
/vis/viewer/refresh
/vis/drawVolume
/vis/scene/add/axes 0 0 0 500 mm
/vis/scene/add/text 0 0 0 mm 50 -100 -240 World
/vis/scene/add/scale 10 cm x 1 0 0
# "Flush the action of all the existing viewers.
/vis/scene/notifyHandlers
/vis/viewer/update
# FOR FUTURE UPDATION
#/vis/viewer/flushAll
# Make the culling on for next visualization
# Note: You may also use "/vis/viewer/reset"
# for this initialization.
/vis/viewer/set/culling global true
+18 -38
View File
@@ -4,6 +4,8 @@
# AUTHOR(S): Satoshi Tanaka #
# #
# DATE: #
# Nov 07, 2001 #
# Sept 08-09, 2001 (at Hebden Bridge, UK) #
# June 20, 2001 #
# November 26, 2000 #
# October 17, 2000 #
@@ -26,13 +28,11 @@
# #
# % setenv OGLHOME ... (e.g. /usr/X11R6) #
# % setenv G4VIS_BUILD_OPENGLX_DRIVER 1 #
# % setenv G4VIS_BUILD_DAWNFILE_DRIVER 1 #
# #
# ENVIRONMENTAL VARIABLES (C-MACROS) FOR COMPILATION: #
# (See geant4/source/visualization/README for details.) #
# #
# % setenv G4VIS_USE_OPENGLX 1 #
# % setenv G4VIS_USE_DAWNFILE 1 #
# #
# ADDITIONAL NOTES: #
# The compound command "/vis/open <vis-driver-name>" #
@@ -55,15 +55,8 @@
# Invoke the OGLSX driver
/vis/open OGLSX
# Create a new scene
/vis/scene/create
# Add the world volume to the current scene
/vis/scene/add/volume
# Attach the current scene handler
# to the current scene (omitable)
/vis/sceneHandler/attach
# Create an empty scene and add the detector geometry to it
/vis/drawVolume
# Add trajectories to the current scene
# Note: This command is not necessary in exampleN03,
@@ -73,24 +66,14 @@
# Set viewing parameters
# viewpoint : (theta,phi) = (10*deg, 10*deg).
# zoom factor: 0.9 x (full screen size)
# drawing style: surface
/vis/viewer/reset
/vis/viewer/set/style surface
/vis/viewer/viewpointThetaPhi 10 10
/vis/viewer/zoom 0.9
/vis/viewer/set/viewpointThetaPhi 10 10
# Generate one event and visualize it.
/run/beamOn 1
# Slide show (spinning).
# Draw 18 frames with steps of 20 degrees.
# The OGLSX driver stores the previously visualized view
# in the display list. So the particle trajectories are
# also rotated together with the detector geometry.
#
/vis/camera/spin 18 20
##########################################################
# Visualization with the DAWNFILE driver
@@ -98,11 +81,6 @@
# * Each visualized view is saved to a file "g4_XX.eps"
# with the "vectorized" PostScript format.
#
# * In order to make the file "g4_XX.eps" printable,
# append the "showpage" PostScript command to the file
# You can do it with the 4th page of the DAWN GUI panel
# or by editing the EPS file by hand.
#
# * Set an environmental variable if you wish to
# skip DAWN GUI:
# % setenv G4DAWNFILE_VIEWER "dawn -d"
@@ -111,15 +89,8 @@
# Invoke the DAWNFILE driver
/vis/open DAWNFILE
# Create a new scene
/vis/scene/create
# Add the world volume to the current scene
/vis/scene/add/volume
# Attach the current scene handler
# to the current scene (omitable)
/vis/sceneHandler/attach
# Create an empty scene and add the detector geometry to it
/vis/drawVolume
# Add trajectories to the current scene
# Note: This command is not necessary in exampleN03,
@@ -127,13 +98,18 @@
# described in the event action.
#/vis/scene/add/trajectories
# Set the trajectory-accumulation mode to "accumulate".
# Trajectories of each event are accumulated
# and visualized at the end of one run.
/vis/scene/endOfEventAction accumulate
# Visualize many events (bird's eye view)
# viewpoint : (theta,phi) = (45*deg, 45*deg)
# zoom factor: 1.5 x (full screen size)
# drawing style: wireframe
/vis/viewer/reset
/vis/viewer/set/style wireframe
/vis/viewer/viewpointThetaPhi 45 45
/vis/viewer/set/viewpointThetaPhi 45 45
/vis/viewer/zoom 1.5
/run/beamOn 50
@@ -142,6 +118,10 @@
# zoom factor: 5 x (full screen size)
/vis/viewer/reset
/vis/viewer/set/style wireframe
/vis/viewer/viewpointThetaPhi 90 0
/vis/viewer/set/viewpointThetaPhi 90 0
/vis/viewer/zoom 5
/run/beamOn 50
# Reset trajectory-accumulation mode to "refresh" (default)
# Trajectories are visualized at the end of each event.
/vis/scene/endOfEventAction refresh
+23 -30
View File
@@ -4,6 +4,8 @@
# AUTHOR(S): Satoshi Tanaka #
# #
# DATE: #
# Nov 07, 2001 #
# Sept 08-09, 2001 (at Hebden Bridge, UK) #
# June 20, 2001 #
# November 26, 2000 #
# October 17, 2000 #
@@ -26,13 +28,11 @@
# #
# % setenv OGLHOME ... (e.g. /usr/local) #
# % setenv G4VIS_BUILD_OPENGLX_DRIVER 1 #
# % setenv G4VIS_BUILD_DAWNFILE_DRIVER 1 #
# #
# ENVIRONMENTAL VARIABLES (C-MACROS) FOR COMPILATION: #
# (See geant4/source/visualization/README for details.) #
# #
# % setenv G4VIS_USE_OPENGLX 1 #
# % setenv G4VIS_USE_DAWNFILE 1 #
# #
# ADDITIONAL NOTES: #
# The compound command "/vis/open <vis-driver-name>" #
@@ -52,18 +52,11 @@
# Visualization with the OGLIX (OpenGL Immediate X) driver
###########################################################
# Invoke the OGLIX driver
/vis/open OGLIX
# Invoke the OGLSX driver
/vis/open OGLSX
# Create a new scene
/vis/scene/create
# Add the world volume to the current scene
/vis/scene/add/volume
# Attach the current scene handler
# to the current scene (omitable)
/vis/sceneHandler/attach
# Create an empty scene and add the detector geometry to it
/vis/drawVolume
# Add trajectories to the current scene
# Note: This command is not necessary in exampleN03,
@@ -74,7 +67,7 @@
# Bird-eye view of events with
# the hidden-surface drawing style
/vis/viewer/reset
/vis/viewer/viewpointThetaPhi 45 45
/vis/viewer/set/viewpointThetaPhi 45 45
/vis/viewer/set/style surface
/run/beamOn 10
@@ -84,11 +77,6 @@
# * Each visualized view is saved to a file "g4_XX.eps"
# with the "vectorized" PostScript format.
#
# * In order to make the file "g4_XX.eps" printable,
# append the "showpage" PostScript command to the file.
# You can do it with the 4th page of the DAWN GUI panel
# or by editing the EPS file by hand.
#
# * Set an environmental variable if you wish to
# skip DAWN GUI:
# % setenv G4DAWNFILE_VIEWER "dawn -d"
@@ -98,15 +86,8 @@
# Invoke the DAWNFILE driver
/vis/open DAWNFILE
# Create a new scene
/vis/scene/create
# Add the world volume to the current scene
/vis/scene/add/volume
# Attach the current scene handler
# to the current scene (omitable)
/vis/sceneHandler/attach
# Create an empty scene and add the detector geometry to it
/vis/drawVolume
# Add trajectories to the current scene
# Note: This command is not necessary in exampleN03,
@@ -118,9 +99,14 @@
# wireframe drawing style
/vis/viewer/reset
/vis/viewer/zoom 1.5
/vis/viewer/viewpointThetaPhi 45 45
/vis/viewer/set/viewpointThetaPhi 45 45
/vis/viewer/set/style wireframe
/run/beamOn 5
/run/beamOn 3
# Set the trajectory-accumulation mode to "accumulate".
# Trajectories of each event are accumulated
# and visualized at the end of one run.
/vis/scene/endOfEventAction accumulate
# Bird-eye view of events with the
# hidden-surface drawing style
@@ -140,4 +126,11 @@
# invisible : on
# low density : off
# covered daughter: off
#
# Note: You may also use "/vis/viewer/reset"
# for this initialization.
/vis/viewer/set/culling density false
# Reset trajectory-accumulation mode to "refresh" (default)
# Trajectories are visualized at the end of each event.
/vis/scene/endOfEventAction refresh
+21 -29
View File
@@ -4,6 +4,8 @@
# AUTHOR(S): Satoshi Tanaka #
# #
# DATE: #
# Nov 07, 2001 #
# Sept 08-09, 2001 (at Hebden Bridge, UK) #
# June 20, 2001 #
# November 26, 2000 #
# October 17, 2000 #
@@ -23,12 +25,13 @@
# ENVIRONMENTAL VARIABLES (C-MACROS) FOR INSTALLATION: #
# (See geant4/source/visualization/README for details.) #
# #
# % setenv G4VIS_BUILD_DAWNFILE_DRIVER 1 #
# % setenv OGLHOME ... (e.g. /usr/X11R6) #
# % setenv G4VIS_BUILD_OPENGLX_DRIVER 1 #
# #
# ENVIRONMENTAL VARIABLES (C-MACROS) FOR COMPILATION: #
# (See geant4/source/visualization/README for details.) #
# #
# % setenv G4VIS_USE_DAWNFILE 1 #
# % setenv G4VIS_USE_OPENGLX 1 #
# #
# ADDITIONAL NOTES: #
# The compound command "/vis/open <vis-driver-name>" #
@@ -43,13 +46,6 @@
# /vis/scene/create #
# /vis/scene/add/logicalVolume $1 #
# /vis/sceneHandler/attach #
# /vis/viewer/refresh #
# /geometry/print $1 #
# #
# WARNING: You should execute "/vis/viewer/update" after #
# "/vis/specify" in order to complete visualization #
# when you use post-processin visualization drivers #
# such as the DAWNFILE, VRMLFILE, OpenGL Motif drivers. #
# #
#######################################################################
@@ -63,11 +59,11 @@
# Set camera
/vis/viewer/reset
/vis/viewer/zoom 0.9
/vis/viewer/viewpointThetaPhi 35 35
/vis/viewer/set/viewpointThetaPhi 35 35
# Visualize a selected logical volume
/vis/specify Absorber
/vis/viewer/update
/vis/viewer/flush
##########################################################
# Visualization with the DAWNFILE driver
@@ -75,11 +71,6 @@
# * Each visualized view is saved to a file "g4_XX.eps"
# with the "vectorized" PostScript format.
#
# * In order to make the file "g4_XX.eps" printable,
# append the "showpage" PostScript command to the file.
# You can do it with the 4th page of the DAWN GUI panel
# or by editing the EPS file by hand.
#
# * Set an environmental variable if you wish to
# skip DAWN GUI:
# % setenv G4DAWNFILE_VIEWER "dawn -d"
@@ -90,24 +81,25 @@
# Set camera
/vis/viewer/reset
/vis/viewer/zoom 0.9
/vis/viewer/viewpointThetaPhi 35 35
/vis/viewer/set/viewpointThetaPhi 35 35
# Visualize a selected logical volume (1)
/vis/scene/create
/vis/scene/add/logicalVolume Absorber
/vis/scene/add/axes 0 0 0 500
/vis/specify Absorber
/vis/scene/add/axes 0 0 0 500 mm
/vis/scene/add/text 0 0 0 mm 40 -100 -200 LogVol:Absorber
/vis/sceneHandler/attach
/vis/viewer/refresh
/geometry/print
/vis/scene/notifyHandlers
/vis/viewer/update
# FOR FUTURE UPDATION
#/vis/viewer/flushAll
# Visualize a selected logical volume (2)
/vis/scene/create
/vis/scene/add/logicalVolume Gap
/vis/scene/add/axes 0 0 0 500
/vis/specify Gap
/vis/scene/add/axes 0 0 0 500 mm
/vis/scene/add/text 0 0 0 mm 40 -100 -200 LogVol:Gap
/vis/sceneHandler/attach
/vis/viewer/refresh
/geometry/print
/vis/scene/notifyHandlers
/vis/viewer/update
# FOR FUTURE UPDATION
#/vis/viewer/flushAll
+1 -1
View File
@@ -51,7 +51,7 @@
# Bird-eye view of events
/vis/viewer/reset
/vis/viewer/viewpointThetaPhi 45 45
/vis/viewer/set/viewpointThetaPhi 45 45
/run/beamOn 1
+1 -1
View File
@@ -41,7 +41,7 @@
# Bird-eye view of events
/vis/viewer/reset
/vis/viewer/viewpointThetaPhi 45 45
/vis/viewer/set/viewpointThetaPhi 45 45
# Attach the just created Go scene graph to the viewer.
/vis/viewer/update
+12 -22
View File
@@ -4,6 +4,8 @@
# AUTHOR(S): Satoshi Tanaka #
# #
# DATE: #
# Nov 07, 2001 #
# Sept 08-09, 2001 (at Hebden Bridge, UK) #
# June 20, 2001 #
# November 26, 2000 #
# October 17, 2000 #
@@ -19,22 +21,17 @@
# #
# ENVIRONMENTAL VARIABLES (C-MACROS) FOR INSTALLATION: #
# (See geant4/source/visualization/README for details.) #
# #
# % setenv G4VIS_BUILD_VRMLFILE_DRIVER 1 #
# * Unnecessary #
# #
# ENVIRONMENTAL VARIABLES (C-MACROS) FOR COMPILATION: #
# (See geant4/source/visualization/README for details.) #
# #
# % setenv G4VIS_USE_VRMLFILE 1 #
# * Unnecessary #
# #
# RECOMMENDED ENVIRONMENTAL VARIABLES FOR VISUALIZATION: #
# #
# % setenv G4VRMLFILE_VIEWER vrmlview #
# ( The default value is "NONE".) #
# #
# % setenv G4VRMLFILE_MAX_FILE_NUM 100 #
# ( The default value is "1".) #
# #
# ADDITIONAL NOTES: #
# The VRML-file viewer "vrmlview" is obtainable from the following #
# Web site: #
@@ -45,34 +42,27 @@
###################################################
# Visualization of detector geometry and events
# with the VRML2FILE driver.
#
# Note: "/vis/viewer/set/style wireframe" means
# "half-transparent" in the VRML2FILE driver.
# It is a convention of this driver.
###################################################
# Store particle trajactories for visualization
/tracking/storeTrajectory 1
# Invoke the VRML2FILE driver
# Note: The VRML1FILE driver generates VRML 1.0 format files.
# The VRML2FILE driver generates VRML 2.0 format files.
/vis/open VRML2FILE
# Create a new scene
/vis/scene/create
# Create an empty scene and add the detector geometry to it
/vis/drawVolume
# Attach the current scene handler
# to the current scene
/vis/sceneHandler/attach
# Add the world volume to the current scene
/vis/scene/add/volume
# Visualize one event added to the current scene
# Visualize 3 events in the wireframe mode
# Note: The command /vis/scene/add/trajectories
# is not necessary in exampleN03,
# since the C++ method DrawTrajectory() is
# described in the event action.
# Note: "/vis/viewer/set/style wireframe" means
# "half-transparent" in the VRML2FILE driver.
# It is a convention only for this driver.
#/vis/scene/add/trajectories
/vis/viewer/set/style wireframe
/run/beamOn 3
+25 -51
View File
@@ -4,42 +4,34 @@
# AUTHOR(S): Satoshi Tanaka #
# #
# DATE: #
# June 20, 2001 #
# November 26, 2000 #
# October 17, 2000 #
# Nov 14, 2001 #
# #
# CONTENTS: A macro to demonstrate creation of a "multi-page" #
# PostScript file #
# CONTENTS: A macro to demonstrate batch visualization to generate #
# PostScript file with the DAWNFILE driver #
# #
# USAGE: % setenv G4DAWNFILE_MAX_FILE_NUM 1 #
# % setenv DAWN_BATCH a #
# % gmake visclean #
# % setenv DAWN_BATCH 1 #
# % make visclean #
# % $G4BINDIR/exampleN03 #
# Idle> /control/execute visTutor/exN03Vis8.mac #
# Idle> exit #
# % gv g4_00.eps #
# #
# Then click, "<<", ">>" etc to traverse pages #
# % gv g4_00.eps & #
# % gv g4_01.eps & #
# % gv g4_02.eps & #
# #
# REQUIRED PLATFORMS & SOFTWARES: Unix, X-window, #
# DAWN (version 3.85 or after) #
# gv (Ghostview), Tcl/Tk #
# #
# ENVIRONMENTAL VARIABLES (C-MACROS) FOR INSTALLATION: #
# (See geant4/source/visualization/README for details.) #
# #
# % setenv G4VIS_BUILD_DAWNFILE_DRIVER 1 #
# * Unnecessary #
# #
# ENVIRONMENTAL VARIABLES (C-MACROS) FOR COMPILATION: #
# (See geant4/source/visualization/README for details.) #
# #
# % setenv G4VIS_USE_DAWNFILE 1 #
# * Unnecessary #
# #
# ADDITIONAL NOTES: #
# * If you execute this macro plural times, all the views are #
# sequentially appended to the file "g4_00.eps". #
# For example if you execute it two times, a 6-page (3+3 page) #
# PostScript file is made. #
# #
#######################################################################
@@ -47,41 +39,23 @@
# Creation of a multi-page PostScript file with the DAWNFILE driver
####################################################################
# Invoke the DAWNFILE driver
# Invoke the DAWNFILE driver
/vis/open DAWNFILE
# Set viewing parameters
/vis/viewer/reset
/vis/viewer/zoom 0.9
/vis/viewer/viewpointThetaPhi 35 35
# Add the world volume to the current scene
/vis/drawVolume
# Generate page 1: Absorber
/vis/scene/create
/vis/scene/add/volume Absorber
/vis/scene/add/axes 0 0 0 500
/vis/scene/add/text 0 0 0 mm 30 -150 -200 Page1/3:Absorber
/vis/sceneHandler/attach
/vis/viewer/refresh
/vis/viewer/update
# Add trajectories to the current scene
# Note: This command is not necessary in exampleN03,
# since the C++ method DrawTrajectory() is
# described in the event action.
#/vis/scene/add/trajectories
# Generate page 2: Gap
/vis/scene/create
/vis/scene/add/volume Gap
/vis/scene/add/axes 0 0 0 500
/vis/scene/add/text 0 0 0 mm 30 -100 -200 Page2/3:Gap
/vis/sceneHandler/attach
/vis/viewer/refresh
/vis/viewer/update
# Set camera
/vis/viewer/reset
/vis/viewer/zoom 1.5
/vis/viewer/set/viewpointThetaPhi 70 20
# Generate page 3: World
/vis/viewer/set/culling global false
/vis/scene/create
/vis/scene/add/volume
/vis/scene/add/axes 0 0 0 500
/vis/scene/add/text 0 0 0 mm 50 -100 -200 Page3/3:world
/vis/sceneHandler/attach
/vis/viewer/refresh
/vis/viewer/update
# Make the culling on for next visualization
/vis/viewer/set/culling global true
# Visualize events added to the current scene
/tracking/storeTrajectory 1
/run/beamOn 3
@@ -0,0 +1,87 @@
#######################################################################
# MACRO FILE NAME: exN03Vis9.mac #
# #
# AUTHOR(S): Satoshi Tanaka #
# #
# DATE: #
# Nov 14, 2001 (renamed from exN03Vis8.mac) #
# Nov 07, 2001 #
# Sept 08-09, 2001 (at Hebden Bridge, UK) #
# June 20, 2001 #
# November 26, 2000 #
# October 17, 2000 #
# #
# CONTENTS: A macro to demonstrate creation of a "multi-page" #
# PostScript file #
# #
# USAGE: % setenv G4DAWNFILE_MAX_FILE_NUM 1 #
# % setenv DAWN_BATCH a #
# % gmake visclean #
# % $G4BINDIR/exampleN03 #
# Idle> /control/execute visTutor/exN03Vis9.mac #
# Idle> exit #
# % gv g4_00.eps #
# #
# Then click, "<<", ">>" etc to traverse pages #
# #
# REQUIRED PLATFORMS & SOFTWARES: Unix, X-window, #
# DAWN (version 3.85 or after) #
# gv (Ghostview), Tcl/Tk #
# #
# ENVIRONMENTAL VARIABLES (C-MACROS) FOR INSTALLATION: #
# (See geant4/source/visualization/README for details.) #
# #
# * Unnecessary #
# #
# ENVIRONMENTAL VARIABLES (C-MACROS) FOR COMPILATION: #
# (See geant4/source/visualization/README for details.) #
# #
# * Unnecessary #
# #
# ADDITIONAL NOTES: #
# * If you execute this macro plural times, all the views are #
# sequentially appended to the file "g4_00.eps". #
# For example if you execute it two times, a 6-page (3+3 page) #
# PostScript file is made. #
# Unset environmental variables to initialize your environment: #
# #
# % unsetenv G4DAWNFILE_MAX_FILE_NUM #
# % unsetenv DAWN_BATCH #
# #
#######################################################################
####################################################################
# Creation of a multi-page PostScript file with the DAWNFILE driver
####################################################################
# Invoke the DAWNFILE driver
/vis/open DAWNFILE
# Set viewing parameters
/vis/viewer/reset
/vis/viewer/zoom 0.9
/vis/viewer/set/viewpointThetaPhi 35 35
# Generate page 1: Absorber
/vis/drawVolume Absorber
/vis/scene/add/axes 0 0 0 500 mm
/vis/scene/add/text 0 0 0 mm 30 -150 -200 Page1/3:Absorber
/vis/viewer/flush
# Generate page 2: Gap
/vis/drawVolume Gap
/vis/scene/add/axes 0 0 0 500 mm
/vis/scene/add/text 0 0 0 mm 30 -100 -200 Page2/3:Gap
/vis/viewer/flush
# Generate page 3: World
/vis/viewer/set/culling global false
/vis/drawVolume
/vis/scene/add/axes 0 0 0 500 mm
/vis/scene/add/text 0 0 0 mm 50 -100 -200 Page3/3:world
/vis/viewer/flush
# Make the culling on for next visualization
# Note: You may also use "/vis/viewer/reset"
# for this initialization.
/vis/viewer/set/culling global true
+5 -1
View File
@@ -1,4 +1,4 @@
$Id: History,v 1.18 2001/03/06 10:11:20 kurasige Exp $
$Id: History,v 1.19 2001/10/19 05:27:13 stesting Exp $
-------------------------------------------------------------------
=========================================================
@@ -14,6 +14,10 @@ track of all tags.
----------------------------------------------------------
* Reverse chronological order (last date on top), please *
----------------------------------------------------------
Oct 19, 2001 Steve O'Neale (examples-V03-02-00)
- Update reference output
March 07 2001 H.Kurashige (exampleN04-V03-00-07)
- Add G4MuonMinusCaptureAtRest in G4MuonPhysics
@@ -1,5 +1,5 @@
**********************************************
Geant4 version $Name: geant4-03-00-ref-03 $
Geant4 version $Name: geant4-04-00 $
(15-Dec-2000)
Copyright : Geant4 Collaboration
**********************************************
+16 -16
View File
@@ -1,6 +1,6 @@
**********************************************
Geant4 version $Name: geant4-03-01-ref-01 $
(06-Apr-2001)
Geant4 version $Name: geant4-04-00 $
(14-Dec-2001)
Copyright : Geant4 Collaboration
**********************************************
MuonMinusCaptureAtRest is created
@@ -10,7 +10,7 @@ phot: Total cross sections from a parametrisation. Good description from 10 KeV
PhysicsTables from 50 keV to 50 MeV in 100 bins.
compt: Total cross sections from a parametrisation. Good description from 10 KeV to (100/Z) GeV.
Scattered gamma energy according Klein-Nishina.
Scattered gamma energy according Klein-Nishina.
PhysicsTables from 10 keV to 100 GeV in 100 bins.
conv: Total cross sections from a parametrisation. Good description from 1.5 MeV to 100 GeV for all Z.
@@ -32,11 +32,11 @@ msc: Tables of transport mean free paths.
displacement of the particle , too.
PhysicsTables from 100 eV to 100 TeV in 100 bins.
annihil: Total cross section from Heilter formula (annihilation into 2 photons).
annihil: Total cross section from Heilter formula(annihilation into 2 photons).
gamma energies sampled according Heitler
PhysicsTables from 10 keV to 10 TeV in 100 bins.
annihil: Total cross section from Heilter formula (annihilation into 2 photons).
annihil: Total cross section from Heilter formula(annihilation into 2 photons).
gamma energies sampled according Heitler
PhysicsTables from 10 keV to 10 TeV in 100 bins.
@@ -50,10 +50,10 @@ msc: Tables of transport mean free paths.
displacement of the particle , too.
PhysicsTables from 100 eV to 100 TeV in 100 bins.
MuIoni: knock-on electron cross sections .
Good description above the mean excitation energy.
MuIoni: Knock-on electron cross sections .
Good description above the mean excitation energy.
delta ray energy sampled from differential Xsection.
PhysicsTables from 1 keV to 1000 PeV in 150 bins.
PhysicsTables from 1 keV to 1000 PeV in 150 bins.
MuBrems: theoretical cross section
Good description up to 1000 PeV.
@@ -70,21 +70,21 @@ msc: Tables of transport mean free paths.
Stage 0->1 : 1 hits found in the muon chamber.
Stage 1->2 : 1 isolated muon found.
>>> Event 0
10 hits are stored in ExN04TrackerHitsCollection.
11 hits are stored in ExN04TrackerHitsCollection.
4 hits are stored in ExN04CalorimeterHitsCollection.
Total energy deposition in calorimeter : 0.343686 (GeV)
Total energy deposition in calorimeter : 0.337948 (GeV)
1 hits are stored in ExN04MuonHitsCollection.
Stage 0->1 : 1 hits found in the muon chamber.
Stage 1->2 : 1 isolated muon found.
>>> Event 0
13 hits are stored in ExN04TrackerHitsCollection.
16 hits are stored in ExN04CalorimeterHitsCollection.
Total energy deposition in calorimeter : 8.03057 (GeV)
24 hits are stored in ExN04TrackerHitsCollection.
21 hits are stored in ExN04CalorimeterHitsCollection.
Total energy deposition in calorimeter : 20.4442 (GeV)
1 hits are stored in ExN04MuonHitsCollection.
Stage 0->1 : 1 hits found in the muon chamber.
Stage 1->2 : 1 isolated muon found.
>>> Event 1
5 hits are stored in ExN04TrackerHitsCollection.
10 hits are stored in ExN04CalorimeterHitsCollection.
Total energy deposition in calorimeter : 1.07491 (GeV)
24 hits are stored in ExN04TrackerHitsCollection.
34 hits are stored in ExN04CalorimeterHitsCollection.
Total energy deposition in calorimeter : 9.76921 (GeV)
1 hits are stored in ExN04MuonHitsCollection.
+2 -2
View File
@@ -21,8 +21,8 @@
// ********************************************************************
//
//
// $Id: exampleN04.cc,v 1.2.4.2 2001/06/28 20:18:47 gunter Exp $
// GEANT4 tag $Name: $
// $Id: exampleN04.cc,v 1.3 2001/07/11 09:58:24 gunter Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
// --------------------------------------------------------------
+13 -15
View File
@@ -1,6 +1,6 @@
**********************************************
Geant4 version $Name: geant4-03-01-ref-01 $
(06-Apr-2001)
Geant4 version $Name: geant4-04-00 $
(14-Dec-2001)
Copyright : Geant4 Collaboration
**********************************************
MuonMinusCaptureAtRest is created
@@ -10,7 +10,7 @@ phot: Total cross sections from a parametrisation. Good description from 10 KeV
PhysicsTables from 50 keV to 50 MeV in 100 bins.
compt: Total cross sections from a parametrisation. Good description from 10 KeV to (100/Z) GeV.
Scattered gamma energy according Klein-Nishina.
Scattered gamma energy according Klein-Nishina.
PhysicsTables from 10 keV to 100 GeV in 100 bins.
conv: Total cross sections from a parametrisation. Good description from 1.5 MeV to 100 GeV for all Z.
@@ -32,11 +32,11 @@ msc: Tables of transport mean free paths.
displacement of the particle , too.
PhysicsTables from 100 eV to 100 TeV in 100 bins.
annihil: Total cross section from Heilter formula (annihilation into 2 photons).
annihil: Total cross section from Heilter formula(annihilation into 2 photons).
gamma energies sampled according Heitler
PhysicsTables from 10 keV to 10 TeV in 100 bins.
annihil: Total cross section from Heilter formula (annihilation into 2 photons).
annihil: Total cross section from Heilter formula(annihilation into 2 photons).
gamma energies sampled according Heitler
PhysicsTables from 10 keV to 10 TeV in 100 bins.
@@ -50,10 +50,10 @@ msc: Tables of transport mean free paths.
displacement of the particle , too.
PhysicsTables from 100 eV to 100 TeV in 100 bins.
MuIoni: knock-on electron cross sections .
Good description above the mean excitation energy.
MuIoni: Knock-on electron cross sections .
Good description above the mean excitation energy.
delta ray energy sampled from differential Xsection.
PhysicsTables from 1 keV to 1000 PeV in 150 bins.
PhysicsTables from 1 keV to 1000 PeV in 150 bins.
MuBrems: theoretical cross section
Good description up to 1000 PeV.
@@ -67,13 +67,12 @@ msc: Tables of transport mean free paths.
New model of MSC , computes the lateral
displacement of the particle , too.
PhysicsTables from 100 eV to 100 TeV in 100 bins.
#
Stage 0->1 : 1 hits found in the muon chamber.
Stage 1->2 : 1 isolated muon found.
>>> Event 0
149 hits are stored in ExN04TrackerHitsCollection.
46 hits are stored in ExN04CalorimeterHitsCollection.
Total energy deposition in calorimeter : 0.637807 (GeV)
130 hits are stored in ExN04TrackerHitsCollection.
56 hits are stored in ExN04CalorimeterHitsCollection.
Total energy deposition in calorimeter : 0.896933 (GeV)
1 hits are stored in ExN04MuonHitsCollection.
Stage 0->1 : 0 hits found in the muon chamber.
++++++++ event aborted
@@ -86,8 +85,7 @@ Stage 0->1 : 1 hits found in the muon chamber.
Stage 1->2 : 0 isolated muon found.
++++++++ event aborted
>>> Event 2
91 hits are stored in ExN04TrackerHitsCollection.
84 hits are stored in ExN04TrackerHitsCollection.
13 hits are stored in ExN04CalorimeterHitsCollection.
Total energy deposition in calorimeter : 0.334183 (GeV)
Total energy deposition in calorimeter : 0.315841 (GeV)
1 hits are stored in ExN04MuonHitsCollection.
#
@@ -26,19 +26,21 @@
#include "globals.hh"
#include "G4VPVParameterisation.hh"
class G4VPhysicalVolume;
class G4Tubs;
class ExN04CalorimeterParametrisation : public G4VPVParameterisation
{
public:
ExN04CalorimeterParametrisation();
~ExN04CalorimeterParametrisation();
void ComputeTransformation
(const G4int copyNo,G4VPhysicalVolume *physVol) const;
void ComputeDimensions
(G4Tubs & calorimeterLayer, const G4int copyNo,
const G4VPhysicalVolume * physVol) const;
virtual ~ExN04CalorimeterParametrisation();
void ComputeTransformation(const G4int copyNo,
G4VPhysicalVolume *physVol) const;
void ComputeDimensions( G4Tubs & calorimeterLayer,
const G4int copyNo,
const G4VPhysicalVolume * physVol) const;
private:
@@ -21,8 +21,8 @@
// ********************************************************************
//
//
// $Id: ExN04EMPhysics.hh,v 1.1.2.1 2001/06/28 19:07:35 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN04EMPhysics.hh,v 1.2 2001/07/11 09:58:26 gunter Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
// ------------------------------------------------------------
@@ -21,8 +21,8 @@
// ********************************************************************
//
//
// $Id: ExN04GeneralPhysics.hh,v 1.1.2.1 2001/06/28 19:07:35 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN04GeneralPhysics.hh,v 1.2 2001/07/11 09:58:26 gunter Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
// ------------------------------------------------------------
@@ -21,8 +21,8 @@
// ********************************************************************
//
//
// $Id: ExN04HadronPhysics.hh,v 1.1.2.1 2001/06/28 19:07:35 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN04HadronPhysics.hh,v 1.2 2001/07/11 09:58:26 gunter Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
// ------------------------------------------------------------
@@ -21,8 +21,8 @@
// ********************************************************************
//
//
// $Id: ExN04IonPhysics.hh,v 1.1.2.1 2001/06/28 19:07:35 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN04IonPhysics.hh,v 1.2 2001/07/11 09:58:26 gunter Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
// ------------------------------------------------------------
@@ -21,8 +21,8 @@
// ********************************************************************
//
//
// $Id: ExN04MuonPhysics.hh,v 1.2.2.1 2001/06/28 19:07:36 gunter Exp $
// GEANT4 tag $Name: $
// $Id: ExN04MuonPhysics.hh,v 1.3 2001/07/11 09:58:26 gunter Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
// ------------------------------------------------------------
@@ -26,19 +26,21 @@
#include "globals.hh"
#include "G4VPVParameterisation.hh"
class G4VPhysicalVolume;
class G4Tubs;
class ExN04TrackerParametrisation : public G4VPVParameterisation
{
public:
ExN04TrackerParametrisation();
~ExN04TrackerParametrisation();
void ComputeTransformation
(const G4int copyNo,G4VPhysicalVolume *physVol) const;
void ComputeDimensions
(G4Tubs & trackerLayer, const G4int copyNo,
const G4VPhysicalVolume * physVol) const;
virtual ~ExN04TrackerParametrisation();
void ComputeTransformation(const G4int copyNo,
G4VPhysicalVolume *physVol) const;
void ComputeDimensions( G4Tubs & trackerLayer,
const G4int copyNo,
const G4VPhysicalVolume * physVol) const;
private:
@@ -31,10 +31,10 @@
G4Allocator<ExN04CalorimeterHit> ExN04CalorimeterHitAllocator;
ExN04CalorimeterHit::ExN04CalorimeterHit()
{pLogV=NULL;}
{pLogV=0;}
ExN04CalorimeterHit::ExN04CalorimeterHit(G4LogicalVolume* logVol,G4int z,G4int phi)
:pLogV(logVol),ZCellID(z),PhiCellID(phi)
: ZCellID(z), PhiCellID(phi), pLogV(logVol)
{;}
ExN04CalorimeterHit::~ExN04CalorimeterHit()
@@ -94,8 +94,8 @@ G4VPhysicalVolume* ExN04CalorimeterROGeometry::Build()
caloRing_dz, caloRing_sphi, caloRing_dphi);
G4LogicalVolume * caloROcellLog
= new G4LogicalVolume(caloROcellTub, dummyMat, "caloROcellLogical",0,0,0);
G4VPhysicalVolume * caloROcellPhys
= new G4PVReplica("caloROcellPhysical", caloROcellLog, caloROphiDivisionPhys,
// G4VPhysicalVolume * caloROcellPhys =
new G4PVReplica("caloROcellPhysical", caloROcellLog, caloROphiDivisionPhys,
kZAxis, segmentsinZ,2.*caloRing_dz);
@@ -62,7 +62,7 @@ G4bool ExN04CalorimeterSD::ProcessHits(G4Step*aStep,G4TouchableHistory*ROhist)
G4VPhysicalVolume* physVol = ROhist->GetVolume();
//ROhist->MoveUpHistory();
G4VPhysicalVolume* mothVol = ROhist->GetVolume(1);
//G4VPhysicalVolume* mothVol = ROhist->GetVolume(1);
int copyIDinZ = ROhist->GetReplicaNumber();
int copyIDinPhi = ROhist->GetReplicaNumber(1);

Some files were not shown because too many files have changed in this diff Show More