Noiredd / PEGAS

Powered Explicit Guidance Ascent System - a KSP & RO autopilot using the Space Shuttle guidance algorithm, UPFG
http://forum.kerbalspaceprogram.com/index.php?/topic/142213-pegas-powered-explicit-guidance-ascent-system-devlog
MIT License
114 stars 31 forks source link

Coast phases #8

Open Noiredd opened 7 years ago

Noiredd commented 7 years ago

UPFG in the current implementation assumes that all the burns are executed immediately one after another, but in reality some time is needed between stages to let them separate and ignite. This time is user-input and thus predictable. Lack of handling those small coasts isn't usually a big issue (any error that it generates is eventually accounted for in the next stage), but in some cases this might cause weird behavior. Example of such case is the Saturn V, where the final stage (S-IVb) ignites only for a few seconds to circularize, but before it does, the vehicle is in ballistic flight for a while. Since PEGAS isn't aware of that coast, it doesn't prepare for it, so there are several seconds during which the vehicle is coasting but all the calculations were done assuming it would be thrusting instead. This is the potential cause to the resulting problem*: after the stage ignites, attitude rapidly changes and the vehicle makes two sharp pitches.

In the original implementation, UPFG is able to handle at least one coast stage (period after jettisoning the Shuttle's External Tank, before the OMS burn). The thrust integrals potentially could handle more than that, and implementing it would make PEGAS more robust to coasts, potentially even allowing longer coast periods.

Marking this as future enhancement, since 1) it is not a dire issue, 2) it might be difficult to implement, requiring alpha-test in a prototype environment.

* - this problem has at least one alternative cause: the convergence check could be still imperfect and allow PEGAS to take steering even though the UPFG isn't actually ready yet.