check2d
    Preparing search index...

    Function almostEqual

    • Compares two numbers for approximate equality within a given tolerance.

      Useful for floating-point calculations where exact equality (===) is unreliable due to rounding errors.

      Parameters

      • a: number

        First number to compare

      • b: number

        Second number to compare

      • Optionaleps: number = EPSILON

        Allowed tolerance (default: global EPSILON)

      Returns boolean

      true if numbers differ by less than eps