Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Volume Moves can be too large, resulting in negative volume #525

Open
LSchwiebert opened this issue May 18, 2024 · 0 comments · May be fixed by #526
Open

Volume Moves can be too large, resulting in negative volume #525

LSchwiebert opened this issue May 18, 2024 · 0 comments · May be fixed by #526
Assignees
Labels

Comments

@LSchwiebert
Copy link
Collaborator

Describe the bug

Because the maximum adjustment for the volume move can be only a bit smaller than the total volume of the box, it's possible to have a move attempt that results in a negative volume. This causes the simulation to terminate with an error message.

To Reproduce

This was observed with a long-running simulation that uses the GEMC-NPT ensemble. A combination of bad luck, with a small reduction in the volume that is accepted, followed by a random decision to reduce the volume by nearly the maximum amount will result in a negative box volume.

Expected behavior

The maximum volume transfer amount should be smaller, so that the volume is changed modestly and won't underflow.

Screenshots

Example output with some additional debugging information.

Volume Move: Scale is 2.32458238e+06 for box 1
Changing volume by -2.48648638e+05
Current volume is 2.33258238e+06 and new volume is 2.08393374e+06
New dimensions of [1.27730507e+02, 1.27730507e+02, 1.27730507e+02]
Old dimensions of [1.32621010e+02, 1.32621010e+02, 1.32621010e+02]

Volume Move: Scale is 2.32458238e+06 for box 1
Changing volume by -2.30452861e+06
Current volume is 2.08393374e+06 and new volume is -2.20594872e+05
New dimensions of [-6.04224695e+01, -6.04224695e+01, -6.04224695e+01]
Old dimensions of [1.27730507e+02, 1.27730507e+02, 1.27730507e+02]

WARNING!!! Box 1 shrunk below 2*Rcut! Auto-rejecting!
Volume was reduced from 2.08393374e+06 to -2.20594872e+05
Old Axis Dimensions: [1.27730507e+02, 1.27730507e+02, 1.27730507e+02]
New Axis Dimensions: [-6.04224695e+01, -6.04224695e+01, -6.04224695e+01]
Exiting!

Input files

Not uploaded, since I will submit the patch.

Please complete the following information:

  • OS: CentOS
  • Ensemble: GEMC-NPT
  • Code version: 2.75, development branch

Additional context

N/A

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant