File indexing completed on 2025-01-18 09:58:25
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014
0015
0016
0017
0018
0019
0020
0021
0022
0023
0024
0025
0026
0027
0028
0029
0030
0031
0032
0033
0034 #define INCLXX_IN_GEANT4_MODE 1
0035
0036 #include "globals.hh"
0037
0038 #ifndef G4INCLConfig_hh
0039 #define G4INCLConfig_hh 1
0040
0041 #include "G4INCLParticleSpecies.hh"
0042 #include "G4INCLConfigEnums.hh"
0043 #include "G4INCLRandomSeedVector.hh"
0044 #include <iostream>
0045 #include <string>
0046 #include <sstream>
0047
0048
0049 class ConfigParser;
0050
0051 namespace G4INCL {
0052
0053
0054
0055
0056
0057
0058
0059
0060 class Config {
0061 public:
0062
0063 Config();
0064
0065
0066 ~Config();
0067
0068
0069 void init();
0070
0071
0072 std::string summary();
0073
0074
0075 G4int getVerbosity() const { return verbosity; }
0076
0077
0078 std::string const &getCalculationTitle() const { return title; }
0079
0080
0081 std::string const &getOutputFileRoot() const { return outputFileRoot; }
0082
0083
0084 G4int getNumberOfShots() const { return nShots; }
0085
0086
0087 G4bool isNaturalTarget() const { return naturalTarget; }
0088
0089
0090
0091
0092
0093
0094 G4int getTargetA() const { return targetSpecies.theA; }
0095
0096
0097 G4int getTargetZ() const { return targetSpecies.theZ; }
0098
0099
0100 G4int getTargetS() const { return targetSpecies.theS; }
0101
0102
0103 void setTargetA(G4int A) { targetSpecies.theA = A; }
0104
0105
0106 void setTargetZ(G4int Z) { targetSpecies.theZ = Z; }
0107
0108
0109 void setTargetS(G4int S) { targetSpecies.theS = S; }
0110
0111
0112 ParticleType getProjectileType() const { return projectileSpecies.theType; }
0113
0114
0115 ParticleSpecies getProjectileSpecies() const { return projectileSpecies; }
0116
0117
0118 void setProjectileSpecies(ParticleSpecies const &pars) { projectileSpecies=pars; }
0119
0120
0121 G4double getProjectileKineticEnergy() const { return projectileKineticEnergy; }
0122
0123
0124 void setProjectileKineticEnergy(G4double const kinE) { projectileKineticEnergy=kinE; }
0125
0126
0127 G4int getVerboseEvent() const { return verboseEvent; }
0128
0129
0130 static std::string const getVersionID();
0131
0132
0133 static std::string const getVersionHash();
0134
0135
0136 static std::string const getVersionString() {
0137 std::stringstream ss;
0138 ss << getVersionID() << "-" << getVersionHash();
0139 return ss.str();
0140 }
0141
0142
0143 Random::SeedVector getRandomSeeds() const {
0144 return randomSeedVector;
0145 }
0146
0147
0148 PauliType getPauliType() const { return pauliType; }
0149
0150
0151 G4bool getCDPP() const { return CDPP; }
0152
0153
0154 CoulombType getCoulombType() const { return coulombType; }
0155
0156
0157 void setCoulombType(CoulombType const c) { coulombType = c; }
0158
0159
0160 PotentialType getPotentialType() const { return potentialType; }
0161
0162
0163 void setPotentialType(PotentialType type) { potentialType = type; }
0164
0165
0166 G4bool getPionPotential() const { return pionPotential; }
0167
0168
0169 void setPionPotential(const G4bool pionPot) { pionPotential = pionPot; }
0170
0171
0172 LocalEnergyType getLocalEnergyBBType() const { return localEnergyBBType; }
0173
0174
0175 void setLocalEnergyBBType(const LocalEnergyType t) { localEnergyBBType=t; }
0176
0177
0178 LocalEnergyType getLocalEnergyPiType() const { return localEnergyPiType; }
0179
0180
0181 void setLocalEnergyPiType(const LocalEnergyType t) { localEnergyPiType=t; }
0182
0183
0184 std::string const &getLogFileName() const { return logFileName; }
0185
0186
0187 DeExcitationType getDeExcitationType() const { return deExcitationType; }
0188
0189
0190 std::string getDeExcitationString() const { return deExcitationString; }
0191
0192
0193 ClusterAlgorithmType getClusterAlgorithm() const { return clusterAlgorithmType; }
0194
0195
0196 void setClusterAlgorithm(ClusterAlgorithmType const c) { clusterAlgorithmType = c; }
0197
0198
0199 G4int getClusterMaxMass() const { return clusterMaxMass; }
0200
0201
0202 void setClusterMaxMass(const G4int clm){ clusterMaxMass=clm; }
0203
0204
0205 G4bool getBackToSpectator() const { return backToSpectator; }
0206
0207
0208 void setBackToSpectator(const G4bool b) { backToSpectator = b; }
0209
0210
0211 G4bool getUseRealMasses() const { return useRealMasses; }
0212
0213
0214 void setUseRealMasses(G4bool use) { useRealMasses = use; }
0215
0216
0217 void setINCLXXDataFilePath(std::string const &path) { INCLXXDataFilePath=path; }
0218
0219
0220 #ifdef INCL_DEEXCITATION_ABLAXX
0221 void setABLAXXDataFilePath(std::string const &path) { ablaxxDataFilePath=path; }
0222 #endif
0223
0224 std::string const &getINCLXXDataFilePath() const {
0225 return INCLXXDataFilePath;
0226 }
0227
0228 #ifdef INCL_DEEXCITATION_ABLAXX
0229 std::string const &getABLAXXDataFilePath() const {
0230 return ablaxxDataFilePath;
0231 }
0232 #endif
0233
0234 #ifdef INCL_DEEXCITATION_ABLA07
0235 std::string const &getABLA07DataFilePath() const {
0236 return abla07DataFilePath;
0237 }
0238 #endif
0239 #ifdef INCL_DEEXCITATION_GEMINIXX
0240 std::string const &getGEMINIXXDataFilePath() const {
0241 return geminixxDataFilePath;
0242 }
0243 #endif
0244
0245 G4double getImpactParameter() const { return impactParameter; }
0246
0247
0248 SeparationEnergyType getSeparationEnergyType() const { return separationEnergyType; }
0249
0250
0251 FermiMomentumType getFermiMomentumType() const { return fermiMomentumType; }
0252
0253
0254 void setFermiMomentumType(FermiMomentumType const f) { fermiMomentumType=f; }
0255
0256
0257 G4double getFermiMomentum() const { return fermiMomentum; }
0258
0259
0260 void setFermiMomentum(const G4double p) { fermiMomentum = p; }
0261
0262 G4double getCutNN() const { return cutNN; }
0263
0264 #ifdef INCL_ROOT_USE
0265 std::string const &getROOTSelectionString() const {
0266 return rootSelectionString;
0267 }
0268 #endif
0269
0270 #ifdef INCL_DEEXCITATION_FERMI_BREAKUP
0271 G4int getMaxMassFermiBreakUp() const {
0272 return maxMassFermiBreakUp;
0273 }
0274
0275 G4int getMaxChargeFermiBreakUp() const {
0276 return maxChargeFermiBreakUp;
0277 }
0278 #endif
0279
0280
0281 G4double getRPCorrelationCoefficient(const ParticleType t) const {
0282
0283 return ((t==Proton) ? rpCorrelationCoefficientProton : rpCorrelationCoefficientNeutron);
0284 }
0285
0286
0287 void setRPCorrelationCoefficient(const ParticleType t, const G4double corrCoeff) {
0288
0289 if(t==Proton)
0290 rpCorrelationCoefficientProton=corrCoeff;
0291 else
0292 rpCorrelationCoefficientNeutron=corrCoeff;
0293 }
0294
0295
0296 void setRPCorrelationCoefficient(const G4double corrCoeff) {
0297 setRPCorrelationCoefficient(Proton,corrCoeff);
0298 setRPCorrelationCoefficient(Neutron,corrCoeff);
0299 }
0300
0301
0302 G4double getNeutronSkin() const { return neutronSkin; }
0303
0304
0305 void setNeutronSkin(const G4double d) { neutronSkin=d; }
0306
0307
0308 G4double getNeutronHalo() const { return neutronHalo; }
0309
0310
0311 void setNeutronHalo(const G4double d) { neutronHalo=d; }
0312
0313
0314 G4bool getRefraction() const { return refraction; }
0315
0316
0317 void setRefraction(const G4bool r) { refraction = r; }
0318
0319
0320 RNGType getRNGType() const { return rngType; }
0321
0322
0323 void setRNGType(RNGType const r) { rngType=r; }
0324
0325
0326 PhaseSpaceGeneratorType getPhaseSpaceGeneratorType() const { return phaseSpaceGeneratorType; }
0327
0328
0329 void setPhaseSpaceGeneratorType(PhaseSpaceGeneratorType const p) { phaseSpaceGeneratorType=p; }
0330
0331
0332 CascadeActionType getCascadeActionType() const { return cascadeActionType; }
0333
0334
0335 void setCascadeActionType(CascadeActionType const c) { cascadeActionType=c; }
0336
0337
0338 unsigned int getAutosaveFrequency() const { return autosaveFrequency; }
0339
0340
0341 void setAutosaveFrequency(const unsigned int f) { autosaveFrequency=f; }
0342
0343
0344 CrossSectionsType getCrossSectionsType() const { return crossSectionsType; }
0345
0346
0347 G4int getMaxNumberMultipions() const { return maxNumberMultipions; }
0348
0349
0350 void setMaxNumberMultipions(const G4int n) { maxNumberMultipions=n; }
0351
0352
0353 void setCrossSectionsType(CrossSectionsType const c) { crossSectionsType=c; }
0354
0355
0356 G4double getHadronizationTime() const { return hadronizationTime; }
0357
0358
0359 void setHadronizationTime(const G4double t) { hadronizationTime=t; }
0360
0361 #ifdef INCL_ROOT_USE
0362 G4bool getConciseROOTTree() const { return conciseROOTTree; }
0363 #endif
0364
0365 G4bool getInverseKinematics() const { return inverseKinematics; }
0366
0367 G4bool getsrcPairConfig() const { return srcPairCorrelations; }
0368
0369 G4float getsrcPairDist() const { return srcPairDistance; }
0370
0371
0372 G4double getDecayTimeThreshold() const { return decayTimeThreshold; }
0373
0374
0375 void setDecayTimeThreshold(const G4double t) { decayTimeThreshold=t; }
0376
0377
0378 G4double getBias() const { return bias; }
0379
0380
0381 G4double getAtrestThreshold() const { return atrestThreshold; }
0382
0383
0384 void setAtrestThreshold(const G4double t) { atrestThreshold=t; }
0385
0386 private:
0387
0388 G4int verbosity;
0389 std::string inputFileName;
0390 std::string title;
0391 std::string outputFileRoot;
0392 std::string fileSuffix;
0393 std::string logFileName;
0394
0395 G4int nShots;
0396
0397 std::string targetString;
0398 ParticleSpecies targetSpecies;
0399 G4bool naturalTarget;
0400
0401 std::string projectileString;
0402 ParticleSpecies projectileSpecies;
0403 G4double projectileKineticEnergy;
0404
0405 G4int verboseEvent;
0406
0407 std::string randomSeeds;
0408 Random::SeedVector randomSeedVector;
0409
0410 std::string pauliString;
0411 PauliType pauliType;
0412 G4bool CDPP;
0413
0414 std::string coulombString;
0415 CoulombType coulombType;
0416
0417 std::string potentialString;
0418 PotentialType potentialType;
0419 G4bool pionPotential;
0420
0421 std::string localEnergyBBString;
0422 LocalEnergyType localEnergyBBType;
0423
0424 std::string localEnergyPiString;
0425 LocalEnergyType localEnergyPiType;
0426
0427 std::string deExcitationModelList;
0428 std::string deExcitationOptionDescription;
0429 std::string deExcitationString;
0430 DeExcitationType deExcitationType;
0431 #ifdef INCL_DEEXCITATION_ABLAXX
0432 std::string ablaxxDataFilePath;
0433 #endif
0434 #ifdef INCL_DEEXCITATION_ABLA07
0435 std::string abla07DataFilePath;
0436 #endif
0437 #ifdef INCL_DEEXCITATION_GEMINIXX
0438 std::string geminixxDataFilePath;
0439 #endif
0440 std::string INCLXXDataFilePath;
0441
0442 std::string clusterAlgorithmString;
0443 ClusterAlgorithmType clusterAlgorithmType;
0444
0445 G4int clusterMaxMass;
0446
0447 G4bool backToSpectator;
0448
0449 G4bool useRealMasses;
0450
0451 G4double impactParameter;
0452
0453 std::string separationEnergyString;
0454 SeparationEnergyType separationEnergyType;
0455
0456 std::string fermiMomentumString;
0457 FermiMomentumType fermiMomentumType;
0458
0459 G4double fermiMomentum;
0460
0461 G4double cutNN;
0462
0463 G4bool ann;
0464
0465 G4double bias;
0466
0467 G4double atrestThreshold;
0468
0469 #ifdef INCL_ROOT_USE
0470 std::string rootSelectionString;
0471 #endif
0472
0473 #ifdef INCL_DEEXCITATION_FERMI_BREAKUP
0474 G4int maxMassFermiBreakUp;
0475 G4int maxChargeFermiBreakUp;
0476 #endif
0477
0478 G4double rpCorrelationCoefficient;
0479 G4double rpCorrelationCoefficientProton;
0480 G4double rpCorrelationCoefficientNeutron;
0481
0482 G4double neutronSkin;
0483 G4double neutronHalo;
0484
0485 G4bool refraction;
0486
0487 std::string randomNumberGenerator;
0488 RNGType rngType;
0489
0490 std::string phaseSpaceGenerator;
0491 PhaseSpaceGeneratorType phaseSpaceGeneratorType;
0492
0493 unsigned int autosaveFrequency;
0494
0495 std::string crossSectionsString;
0496 CrossSectionsType crossSectionsType;
0497 G4int maxNumberMultipions;
0498
0499 std::string cascadeAction;
0500 CascadeActionType cascadeActionType;
0501
0502 G4double hadronizationTime;
0503
0504 #ifdef INCL_ROOT_USE
0505 G4bool conciseROOTTree;
0506 #endif
0507
0508 G4bool inverseKinematics;
0509
0510 G4bool srcPairCorrelations;
0511
0512 G4float srcPairDistance;
0513
0514 G4double decayTimeThreshold;
0515
0516 friend class ::ConfigParser;
0517 };
0518
0519 }
0520
0521 #endif