45 double MyRNG(
void*) {
return G4Random::getTheEngine()->flat(); }
69 for ( std::map< G4int , G4LENDUsedTarget* >::iterator
80 for ( std::map< G4int , G4LENDUsedTarget* >::iterator
101 for (
size_t i = 0 ; i < numberOfElements ; ++i )
104 const G4Element* anElement = (*theElementTable)[i];
107 if ( numberOfIsotope > 0 )
110 for (
G4int i_iso = 0 ; i_iso < numberOfIsotope ; i_iso++ )
130 for (
G4int ii = 0 ; ii < numberOfNistIso ; ii++ )
187 theNeutron.SetKineticEnergy( ke );
204 G4double nEnergy = theNeutron.GetTotalEnergy();
211 G4double cmsMom = std::sqrt(the3CMS*the3CMS);
212 G4double sqrts = std::sqrt((totE-cmsMom)*(totE+cmsMom));
216 theNeutron.Lorentz(theNeutron, theCMS);
217 theTarget.
Lorentz(theTarget, theCMS);
218 G4double en = theNeutron.GetTotalMomentum();
223 tempVector.
setX(std::cos(theta)*std::sin(cms_theta)*std::cos(cms_phi)
224 +std::sin(theta)*std::cos(phi)*std::cos(cms_theta)*std::cos(cms_phi)
225 -std::sin(theta)*std::sin(phi)*std::sin(cms_phi) );
226 tempVector.
setY(std::cos(theta)*std::sin(cms_theta)*std::sin(cms_phi)
227 +std::sin(theta)*std::cos(phi)*std::cos(cms_theta)*std::sin(cms_phi)
228 +std::sin(theta)*std::sin(phi)*std::cos(cms_phi) );
229 tempVector.
setZ(std::cos(theta)*std::cos(cms_theta)
230 -std::sin(theta)*std::cos(phi)*std::sin(cms_theta) );
232 theNeutron.SetMomentum(tempVector);
237 theNeutron.Lorentz(theNeutron, -1.*theCMS);
238 theTarget.
Lorentz(theTarget, -1.*theCMS);
256 message =
"Produce unchanged final state is requested in ";
258 message +=
". Cross section and model likely have an inconsistency.";
270 target =
usedTarget_map.find( nuclear_code )->second->GetTarget();
280 G4cout <<
"Requested Evaluation, Z , A -> Actual Evaluation, Z , A(0=Nat) " <<
G4endl;
281 for ( std::map< G4int , G4LENDUsedTarget* >::iterator
284 <<
" " << it->second->GetWantedEvaluation()
285 <<
", " << it->second->GetWantedZ()
286 <<
", " << it->second->GetWantedA()
287 <<
" -> " << it->second->GetActualEvaluation()
288 <<
", " << it->second->GetActualZ()
289 <<
", " << it->second->GetActualA()
G4int GetNistFirstIsotopeN(G4int Z) const
void SetMinEnergy(G4double anEnergy)
G4LENDModel(G4String name="LENDModel")
void SetMaxEnergy(const G4double anEnergy)
static constexpr double MeV
static G4IonTable * GetIonTable()
void SetMomentumChange(const G4ThreeVector &aV)
void SetMomentum(const G4double x, const G4double y, const G4double z)
void message(RunManager *runmanager)
const G4String & GetParticleName() const
void AddSecondary(G4DynamicParticle *aP, G4int mod=-1)
static constexpr double second
G4bool RequestChangeOfVerboseLevel(G4int)
G4double GetPDGMass() const
void SetTotalEnergy(const G4double en)
G4LENDManager * lend_manager
void SetMass(const G4double mas)
void SetEnergyChange(G4double anEnergy)
G4NistElementBuilder * GetNistElementBuilder()
G4double GetTotalEnergy() const
G4int GetNucleusEncoding(G4int iZ, G4int iA, G4int iM)
const G4Material * GetMaterial() const
G4double GetIsotopeAbundance(G4int Z, G4int N) const
const G4Isotope * GetIsotope()
G4HadFinalState * returnUnchanged(const G4HadProjectile &aTrack, G4HadFinalState *theResult)
G4int GetNumberOfNistIsotopes(G4int Z) const
std::vector< G4Element * > G4ElementTable
double getElasticFinalState(double e_in, double temperature, double(*rng)(void *), void *rngState)
static constexpr double twopi
G4ErrorTarget * theTarget
typedef int(XMLCALL *XML_NotStandaloneHandler)(void *userData)
G4double GetTotalMomentum() const
std::map< G4int, G4LENDUsedTarget * > usedTarget_map
static constexpr double eV
G4ThreeVector GetMomentum() const
G4ParticleDefinition * proj
void DumpLENDTargetInfo(G4bool force=false)
ThreeVector shoot(const G4int Ap, const G4int Af)
const G4LorentzVector & Get4Momentum() const
G4double GetKineticEnergy() const
void G4Exception(const char *originOfException, const char *exceptionCode, G4ExceptionSeverity severity, const char *description)
const G4ParticleDefinition * GetDefinition() const
G4String default_evaluation
static constexpr double k_Boltzmann
void SetMomentum(const G4ThreeVector &momentum)
void SetDefinition(const G4ParticleDefinition *aParticleDefinition)
G4GLOB_DLL std::ostream G4cout
const G4Isotope * GetIsotope(G4int iso) const
static size_t GetNumberOfElements()
G4ParticleDefinition * GetIon(G4int Z, G4int A, G4int lvl=0)
static G4LENDManager * GetInstance()
void Lorentz(const G4ReactionProduct &p1, const G4ReactionProduct &p2)
void recreate_used_target_map()
G4GIDI_target * get_target_from_map(G4int nuclear_code)
G4double GetTemperature() const
void create_used_target_map()
static G4ElementTable * GetElementTable()
const G4String & GetModelName() const
size_t GetNumberOfIsotopes() const
virtual G4HadFinalState * ApplyYourself(const G4HadProjectile &aTrack, G4Nucleus &aTargetNucleus)