Skip to content

Commit

Permalink
fixed the instability
Browse files Browse the repository at this point in the history
  • Loading branch information
chunshen1987 committed Nov 16, 2023
1 parent e0e158d commit b1090b4
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/dissipative.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -235,9 +235,9 @@ void Diss::Make_uWSource(const double tau, const Cell_small &grid_pt,
if (DATA.FlagResumTransportCoeff) {
double R_shear = 0.;
double R_bulk = 0.;
computeInverseReynoldsNumbers(epsilon + pressure, grid_pt, ////////////////////////////////////////////////////////////////////////
computeInverseReynoldsNumbers(epsilon + pressure, grid_pt,
R_shear, R_bulk);
double r_combined = 1.5*(R_shear+abs(R_bulk));
double r_combined = 1.5*(R_shear + std::abs(R_bulk));
if (r_combined < 1.) {
resummedCorrection = 1./(1. + atanh(r_combined));
} else {
Expand Down Expand Up @@ -627,12 +627,12 @@ double Diss::Make_uPiSource(const double tau, const Cell_small &grid_pt,
double resummedCorrection = 1;
double R_shear = 0.;
double R_bulk = 0.;
computeInverseReynoldsNumbers(epsilon + pressure, grid_pt, ////////////////////////////////////////////////////////////////////////
computeInverseReynoldsNumbers(epsilon + pressure, grid_pt,
R_shear, R_bulk);
double r_combined = 1.5*(R_shear+abs(R_bulk));
if (r_combined) {
double r_combined = 1.5*(R_shear + std::abs(R_bulk));
if (r_combined < 1.) {
resummedCorrection = 1./(1. + atanh(r_combined));
}else {
} else {
resummedCorrection = 1e-4;
Bulk_Relax_time = Bulk_Relax_time*resummedCorrection;
// avoid overflow or underflow of the bulk relaxation time
Expand Down

0 comments on commit b1090b4

Please sign in to comment.