diff options
author | Jaron Kent-Dobias <jaron@kent-dobias.com> | 2025-05-15 08:55:21 -0300 |
---|---|---|
committer | Jaron Kent-Dobias <jaron@kent-dobias.com> | 2025-05-15 08:55:21 -0300 |
commit | 0968903c4c0a64608c8ba7449d4fcf64614523fc (patch) | |
tree | 1f320c08ac28cdbda6bf045f610ab8b538c91288 /log_get_energy.cpp | |
parent | 4c045af4a3d3a12b1e4e73bc9ab1789ceb7b4d7e (diff) | |
download | code-0968903c4c0a64608c8ba7449d4fcf64614523fc.tar.gz code-0968903c4c0a64608c8ba7449d4fcf64614523fc.tar.bz2 code-0968903c4c0a64608c8ba7449d4fcf64614523fc.zip |
Use different mechanism for testing existence of file
Diffstat (limited to 'log_get_energy.cpp')
-rw-r--r-- | log_get_energy.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/log_get_energy.cpp b/log_get_energy.cpp index a183861..6a7be56 100644 --- a/log_get_energy.cpp +++ b/log_get_energy.cpp @@ -3,6 +3,7 @@ #include <iomanip> #include <iostream> #include <iomanip> +#include <filesystem> int main(int argc, char* argv[]) { /* Model parameters */ @@ -77,8 +78,9 @@ int main(int argc, char* argv[]) { std::cout << std::setprecision(16); - while (β += Δβ, β <= βₘₐₓ) { - if (logFourierLoad(C, R, Ct, Rt, p, s, λ, τ₀, β, log2n, Δτ, logShift)) { + while (β = std::round(1e6 * (β + Δβ)) / 1e6, β <= βₘₐₓ) { + if (std::filesystem::exists(logFourierFile("C", p, s, λ, τ₀, β, log2n, Δτ, logShift))) { + logFourierLoad(C, R, Ct, Rt, p, s, λ, τ₀, β, log2n, Δτ, logShift); Real e = energy(fft, C, R, p, s, λ, β); |