added unavailable range calculation