File tree Expand file tree Collapse file tree 1 file changed +9
-1
lines changed
Expand file tree Collapse file tree 1 file changed +9
-1
lines changed Original file line number Diff line number Diff line change @@ -445,6 +445,9 @@ number_t chugunov2007 (const plasma_state_t<number_t>& state,
445445 // machine limit the output
446446 constexpr amrex::Real h_max = 300 .e0_rt ;
447447 h = admath::min (h, h_max);
448+ if (h <= 0.0 ) {
449+ return 1.0 ;
450+ }
448451 return admath::exp (h);
449452}
450453
@@ -537,6 +540,9 @@ number_t chugunov2009 (const plasma_state_t<number_t>& state,
537540 // machine limit the output
538541 constexpr amrex::Real h12_max = 300 .e0_rt ;
539542 h12 = admath::min (h12, h12_max);
543+ if (h12 <= 0.0 ) {
544+ return 1.0 ;
545+ }
540546 return admath::exp (h12);
541547}
542548
@@ -632,7 +638,9 @@ number_t chabrier1998 (const plasma_state_t<number_t>& state,
632638
633639 constexpr amrex::Real h12_max = 300 .0_rt;
634640 h12 = admath::min (h12_max, h12);
635-
641+ if (h12 <= 0.0 ) {
642+ return 1.0 ;
643+ }
636644 return admath::exp (h12);
637645}
638646#endif
You can’t perform that action at this time.
0 commit comments