if (Float.isNaN(lat) || Float.isNaN(lon)) {
if (Float.isNaN(lat) || Float.isNaN(lon)) { Debug.message("proj", "Gnomonic.inverse(): outer space!");
    public LatLonPoint inverse(int x, int y, LatLonPoint llp) {        // convert from screen to world coordinates        x = x - wx;        y = hy - y;//      Debug.output("Gnomonic.inverse: x,y=" + x + "," + y);        float rho = (float)Math.sqrt(x*x + y*y);        if (rho == 0f) {            Debug.message("proj", "Gnomonic.inverse: center!");            llp.setLatLon(                    ProjMath.radToDeg(ctrLat),                    ProjMath.radToDeg(ctrLon));            return llp;        }        float c = (float)Math.atan2(rho, scaled_radius);        float cosC = (float)Math.cos(c);        float sinC = (float)Math.sin(c);        // calculate latitude         float lat = (float)Math.asin(            cosC * sinCtrLat + (y * sinC * (cosCtrLat/rho)));        // calculate longitude        float lon = ctrLon + (float)Math.atan2(                (x*sinC),                (rho*cosCtrLat*cosC - y*sinCtrLat*sinC));//      Debug.output("Gnomonic.inverse: lat,lon=" +//                         ProjMath.radToDeg(lat) + "," +//                         ProjMath.radToDeg(lon));        // check if point in outer space//      if (MoreMath.approximately_equal(lat, ctrLat) &&//             MoreMath.approximately_equal(lon, ctrLon) &&//             (Math.abs(x-(width/2))<2) &&//             (Math.abs(y-(height/2))<2))        if (Float.isNaN(lat) || Float.isNaN(lon))        {//          Debug.message("proj", "Gnomonic.inverse(): outer space!");            lat = ctrLat;            lon = ctrLon;        }        llp.setLatLon(                ProjMath.radToDeg(lat),                ProjMath.radToDeg(lon));        return llp;    }