#include <G4INCLNuclearDensity.hh>
Public Member Functions | |
NuclearDensity (G4int A, G4int Z, InverseInterpolationTable *rpCorrelationTable) | |
~NuclearDensity () | |
NuclearDensity (const NuclearDensity &rhs) | |
Copy constructor. | |
NuclearDensity & | operator= (const NuclearDensity &rhs) |
Assignment operator. | |
void | swap (NuclearDensity &rhs) |
Helper method for the assignment operator. | |
G4double | getMaxRFromP (G4double p) const |
Get the maximum allowed radius for a given momentum. | |
G4double | getMaxTFromR (G4double r) const |
G4double | getMaximumRadius () const |
G4double | getTransmissionRadius (Particle const *const p) const |
The radius used for calculating the transmission coefficient. | |
G4double | getTransmissionRadius (ParticleType type) |
The radius used for calculating the transmission coefficient. | |
G4int | getA () const |
Get the mass number. | |
G4int | getZ () const |
Get the charge number. | |
G4double | getNuclearRadius () |
Definition at line 53 of file G4INCLNuclearDensity.hh.
G4INCL::NuclearDensity::NuclearDensity | ( | G4int | A, | |
G4int | Z, | |||
InverseInterpolationTable * | rpCorrelationTable | |||
) |
Definition at line 44 of file G4INCLNuclearDensity.cc.
References DEBUG, and G4INCL::InverseInterpolationTable::print().
00044 : 00045 theA(A), 00046 theZ(Z), 00047 theMaximumRadius((*rpCorrelationTable)(1.)), 00048 theNuclearRadius(ParticleTable::getNuclearRadius(theA,theZ)), 00049 rFromP(rpCorrelationTable), 00050 // The interpolation table for local-energy look-ups is simply obtained by 00051 // inverting the r-p correlation table. 00052 tFromR(new InverseInterpolationTable(rFromP->getNodeValues(), rFromP->getNodeAbscissae())) 00053 { 00054 DEBUG("Interpolation table for local energy (A=" << theA << ", Z=" << theZ << ") initialised:" 00055 << std::endl 00056 << tFromR->print() 00057 << std::endl); 00058 initializeTransmissionRadii(); 00059 }
G4INCL::NuclearDensity::~NuclearDensity | ( | ) |
Definition at line 61 of file G4INCLNuclearDensity.cc.
00061 { 00062 // We don't delete the rFromP table, which is cached in the 00063 // NuclearDensityFactory 00064 delete tFromR; 00065 }
G4INCL::NuclearDensity::NuclearDensity | ( | const NuclearDensity & | rhs | ) |
Copy constructor.
Definition at line 67 of file G4INCLNuclearDensity.cc.
References transmissionRadius, and G4INCL::UnknownParticle.
00067 : 00068 theA(rhs.theA), 00069 theZ(rhs.theZ), 00070 theMaximumRadius(rhs.theMaximumRadius), 00071 theNuclearRadius(rhs.theNuclearRadius), 00072 // rFromP is owned by NuclearDensityFactory, so shallow copy is sufficient 00073 rFromP(rhs.rFromP), 00074 // deep copy for tFromR 00075 tFromR(new InverseInterpolationTable(*(rhs.tFromR))) 00076 { 00077 std::copy(rhs.transmissionRadius, rhs.transmissionRadius+UnknownParticle, transmissionRadius); 00078 }
G4int G4INCL::NuclearDensity::getA | ( | ) | const [inline] |
G4double G4INCL::NuclearDensity::getMaximumRadius | ( | ) | const [inline] |
Get the maximum allowed radius for a given momentum.
p | Absolute value of the particle momentum, divided by the relevant Fermi momentum. |
Definition at line 110 of file G4INCLNuclearDensity.cc.
Referenced by G4INCL::Nucleus::getSurfaceRadius().
G4double G4INCL::NuclearDensity::getNuclearRadius | ( | ) | [inline] |
Definition at line 107 of file G4INCLNuclearDensity.hh.
Referenced by G4INCL::PauliStandard::getBlockingProbability(), and G4INCL::ClusteringModelIntercomparison::getCluster().
G4double G4INCL::NuclearDensity::getTransmissionRadius | ( | ParticleType | type | ) | [inline] |
The radius used for calculating the transmission coefficient.
Definition at line 96 of file G4INCLNuclearDensity.hh.
The radius used for calculating the transmission coefficient.
Definition at line 82 of file G4INCLNuclearDensity.hh.
References G4INCL::Composite, G4INCL::Particle::getA(), G4INCL::ParticleTable::getNuclearRadius(), G4INCL::Particle::getType(), and G4INCL::Particle::getZ().
Referenced by G4INCL::CoulombNonRelativistic::distortOut(), and G4INCL::Nucleus::getTransmissionBarrier().
00082 { 00083 const ParticleType t = p->getType(); 00084 // assert(t!=Neutron && t!=PiZero && t!=DeltaZero); // no neutral particles here 00085 if(t==Composite) { 00086 return transmissionRadius[t] + 00087 ParticleTable::getNuclearRadius(p->getA(), p->getZ()); 00088 } else 00089 return transmissionRadius[t]; 00090 };
G4int G4INCL::NuclearDensity::getZ | ( | ) | const [inline] |
NuclearDensity & G4INCL::NuclearDensity::operator= | ( | const NuclearDensity & | rhs | ) |
Assignment operator.
Definition at line 80 of file G4INCLNuclearDensity.cc.
References swap().
00080 { 00081 NuclearDensity temporaryDensity(rhs); 00082 swap(temporaryDensity); 00083 return *this; 00084 }
void G4INCL::NuclearDensity::swap | ( | NuclearDensity & | rhs | ) |
Helper method for the assignment operator.
Definition at line 86 of file G4INCLNuclearDensity.cc.
References rFromP, tFromR, theA, theMaximumRadius, theNuclearRadius, theZ, transmissionRadius, and G4INCL::UnknownParticle.
Referenced by operator=().
00086 { 00087 std::swap(theA, rhs.theA); 00088 std::swap(theZ, rhs.theZ); 00089 std::swap(theMaximumRadius, rhs.theMaximumRadius); 00090 std::swap(theNuclearRadius, rhs.theNuclearRadius); 00091 std::swap_ranges(transmissionRadius, transmissionRadius+UnknownParticle, rhs.transmissionRadius); 00092 std::swap(rFromP, rhs.rFromP); 00093 std::swap(tFromR, rhs.tFromR); 00094 }