40 #ifdef G4MULTITHREADED 41 #include "G4MTRunManager.hh" 43 #include "G4RunManager.hh" 46 #include "G4UImanager.hh" 47 #include "G4UIExecutive.hh" 48 #include "G4VisExecutive.hh" 50 #include "Randomize.hh" 54 #include "ActionInitialization.hh" 55 #include "SteppingVerbose.hh" 59 int main(
int argc,
char** argv) {
65 G4UIExecutive* ui = 0;
67 ui =
new G4UIExecutive(argc, argv);
71 #ifdef G4MULTITHREADED 72 G4MTRunManager* runManager =
new G4MTRunManager();
73 G4int nThreads = G4Threading::G4GetNumberOfCores();
74 if (argc==3) nThreads = G4UIcommand::ConvertToInt(argv[2]);
75 runManager->SetNumberOfThreads(nThreads);
77 G4VSteppingVerbose::SetInstance(
new SteppingVerbose);
78 G4RunManager* runManager =
new G4RunManager();
83 runManager->SetUserInitialization(detector);
84 runManager->SetUserInitialization(
new PhysicsList());
85 runManager->SetUserInitialization(
new ActionInitialization(detector));
88 G4VisManager* visManager =
new G4VisExecutive;
89 visManager->Initialize();
92 G4UImanager* UI = G4UImanager::GetUIpointer();
96 G4String command =
"/control/execute ";
98 UI->ApplyCommand(command+fileName);
TConfigurablePhysicsList< ModularPhysicsList > PhysicsList
int main(int argc, char **argv)