diff options
author | Jaron Kent-Dobias <jaron@kent-dobias.com> | 2020-02-25 15:23:41 -0500 |
---|---|---|
committer | Jaron Kent-Dobias <jaron@kent-dobias.com> | 2020-02-25 15:23:41 -0500 |
commit | 1da9ba0af64dd1ff07c9fda6226689b4e8701e43 (patch) | |
tree | 7583c571b34e4e7a3dac0cc6e34016c6a6270e56 /ising.hpp | |
parent | 5fe3e194a2d4690b541ecee8ea342681c4eeaa6c (diff) | |
download | space_wolff-1da9ba0af64dd1ff07c9fda6226689b4e8701e43.tar.gz space_wolff-1da9ba0af64dd1ff07c9fda6226689b4e8701e43.tar.bz2 space_wolff-1da9ba0af64dd1ff07c9fda6226689b4e8701e43.zip |
Minor refactoring of sphere commands and animation class, and introduction of Dimers
Diffstat (limited to 'ising.hpp')
-rw-r--r-- | ising.hpp | 18 |
1 files changed, 9 insertions, 9 deletions
@@ -91,15 +91,15 @@ void isingPopulate(isingModel& m, unsigned L, double pop, double mag) { for (unsigned i = 0; i < L; i++) { for (unsigned j = 0; j < L; j++) { if (rng.uniform<double>(0, 1) < pop) { - Spin<signed, D, signed>* ss = new Spin<signed, D, signed>(); - ss->x = {i, j}; - if (rng.uniform<double>(0, 1) < mag) { - ss->s = 1; - } else { - ss->s = -1; - } - m.s.push_back(ss); - m.dict.insert(ss); + Spin<signed, D, signed>* ss = new Spin<signed, D, signed>(); + ss->x = {i, j}; + if (rng.uniform<double>(0, 1) < mag) { + ss->s = 1; + } else { + ss->s = -1; + } + m.s.push_back(ss); + m.dict.insert(ss); } } } |