Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
zhichen3 committed Nov 26, 2024
1 parent 559cac1 commit 31ba3d5
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions Source/hydro/trans.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -441,6 +441,7 @@ Castro::actual_trans_single(const Box& bx, // NOLINT(readability-convert-member
// If we are wrong, we will fix it later.

if (transverse_use_eos) {

eos_rep_t eos_state;
eos_state.rho = rrnewn;
eos_state.e = qo_arr(i,j,k,QREINT) / rrnewn;
Expand All @@ -449,6 +450,8 @@ Castro::actual_trans_single(const Box& bx, // NOLINT(readability-convert-member
}
eos(eos_input_re, eos_state);
Real pnewn = eos_state.p;
qo_arr(i,j,k,QPRES) = amrex::max(pnewn, small_p);

} else {
// Add the transverse term to the p evolution eq here.
#if AMREX_SPACEDIM == 2
Expand All @@ -457,9 +460,8 @@ Castro::actual_trans_single(const Box& bx, // NOLINT(readability-convert-member
#else
Real pnewn = q_arr(i,j,k,QPRES) - cdtdx * (dup + pav * du * (gamc - 1.0_rt));
#endif
qo_arr(i,j,k,QPRES) = amrex::max(pnewn, small_p);
}

qo_arr(i,j,k,QPRES) = amrex::max(pnewn, small_p);
}
else {
qo_arr(i,j,k,QPRES) = q_arr(i,j,k,QPRES);
Expand Down

0 comments on commit 31ba3d5

Please sign in to comment.