Skip to content

Commit

Permalink
cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
psharda committed Aug 1, 2023
1 parent 6c908cf commit 05af4d1
Showing 1 changed file with 1 addition and 16 deletions.
17 changes: 1 addition & 16 deletions src/HLLC.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ AMREX_FORCE_INLINE AMREX_GPU_DEVICE auto HLLC(quokka::HydroState<N_scalars, N_ms
cs_tilde = std::sqrt((1.0 / C_tilde_P) * (H_tilde - 0.5 * vsq_tilde - C_tilde_rho));

const double G_L = 0.5 * (G_gamma_L + 1.); // 'fundamental derivative' for ideal gases
const double G_R = 0.5 * (G_gamma_R + 1.); // 'fundamental derivative' for ideal gases
const double G_R = 0.5 * (G_gamma_R + 1.);

const double s_NL = 0.5 * G_L * std::max(dU, 0.); // second-order wavespeed correction
const double s_NR = 0.5 * G_R * std::max(dU, 0.);
Expand All @@ -82,21 +82,6 @@ AMREX_FORCE_INLINE AMREX_GPU_DEVICE auto HLLC(quokka::HydroState<N_scalars, N_ms
S_R = std::max(sR.u + (sR.cs + s_NR), u_tilde + (cs_tilde + s_NR));
}

// compute nonlinear wavespeed correction [Rider, Computers & Fluids 28 (1999) 741-777]
// (Only applicable in compressions. Significantly reduces slow-moving shock oscillations.)

// const double dU = sL.u - sR.u;
// const double G_L = 0.5 * (G_gamma_L + 1.); // 'fundamental derivative' for ideal gases
// const double G_R = 0.5 * (G_gamma_R + 1.);
// const double s_NL = 0.5 * G_L * std::max(dU, 0.); // second-order wavespeed correction
// const double s_NR = 0.5 * G_R * std::max(dU, 0.);
// amrex::Print() << "GL is " << G_L << " " << G_R << " " << s_NL << " " << s_NR << std::endl;

// compute wave speeds following Batten et al. (1997)

// const double S_L = std::min(sL.u - (sL.cs + s_NL), u_tilde - (cs_tilde + s_NL));
// const double S_R = std::max(sR.u + (sR.cs + s_NL), u_tilde + (cs_tilde + s_NL));

// carbuncle correction [Eq. 10 of Minoshima & Miyoshi (2021)]

const double cs_max = std::max(sL.cs, sR.cs);
Expand Down

0 comments on commit 05af4d1

Please sign in to comment.