docs: public static boolean approxEquals(double value1,
                                         double value2,
                                         double tolerance)
      {
          if (tolerance < 0 || tolerance > 1)
          {
              throw new IllegalArgumentException("Tolerance must be between 0 and 1.");
          }
          return Math.abs(value1 - value2) <= value1 * tolerance;
      }