Skip to content

Commit

Permalink
remove unused var; assert P
Browse files Browse the repository at this point in the history
  • Loading branch information
psharda committed Jul 26, 2023
1 parent 6cea067 commit c9ffd1c
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/hydro_system.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -231,10 +231,8 @@ void HydroSystem<problem_t>::ComputeMaxSignalSpeed(amrex::Array4<const amrex::Re
if constexpr (is_eos_isothermal()) {
cs = cs_iso_;
} else {
const auto E = cons(i, j, k, energy_index); // *total* gas energy per unit volume
AMREX_ASSERT(!std::isnan(E));
const auto kinetic_energy = 0.5 * rho * (vx * vx + vy * vy + vz * vz);
const auto P = ComputePressure(cons, i, j, k);
AMREX_ASSERT(!std::isnan(P));
cs = std::sqrt(HydroSystem<problem_t>::gamma_ * P / rho);
}
AMREX_ASSERT(cs > 0.);
Expand Down

0 comments on commit c9ffd1c

Please sign in to comment.