Skip to content

Commit

Permalink
Update C++ code to Vallado revision of 2023 May 09
Browse files Browse the repository at this point in the history
  • Loading branch information
brandon-rhodes committed Jul 2, 2023
1 parent 97b7653 commit fac882a
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 5 deletions.
2 changes: 2 additions & 0 deletions extension/SGP4.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2143,6 +2143,7 @@ namespace SGP4Funcs
* included at the end of the second line of data. this only works with the
* verification mode. the catalog mode simply propagates from -1440 to 1440 min
* from epoch and is useful when performing entire catalog runs.
* update for alpha 5 numbering system. 4 mar 2021.
*
* author : david vallado 719-573-2600 1 mar 2001
*
Expand Down Expand Up @@ -2302,6 +2303,7 @@ namespace SGP4Funcs
// ---- find no, ndot, nddot ----
satrec.no_kozai = satrec.no_kozai / xpdotp; //* rad/min
satrec.nddot = satrec.nddot * pow(10.0, nexp);
// could multiply by 0.00001, but implied decimal is set in the longstr1 above
satrec.bstar = satrec.bstar * pow(10.0, ibexp);

// ---- convert to sgp4 units ----
Expand Down
15 changes: 10 additions & 5 deletions sgp4/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,16 @@
"""Track Earth satellites given TLE data, using up-to-date 2020 SGP4 routines.
This package compiles the official C++ code from `Revisiting Spacetrack
Report #3 <https://celestrak.org/publications/AIAA/2006-6753/>`_ (AIAA
2006-6753) and uses it to compute the positions of satellites in Earth
orbit. Orbital elements can be read from either a legacy TLE file or
from a modern OMM element set, both of which you can fetch from a site
like `CelesTrak <https://celestrak.com/>`_.
Report #3`_ (AIAA 2006-6753) — specifically, the 2023 May 09 release
from David Vallado’s `Fundamentals of Astrodynamics and Applications`_
webpage — and uses it to compute the positions of satellites in Earth
orbit. Satellite orbital elements can be loaded from either a legacy
TLE file or from a modern OMM element set, both of which you can fetch
from a site like `CelesTrak <https://celestrak.com/>`_.
.. _Revisiting Spacetrack Report #3: https://celestrak.org/publications/AIAA/2006-6753/
.. _Fundamentals of Astrodynamics and Applications: https://celestrak.org/software/vallado-sw.php
If your machine can’t install or compile the C++ code, then this package
falls back to using a slower pure-Python implementation of SGP4. Tests
Expand Down

0 comments on commit fac882a

Please sign in to comment.