public double rangeScan(final long rangeCount,final int m,final int h,final int leafUtilization){
  if (rangeCount == 0)   return 0d;
  final double averageSeekTime=Math.max(0,(h - 1)) * diskCostModel.seekTime;
  final double leafFillRate=((double)leafUtilization) / 100;
  final double expectedLeafCount=Math.ceil((((double)rangeCount) / m) * Math.min(1,(1 / leafFillRate)));
  final double estimatedCost=averageSeekTime * expectedLeafCount;
  return estimatedCost;
}

public double rangeScan ( final long rangeCount , final int m , final int h , final int leafUtilization ) { if ( rangeCount == 0 ) return 0d ; final double averageSeekTime = Math . max ( 0 , ( h - 1 ) ) * diskCostModel . seekTime ; final double leafFillRate = ( ( double ) leafUtilization ) / 100 ; final double expectedLeafCount = Math . ceil ( ( ( ( double ) rangeCount ) / m ) * Math . min ( 1 , ( 1 / leafFillRate ) ) ) ; final double estimatedCost = averageSeekTime * expectedLeafCount ; return estimatedCost ; }
return the estimated cost of a range scan of the index .
