1
$\begingroup$

Subsequently to this answer:

What is the way of generation of TLE file for a satellite? How to deal with BSTAR drag term, mean orbital elements, etc.?

The generated TLE will be used as the input for sgp4 algorithm. Is there already developed package for generation in python?

$\endgroup$
  • $\begingroup$ search for book "COMPUTING NORAD MEAN ORBITAL ELEMENTS FROM A STATE VECTOR" it might help to write code for converting state vector to TLE, it has code in fortran printed in the book. I am dealing with the same problem right now. $\endgroup$ – Kristijonas Grigorovičius Apr 11 at 11:46
2
$\begingroup$

Do not make FAKE TLEs!


Step 1: Read this answer.

Step 2: Review all of the links in the answer. I'll repeat them here:

Step 3: Decide that this is a Bad Idea for the following reasons:

  • Making Fake TLEs is dangerous!! You (or others) may end up confusing them with officially produced TLEs at some later time. It could "poison the deck." The deck could be yours, or somebody else's. What is a "deck"? See the next two items.
  • The TLE + SGP4 ecosystem were produced at a time in history when computing power was quite limited, it does not make sense to start a new effort in 2018 based on these approximations.

enter image description here enter image description here

  • The TLE + SGP4 ecosystem were produced at a time in history when distributing data was quite limited, it does not make sense to start a new effort in 2018 based on parameters that can fit on two cards using a method developed by Herman Hollerith.

enter image description here enter image description here

  • The TLE + SGP4 ecosystem use several approximations that are just not necessary to make. There is nothing involved in doing a better job now that would be harder than understanding the process that is used to determine the parameters in TLEs that give the best results when interpreted through SGP4. This is a closed system and it is best to leave it undisturbed and unmodified and used as-is. That process is:

    1. Obtain TLEs from an official source.

    2. Propagate those TLEs using a widely distributed software package for SGP4 or similar propagator.

$\endgroup$
  • $\begingroup$ Thanks. What I'm trying to do, is to apply maneuvers. So, I need either to generate new TLE, or use another propagator. Please, see space.stackexchange.com/a/26005/19219 $\endgroup$ – Tarlan Mammadzada Mar 21 '18 at 12:38
  • 1
    $\begingroup$ I think you are using SGP4 in your project because you want to avoid learning how to propagate orbits. That resulted in the previous question, and the answer there (which is not helpful) has lead to this question. These are both examples of what is called the XY problem. In short, you are asking "How to solve this problem the wrong way?" Your actual question is "How can I propagate Earth satellite orbits?" and this question requires a text book to answer, rather than a SE answer. $\endgroup$ – uhoh Mar 21 '18 at 12:57
  • $\begingroup$ There is nothing wrong with breaking it into small pieces and asking one at a time, in principle. You might get more responses by showing what you've tried, as examples of efforts. This would probably be more effective than small bounties, which are extremely expensive for you but not very valuable to many users. $\endgroup$ – uhoh Mar 21 '18 at 12:59
  • $\begingroup$ Ok, I would assume that SGP4 only for tracking on the basis of NORAD's TLEs. For propagation and maneuvers I would develop a numerical method. Accepting your answer. $\endgroup$ – Tarlan Mammadzada Mar 21 '18 at 13:14
  • 3
    $\begingroup$ While there is merit for this answer and I agree we have likely an XY problem here, I myself have been required to generate TLEs for simulated orbits in the past. And the TLE message has plenty space for leaving warnings such as satellite number 00000, classification F for Fake, international designation year =49 (before sputnik), wrong checksums, etc. So I don't see much of a danger here. $\endgroup$ – Mefitico Jan 18 at 16:17
3
$\begingroup$

What exactly do you mean by ‚generate‘?

TLEs are mainly used by NORAD, you can find a specification on their website, telling you what exactly any particiluar character of the TLE means. That will be helpful if you want to create your own.

If you just want to read TLEs for existing spacecraft, there is a big list on NORAD‘s website, where you can download any TLE for any tracked object.

There are quite a few python libraries for dealing with TLEs, using those you can just plug in a string and get SGP4 computed locations for any time in the future or past of the vessel.

I am not sure however if there is a python library for creating TLEs from orbital data, you will have to just do it yourself using the specification.

$\endgroup$
  • $\begingroup$ Thanks for the answer. I've already implemented sgp4, which reads data from NORAD's service. What I've asked is, how to generate the characters of TLE, such as BSTAR drag term, mean orbital elements, etc.? $\endgroup$ – Tarlan Mammadzada Mar 21 '18 at 0:14
  • $\begingroup$ There are several reasons why there aren't such libraries! $\endgroup$ – uhoh Mar 21 '18 at 4:44
  • 2
    $\begingroup$ A perfectly valid reason to be willing to do it (and to ask for it in SE) is to learn. I don't think there's any harm in sharing this type of knowledge or in writing open-source libraries. Even if it's just for the fun of it... $\endgroup$ – Carles Araguz Nov 27 '18 at 20:55

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.