calc length ranges