File Exchange

image thumbnail

High Precision Orbit Propagator

version (19.5 MB) by Meysam Mahooti
Precise modeling of satellite's perturbed motion (special perturbations approach)


Updated 30 Mar 2021

View Version History

View License

The motion of a near-Earth satellite is affected by various forces. One of these forces is the Earth's central gravitation and the others are known as perturbations. These perturbations are classified into gravitational and non-gravitational forces. In this case, the equation of motion can be written as:
r ̈=-(GM/r^3)*r+γ_p
γ_p is the vector of additional accelerations induced by the disturbing forces.
γ_p=r ̈_E+r ̈_S+r ̈_M+r ̈_P+r ̈_e+r ̈_o+r ̈_D+r ̈_SP+r ̈_A+r ̈_emp
r ̈_E = Accelerations due to the non-spherically and inhomogeneous mass distribution within Earth (central body)
r ̈_S, r ̈_M, r ̈_P = Accelerations due to other celestial bodies (Sun, Moon and planets)
r ̈_e, r ̈_o = Accelerations due to Earth and oceanic tides
r ̈_D = Accelerations due to atmospheric drag
r ̈_SP, r ̈_A = Accelerations due to direct and Earth-reflected solar radiation pressure
r ̈_emp = Accelerations due to unmodeled forces
Here I have used the following integrator and force model to simulate satellite's perturbed motion:
Integrator: Variable-order Radau IIA integrator with step-size control
Force Model:
- gravity field of the Earth (GGM03S model)
- gravity of the solar system planets (positions of the planets are computed by JPLDE436)
- drag effect using Jacchia-Bowman 2008, NRLMSISE-00, MSIS-86, Jacchia 70 or modified Harris-Priester atmospheric density model (in Accel.m you can uncomment your favorite model)
- solar radiation pressure using geometrical or cylindrical shadow model
- solid Earth tides (IERS Conventions 2010)
- ocean tides
- general relativity
- ECEF2ECI and ECI2ECEF transformations using IAU 2006 Resolution
Simulation starts by running HPOP.m. In InitialState.txt set initial values for your favorite satellite. In HPOP.m you can consider different perturbations by setting them 1 as follows:
AuxParam.n = 70; % maximum degree of central body's gravitation field
AuxParam.m = 70; % minimum order of central body's gravitation field
AuxParam.sun = 1; % perturbation of the Sun
AuxParam.moon = 1; % perturbation of Moon
AuxParam.planets = 1; % perturbations of planets
AuxParam.sRad = 1; % solar radiation pressure
AuxParam.drag = 1; % atmospheric drag
AuxParam.SolidEarthTides = 1; % solid Earth tides
AuxParam.OceanTides = 1; % ocean tides
AuxParam.Relativity = 1; % general relativity
Montenbruck O., Gill E.; Satellite Orbits: Models, Methods and Applications; Springer Verlag, Heidelberg; Corrected 3rd Printing (2005).
Montenbruck O., Pfleger T.; Astronomy on the Personal Computer; Springer Verlag, Heidelberg; 4th edition (2000).
Seeber G.; Satellite Geodesy; Walter de Gruyter, Berlin, New York; 2nd completely revised and extended edition (2003).
Vallado D. A; Fundamentals of Astrodynamics and Applications; McGraw-Hill, New York; 3rd edition(2007).
NIMA. 2000. Department of Defense World Geodetic System 1984. NIMA-TR 8350.2, 3rd ed, Amendment 1. Washington, DC: Headquarters, National Imagery and Mapping Agency.

Cite As

