Changeset 12003 in josm for trunk/test


Ignore:
Timestamp:
2017-04-26T00:28:45+02:00 (7 years ago)
Author:
Don-vip
Message:

see #13387, see #11924 - raise the allowed difference to 35000 ULPs to catch the worst case (34813 ULP). Logic to remove when JOSM switches to Java 9

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/test/unit/org/openstreetmap/josm/data/projection/ProjectionRegressionTest.java

    r12001 r12003  
    213213    private static boolean equalsDoubleMaxUlp(double d1, double d2) {
    214214        // Due to error accumulation in projection computation, the difference can reach thousands of ULPs
    215         return Math.abs(d1 - d2) <= 3500 * Math.ulp(d1);
     215        // The worst error is 34813 ULP (followed by 6144 ULP then 4193 ULP) with:
     216        // ID74 / UTM zone 49N (EPSG:23849): Projecting latlon(45.59023817877892,104.5874747574324):
     217        // expected: eastnorth(-196.85762506100582,5068568.526775028),
     218        // but got:  eastnorth(-196.85762506199535,5068568.526775027)!
     219        return Math.abs(d1 - d2) <= 35000 * Math.ulp(d1);
    216220    }
    217221
Note: See TracChangeset for help on using the changeset viewer.