@Test public void testScaleBetween1and10() { double scaledValue = MathExt.scale(10.0, 0.0, 100.0, 0.0, 10.0); Assertions.assertThat(scaledValue).isEqualTo(1.0); }
public static double scale(double value, double min, double max) { Preconditions.checkArgument(min < max, "min must be less than max"); return (value - min) / (max - min); }
MathExt { public static double scale(double value, double min, double max) { Preconditions.checkArgument(min < max, "min must be less than max"); return (value - min) / (max - min); } }
MathExt { public static double scale(double value, double min, double max) { Preconditions.checkArgument(min < max, "min must be less than max"); return (value - min) / (max - min); }  }
MathExt { public static double scale(double value, double min, double max) { Preconditions.checkArgument(min < max, "min must be less than max"); return (value - min) / (max - min); }  static double scale(double value, double min, double max); static double scale(double value, double min, double max, double minRangeValue, double maxRangeValue); static double between(double value, double min, double max); static long between(long value, long min, long max); }
MathExt { public static double scale(double value, double min, double max) { Preconditions.checkArgument(min < max, "min must be less than max"); return (value - min) / (max - min); }  static double scale(double value, double min, double max); static double scale(double value, double min, double max, double minRangeValue, double maxRangeValue); static double between(double value, double min, double max); static long between(long value, long min, long max);  }