From 6c2363e88f8eb86e1331b3dc5f05897436ad9c43 Mon Sep 17 00:00:00 2001 From: Charles Karney Date: Mon, 26 Oct 2020 14:57:52 -0400 Subject: phi2.cpp: remove unused static consts + minor code tweak --- src/phi2.cpp | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'src') diff --git a/src/phi2.cpp b/src/phi2.cpp index 6e810240..c60ca055 100644 --- a/src/phi2.cpp +++ b/src/phi2.cpp @@ -7,9 +7,6 @@ #include "proj.h" #include "proj_internal.h" -static const double TOL = 1.0e-10; -static const int N_ITER = 15; - double pj_sinhpsi2tanphi(projCtx ctx, const double taup, const double e) { /**************************************************************************** * Convert tau' = sinh(psi) = tan(chi) to tau = tan(phi). The code is taken @@ -97,7 +94,7 @@ double pj_sinhpsi2tanphi(projCtx ctx, const double taup, const double e) { sig = sinh( e * atanh(e * tau / tau1) ), taupa = sqrt(1 + sig * sig) * tau - sig * tau1, dtau = (taup - taupa) * (1 + e2m * tau * tau) / - ( e2m * sqrt(1 + tau * tau) * sqrt(1 + taupa * taupa) ); + ( e2m * tau1 * sqrt(1 + taupa * taupa) ); tau += dtau; if (!(fabs(dtau) >= stol)) break; -- cgit v1.2.3