31 #ifdef G4MULTITHREADED 32 #include "G4MTRunManager.hh" 34 #include "G4RunManager.hh" 36 #include "G4ScoringManager.hh" 37 #include "G4UImanager.hh" 40 #include "G4VisExecutive.hh" 44 #include "G4UIExecutive.hh" 47 #include "RE04ActionInitialization.hh" 48 #include "RE04DetectorConstruction.hh" 49 #include "RE04ParallelWorldConstruction.hh" 51 #include "FTFP_BERT.hh" 52 #include "G4ParallelWorldPhysics.hh" 54 int main(
int argc,
char** argv)
58 #ifdef G4MULTITHREADED 59 G4MTRunManager * runManager =
new G4MTRunManager;
62 G4RunManager * runManager =
new G4RunManager;
65 G4ScoringManager::GetScoringManager();
67 G4String paraWorldName =
"ParallelWorld";
71 RE04DetectorConstruction* realWorld =
new RE04DetectorConstruction;
72 RE04ParallelWorldConstruction* parallelWorld
73 =
new RE04ParallelWorldConstruction(paraWorldName);
74 realWorld->RegisterParallelWorld(parallelWorld);
75 runManager->SetUserInitialization(realWorld);
77 G4VModularPhysicsList* physicsList =
new FTFP_BERT;
78 physicsList->RegisterPhysics
79 (
new G4ParallelWorldPhysics(paraWorldName,
true));
80 runManager->SetUserInitialization(physicsList);
84 runManager->SetUserInitialization(
new RE04ActionInitialization);
89 G4VisManager* visManager =
new G4VisExecutive;
90 visManager->Initialize();
95 runManager->Initialize();
99 G4UImanager* pUImanager = G4UImanager::GetUIpointer();
104 G4UIExecutive * ui =
new G4UIExecutive(argc,argv);
106 pUImanager->ApplyCommand(
"/control/execute vis.mac");
114 G4String command =
"/control/execute ";
116 pUImanager->ApplyCommand(command+fileName);
int main(int argc, char **argv)