From 3647405bcab1b12b1ad699e7a9970a4d3103680d Mon Sep 17 00:00:00 2001 From: Daniel Warner Date: Wed, 30 Mar 2011 15:35:38 +0100 Subject: [PATCH] Added possible fix from dundee code --- SGDP4.cpp | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/SGDP4.cpp b/SGDP4.cpp index 78b3824..9ff61d2 100644 --- a/SGDP4.cpp +++ b/SGDP4.cpp @@ -287,6 +287,15 @@ void SGDP4::FindPositionSDP4(double tsince) { DeepPeriodics(tsince, e, xinc, omgadf, xnode, xmam); + /* + * TODO: is this needed + */ + if (xinc < 0.0) { + xinc = -xinc; + xnode += Globals::PI(); + omgadf -= Globals::PI(); + } + xl = xmam + omgadf + xnode; xincl = xinc; omega = omgadf;