From 83c6103249df04c1a048294fb6ab154eee235070 Mon Sep 17 00:00:00 2001 From: SamG-01 Date: Fri, 13 Dec 2024 13:10:28 -0500 Subject: [PATCH] machine limit the output --- screening/screen.H | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/screening/screen.H b/screening/screen.H index bc585b3f6..983357fe6 100644 --- a/screening/screen.H +++ b/screening/screen.H @@ -173,7 +173,11 @@ number_t debye_huckel (const plasma_state_t& state, // eq. A1 number_t h_DH = z1z2 * gcem::sqrt(3 * amrex::Math::powi<3>(Gamma_e) * z_ratio); - return admath::exp(h_DH); + + // machine limit the output + constexpr amrex::Real h_max = 300.e0_rt; + h = admath::min(h_DH, h_max); + return admath::exp(h); } #if SCREEN_METHOD == SCREEN_METHOD_screen5