Class GridCell
java.lang.Object
org.biojava.nbio.structure.contact.GridCell
A grid cell to be used in contact calculation via spatial hashing algorithm.
- Author:
- Jose Duarte
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
addIindex
(int serial) void
addJindex
(int serial) getContactsToOtherCell
(GridCell otherCell) Calculates all distances of atoms between this cell and the given cell returning those that are within the given cutoff as a list of Contacts containing the indices of the pair and the calculated distance.Calculates all distances of atoms within this cell returning those that are within the given cutoff as a list of Contacts containing the indices of the pair and the calculated distance.int
int
boolean
hasContactToAtom
(javax.vecmath.Point3d[] iAtoms, javax.vecmath.Point3d[] jAtoms, javax.vecmath.Point3d query, double cutoff) Tests whether any atom in this cell has a contact with the specified query atomtoString()
-
Constructor Details
-
GridCell
-
-
Method Details
-
addIindex
-
addJindex
-
getNumIindices
-
getNumJindices
-
getContactsWithinCell
Calculates all distances of atoms within this cell returning those that are within the given cutoff as a list of Contacts containing the indices of the pair and the calculated distance. IfGrid.getJAtoms()
is null, distances are within the iAtoms only- Returns:
-
getContactsToOtherCell
Calculates all distances of atoms between this cell and the given cell returning those that are within the given cutoff as a list of Contacts containing the indices of the pair and the calculated distance.- Parameters:
otherCell
-- Returns:
-
hasContactToAtom
public boolean hasContactToAtom(javax.vecmath.Point3d[] iAtoms, javax.vecmath.Point3d[] jAtoms, javax.vecmath.Point3d query, double cutoff) Tests whether any atom in this cell has a contact with the specified query atom- Parameters:
iAtoms
- the first set of atoms to which the iIndices correspondjAtoms
- the second set of atoms to which the jIndices correspond, or nullquery
- test pointcutoff
-- Returns:
-
toString
-