Fixes a bug in the Ewald code left over from the transition to using fractional coordinates. When creating the superlattice Lattice in the Ewald summation, the absolute (non-fractional) basis vectors were being passed. This would silently work when these basis vectors had coordinates in [0.0, 1.0], but would error otherwise. However, these basis vectors were not actually used by any computation using the superlattice, so previous calculations should be correct.
Also perform some minor refactors surrounding the bugfix.
Fixes a bug in the Ewald code left over from the transition to using fractional coordinates. When creating the superlattice
Lattice
in the Ewald summation, the absolute (non-fractional) basis vectors were being passed. This would silently work when these basis vectors had coordinates in [0.0, 1.0], but would error otherwise. However, these basis vectors were not actually used by any computation using the superlattice, so previous calculations should be correct.Also perform some minor refactors surrounding the bugfix.