From c7e37f6f855e712d39c0733d10a0c4b63f6e1670 Mon Sep 17 00:00:00 2001 From: Cory Date: Tue, 26 Dec 2023 15:32:58 +0100 Subject: [PATCH] Fix mistake --- lib/WaveSimulation.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/WaveSimulation.cpp b/lib/WaveSimulation.cpp index 7d425bc..1ccde39 100644 --- a/lib/WaveSimulation.cpp +++ b/lib/WaveSimulation.cpp @@ -274,10 +274,10 @@ void WaveSimulation::solve(std::string outfile, std::vector &steps) for (size_t i=0; i < steps.size(); i++) { if (i == 0) { - iterations = steps[i] / this->h; + iterations = steps[i] / this->dt; } else { - iterations = (steps[i] - steps[i-1]) / this->h; + iterations = (steps[i] - steps[i-1]) / this->dt; } for (size_t j=0; j < iterations; j++) {