-
Notifications
You must be signed in to change notification settings - Fork 139
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
Use minimum image of particles in EwaldRef #3763
Conversation
Test this please |
Is the underlying issue a premature truncation of the real space sum? If r_i-r_j is outside the cell, then the first term in the sum (centered at zero lattice vector shift) could be rather small, perhaps smaller than the tolerance for the sum overall. |
Yes
The tolerance check is on the sum of the absolute values contributed by grid points on the surface shell. |
I also thought about testing for several shells in a row being below tolerance, but I think once the particles are minimum imaged that is no longer necessary. Also, if a particle ever wandered "far enough" there could still be an issue with not testing enough shells. Since this fixes the reported problem, adds a test for it, and doesn't require any changes to the values used in other tests, can we consider this safe to merge? |
Test this please |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, let's merge this.
Test this please |
Proposed changes
The reference calculation went wrong this time.
When particles don't start within the unit cell, the grid summation of EwardRef doesn't work well. See first commit.
The QMCPACK value is OK. #2105 (comment) passes with this fix.
Closes #2105
What type(s) of changes does this code introduce?
Does this introduce a breaking change?
What systems has this change been tested on?
epyc-server
Checklist