Skip to content

Commit

Permalink
almostEqual for arbitrary floating point types
Browse files Browse the repository at this point in the history
  • Loading branch information
ajnonaka committed Sep 16, 2024
1 parent 0c79af8 commit 1ede927
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Src/Base/AMReX_RKIntegrator.H
Original file line number Diff line number Diff line change
Expand Up @@ -252,7 +252,7 @@ public:
{
// Adjust step size to reach output time
// protect against roundoff
if (std::abs(time_out - time_current - dt) <= 1.e5 * std::numeric_limits<amrex::Real>::epsilon() * std::abs(dt)) {
if (almostEqual(std::abs(time_out-time_current), std::abs(dt)), 10.) {
dt = time_out - time_current;
stop = true;
}
Expand Down

0 comments on commit 1ede927

Please sign in to comment.