tleread() loading incorrect data

Hello,
I'm trying to load TLE data to MATLAB using tleread function. Examining the MeanMotion values, they seem to either be loaded incorrectly or some conversion is going on. I tried to look in the help files for the tleread but couldn't find any details.
For instance, this is the tle data for the Iridium constellation: https://celestrak.org/NORAD/elements/gp.php?GROUP=iridium&FORMAT=tle
When saved as a .tle file and loaded to MATLAB, the MeanMotion values are incorrect.
I'm using MATLAB online, so version R2024a. I also tried it on a locally installed MATLAB (2024a), and getting the same results.
Am I missing something?

3 comentarios

dpb
dpb el 8 de Ag. de 2024
Editada: dpb el 8 de Ag. de 2024
which -all tleread
/MATLAB/toolbox/aero/spacecraft/tleread.p
Unfortunately, it's published as a p instead of as an m file, so can't see what it may be doing, but agreed; that doesn't seem to match anything in the records.
Only MATHWORKS can answer this since it is p-code; submit an official bug report.
There is an <FEX submission> that reads the tle file that you might use as a workaround in the meantime, or it doesn't appear to be too difficult to roll your own although it is somewhat tedious to parse fixed width files with MATLAB's toolset...
am
am el 8 de Ag. de 2024
Thank you for your reply! I have just submitted a bug report.
Kurt
Kurt el 20 de Sept. de 2024
Editada: Kurt el 20 de Sept. de 2024
I ran into this too. Apparently Matlab is converting Mean Motion to orbits per second, not orbits per day. The conversion factor is 0.0041667 which equals 360/86400. It took me a while to track down this magic number.

Iniciar sesión para comentar.

 Respuesta aceptada

Gayathri
Gayathri el 9 de Ag. de 2024

3 votos

Hi @am,
The TLE data contains “mean motion” in revolutions/day unit. The “tleread” function in MATLAB reads the “mean motion” in degree/second unit. Hence the change in values is observed.
1 revolution/day = (360/(24*60*60)) degree/second
Hence, all the mean motion values in original TLE data are divided by 240 and this is the value seen in the data read by “tleread” function.
E.g. The first “mean motion” value 14.35329424426931 rev/day is converted to (14.35329424426931/240) degree/second = 0.0598 degree/second.
Hope you find this information helpful.

6 comentarios

dpb
dpb el 9 de Ag. de 2024
That appears to be the cause, but that's nasty! Nowhere can I find it documented that the MATLAB function changes units on the one variable.
I would consider that a poor quality of implementation "feature" and unfortunately, since it's distributed as a p-file, one can't fix it so if one writes code based on the documented content of the tle file, one has to fix up the data first. Ugly...
am
am el 12 de Ag. de 2024
Thank you @Gayathri !
As @dpb wrote, it's not in the documentation and it's weird to map every other variable from the TLE file except for this one. I hope this at least gets noted in the documentation.
dpb
dpb el 12 de Ag. de 2024
I would suggest it is worthy of a bug report on it asking for at least the documentation, but preferably leave the data as are in the original file.
am
am el 12 de Ag. de 2024
I reported it as a bug and have received the following response from the support.
"Thank you for bringing this up. As already mentioned in the MATLAB Answers Thread, the "tleread" function in MATLAB outputs the “mean motion” in degree/second. This is also "documented" if you type "help tleread" in the MATLAB Command Window:
MeanMotion :Mean motion, specified as a scalar double in degrees/second.
But I admit that this should also be mentioned in the "regular" documentation such that there is no confusion about that. I will forward this feedback internally in order to fix this in the documentation."
dpb
dpb el 12 de Ag. de 2024
Editada: dpb el 12 de Ag. de 2024
I'd write back and ask why they think they should mung on the file data in the first place...
Kurt
Kurt el 20 de Sept. de 2024
Agreed, it really threw my Mean Anomaly calculations for a loop.

Iniciar sesión para comentar.

Más respuestas (0)

Categorías

Más información sobre CubeSat and Satellites en Centro de ayuda y File Exchange.

Productos

Preguntada:

am
el 8 de Ag. de 2024

Editada:

el 20 de Sept. de 2024

Community Treasure Hunt

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

Start Hunting!

Translated by