/** @return the minimum distance between the 1/2 of VDW surface of the selected and that of the unselected. */
	public float getMinimumDistance(BitSet bs) {
		float min = Float.MAX_VALUE;
		boolean bi = false;
		boolean bj = false;
		float xij, yij, zij, rij;
		int imin = -1, jmin = -1;
		for (int i = 0; i < iAtom; i++) {
			bi = bs.get(i);
			for (int j = i; j < iAtom; j++) {
				bj = bs.get(j);
				if ((bi && bj) || (!bi && !bj))
					continue;
				xij = atom[i].rx - atom[j].rx;
				yij = atom[i].ry - atom[j].ry;
				zij = atom[i].rz - atom[j].rz;
				rij = xij * xij + yij * yij + zij * zij;
				if (min > rij) {
					min = rij;
					imin = i;
					jmin = j;
				}
			}
		}
		if (imin == -1 && jmin == -1)
			return min;
		// allow the VDW surfaces to overlap at 50% size
		return (float) Math.sqrt(min) - 0.25f * (atom[imin].sigma + atom[jmin].sigma);
	}