Question related fix shake

Hi all!
I've notice that shake algorithm implemented in LAMMPS adds constraint forces and calculates new positions and virial in post_force() routine, which comes after the calculation of energies. That way, the potential energy would be incorrect as it is calculated considering unconstrained positions. Am I right about that?

Thanks you in advance!
Ana

Hi all!
I've notice that shake algorithm implemented in LAMMPS adds constraint
forces and calculates new positions and virial in post_force() routine,
which comes after the calculation of energies. That way, the potential
energy would be incorrect as it is calculated considering unconstrained
positions. Am I right about that?

i don't know what sources you have looked at, but what i see are only
modifications to the forces (and consequently the virial, because it
depends on the forces). please be so kind and point out the part of
the code that would update the positions.

as far as i can tell (and know) the positions that are used to compute
any energies are unchanged by any changes to the forces until the next
time step.

axel.