public double fromBin(int b) {
            if (b > this.bins - 1) {
                return Float.POSITIVE_INFINITY;
            } else if (b < 0.0000d) {
                return Float.NEGATIVE_INFINITY;
            } else {
                return this.scale * (b * (b + 1.0)) / 2.0;
            }
        }
Create a linear bin scheme with the specified number of bins and the maximum value to be counted in the bins.

@param numBins the number of bins; must be at least 2
@param max the maximum value to be counted in the bins
clients/src/main/java/org/apache/kafka/common/metrics/stats/Histogram.java