diff --git a/src/fixup/fixup.hpp b/src/fixup/fixup.hpp index c3411abe..553852d0 100644 --- a/src/fixup/fixup.hpp +++ b/src/fixup/fixup.hpp @@ -196,26 +196,17 @@ class Ceilings { KOKKOS_INLINE_FUNCTION void GetCeilings(const Real x1, const Real x2, const Real x3, Real &gmax, Real &smax) const { - if (!eos_bnds_set_) { - PARTHENON_FAIL("EOS bounds not set in ceilings."); - } + switch (ceiling_flag_) { case 1: gmax = g0_; - smax = std::min(s0_, sie_max_eos_); + smax = s0_; break; default: PARTHENON_FAIL("No valid ceiling set."); } } - void SetEOSBnds(StateDescriptor *eos_pkg) { - if (!eos_bnds_set_) { - sie_max_eos_ = eos_pkg->Param("sie_max"); - eos_bnds_set_ = true; - } - } - private: Real g0_, s0_, sie_max_eos_; const int ceiling_flag_; @@ -301,7 +292,6 @@ class Bounds { template KOKKOS_INLINE_FUNCTION void SetEOSBnds(Args &&...args) { floors_.SetEOSBnds(std::forward(args)...); - ceilings_.SetEOSBnds(std::forward(args)...); } template