Changeset 1337 for trunk/examples/extended/analysis/N03Con
- Timestamp:
- Sep 30, 2010, 2:47:17 PM (14 years ago)
- Location:
- trunk/examples/extended/analysis/N03Con
- Files:
-
- 23 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/examples/extended/analysis/N03Con/GNUmakefile
r807 r1337 1 # $Id: GNUmakefile,v 1. 1 2007/05/26 00:18:27 tkoiExp $1 # $Id: GNUmakefile,v 1.2 2010/01/11 16:22:59 gcosmo Exp $ 2 2 # -------------------------------------------------------------- 3 3 # GNUmakefile for examples module. Gabriele Cosmo, 06/04/98. … … 9 9 10 10 ifndef G4INSTALL 11 G4INSTALL = ../../.. 11 G4INSTALL = ../../../.. 12 12 endif 13 13 -
trunk/examples/extended/analysis/N03Con/History
r807 r1337 15 15 ---------------------------------------------------------- 16 16 17 12-05-10 J. Allison exampleN03Con-V09-03-01 18 - Introduced G4UIExecutive. 19 20 31-03-10 T. Koi exampleN03Con-V09-03-00 21 Update Physics list corresponding to the "exampleN03-V09-03-01" 22 include/ExN03PhysicsList.hh 23 src/ExN03PhysicsList.cc 24 17 25 25-05-07 T. Koi exampleN03Con-V08-03-01 18 26 -
trunk/examples/extended/analysis/N03Con/exampleN03Con.cc
r1230 r1337 25 25 // 26 26 // 27 // $Id: exampleN03Con.cc,v 1. 2 2007/05/26 00:24:09 tkoiExp $28 // GEANT4 tag $Name: geant4-09-0 3-cand-01 $27 // $Id: exampleN03Con.cc,v 1.4 2010/05/12 12:45:06 allison Exp $ 28 // GEANT4 tag $Name: geant4-09-04-beta-01 $ 29 29 // 30 30 // … … 34 34 #include "G4RunManager.hh" 35 35 #include "G4UImanager.hh" 36 #include "G4UIterminal.hh"37 #include "G4UItcsh.hh"38 39 #ifdef G4UI_USE_XM40 #include "G4UIXm.hh"41 #endif42 43 #ifdef G4UI_USE_WIN3244 #include "G4UIWin32.hh"45 #endif46 36 47 37 #include "Randomize.hh" … … 49 39 #ifdef G4VIS_USE 50 40 #include "G4VisExecutive.hh" 41 #endif 42 43 #ifdef G4UI_USE 44 #include "G4UIExecutive.hh" 51 45 #endif 52 46 … … 84 78 runManager->SetUserInitialization(physics); 85 79 86 G4UIsession* session=0;87 88 if (argc==1) // Define UI session for interactive mode.89 {90 // G4UIterminal is a (dumb) terminal91 //92 #if defined(G4UI_USE_XM)93 session = new G4UIXm(argc,argv);94 #elif defined(G4UI_USE_WIN32)95 session = new G4UIWin32();96 #elif defined(G4UI_USE_TCSH)97 session = new G4UIterminal(new G4UItcsh);98 #else99 session = new G4UIterminal();100 #endif101 }102 103 #ifdef G4VIS_USE104 // Visualization manager105 //106 G4VisManager* visManager = new G4VisExecutive;107 visManager->Initialize();108 #endif109 110 80 // Set user action classes 111 81 // … … 127 97 runManager->Initialize(); 128 98 99 #ifdef G4VIS_USE 100 // Visualization manager 101 // 102 G4VisManager* visManager = new G4VisExecutive; 103 visManager->Initialize(); 104 #endif 105 129 106 // Get the pointer to the User Interface manager 130 107 // 131 G4UImanager* UI = G4UImanager::GetUIpointer();108 G4UImanager* UImanager = G4UImanager::GetUIpointer(); 132 109 133 if ( session) // Define UI session for interactivemode110 if (argc!=1) // batch mode 134 111 { 135 // G4UIterminal is a (dumb) terminal136 //137 // UI->ApplyCommand("/control/execute vis.mac");138 #if defined(G4UI_USE_XM) || defined(G4UI_USE_WIN32)139 // Customize the G4UIXm,Win32 menubar with a macro file140 //141 // UI->ApplyCommand("/control/execute visTutor/gui.mac");142 #endif143 session->SessionStart();144 delete session;145 }146 else // Batch mode147 {148 112 #ifdef G4VIS_USE 149 113 visManager->SetVerboseLevel("quiet"); … … 151 115 G4String command = "/control/execute "; 152 116 G4String fileName = argv[1]; 153 UI->ApplyCommand(command+fileName); 117 UImanager->ApplyCommand(command+fileName); 118 } 119 else 120 { // interactive mode : define UI session 121 #ifdef G4UI_USE 122 G4UIExecutive* ui = new G4UIExecutive(argc, argv); 123 ui->SessionStart(); 124 delete ui; 125 #endif 154 126 } 155 127 -
trunk/examples/extended/analysis/N03Con/include/ExN03DetectorConstruction.hh
r1230 r1337 26 26 // 27 27 // $Id: ExN03DetectorConstruction.hh,v 1.1 2007/05/26 00:18:27 tkoi Exp $ 28 // GEANT4 tag $Name: geant4-09-0 3-cand-01 $28 // GEANT4 tag $Name: geant4-09-04-beta-01 $ 29 29 // 30 30 // -
trunk/examples/extended/analysis/N03Con/include/ExN03DetectorMessenger.hh
r1230 r1337 26 26 // 27 27 // $Id: ExN03DetectorMessenger.hh,v 1.1 2007/05/26 00:18:27 tkoi Exp $ 28 // GEANT4 tag $Name: geant4-09-0 3-cand-01 $28 // GEANT4 tag $Name: geant4-09-04-beta-01 $ 29 29 // 30 30 // -
trunk/examples/extended/analysis/N03Con/include/ExN03EventAction.hh
r1230 r1337 26 26 // 27 27 // $Id: ExN03EventAction.hh,v 1.1 2007/05/26 00:18:27 tkoi Exp $ 28 // GEANT4 tag $Name: geant4-09-0 3-cand-01 $28 // GEANT4 tag $Name: geant4-09-04-beta-01 $ 29 29 // 30 30 // -
trunk/examples/extended/analysis/N03Con/include/ExN03EventActionMessenger.hh
r1230 r1337 26 26 // 27 27 // $Id: ExN03EventActionMessenger.hh,v 1.1 2007/05/26 00:18:27 tkoi Exp $ 28 // GEANT4 tag $Name: geant4-09-0 3-cand-01 $28 // GEANT4 tag $Name: geant4-09-04-beta-01 $ 29 29 // 30 30 // -
trunk/examples/extended/analysis/N03Con/include/ExN03PhysicsList.hh
r1230 r1337 25 25 // 26 26 // 27 // $Id: ExN03PhysicsList.hh,v 1. 1 2007/05/26 00:18:27tkoi Exp $28 // GEANT4 tag $Name: geant4-09-0 3-cand-01 $27 // $Id: ExN03PhysicsList.hh,v 1.2 2010/03/31 21:43:48 tkoi Exp $ 28 // GEANT4 tag $Name: geant4-09-04-beta-01 $ 29 29 // 30 30 // … … 43 43 class ExN03PhysicsList: public G4VUserPhysicsList 44 44 { 45 46 47 ~ExN03PhysicsList();45 public: 46 ExN03PhysicsList(); 47 virtual ~ExN03PhysicsList(); 48 48 49 protected: 50 // Construct particle and physics 51 void ConstructParticle(); 52 void ConstructProcess(); 49 // Construct particle and physics 50 void ConstructParticle(); 51 void ConstructProcess(); 53 52 54 void SetCuts(); 53 void SetCuts(); 54 55 private: 55 56 56 57 protected: 58 // these methods Construct particles 59 void ConstructBosons(); 60 void ConstructLeptons(); 61 void ConstructMesons(); 62 void ConstructBaryons(); 63 64 protected: 65 // these methods Construct physics processes and register them 66 void ConstructGeneral(); 67 void ConstructEM(); 57 // these methods Construct physics processes and register them 58 void ConstructDecay(); 59 void ConstructEM(); 68 60 }; 69 61 -
trunk/examples/extended/analysis/N03Con/include/ExN03PrimaryGeneratorAction.hh
r1230 r1337 26 26 // 27 27 // $Id: ExN03PrimaryGeneratorAction.hh,v 1.1 2007/05/26 00:18:27 tkoi Exp $ 28 // GEANT4 tag $Name: geant4-09-0 3-cand-01 $28 // GEANT4 tag $Name: geant4-09-04-beta-01 $ 29 29 // 30 30 // -
trunk/examples/extended/analysis/N03Con/include/ExN03PrimaryGeneratorMessenger.hh
r1230 r1337 26 26 // 27 27 // $Id: ExN03PrimaryGeneratorMessenger.hh,v 1.1 2007/05/26 00:18:27 tkoi Exp $ 28 // GEANT4 tag $Name: geant4-09-0 3-cand-01 $28 // GEANT4 tag $Name: geant4-09-04-beta-01 $ 29 29 // 30 30 // -
trunk/examples/extended/analysis/N03Con/include/ExN03RunAction.hh
r1230 r1337 26 26 // 27 27 // $Id: ExN03RunAction.hh,v 1.1 2007/05/26 00:18:28 tkoi Exp $ 28 // GEANT4 tag $Name: geant4-09-0 3-cand-01 $28 // GEANT4 tag $Name: geant4-09-04-beta-01 $ 29 29 // 30 30 // -
trunk/examples/extended/analysis/N03Con/include/ExN03SteppingAction.hh
r1230 r1337 26 26 // 27 27 // $Id: ExN03SteppingAction.hh,v 1.1 2007/05/26 00:18:28 tkoi Exp $ 28 // GEANT4 tag $Name: geant4-09-0 3-cand-01 $28 // GEANT4 tag $Name: geant4-09-04-beta-01 $ 29 29 // 30 30 // -
trunk/examples/extended/analysis/N03Con/include/ExN03SteppingVerbose.hh
r1230 r1337 26 26 // 27 27 // $Id: ExN03SteppingVerbose.hh,v 1.1 2007/05/26 00:18:28 tkoi Exp $ 28 // GEANT4 tag $Name: geant4-09-0 3-cand-01 $28 // GEANT4 tag $Name: geant4-09-04-beta-01 $ 29 29 // 30 30 // -
trunk/examples/extended/analysis/N03Con/src/ExN03DetectorConstruction.cc
r1230 r1337 26 26 // 27 27 // $Id: ExN03DetectorConstruction.cc,v 1.1 2007/05/26 00:18:28 tkoi Exp $ 28 // GEANT4 tag $Name: geant4-09-0 3-cand-01 $28 // GEANT4 tag $Name: geant4-09-04-beta-01 $ 29 29 // 30 30 // -
trunk/examples/extended/analysis/N03Con/src/ExN03DetectorMessenger.cc
r1230 r1337 26 26 // 27 27 // $Id: ExN03DetectorMessenger.cc,v 1.1 2007/05/26 00:18:28 tkoi Exp $ 28 // GEANT4 tag $Name: geant4-09-0 3-cand-01 $28 // GEANT4 tag $Name: geant4-09-04-beta-01 $ 29 29 // 30 30 // -
trunk/examples/extended/analysis/N03Con/src/ExN03EventAction.cc
r1230 r1337 26 26 // 27 27 // $Id: ExN03EventAction.cc,v 1.1 2007/05/26 00:18:28 tkoi Exp $ 28 // GEANT4 tag $Name: geant4-09-0 3-cand-01 $28 // GEANT4 tag $Name: geant4-09-04-beta-01 $ 29 29 // 30 30 // -
trunk/examples/extended/analysis/N03Con/src/ExN03EventActionMessenger.cc
r1230 r1337 26 26 // 27 27 // $Id: ExN03EventActionMessenger.cc,v 1.1 2007/05/26 00:18:28 tkoi Exp $ 28 // GEANT4 tag $Name: geant4-09-0 3-cand-01 $28 // GEANT4 tag $Name: geant4-09-04-beta-01 $ 29 29 // 30 30 // -
trunk/examples/extended/analysis/N03Con/src/ExN03PhysicsList.cc
r1230 r1337 25 25 // 26 26 // 27 // $Id: ExN03PhysicsList.cc,v 1. 1 2007/05/26 00:18:28 tkoi Exp $28 // GEANT4 tag $Name: geant4-09-0 3-cand-01 $27 // $Id: ExN03PhysicsList.cc,v 1.2 2010/03/31 21:43:48 tkoi Exp $ 28 // GEANT4 tag $Name: geant4-09-04-beta-01 $ 29 29 // 30 30 // … … 36 36 37 37 #include "G4ProcessManager.hh" 38 #include "G4ParticleTypes.hh" 38 39 #include "G4BosonConstructor.hh" 40 #include "G4LeptonConstructor.hh" 41 #include "G4MesonConstructor.hh" 42 #include "G4BosonConstructor.hh" 43 #include "G4BaryonConstructor.hh" 44 #include "G4IonConstructor.hh" 39 45 40 46 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... … … 42 48 ExN03PhysicsList::ExN03PhysicsList(): G4VUserPhysicsList() 43 49 { 44 defaultCutValue = 1.0*mm;45 SetVerboseLevel(1);50 defaultCutValue = 1.0*mm; 51 SetVerboseLevel(1); 46 52 } 47 53 … … 60 66 // created in the program. 61 67 62 ConstructBosons(); 63 ConstructLeptons(); 64 ConstructMesons(); 65 ConstructBaryons(); 66 } 67 68 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 69 70 void ExN03PhysicsList::ConstructBosons() 71 { 72 // pseudo-particles 73 G4Geantino::GeantinoDefinition(); 74 G4ChargedGeantino::ChargedGeantinoDefinition(); 75 76 // gamma 77 G4Gamma::GammaDefinition(); 78 79 // optical photon 80 G4OpticalPhoton::OpticalPhotonDefinition(); 81 } 82 83 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 84 85 void ExN03PhysicsList::ConstructLeptons() 86 { 87 // leptons 88 G4Electron::ElectronDefinition(); 89 G4Positron::PositronDefinition(); 90 G4MuonPlus::MuonPlusDefinition(); 91 G4MuonMinus::MuonMinusDefinition(); 92 93 G4NeutrinoE::NeutrinoEDefinition(); 94 G4AntiNeutrinoE::AntiNeutrinoEDefinition(); 95 G4NeutrinoMu::NeutrinoMuDefinition(); 96 G4AntiNeutrinoMu::AntiNeutrinoMuDefinition(); 97 } 98 99 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 100 101 void ExN03PhysicsList::ConstructMesons() 102 { 103 // mesons 104 G4PionPlus::PionPlusDefinition(); 105 G4PionMinus::PionMinusDefinition(); 106 G4PionZero::PionZeroDefinition(); 107 G4Eta::EtaDefinition(); 108 G4EtaPrime::EtaPrimeDefinition(); 109 G4KaonPlus::KaonPlusDefinition(); 110 G4KaonMinus::KaonMinusDefinition(); 111 G4KaonZero::KaonZeroDefinition(); 112 G4AntiKaonZero::AntiKaonZeroDefinition(); 113 G4KaonZeroLong::KaonZeroLongDefinition(); 114 G4KaonZeroShort::KaonZeroShortDefinition(); 115 } 116 117 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 118 119 void ExN03PhysicsList::ConstructBaryons() 120 { 121 // barions 122 G4Proton::ProtonDefinition(); 123 G4AntiProton::AntiProtonDefinition(); 124 G4Neutron::NeutronDefinition(); 125 G4AntiNeutron::AntiNeutronDefinition(); 126 } 127 68 G4BosonConstructor pBosonConstructor; 69 pBosonConstructor.ConstructParticle(); 70 71 G4LeptonConstructor pLeptonConstructor; 72 pLeptonConstructor.ConstructParticle(); 73 74 G4MesonConstructor pMesonConstructor; 75 pMesonConstructor.ConstructParticle(); 76 77 G4BaryonConstructor pBaryonConstructor; 78 pBaryonConstructor.ConstructParticle(); 79 80 G4IonConstructor pIonConstructor; 81 pIonConstructor.ConstructParticle(); 82 } 128 83 129 84 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... … … 133 88 AddTransportation(); 134 89 ConstructEM(); 135 Construct General();90 ConstructDecay(); 136 91 } 137 92 … … 142 97 #include "G4PhotoElectricEffect.hh" 143 98 144 #include "G4MultipleScattering.hh" 145 99 #include "G4eMultipleScattering.hh" 146 100 #include "G4eIonisation.hh" 147 101 #include "G4eBremsstrahlung.hh" 148 102 #include "G4eplusAnnihilation.hh" 149 103 104 #include "G4MuMultipleScattering.hh" 150 105 #include "G4MuIonisation.hh" 151 106 #include "G4MuBremsstrahlung.hh" 152 107 #include "G4MuPairProduction.hh" 153 108 109 #include "G4hMultipleScattering.hh" 154 110 #include "G4hIonisation.hh" 111 #include "G4hBremsstrahlung.hh" 112 #include "G4hPairProduction.hh" 113 114 #include "G4ionIonisation.hh" 155 115 156 116 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... … … 172 132 } else if (particleName == "e-") { 173 133 //electron 174 pmanager->AddProcess(new G4 MultipleScattering,-1, 1,1);175 pmanager->AddProcess(new G4eIonisation, -1, 2,2);176 pmanager->AddProcess(new G4eBremsstrahlung, -1, 3,3);134 pmanager->AddProcess(new G4eMultipleScattering,-1, 1, 1); 135 pmanager->AddProcess(new G4eIonisation, -1, 2, 2); 136 pmanager->AddProcess(new G4eBremsstrahlung, -1, 3, 3); 177 137 178 138 } else if (particleName == "e+") { 179 139 //positron 180 pmanager->AddProcess(new G4 MultipleScattering,-1, 1,1);181 pmanager->AddProcess(new G4eIonisation, -1, 2,2);182 pmanager->AddProcess(new G4eBremsstrahlung, -1, 3,3);183 pmanager->AddProcess(new G4eplusAnnihilation, 0,-1,4);184 140 pmanager->AddProcess(new G4eMultipleScattering,-1, 1, 1); 141 pmanager->AddProcess(new G4eIonisation, -1, 2, 2); 142 pmanager->AddProcess(new G4eBremsstrahlung, -1, 3, 3); 143 pmanager->AddProcess(new G4eplusAnnihilation, 0,-1, 4); 144 185 145 } else if( particleName == "mu+" || 186 146 particleName == "mu-" ) { 187 147 //muon 188 pmanager->AddProcess(new G4MultipleScattering,-1, 1,1); 189 pmanager->AddProcess(new G4MuIonisation, -1, 2,2); 190 pmanager->AddProcess(new G4MuBremsstrahlung, -1, 3,3); 191 pmanager->AddProcess(new G4MuPairProduction, -1, 4,4); 148 pmanager->AddProcess(new G4MuMultipleScattering,-1, 1, 1); 149 pmanager->AddProcess(new G4MuIonisation, -1, 2, 2); 150 pmanager->AddProcess(new G4MuBremsstrahlung, -1, 3, 3); 151 pmanager->AddProcess(new G4MuPairProduction, -1, 4, 4); 152 153 } else if( particleName == "proton" || 154 particleName == "pi-" || 155 particleName == "pi+" ) { 156 //proton 157 pmanager->AddProcess(new G4hMultipleScattering, -1, 1, 1); 158 pmanager->AddProcess(new G4hIonisation, -1, 2, 2); 159 pmanager->AddProcess(new G4hBremsstrahlung, -1, 3, 3); 160 pmanager->AddProcess(new G4hPairProduction, -1, 4, 4); 192 161 193 } else if ((!particle->IsShortLived()) && 162 } else if( particleName == "alpha" || 163 particleName == "He3" ) { 164 //alpha 165 pmanager->AddProcess(new G4hMultipleScattering, -1, 1, 1); 166 pmanager->AddProcess(new G4ionIonisation, -1, 2, 2); 167 168 } else if( particleName == "GenericIon" ) { 169 //Ions 170 pmanager->AddProcess(new G4hMultipleScattering, -1, 1, 1); 171 pmanager->AddProcess(new G4ionIonisation, -1, 2, 2); 172 173 } else if ((!particle->IsShortLived()) && 194 174 (particle->GetPDGCharge() != 0.0) && 195 175 (particle->GetParticleName() != "chargedgeantino")) { 196 176 //all others charged particles except geantino 197 pmanager->AddProcess(new G4 MultipleScattering,-1, 1,1);198 pmanager->AddProcess(new G4hIonisation, -1, 2,2);199 } 177 pmanager->AddProcess(new G4hMultipleScattering,-1, 1, 1); 178 pmanager->AddProcess(new G4hIonisation, -1, 2, 2); 179 } 200 180 } 201 181 } … … 205 185 #include "G4Decay.hh" 206 186 207 void ExN03PhysicsList::Construct General()187 void ExN03PhysicsList::ConstructDecay() 208 188 { 209 189 // Add Decay Process 210 190 G4Decay* theDecayProcess = new G4Decay(); 211 191 theParticleIterator->reset(); 212 192 while( (*theParticleIterator)() ){ … … 237 217 SetCutValue(defaultCutValue, "e-"); 238 218 SetCutValue(defaultCutValue, "e+"); 219 SetCutValue(defaultCutValue, "proton"); 239 220 240 221 if (verboseLevel>0) DumpCutValuesTable(); -
trunk/examples/extended/analysis/N03Con/src/ExN03PrimaryGeneratorAction.cc
r1230 r1337 26 26 // 27 27 // $Id: ExN03PrimaryGeneratorAction.cc,v 1.1 2007/05/26 00:18:28 tkoi Exp $ 28 // GEANT4 tag $Name: geant4-09-0 3-cand-01 $28 // GEANT4 tag $Name: geant4-09-04-beta-01 $ 29 29 // 30 30 // -
trunk/examples/extended/analysis/N03Con/src/ExN03PrimaryGeneratorMessenger.cc
r1230 r1337 26 26 // 27 27 // $Id: ExN03PrimaryGeneratorMessenger.cc,v 1.1 2007/05/26 00:18:28 tkoi Exp $ 28 // GEANT4 tag $Name: geant4-09-0 3-cand-01 $28 // GEANT4 tag $Name: geant4-09-04-beta-01 $ 29 29 // 30 30 // -
trunk/examples/extended/analysis/N03Con/src/ExN03RunAction.cc
r1230 r1337 26 26 // 27 27 // $Id: ExN03RunAction.cc,v 1.1 2007/05/26 00:18:28 tkoi Exp $ 28 // GEANT4 tag $Name: geant4-09-0 3-cand-01 $28 // GEANT4 tag $Name: geant4-09-04-beta-01 $ 29 29 // 30 30 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... -
trunk/examples/extended/analysis/N03Con/src/ExN03SteppingAction.cc
r1230 r1337 26 26 // 27 27 // $Id: ExN03SteppingAction.cc,v 1.1 2007/05/26 00:18:28 tkoi Exp $ 28 // GEANT4 tag $Name: geant4-09-0 3-cand-01 $28 // GEANT4 tag $Name: geant4-09-04-beta-01 $ 29 29 // 30 30 // -
trunk/examples/extended/analysis/N03Con/src/ExN03SteppingVerbose.cc
r1230 r1337 26 26 // 27 27 // $Id: ExN03SteppingVerbose.cc,v 1.1 2007/05/26 00:18:28 tkoi Exp $ 28 // GEANT4 tag $Name: geant4-09-0 3-cand-01 $28 // GEANT4 tag $Name: geant4-09-04-beta-01 $ 29 29 // 30 30 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
Note: See TracChangeset
for help on using the changeset viewer.