Update pair_lj_improved_cut.cpp

Corrected energy calculation for r-RESPA
This commit is contained in:
Mateo Rodríguez
2025-04-18 13:48:10 +02:00
committed by GitHub
parent 95a0c0a69a
commit 8adc2d3391

View File

@ -531,6 +531,12 @@ void PairLJImprovedCut::compute_outer(int eflag, int vflag)
if (eflag) {
r = sqrt(rsq);
rx = r / rm[itype][jtype];
n_x = alpha[itype][jtype] * rx * rx + beta[itype][jtype];
ilj1 = epsilon[itype][jtype] * gamma[itype][jtype] * pow(1 / rx, n_x) /
(n_x - gamma[itype][jtype]);
ilj2 = -epsilon[itype][jtype] * n_x * pow(1 / rx, gamma[itype][jtype]) /