docs: private void linearScan(Relation<? extends O> relation, DBIDIter iter, O obj, double range, ModifiableDoubleDBIDList result) {
      final SquaredEuclideanDistanceFunction squared = SquaredEuclideanDistanceFunction.STATIC;
      // Avoid a loss in numerical precision when using the squared radius:
      final double upper = range * 1.0000001;
      // This should be more precise, but slower:
      // upper = MathUtil.floatToDoubleUpper((float)range);
      final double sqrange = upper * upper;
      while(iter.valid()) {
        final double sqdistance = squared.distance(obj, relation.get(iter));
        if(sqdistance <= sqrange) {
          final double dist = FastMath.sqrt(sqdistance);
          if(dist <= range) { // double check, as we increased the radius above
            result.add(dist, iter);
          }
        }
        iter.advance();
      }
    }