Meysam Mahooti (2021). High Precision Orbit Propagator (, MATLAB Central File Exchange. Retrieved .

Comments and Ratings (39)

Ignacio Gia

Hi. I've been following your code updates and I'm trying to find how one can generate the Harris-Priester coefficients tables that you provide as a function of mean F10.7 solar flux. I'll really appreciate any kind of reference. Best regards, Ignacio.

Pietro De Marchi

Hi. Thank you. Have you uploaded somewhere the scheme of the code?

Mehmet Rauf Geden

Harrison Handley

@Roshan Sah
In InitialState.txt lines 2-7 are the state vector of the satellite/spacecraft in International Terrestrial Reference Frame (ITRF), which is an ECEF frame.
Line 2: x position in ITRF in m
Line 3: y position in ITRF in m
Line 4: z position in ITRF in m
Line 5: x velocity in ITRF in m/s
Line 6: y velocity in ITRF in m/s
Line 7: z velocity in ITRF in m/s

Lines 8 to 12 are satellite specific parameters related to the forces from atmospheric drag and solar radiation pressure.
Line 8 - 10 are self explanatory and in units m^2 and kg.
Line 11: Cr is the radiation pressure coefficient (Cr = 1 + reflectivity of satellite).
Line 12: Cd is the atmospheric drag coefficient of the satellite

Roshan Sah

Can u elaborate on InitialState.txt set initial values of the satellite? what each line of text signifies especially 2-7 line, what kind of data they are and what that represents??

Kazuko Hagiwara

Mark Elowitz

Tool is now a very mature piece of code, suitable for high-precision orbit propagation (similar to the HPOP found in NASA's GMAT tool and STK HPOP). It would be nice to include perturbations from the most massive asteroids, which is needed for very high-precision trajectory propagation. Also, are there any plans to incorporate perturbations due to the Earth's magnetic field? I may have missed this, but does this code include the EGM2008 gravity model, a significant improvement over the former EGM96 model?

Murat Bulut

Feng Xuefeng

Andy Williams

xiupeng Jiang


Hi! How can I update the solar files and so on? I can download them but the format is slightly different. Thanks

Jared Van Cor

Looks like really good stuff, thanks for sharing. I just wish a user document accompanied this. A technical one would be really awesome, but I do see how you link to technical documentation so I wouldn't strike it for that. But really, just pulling out the top of function abstracts into a single document would make learning about this tool box way easier. Still, I am grateful!

xiupeng Jiang

Gabriel Labos

I think this is a plagiarism of the SOFA software (

Hong-Xin Shen

Changyong He

Meysam Mahooti

Dear Ignacio Gia,
Legendre.m is computed based on following reference:
Kind regards,
Meysam Mahooti

Ignacio Gia

I've been struggling to understand the Lagrange.m algorithm, and how the expressions are deducted.
Is there any bibligraphy reference to study these particular derivations used in the Lagrange.m file?
Any help or pointer to the topic will be very much appreciated.
Best regards,

Gatech AE

I've found this to be an extremely useful reference for learning about the numerical application of special perturbations. My only question is, what is the source of the expression for relativistic perturbations?

Meysam Mahooti

Dear Mr. Wang,
Earth orientation parameters (EOP) and space weather data are available in:
and DE405, DE430 and DE436 full matrices can be found on my page in
furthermore, solar and geomagnetic storm indices which are needed in Jacchia-Bowman 2008 atmospheric model are in the following link:

dongfang wang

Dear Dr. Mahooti,
where can I find the related txt or mat file?(such as DE436Coeff.mat )

Rebecca guan

It doesn't work for LEO satellites, if i put a LEO satellite coordinates in ,it will get funny results. Does anybody know how to change it so it can works for LEO?

Alvaro Crespo Serrano

How can I input the characteristics of an own satellite? Is it in InitialState.txt? In which units these parameters must be as I have them in Keplerian Orbital Classic parameters. Thanks in advance :)!

Alvaro Crespo Serrano


Excellent work! Thank you very much!

ahmed morsi

Dear Dr. Mahooti,
Can you add the effect of Magnetic Field

xun li

Hui Wang

ahmed morsi

Dear Dr. Mahooti,
Can you add the effect of Magnetic Field


Do you have the original paper used in the Shadow() function? I'm trying to understand the expressions used and I can't find the source. Thanks in advance!


Dear Dr. Mahooti,
I wonder if the function "Accel(x, Y)" in the section where you compute "% Atmospheric drag", you might want to employ E instead T to transform positions. Note: Please check inside the code JB2008(), I think it already rotates the GMST.

jiang li

Gread job! Just one question. The data in the file True_EnvisatStates.m are supposed to be "True".
Are they generated by some high precision propagator or just from observation data?

Max Mustermann

Arahms Lee

peter anderson

terry moore

Qiu Felix

Excuse me.where can I find the file about the structure of this code ?

Sam Davidson

MATLAB Release Compatibility
Created with R2020a
Compatible with any release
Platform Compatibility
Windows macOS Linux

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!