plumed / plumed2

Development version of plumed 2
https://www.plumed.org
GNU Lesser General Public License v3.0
364 stars 289 forks source link

FIX-2.9 Now the forces from LWALLS should be correct #1111

Closed Iximiel closed 1 month ago

Iximiel commented 2 months ago
Description

This is about #1091, now if a lower wall is asked with an odd exponent, it should give the correct force, and I think also the energy because ene += k * power; now will contribute with a positive and repulsive term in any case.

I think we need some more tests to check this.

Target release

I would like my code to appear in release v2.9

Type of contribution
Copyright
Tests
carlocamilloni commented 2 months ago

shouldn't we back port it as back as possible?

Iximiel commented 2 months ago

shouldn't we back port it as back as possible?

I agree

Iximiel commented 2 months ago

The new commit changes the documentation: I noted that the offset for UPPER was added, and for LOWER was removed, so I slightly changed the documentation accordingly, this should also reflect that the wall is repulsive with the absolute value before the power, (it is correct to put the absolute value in the documentation like that?)