SunnySuite / Sunny.jl

Spin dynamics and generalization to SU(N) coherent states
Other
86 stars 19 forks source link

Fix superlat construction bug + minor refactors #22

Closed ColeMiles closed 2 years ago

ColeMiles commented 2 years ago

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.