summaryrefslogtreecommitdiff
path: root/fourier_integrator.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'fourier_integrator.cpp')
-rw-r--r--fourier_integrator.cpp14
1 files changed, 8 insertions, 6 deletions
diff --git a/fourier_integrator.cpp b/fourier_integrator.cpp
index 9e41b5f..d83fb9d 100644
--- a/fourier_integrator.cpp
+++ b/fourier_integrator.cpp
@@ -146,14 +146,16 @@ int main(int argc, char* argv[]) {
z *= Cnew[0];
- if (ΔC < ΔCprev) {
- γ = std::min(1.1 * γ, 1.0);
- } else {
- γ /= 2;
+ if (it % maxIterations == 0) {
+ if (ΔC < ΔCprev) {
+ γ = std::min(1.1 * γ, 1.0);
+ } else {
+ γ /= 2;
+ }
+
+ ΔCprev = ΔC;
}
- ΔCprev = ΔC;
-
std::cerr << it << " " << p << " " << s << " " << τ₀ << " " << y << " " << sqrt(2 * ΔC / C.size()) << " " << γ << std::endl;
}