Changed bring_into_cell to use a single call to MOD instead of a do while loop.
So now it's:
v = MOD(v, 1.0_dp)
! If a component >= 1, translate by subtracting a lattice vector
! If a component < 0, translate by adding a lattice vector
if (any(v >= 1.0_dp - eps) .or. any(v < 0.0_dp - eps)) then
instead of:
do while (any(v >= 1.0_dp - eps) .or. any(v < 0.0_dp - eps))
Changed
bring_into_cell
to use a single call toMOD
instead of ado while
loop.So now it's:
instead of: