Skip to content

Commit 2f5ad31

Browse files
Apply suggestions from code review
Co-authored-by: Hendrik Ranocha <ranocha@users.noreply.github.com>
1 parent 94c9837 commit 2f5ad31

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/equations/compressible_euler_internal_energy_with_gravity_2d.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -250,7 +250,7 @@ end
250250
rho, v1, v2, p, phi = prim
251251
rho_v1 = rho * v1
252252
rho_v2 = rho * v2
253-
rho_e_internal = p / (equations.gamma - 1)
253+
rho_e_internal = p * equations.inv_gamma_minus_one
254254
return SVector(rho, rho_v1, rho_v2, rho_e_internal, phi)
255255
end
256256

@@ -281,7 +281,7 @@ end
281281

282282
@inline function entropy(cons,
283283
equations::CompressibleEulerInternalEnergyEquationsWithGravity2D)
284-
p = (equations.gamma - 1) * cons[4]
284+
p = pressure(cons, equations)
285285
# Thermodynamic entropy
286286
s = log(p) - equations.gamma * log(cons[1])
287287
S = -s * cons[1] / (equations.gamma - 1)

0 commit comments

Comments
 (0)