From d244bf28e4f1c9babb314786bc9bc386ce052d88 Mon Sep 17 00:00:00 2001 From: Jaron Kent-Dobias Date: Fri, 20 Dec 2019 01:59:53 -0500 Subject: another try --- hadamard_pt.hpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/hadamard_pt.hpp b/hadamard_pt.hpp index 9f50e1e..59081b2 100644 --- a/hadamard_pt.hpp +++ b/hadamard_pt.hpp @@ -86,8 +86,8 @@ public: } colors.front() = down; colors.back() = up; - for (unsigned j = 0; j < Ms.size(); j++) { - if (i > n / 2) { + if (i > n / 2) { + for (unsigned j = 0; j < Ms.size(); j++) { if (colors[j] == up) { nu[j]++; } else if (colors[j] == down) { @@ -133,7 +133,7 @@ public: for (unsigned i = 0; i < η.size(); i++) { double xnew = x + η[i] * (T(i + 1) - T(i)) / C; while (j < xnew * η.size() && j < η.size()) { - T1[j - 1] = T(i) + (j / (double)η.size() - x) / η[i] * C; + T1[j - 1] = T(i) + (j / (double)Ms.size() - x) / η[i] * C; j++; } x = xnew; -- cgit v1.2.3-54-g00ecf