You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am using mda.analysis.distances.distance_array() to calculate all of the distances between alpha carbons of arginine residue with resid 2 in a cluster and the centroid of the cluster. After identifying the cluster and the coordinates of the centroid, the lines to calculate distances looks like this:
sel=univ.select_atoms(f'resnum 2 and resname ARG and name CA')
dists=distances.distance_array(centroid, sel.atoms.positions, univ.dimensions)
No errors occur and the calculation seems to go smoothly. However, I am getting distances as large as ~89 angstroms in a box with dimensions: [92.57094, 92.57094, 92.57094]. I am under the impression that by passing "univ.dimensions", periodic boundary conditions are supposed to be accounted for through minimum image convention, but there aren't any situations where the clusters in my trajectories should have that large of radii, let alone distances from the centroid. I am just curious if there is a way to assure that periodic boundary conditions will be accounted for.
Thank you
The text was updated successfully, but these errors were encountered:
I'd generally agree with you, I'd expect that the min-image distance between any two coordinates inside the box should always be less than half the longest box diagonal. Can you provide a file or the set of coordinates together with code that shows that the distances are too large?
I am using mda.analysis.distances.distance_array() to calculate all of the distances between alpha carbons of arginine residue with resid 2 in a cluster and the centroid of the cluster. After identifying the cluster and the coordinates of the centroid, the lines to calculate distances looks like this:
No errors occur and the calculation seems to go smoothly. However, I am getting distances as large as ~89 angstroms in a box with dimensions: [92.57094, 92.57094, 92.57094]. I am under the impression that by passing "univ.dimensions", periodic boundary conditions are supposed to be accounted for through minimum image convention, but there aren't any situations where the clusters in my trajectories should have that large of radii, let alone distances from the centroid. I am just curious if there is a way to assure that periodic boundary conditions will be accounted for.
Thank you
The text was updated successfully, but these errors were encountered: