Skip to content

Commit 4c5ad6b

Browse files
committed
Correct version this time...
1 parent 68f6ec3 commit 4c5ad6b

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/MainSequence.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -230,10 +230,10 @@ double MainSequence::CalculateGamma(const double p_Mass) const {
230230

231231
double gamma = 0.0; // default return value
232232

233-
if (utils::Compare(p_Mass, 1.0) <= 0) gamma = an[76] + (an[77] * PPOW(std::abs(p_Mass - an[78]), an[79])); // BSE Fortran code has abs()
234-
else if (utils::Compare(p_Mass, an[75]) <= 0) gamma = B_GAMMA + (an[80] - B_GAMMA) * PPOW((p_Mass - 1.0) / (an[75] - 1.0), an[81]);
235-
else if (utils::Compare(p_Mass, (an[75] + 0.1)) <= 0) gamma = C_GAMMA - (10.0 * (p_Mass - an[75]) * C_GAMMA); // see discussion just prior to eq 23 - the end point is wrong in the arxiv version of Hurley et al. 2000 (should be 0.1, not 1.0) - confirmed in BSE Fortran code
236-
else gamma = 0.0; // see discussion just prior to eq 23 - confirmed in BSE Fortran code
233+
if (utils::Compare(p_Mass, 1.0) <= 0) gamma = a[76] + (a[77] * PPOW(std::abs(p_Mass - a[78]), a[79])); // BSE Fortran code has abs()
234+
else if (utils::Compare(p_Mass, a[75]) <= 0) gamma = B_GAMMA + (a[80] - B_GAMMA) * PPOW((p_Mass - 1.0) / (a[75] - 1.0), a[81]);
235+
else if (utils::Compare(p_Mass, (a[75] + 0.1)) <= 0) gamma = C_GAMMA - (10.0 * (p_Mass - a[75]) * C_GAMMA); // see discussion just prior to eq 23 - the end point is wrong in the arxiv version of Hurley et al. 2000 (should be 0.1, not 1.0) - confirmed in BSE Fortran code
236+
else gamma = 0.0; // see discussion just prior to eq 23 - confirmed in BSE Fortran code
237237

238238
return std::max(0.0, gamma); // see discussion following eq 23 - confirmed in BSE Fortran code
239239

0 commit comments

Comments
 (0)