code: private void calculate(List<String> paths, IAtomContainer mol) {
          AllPairsShortestPaths apsp     = new AllPairsShortestPaths(mol);
          int                   numAtoms = mol.getAtomCount();
          for (int i = 0; i < numAtoms; i++) {
              if (!include(mol.getAtom(i)))
                  continue;
              for (int j = i + 1; j < numAtoms; j++) {
                  if (!include(mol.getAtom(j))) continue;
                  final int dist = apsp.from(i).distanceTo(j);
                  if (dist > MAX_DISTANCE)
                      continue;
                  final IAtom beg = mol.getAtom(i);
                  final IAtom end = mol.getAtom(j);
                  paths.add(encodePath(dist, beg, end));
                  paths.add(encodePath(dist, end, beg));
                  if (isHalogen(mol.getAtom(i)) || isHalogen(mol.getAtom(j))) {
                      paths.add(encodeHalPath(dist, beg, end));
                      paths.add(encodeHalPath(dist, end, beg));
                  }
              }
          }
      }
docs: This performs the calculations used to generate the fingerprint
  @param paths
  @param mol