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

Acknowledgments to Parvalli #1671

Merged
merged 1 commit into from
Sep 18, 2017
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 5 additions & 3 deletions package/MDAnalysis/lib/pkdtree.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,9 @@ class PeriodicKDTree(object):
A tree is first constructed with the coordinates wrapped onto the central
cell. A query for neighbors around a center point is performed first by
wrapping the center point coordinates to the central cell, then generating
images of this wrapped center point and finally searching for neighbors
close to the images.
images of this wrapped center point (thanks to
https://github.com/patvarilly/periodic_kdtree for the idea) and finally
searching for neighbors close to the images.

Only the necessary number of center point images is generated for each
case. For instance, if the wrapped center point lies well within the cell
Expand Down Expand Up @@ -146,7 +147,8 @@ def set_coords(self, coords):

def find_centers(self, center_point, radius):
"""
Find relevant images of a center point.
Find relevant images of a center point, inspired by
https://github.com/patvarilly/periodic_kdtree

Parameters
----------
Expand Down