Figure out how to do lambertSolver() giving R1,V1,R2,V2 instead of R1,V1,R2,T (because we don't care about time; we never care about time, its space travel, for fucks sake),.
That will give a proper normal to the B-plane instead of having to make it up and it should be several orders of magnitude more accurate.
Last edit: Stäphen Goedzal 2020-08-23
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
The problem seems to be we cant figure out V2 accurately enough. KSP/kOS might not be able to calculate it well enough - it should be close to 90°,, but not exactly and the furthur away you are, the bigger the error.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I just noticed unity only uses 32-bit maths, so it will always be horribly wrong.
Recommend only using tcm when closer to the body - it becomes more accurate as you get closer.
Most recent attempt achieved 38km from a requested 40km orbit around Minmus. That was run a little over 1/2 way there.
Last edit: Stäphen Goedzal 2021-05-12
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Some of the errors may have been caused by slightly inaccurate R2 vectors fed into the lambert solver. r97 has this fixed and tested. It is still slightly off but as mentioned above it's most probably caused by having to "guess" V2 (hyperbolic velocity).
Last edit: Stäphen Goedzal 2023-02-04
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Probably due to miscalculation of hyperbolic velocity. Particularly, the angle.
B-frame maths seems to work nicely.
Last edit: Stäphen Goedzal 2019-06-20
Figure out how to do lambertSolver() giving R1,V1,R2,V2 instead of R1,V1,R2,T (because we don't care about time; we never care about time, its space travel, for fucks sake),.
That will give a proper normal to the B-plane instead of having to make it up and it should be several orders of magnitude more accurate.
Last edit: Stäphen Goedzal 2020-08-23
The problem seems to be we cant figure out V2 accurately enough. KSP/kOS might not be able to calculate it well enough - it should be close to 90°,, but not exactly and the furthur away you are, the bigger the error.
I just noticed unity only uses 32-bit maths, so it will always be horribly wrong.
Recommend only using tcm when closer to the body - it becomes more accurate as you get closer.
Most recent attempt achieved 38km from a requested 40km orbit around Minmus. That was run a little over 1/2 way there.
Last edit: Stäphen Goedzal 2021-05-12
correctout4() seems to be pretty precice, though not very accurate. We can now even run tcm before the periapse!
Still working on it...
Some of the errors may have been caused by slightly inaccurate R2 vectors fed into the lambert solver. r97 has this fixed and tested. It is still slightly off but as mentioned above it's most probably caused by having to "guess" V2 (hyperbolic velocity).
Last edit: Stäphen Goedzal 2023-02-04