aboutsummaryrefslogtreecommitdiff
path: root/src/projections/somerc.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/projections/somerc.cpp')
-rw-r--r--src/projections/somerc.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/projections/somerc.cpp b/src/projections/somerc.cpp
index be1f660d..fe6477fa 100644
--- a/src/projections/somerc.cpp
+++ b/src/projections/somerc.cpp
@@ -82,7 +82,9 @@ PJ *PROJECTION(somerc) {
cp *= cp;
Q->c = sqrt (1 + P->es * cp * cp * P->rone_es);
sp = sin (P->phi0);
- Q->cosp0 = cos( phip0 = aasin (P->ctx, Q->sinp0 = sp / Q->c) );
+ Q->sinp0 = sp / Q->c;
+ phip0 = aasin (P->ctx, Q->sinp0);
+ Q->cosp0 = cos(phip0);
sp *= P->e;
Q->K = log (tan (M_FORTPI + 0.5 * phip0)) - Q->c * (
log (tan (M_FORTPI + 0.5 * P->phi0)) - Q->hlf_e *