[Proj] bug in PJ_tmerc.c ?

Gerald Evenden gerald.evenden at verizon.net
Wed Jun 1 21:26:29 EDT 2005


Ignore my previous correction to the spherical tmerc inverse.

Current spherical inverse code now contains (from PP1395):

     double D = xy.y / aks0 + P->phi0, xp = xy.x / aks0;

     lp.phi = asin(sin(D) / cosh(xp));
     lp.lam = atan2(sinh(xp), cos(D));

The above is what will be in the next release of libproj4.  Sign of phi
carries through automatically.  The problem code must have been a
messed up carry over from GCTP as I have not touched  the
spherical stuff in years.  Obviously, no one else has been using it.

For pre C99 compilers that cannot handle hyperbolic functions:
it is time to update.  :-)

Thanks for the error report.  And I apologize for the previous
erroneous quicky correction.
_____________________________________
Jerry and the low riders: Daisy Mae and Joshua.
"The whole religious complexion of the modern world is due to the
absence from Jerusalem of a lunatic asylum." Havelock Ellis, 1914




More information about the Proj mailing list