Bug #1501

Wall combined with perturbed energy results in zero interaction for state B

Added by Alexander Schlaich over 6 years ago. Updated over 6 years ago.

Target version:
Affected version - extra info:
Affected version:


For the perturbed energy, the state A is defined as (1-lambda) whereas B is set to
0 and correspondingly the wall interaction for type B is switched off.

I guess the correct expression for the B-state should be lamfac = lambda?

The attached patch against release-4-6 proposes this solution and seems to fix my troubles when performing thermodynamic integration with pbc=xy and nwalls=2.

Associated revisions

Revision 4dcd9bdc (diff)
Added by Berk Hess over 6 years ago

Fixed perturbed wall interactions

With free-energy calculations, the B-state wall force and potential
were set to zero.
Fixes #1501

Change-Id: Ib53073c19fee19979ade96455b6505001187a2fa


#1 Updated by Alexander Schlaich over 6 years ago

Actually, I should add that the total interaction with the wall is accounted for in the derivative of the perturbed Hamiltonian, i.e. in the current implementation state A mimicks a system with the wall present and state B the system without any walls.

I'm not sure if this is the intended behaviour, anyway I did not find something like this in the documentation (maybe I overlooked it, though).

The trouble however starts if you want to determine the free energy of solvation of a particle enclosed between two walls using e.g. thermodynamic integration/BAR/...

Thanks for any feedback!

#2 Updated by Gerrit Code Review Bot over 6 years ago

Gerrit received a related patchset '1' for Issue #1501.
Uploader: Berk Hess ()
Change-Id: Ib53073c19fee19979ade96455b6505001187a2fa
Gerrit URL:

#3 Updated by Berk Hess over 6 years ago

  • Status changed from New to Fix uploaded

#4 Updated by Berk Hess over 6 years ago

  • Status changed from Fix uploaded to Resolved
  • % Done changed from 0 to 100

#5 Updated by Erik Lindahl over 6 years ago

  • Status changed from Resolved to Closed

Also available in: Atom PDF