29 #ifdef G4MULTITHREADED 30 #include "G4MTRunManager.hh" 32 #include "G4RunManager.hh" 35 #include "G4UImanager.hh" 36 #include "G4UIterminal.hh" 37 #include "G4UItcsh.hh" 39 #include "ActionInitialization.hh" 43 int main(
int argc,
char** argv) {
47 G4Random::setTheEngine(
new CLHEP::RanecuEngine);
51 #ifdef G4MULTITHREADED 52 G4MTRunManager* runManager =
new G4MTRunManager;
59 runManager->SetNumberOfThreads(1);
63 G4RunManager* runManager =
new G4RunManager;
72 runManager->SetUserInitialization(detector);
78 runManager->SetUserInitialization(
new ActionInitialization(detector));
82 runManager->Initialize();
86 G4UImanager* UImanager = G4UImanager::GetUIpointer();
91 G4UIsession *
session =
new G4UIterminal();
93 G4UIsession * session =
new G4UIterminal(
new G4UItcsh);
95 UImanager->ApplyCommand(
"/control/execute default.mac");
96 session->SessionStart();
101 G4String command =
"/control/execute ";
103 UImanager->ApplyCommand(command+fileName);
static G4UIterminal * session
int main(int argc, char **argv)