diff options
Diffstat (limited to 'spheres.cpp')
-rw-r--r-- | spheres.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/spheres.cpp b/spheres.cpp index 9ca2036..4b2237d 100644 --- a/spheres.cpp +++ b/spheres.cpp @@ -75,7 +75,7 @@ int main(int argc, char* argv[]) { sphere.s.resize(n); - unsigned nx = floor(sqrt(n)); + unsigned nx = ceil(sqrt(n)); for (unsigned i = 0; i < sphere.s.size(); i++) { Spin<double, 2, double>* ss = new Spin<double, 2, double>(); ss->x = {(i / nx) * L / nx, (i % nx) * L / nx}; |