35#define INCLXX_IN_GEANT4_MODE 1
44#ifdef HAS_BOOST_PROGRAM_OPTIONS
45#include <boost/program_options/options_description.hpp>
46#include <boost/program_options/parsers.hpp>
47#include <boost/program_options/variables_map.hpp>
66 projectileSpecies = proj;
67 projectileKineticEnergy = projectileE;
71#ifdef HAS_BOOST_PROGRAM_OPTIONS
73 const std::string suggestHelpMsg(
"You might want to run `INCLCascade -h' to get a help message.\n");
78 boost::program_options::options_description hiddenOptDesc(
"Hidden options");
79 hiddenOptDesc.add_options()
80 (
"input-file", boost::program_options::value<std::string>(&inputFileName),
"input file")
81 (
"impact-parameter", boost::program_options::value<G4double>(&impactParameter)->default_value(-1.),
"impact parameter")
85 std::stringstream verbosityDescription;
86 verbosityDescription <<
"set verbosity level:\n"
87 <<
" 0: \tquiet, suppress all output messages\n"
88 <<
" " <<
InfoMsg <<
": \tminimal logging\n"
89 <<
" " <<
FatalMsg <<
": \tlog fatal error messages as well\n"
90 <<
" " <<
ErrorMsg <<
": \tlog error messages as well\n"
91 <<
" " <<
WarningMsg <<
": \tlog warning messages as well\n"
92 <<
" " <<
DebugMsg <<
": \tlog debug messages as well\n"
93 <<
" " <<
DataBlockMsg <<
": \tlog data-block messages as well";
95 boost::program_options::options_description genericOptDesc(
"Generic options");
96 genericOptDesc.add_options()
97 (
"help,h",
"produce this help message")
98 (
"version",
"print version string and exit")
102 boost::program_options::options_description runOptDesc(
"Run options");
103 runOptDesc.add_options()
104 (
"title", boost::program_options::value<std::string>(&title)->default_value(
"INCL default run title"),
"run title")
105 (
"output,o", boost::program_options::value<std::string>(&outputFileRoot),
"root for generating output file names. Suffixes (.root, .out, etc.) will be appended to this root. Defaults to the input file name, if given; otherwise, defaults to a string composed of the explicitly specified options")
106 (
"logfile,l", boost::program_options::value<std::string>(&logFileName),
"log file name. Defaults to `<output_root>.log'. Use `-' if you want to redirect logging to stdout")
107 (
"number-shots,N", boost::program_options::value<G4int>(&nShots),
"* number of shots")
108 (
"target,t", boost::program_options::value<std::string>(&targetString),
"* target nuclide. Can be specified as Fe56, 56Fe, Fe-56, 56-Fe, Fe_56, 56_Fe or Fe. If the mass number is omitted, natural target composition is assumed.")
109 (
"projectile,p", boost::program_options::value<std::string>(&projectileString),
"* projectile name:\n"
112 " \tpi+, piplus, pion+, pionplus\n"
113 " \tpi0, pizero, pion0, pionzero\n"
114 " \tpi-, piminus, pion-, pionminus\n"
115 " \td, t, a, deuteron, triton, alpha\n"
116 " \tHe-4, He4, 4He (and so on)\n")
117 (
"energy,E", boost::program_options::value<G4float>(&projectileKineticEnergy),
"* total kinetic energy of the projectile, in MeV")
118 (
"verbose-event", boost::program_options::value<G4int>(&verboseEvent)->default_value(-1),
"request verbose logging for the specified event only")
119 (
"random-seed-1", boost::program_options::value<G4int>(&randomSeed1)->default_value(666),
"first seed for the random-number generator")
120 (
"random-seed-2", boost::program_options::value<G4int>(&randomSeed2)->default_value(777),
"second seed for the random-number generator")
121 (
"inclxx-datafile-path", boost::program_options::value<std::string>(&INCLXXDataFilePath)->default_value(
"./data/"))
122#ifdef INCL_DEEXCITATION_ABLAXX
123 (
"ablav3p-cxx-datafile-path", boost::program_options::value<std::string>(&ablav3pCxxDataFilePath)->default_value(
"./de-excitation/ablaxx/data/G4ABLA3.0/"))
125#ifdef INCL_DEEXCITATION_ABLA07
126 (
"abla07-datafile-path", boost::program_options::value<std::string>(&abla07DataFilePath)->default_value(
"./de-excitation/abla07/upstream/tables/"))
128#ifdef INCL_DEEXCITATION_GEMINIXX
129 (
"geminixx-datafile-path", boost::program_options::value<std::string>(&geminixxDataFilePath)->default_value(
"./de-excitation/geminixx/upstream/"))
131 (
"verbosity,v", boost::program_options::value<G4int>(&verbosity)->default_value(4), verbosityDescription.str().c_str())
135 boost::program_options::options_description physicsOptDesc(
"Physics options");
136 physicsOptDesc.add_options()
137 (
"pauli", boost::program_options::value<std::string>(&pauliString)->default_value(
"strict-statistical"),
"Pauli-blocking algorithm:\n"
138 " \tstrict-statistical (default)\n"
143 (
"cdpp", boost::program_options::value<G4bool>(&
CDPP)->default_value(
true),
"whether to apply CDPP after collisions:\n \ttrue, 1 (default)\n \tfalse, 0")
144 (
"coulomb", boost::program_options::value<std::string>(&coulombString)->default_value(
"non-relativistic"),
"Coulomb-distortion algorithm:\n \tnon-relativistic (default)\n \tnone")
145 (
"potential", boost::program_options::value<std::string>(&potentialString)->default_value(
"isospin-energy"),
"nucleon potential:\n \tisospin-energy-smooth\n \tisospin-energy (default)\n \tisospin\n \tconstant")
146 (
"pion-potential", boost::program_options::value<G4bool>(&pionPotential)->default_value(
"true"),
"whether to use a pion potential:\n \ttrue, 1 (default)\n \tfalse, 0")
147 (
"local-energy-BB", boost::program_options::value<std::string>(&localEnergyBBString)->default_value(
"first-collision"),
"local energy in baryon-baryon collisions:\n \talways\n \tfirst-collision (default)\n \tnever")
148 (
"local-energy-pi", boost::program_options::value<std::string>(&localEnergyPiString)->default_value(
"first-collision"),
"local energy in pi-N collisions and in delta decays:\n \talways\n \tfirst-collision (default)\n \tnever")
149 (
"de-excitation", boost::program_options::value<std::string>(&deExcitationString)->default_value(
"none"),
"which de-excitation model to use:"
150 "\n \tnone (default)"
151#ifdef INCL_DEEXCITATION_ABLAXX
154#ifdef INCL_DEEXCITATION_ABLA07
157#ifdef INCL_DEEXCITATION_SMM
160#ifdef INCL_DEEXCITATION_GEMINIXX
164 (
"cluster-algorithm", boost::program_options::value<std::string>(&clusterAlgorithmString)->default_value(
"intercomparison"),
"clustering algorithm for production of composites:\n \tintercomparison (default)\n \tnone")
165 (
"cluster-max-mass", boost::program_options::value<G4int>(&clusterMaxMass)->default_value(8),
"maximum mass of produced composites:\n \tminimum 2\n \tmaximum 12")
166 (
"back-to-spectator", boost::program_options::value<G4bool>(&backToSpectator)->default_value(
"true"),
"whether to use back-to-spectator:\n \ttrue, 1 (default)\n \tfalse, 0")
167 (
"use-real-masses", boost::program_options::value<G4bool>(&useRealMasses)->default_value(
"true"),
"whether to use real masses for the outgoing particle energies:\n \ttrue, 1 (default)\n \tfalse, 0")
168 (
"separation-energies", boost::program_options::value<std::string>(&separationEnergyString)->default_value(
"INCL"),
"how to assign the separation energies of the INCL nucleus:\n \tINCL (default)\n \treal\n \treal-light")
172 boost::program_options::options_description cmdLineOptions;
173 cmdLineOptions.add(hiddenOptDesc).add(genericOptDesc).add(runOptDesc).add(physicsOptDesc);
176 boost::program_options::options_description configFileOptions;
177 configFileOptions.add(runOptDesc).add(physicsOptDesc);
180 boost::program_options::options_description visibleOptions;
181 visibleOptions.add(genericOptDesc).add(runOptDesc).add(physicsOptDesc);
186 boost::program_options::positional_options_description p;
187 p.add(
"input-file", 1);
191 boost::program_options::command_line_style::default_style &
192 ~boost::program_options::command_line_style::allow_guessing;
195 boost::program_options::variables_map variablesMap;
196 boost::program_options::store(boost::program_options::command_line_parser(argc, argv).
198 options(cmdLineOptions).positional(p).run(), variablesMap);
199 boost::program_options::notify(variablesMap);
203 if(variablesMap.count(
"input-file")) {
204 std::ifstream inputFileStream(inputFileName.c_str());
205 if(!inputFileStream) {
206 std::cerr <<
"Cannot open input file: " << inputFileName << std::endl;
207 std::exit(EXIT_FAILURE);
210 boost::program_options::parsed_options parsedOptions = boost::program_options::parse_config_file(inputFileStream, configFileOptions,
true);
213 std::vector<std::string> unhandledOptions =
214 boost::program_options::collect_unrecognized(parsedOptions.options, boost::program_options::exclude_positional);
215 G4bool ignoreNext =
false;
216 const std::string match =
"-datafile-path";
217 for(std::vector<std::string>::const_iterator i=unhandledOptions.begin(); i!=unhandledOptions.end(); ++i) {
222 if(i->rfind(match) == i->length()-match.length()) {
223 std::cerr <<
"Ignoring unrecognized option " << *i << std::endl;
226 std::cerr <<
"Error: unrecognized option " << *i << std::endl;
227 std::cerr << suggestHelpMsg;
228 std::exit(EXIT_FAILURE);
233 boost::program_options::store(parsedOptions, variablesMap);
234 boost::program_options::notify(variablesMap);
236 inputFileStream.close();
240 std::string configFileName;
241 const char *
const configFileVar = getenv(
"INCLXXRC");
243 configFileName = configFileVar;
245 const char *
const homeDirectoryPointer = getenv(
"HOME");
246 if(homeDirectoryPointer) {
247 std::string homeDirectory(homeDirectoryPointer);
248 configFileName = homeDirectory +
"/.inclxxrc";
250 std::cerr <<
"Could not determine the user's home directory. "
251 <<
"Are you running Linux, Unix or BSD?"<< std::endl;
252 std::exit(EXIT_FAILURE);
256 std::ifstream configFileStream(configFileName.c_str());
257 std::cout <<
"Reading config file " << configFileName << std::endl;
258 if(!configFileStream) {
259 std::cerr <<
"INCL++ config file " << configFileName
260 <<
" not found. Continuing the run regardless."
264 boost::program_options::parsed_options parsedOptions = boost::program_options::parse_config_file(configFileStream, configFileOptions,
true);
265 boost::program_options::store(parsedOptions, variablesMap);
268 std::vector<std::string> unhandledOptions =
269 boost::program_options::collect_unrecognized(parsedOptions.options, boost::program_options::exclude_positional);
270 G4bool ignoreNext =
false;
271 const std::string match =
"-datafile-path";
272 for(std::vector<std::string>::const_iterator i=unhandledOptions.begin(); i!=unhandledOptions.end(); ++i) {
277 if(i->rfind(match) == i->length()-match.length()) {
278 std::cerr <<
"Ignoring unrecognized option " << *i << std::endl;
281 std::cerr <<
"Error: unrecognized option " << *i << std::endl;
282 std::cerr << suggestHelpMsg;
283 std::exit(EXIT_FAILURE);
288 boost::program_options::store(parsedOptions, variablesMap);
289 boost::program_options::notify(variablesMap);
291 configFileStream.close();
298 if(variablesMap.count(
"help")) {
299 std::cout <<
"Usage: INCLCascade [options] <input_file>" << std::endl;
300 std::cout << std::endl <<
"Options marked with a * are compulsory, i.e. they must be provided either on\nthe command line or in the input file." << std::endl;
301 std::cout << visibleOptions << std::endl;
302 std::exit(EXIT_SUCCESS);
306 if(variablesMap.count(
"version")) {
307 std::cout <<
"INCL++ version " <<
getVersionID() << std::endl;
308 std::exit(EXIT_SUCCESS);
313 std::string missingOption(
"");
314 if(!variablesMap.count(
"number-shots"))
315 missingOption =
"number-shots";
316 else if(!variablesMap.count(
"target"))
317 missingOption =
"target";
318 else if(!variablesMap.count(
"projectile"))
319 missingOption =
"projectile";
320 else if(!variablesMap.count(
"energy"))
321 missingOption =
"energy";
322 if(!missingOption.empty()) {
323 std::cerr <<
"Required option " << missingOption <<
" is missing." << std::endl;
324 std::cerr << suggestHelpMsg;
325 std::exit(EXIT_FAILURE);
328 std::cout <<
"Not performing a full run. This had better be a test..." << std::endl;
332 projectileSpecies = ParticleSpecies(projectileString);
334 std::cerr <<
"Error: unrecognized particle type " << projectileString << std::endl;
335 std::cerr << suggestHelpMsg;
336 std::exit(EXIT_FAILURE);
340 if(variablesMap.count(
"target")) {
341 targetSpecies = ParticleSpecies(targetString);
343 std::cerr <<
"Unrecognized target. You specified: " << targetString << std::endl
344 <<
" The target nuclide must be specified in one of the following forms:" << std::endl
345 <<
" Fe56, 56Fe, Fe-56, 56-Fe, Fe_56, 56_Fe, Fe" << std::endl
346 <<
" You can also use IUPAC element names (such as Uuh)." << std::endl;
347 std::cerr << suggestHelpMsg;
348 std::exit(EXIT_FAILURE);
350 if(targetSpecies.
theA==0)
351 naturalTarget =
true;
355 if(variablesMap.count(
"pauli")) {
356 std::string pauliNorm = pauliString;
357 std::transform(pauliNorm.begin(), pauliNorm.end(), pauliNorm.begin(), ::tolower);
358 if(pauliNorm==
"statistical")
360 else if(pauliNorm==
"strict")
362 else if(pauliNorm==
"strict-statistical")
364 else if(pauliNorm==
"global")
366 else if(pauliNorm==
"none")
369 std::cerr <<
"Unrecognized Pauli-blocking algorithm. Must be one of:" << std::endl
370 <<
" strict-statistical (default)" << std::endl
371 <<
" strict" << std::endl
372 <<
" statistical" << std::endl
373 <<
" global" << std::endl
374 <<
" none" << std::endl;
375 std::cerr << suggestHelpMsg;
376 std::exit(EXIT_FAILURE);
381 if(variablesMap.count(
"coulomb")) {
382 std::string coulombNorm = coulombString;
383 std::transform(coulombNorm.begin(), coulombNorm.end(), coulombNorm.begin(), ::tolower);
384 if(coulombNorm==
"non-relativistic")
386 else if(coulombNorm==
"none")
389 std::cerr <<
"Unrecognized Coulomb-distortion algorithm. Must be one of:" << std::endl
390 <<
" non-relativistic-heavy-ion (default)" << std::endl
391 <<
" non-relativistic" << std::endl
392 <<
" none" << std::endl;
393 std::cerr << suggestHelpMsg;
394 std::exit(EXIT_FAILURE);
399 if(variablesMap.count(
"potential")) {
400 std::string potentialNorm = potentialString;
401 std::transform(potentialNorm.begin(), potentialNorm.end(), potentialNorm.begin(), ::tolower);
402 if(potentialNorm==
"isospin-energy-smooth") {
404 }
else if(potentialNorm==
"isospin-energy") {
406 }
else if(potentialNorm==
"isospin")
408 else if(potentialNorm==
"constant")
411 std::cerr <<
"Unrecognized potential type. Must be one of:" << std::endl
412 <<
" isospin-energy-smooth" << std::endl
413 <<
" isospin-energy (default)" << std::endl
414 <<
" isospin" << std::endl
415 <<
" constant" << std::endl;
416 std::cerr << suggestHelpMsg;
417 std::exit(EXIT_FAILURE);
422 if(variablesMap.count(
"local-energy-BB")) {
423 std::string localEnergyBBNorm = localEnergyBBString;
424 std::transform(localEnergyBBNorm.begin(), localEnergyBBNorm.end(), localEnergyBBNorm.begin(), ::tolower);
425 if(localEnergyBBNorm==
"always") {
427 }
else if(localEnergyBBNorm==
"first-collision")
429 else if(localEnergyBBNorm==
"never")
432 std::cerr <<
"Unrecognized local-energy-BB type. Must be one of:" << std::endl
433 <<
" always" << std::endl
434 <<
" first-collision (default)" << std::endl
435 <<
" never" << std::endl;
436 std::cerr << suggestHelpMsg;
437 std::exit(EXIT_FAILURE);
442 if(variablesMap.count(
"local-energy-pi")) {
443 std::string localEnergyPiNorm = localEnergyPiString;
444 std::transform(localEnergyPiNorm.begin(), localEnergyPiNorm.end(), localEnergyPiNorm.begin(), ::tolower);
445 if(localEnergyPiNorm==
"always") {
447 }
else if(localEnergyPiNorm==
"first-collision")
449 else if(localEnergyPiNorm==
"never")
452 std::cerr <<
"Unrecognized local-energy-pi type. Must be one of:" << std::endl
453 <<
" always" << std::endl
454 <<
" first-collision" << std::endl
455 <<
" never (default)" << std::endl;
456 std::cerr << suggestHelpMsg;
457 std::exit(EXIT_FAILURE);
462 if(variablesMap.count(
"de-excitation")) {
463 std::string deExcitationNorm = deExcitationString;
464 std::transform(deExcitationNorm.begin(),
465 deExcitationNorm.end(),
466 deExcitationNorm.begin(), ::tolower);
467 if(deExcitationNorm==
"none")
469#ifdef INCL_DEEXCITATION_ABLAXX
470 else if(deExcitationNorm==
"ablav3p")
471 deExcitationType = DeExcitationABLAv3p;
473#ifdef INCL_DEEXCITATION_ABLA07
474 else if(deExcitationNorm==
"abla07")
475 deExcitationType = DeExcitationABLA07;
477#ifdef INCL_DEEXCITATION_SMM
478 else if(deExcitationNorm==
"smm")
479 deExcitationType = DeExcitationSMM;
481#ifdef INCL_DEEXCITATION_GEMINIXX
482 else if(deExcitationNorm==
"geminixx")
483 deExcitationType = DeExcitationGEMINIXX;
486 std::cerr <<
"Unrecognized de-excitation model. "
487 <<
"Must be one of:" << std::endl
488 <<
" none (default)" << std::endl
489#ifdef INCL_DEEXCITATION_ABLAXX
490 <<
" ABLAv3p" << std::endl
492#ifdef INCL_DEEXCITATION_ABLA07
493 <<
" ABLA07" << std::endl
495#ifdef INCL_DEEXCITATION_SMM
496 <<
" SMM" << std::endl
498#ifdef INCL_DEEXCITATION_GEMINIXX
499 <<
" GEMINIXX" << std::endl
502 std::cerr << suggestHelpMsg;
503 std::exit(EXIT_FAILURE);
510 if(variablesMap.count(
"cluster-algorithm")) {
511 std::string clusterAlgorithmNorm = clusterAlgorithmString;
512 std::transform(clusterAlgorithmNorm.begin(),
513 clusterAlgorithmNorm.end(),
514 clusterAlgorithmNorm.begin(), ::tolower);
515 if(clusterAlgorithmNorm==
"none")
517 else if(clusterAlgorithmNorm==
"intercomparison")
520 std::cerr <<
"Unrecognized cluster algorithm. "
521 <<
"Must be one of:" << std::endl
522 <<
" intercomparison (default)" << std::endl
523 <<
" none" << std::endl;
524 std::cerr << suggestHelpMsg;
525 std::exit(EXIT_FAILURE);
532 if(variablesMap.count(
"cluster-max-mass") && clusterMaxMass < 2 && clusterMaxMass > 12) {
533 std::cerr <<
"Maximum cluster mass outside the allowed range. Must be between 2 and 12 (included)"
536 std::exit(EXIT_FAILURE);
540 if(variablesMap.count(
"separation-energies")) {
541 std::string separationEnergyNorm = separationEnergyString;
542 std::transform(separationEnergyNorm.begin(),
543 separationEnergyNorm.end(),
544 separationEnergyNorm.begin(), ::tolower);
545 if(separationEnergyNorm==
"incl")
547 else if(separationEnergyNorm==
"real")
549 else if(separationEnergyNorm==
"real-light")
552 std::cerr <<
"Unrecognized separation-energies option. "
553 <<
"Must be one of:" << std::endl
554 <<
" INCL (default)" << std::endl
555 <<
" real" << std::endl
556 <<
" real-light" << std::endl;
557 std::cerr << suggestHelpMsg;
558 std::exit(EXIT_FAILURE);
565 if(!variablesMap.count(
"output") && isFullRun) {
567 if(variablesMap.count(
"input-file"))
568 outputFileRoot = inputFileName;
570 std::stringstream outputFileRootStream;
571 outputFileRootStream.precision(0);
572 outputFileRootStream.setf(std::ios::fixed, std::ios::floatfield);
573 outputFileRootStream <<
576 projectileKineticEnergy;
579 typedef boost::program_options::variables_map::const_iterator BPOVMIter;
580 for(BPOVMIter i=variablesMap.begin(); i!=variablesMap.end(); ++i) {
581 std::string
const &name = i->first;
583 if(name!=
"projectile"
586 && name!=
"number-shots"
587 && name!=
"random-seed-1"
588 && name!=
"random-seed-2"
589 && name!=
"inclxx-datafile-path"
590#ifdef INCL_DEEXCITATION_ABLA07
591 && name!=
"abla07-datafile-path"
593#ifdef INCL_DEEXCITATION_ABLAXX
594 && name!=
"ablav3p-cxx-datafile-path"
596#ifdef INCL_DEEXCITATION_GEMINIXX
597 && name!=
"geminixx-datafile-path"
600 boost::program_options::variable_value v = i->second;
602 const std::type_info &type = v.value().type();
603 if(type==
typeid(std::string))
604 outputFileRootStream <<
"_" << name <<
"=" << v.as<std::string>();
606 outputFileRootStream <<
"_" << name <<
"=" << v.as<
G4float>();
607 else if(type==
typeid(
G4int))
608 outputFileRootStream <<
"_" << name <<
"=" << v.as<
G4int>();
609 else if(type==
typeid(
G4bool))
610 outputFileRootStream <<
"_" << name <<
"=" << v.as<
G4bool>();
615 outputFileRoot = outputFileRootStream.str();
620 if(!variablesMap.count(
"logfile"))
621 logFileName = outputFileRoot +
".log";
624 catch(std::exception& e)
626 std::cerr << e.what() <<
"\n";
627 std::cerr << suggestHelpMsg;
628 std::exit(EXIT_FAILURE);
645 title =
"INCL default run title";
647 naturalTarget =
false;
648 projectileString =
"proton";
650 projectileKineticEnergy = 1000.0;
654 pauliString =
"strict-statistical";
657 coulombString =
"non-relativistic";
659 potentialString =
"isospin-energy";
661 pionPotential =
true;
662 localEnergyBBString =
"first-collision";
664 localEnergyPiString =
"first-collision";
666 deExcitationString =
"none";
668 clusterAlgorithmString =
"intercomparison";
671 backToSpectator =
true;
672 useRealMasses =
true;
673 impactParameter = -1.;
674 separationEnergyString =
"INCL";
679 std::stringstream message;
680 message <<
"INCL++ version " <<
getVersionID() << std::endl;
684 message <<
"Projectile: composite, A=" << projectileSpecies.
theA <<
", Z=" << projectileSpecies.
theZ << std::endl;
685 message <<
" energy = " << projectileKineticEnergy << std::endl;
686 if(targetSpecies.
theA>0)
687 message <<
"Target: A = " << targetSpecies.
theA <<
" Z = " << targetSpecies.
theZ << std::endl;
689 message <<
"Target: natural isotopic composition, Z = " << targetSpecies.
theZ << std::endl;
690 message <<
"Number of requested shots = " << nShots << std::endl;
691 return message.str();
695 std::stringstream ss;
696 ss << std::boolalpha;
697 ss <<
"###########################" << std::endl
698 <<
"### Start of input echo ###" << std::endl
699 <<
"###########################" << std::endl << std::endl
700 <<
" # You may re-use this snippet of the log file as an input file!" << std::endl
701 <<
" # Options marked with a * are compulsory." << std::endl
703 <<
"# Run options" << std::endl
704 <<
"title = " << title <<
"\t# run title" << std::endl
705 <<
"output = " << outputFileRoot <<
"\t# root for generating output file names. Suffixes (.root, .out, etc.) will be appended to this root. Defaults to the input file name, if given; otherwise, defaults to a string composed of the explicitly specified options" << std::endl
706 <<
"logfile = " << logFileName <<
"\t# log file name. Defaults to `<output_root>.log'. Use `-' if you want to redirect logging to stdout" << std::endl
707 <<
"number-shots = " << nShots <<
"\t# * number of shots" << std::endl
708 <<
"inclxx-datafile-path = " << INCLXXDataFilePath << std::endl
709#ifdef INCL_DEEXCITATION_ABLAXX
710 <<
"ablav3p-cxx-datafile-path = " << ablav3pCxxDataFilePath << std::endl
712#ifdef INCL_DEEXCITATION_ABLA07
713 <<
"abla07-datafile-path = " << abla07DataFilePath << std::endl
715#ifdef INCL_DEEXCITATION_GEMINIXX
716 <<
"geminixx-datafile-path = " << geminixxDataFilePath << std::endl
718 << std::endl <<
"# Projectile and target definitions" << std::endl
719 <<
"target = " << targetString <<
"\t# * target nuclide. Can be specified as Fe56, 56Fe, Fe-56, 56-Fe, Fe_56, 56_Fe or Fe. If the mass number is omitted, natural target composition is assumed." << std::endl
720 <<
" " <<
"# the target nuclide was parsed as Z=" << targetSpecies.
theZ;
721 if(targetSpecies.
theA>0)
722 ss <<
", A=" << targetSpecies.
theA;
724 ss <<
", natural target";
726 <<
"projectile = " << projectileString <<
"\t# * projectile name (proton, neutron, pi+, pi0, pi-, d, t, a, He-4...)" << std::endl
727 <<
" " <<
"# the projectile nuclide was parsed as Z=" << projectileSpecies.
theZ <<
", A=" << projectileSpecies.
theA << std::endl
728 <<
"energy = " << projectileKineticEnergy <<
"\t# * total kinetic energy of the projectile, in MeV" << std::endl
729 << std::endl <<
"# Physics options " << std::endl
730 <<
"pauli = " << pauliString <<
"\t# Pauli-blocking algorithm. Must be one of: strict-statistical (default), strict, statistical, global, none" << std::endl
731 <<
"cdpp = " <<
CDPP <<
"\t# whether to apply CDPP after collisions" << std::endl
732 <<
"coulomb = " << coulombString <<
"\t# Coulomb-distortion algorithm. Must be one of: non-relativistic (default), none" << std::endl
733 <<
"potential = " << potentialString <<
"\t# nucleon potential. Must be one of: isospin-energy-smooth, isospin-energy (default), isospin, constant" << std::endl
734 <<
"pion-potential = " << pionPotential <<
"\t# whether to use a pion potential" << std::endl
735 <<
"local-energy-BB = " << localEnergyBBString <<
"\t# local energy in baryon-baryon collisions. Must be one of: always, first-collision (default), never" << std::endl
736 <<
"local-energy-pi = " << localEnergyPiString <<
"\t# local energy in pi-N collisions and in delta decays. Must be one of: always, first-collision (default), never" << std::endl
737 <<
"de-excitation = " << deExcitationString <<
"\t # which de-excitation model to use. Must be one of:"
739#ifdef INCL_DEEXCITATION_ABLAXX
742#ifdef INCL_DEEXCITATION_ABLA07
745#ifdef INCL_DEEXCITATION_SMM
748#ifdef INCL_DEEXCITATION_GEMINIXX
752 <<
"cluster-algorithm = " << clusterAlgorithmString <<
"\t# clustering algorithm for production of composites. Must be one of: intercomparison (default), none" << std::endl
753 <<
"cluster-max-mass = " << clusterMaxMass <<
"\t# maximum mass of produced composites. Must be between 2 and 12 (included)" << std::endl
754 <<
"back-to-spectator = " << backToSpectator <<
"\t# whether to use back-to-spectator" << std::endl
755 <<
"use-real-masses = " << useRealMasses <<
"\t# whether to use real masses for the outgoing particle energies" << std::endl
756 <<
"separation-energies = " << separationEnergyString <<
"\t# how to assign the separation energies of the INCL nucleus. Must be one of: INCL (default), real, real-light" << std::endl
757 << std::endl <<
"# Technical options " << std::endl
758 <<
"verbosity = " << verbosity <<
"\t# from 0 (quiet) to 10 (most verbose)" << std::endl
759 <<
"verbose-event = " << verboseEvent <<
"\t# request verbose logging for the specified event only" << std::endl
760 <<
"random-seed-1 = " << randomSeed1 <<
"\t# first seed for the random-number generator" << std::endl
761 <<
"random-seed-2 = " << randomSeed2 <<
"\t# second seed for the random-number generator" << std::endl
762 << std::endl <<
"#########################" << std::endl
763 <<
"### End of input echo ###" << std::endl
764 <<
"#########################" << std::endl;
static std::string const getVersionID()
Get the INCL version ID.
std::string const echo() const
Echo the input options.
~Config()
Default destructor.
Config()
Default constructor.
std::string summary()
Return a summary of the run configuration.
void init()
Initialise the members.
static std::string getName(const ParticleType t)
Get the native INCL name of the particle.
static std::string getShortName(const ParticleType t)
Get the short INCL name of the particle.
@ FirstCollisionLocalEnergy
@ IntercomparisonClusterAlgorithm
@ IsospinEnergySmoothPotential
@ RealForLightSeparationEnergy