Import Geant4 10.1.0 source tree
This commit is contained in:
@@ -80,8 +80,8 @@ G4NeutronField::~G4NeutronField()
|
||||
G4double G4NeutronField::GetField(const G4ThreeVector & aPosition)
|
||||
{
|
||||
G4double x = aPosition.mag();
|
||||
G4int index = static_cast<G4int>(x/(0.3*fermi) );
|
||||
if(index+2> static_cast<G4int>(theFermiMomBuffer.size())) return theFermiMomBuffer.back();
|
||||
unsigned int index = static_cast<unsigned int>(x/(0.3*fermi));
|
||||
if( (index+2) > theFermiMomBuffer.size()) return theFermiMomBuffer.back();
|
||||
G4double y1 = theFermiMomBuffer[index];
|
||||
G4double y2 = theFermiMomBuffer[index+1];
|
||||
G4double x1 = (0.3*fermi)*index;
|
||||
|
||||
Reference in New Issue
Block a user