Jump to content

What are patched conics ?


Recommended Posts

Patched conics is a less intensive way of calculating gravitation forces.

It requires less CPU, but has some drawbacks (or some might consider some of these advantages)

  • No Lagrange points
  • No Decaying Orbits
  • The gravity of a moon will not affect you in orbit of a planet.

Normally with N-Body physics the Moon would inevitably pull you out of orbit of Earth, depending on the orbit that can take a very long time (some of our satellites will take billions of years) but it is inevitable anyway. This doesn't happen in KSP because if you are in orbit of Kerbin, the Mun doesn't affect you. The same is true in the opposite direction, Kerbin doesn't affect you in orbit of the Mun. In the real world there isn't a hard SOI like in KSP. However, this is more of an advantage in KSP because you are one person managing a fleet of craft. Trying to correct all your orbits would be annoying.

Lagrange points are a disadvantage of patched conics. In the real world there is a median point where gravitational forces between a body and it's parent body equal out and you can put an object at this point and it will never fall and always maintain it's relative position (well it will move but very little and it always comes back). These are Lagrange points and there are 5 of them around any body. Unfortunately Patched Conics eliminates these points.

Edited by Alshain
Link to comment
Share on other sites

In KSP terms: it's a convenient programming simplification that lightens the load on the game when calculating orbital trajectories. It's why celestial bodies in KSP have a "sphere of influence" (SoI) with a sharply defined boundary-- in the real world, there's no such thing, everything affects everything everywhere.

Wikipedia: Patched conic approximation

In specific gameplay terms, if you hear about "unlocking patched conics", that's an upgrade you get when you level-up the tracking station. It makes orbital paths of your ships show up as blue instead of gray, enables maneuver nodes, and lets you see accurate information about your trajectory (e.g. markers for intercepts, ascending/descending nodes, time to periapsis/apoapsis, etc.)

Link to comment
Share on other sites

KSP does not do n-body gravity simulation, only 1-body at a time.

Is there not a mod for n-body gravity?

I've heard about one, and I've heard it's very unstable. Which is to be expected, as I once coded n-body gravities, and the amount of CPU usage increases so much for each body added that it's simply too much to simulate properly and also stay playable. I for one like patched conics, even though it means certain maneuvers and orbits are impossible in KSP.

Link to comment
Share on other sites

what are patched conics?...

Are you asking what you get with the first tracking station update? The one that makes patched conics visible?

Assuming you are; basically it shows more than the basic information about your orbit, the basic information being the apoapsis, periapsis, and general path of your orbit. With patched conics visible you'll be able to see information about your orbit when it encounters the Mun or other bodies and you'll be able to make maneuver nodes, which help you plan flights and make maneuvers easier. It is an important upgrade, I don't go to the Mun without it.

I hope that answers your question, if not could you clarify? :)

Edited by Finox
Link to comment
Share on other sites

Just increase the SOI such that if your inside one or the other SOI, then both bodies count.

It's not that simple.

The two-body problem (World-and-satellite, or Star-and-Planet) is solved. You can use simple (well, relatively simple) math to calculate the future position of the two bodies an arbitrary amount of time into the future. THat's why the sphere of influence simplification is used; it converts the Kerbal solar system into a set of nested two-body problems.

The three-body problem has no general analytic solution, and you have to use significantly more complicated calculation methods to estimate the position of objects as a function of time.

Link to comment
Share on other sites

Just increase the SOI such that if your inside one or the other SOI, then both bodies count.

Except in N-body physics, the Moon and the Sun affect your orbit while orbiting Earth. It would have to be the same for Kerbin, Kerbol, Mun and Minmus. You can't pick just two unless you are orbiting a moonless body.

Edited by Alshain
Link to comment
Share on other sites

KSP does not do n-body gravity simulation, only 1-body at a time.

Is there not a mod for n-body gravity?

As far as I know, nobody has yet figured out a general solution for an N-body system when N is greater than 2. It can only be approximated by various methods which take a lot of work/code/computing power and don't produce results that are much more accurate than patched conics.

So stop worrying about it and just patch the bloody conics already. :D

(so, what does one patch a conic with?? spackle???)

Link to comment
Share on other sites

As far as I know, nobody has yet figured out a general solution for an N-body system when N is greater than 2. It can only be approximated by various methods which take a lot of work/code/computing power and don't produce results that are much more accurate than patched conics.

So stop worrying about it and just patch the bloody conics already. :D

(so, what does one patch a conic with?? spackle???)

I would like Lagrange points. Also Orbiter does a fine job.

Link to comment
Share on other sites

I would like Lagrange points. Also Orbiter does a fine job.

Orbiter does things differently.

Orbiter (and Celestia) use interpolations from the VSOP87 dataset, based off extremely high-accuracy simulations of the Solar System done for astronomical purposes. For objects that are spacecraft, itdoes a Ruinge-Kutta numerical interpolation for their movements, but for prediction, and for celestial bodies whose data aren't available in VSOP87, it does a two-body simulation.

Link to comment
Share on other sites

Wow. Two pages of answers and nobody actually answers the question without throwing around words like "n-body".

Patched conics.

The typical simplifications that are made to model gravity are that there is only two bodies interacting: The spacecraft and the parent body it is orbiting. It is also assumed that the mass of the spacecraft is insignificant compared to the mass of the parent body. This simplification works well for a lot of situations and KSP always uses it.

Under these circumstances your orbit can have various shapes. It can be a circle, an ellipse, a parabola or a hyperbola. (or even a straight line) All of these shapes are so called conic sections. That means you can get them by cutting a cone in half at different angles. The wikipedia article has a picture that illustrates that.

So know we know what conics are. What about patched?

In KSP we have different celestial bodies. Each of them has a sphere of influence (SoI). Imagine you are orbiting Kerbin, wandering along an elliptical path. Kerbin is the only body that exerts gravity at this time. Now you enter the Mün's sphere of influence. Suddenly the Mün is the parent body and you are nolonger traveling along an ellipse, but rather a hyperbola. However, at the point where you switched the SoI, the hyperbola and ellipse were perfectly tangent. They were "patched" because your trajectory does not have any kink in it.

For KSP gameplay that means: If you unlock patched conics, you are able to see your predicted orbit after an SoI change.

Edited by Chaos_Klaus
Link to comment
Share on other sites

I would like Lagrange points.

KSP already has L4 and L5 points, in a sense--simply put your ship there, with the same orbit and speed as the reference body.

L1 through L3 are each unstable in two directions and therefore not very useful. Ya got a plan that wants an L1-L3 point?

Link to comment
Share on other sites

Come on look at how many missions we have in L1 and L2. Look asking for a little more realism (challenge) is not asking for a perfectly accurate simulation of reality. There are a variety of cheats that could be done that can still provide 1) reasonably accurate predictive flight paths and 2) more interesting/realistic/challenging orbital mechanics.

Link to comment
Share on other sites

Come on look at how many missions we have in L1 and L2. Look asking for a little more realism (challenge) is not asking for a perfectly accurate simulation of reality. There are a variety of cheats that could be done that can still provide 1) reasonably accurate predictive flight paths and 2) more interesting/realistic/challenging orbital mechanics.

The Travelling Salesman Problem doesn't sound even nearly as hard as rocket science. It's still NP-Hard though.

So what you've got to ask yourself is, is it worth making KSP run twice as slow, just so your predicted interplanetary orbit in a couple of years is a few mm more accurate than when using patched conics? Can you perform burns that accurately - both by thrust and time? Would you find it interesting/challenging to keep re-positioning your Kerbin commsats every few months because Eeloo has degraded their orbits (it's undeniably realistic)?

Note particularly that of the 'variety of cheats that could be done', KSP uses patched conics because it works well and efficiently. Yes there is a mod for that, if you answers yes to the questions above.

Link to comment
Share on other sites

The Travelling Salesman Problem doesn't sound even nearly as hard as rocket science. It's still NP-Hard though.

So what you've got to ask yourself is, is it worth making KSP run twice as slow, just so your predicted interplanetary orbit in a couple of years is a few mm more accurate than when using patched conics?

Now here I think you misunderstand me, I don't see why we would need to PREDICT that far ahead, live n-body orbital mechanics is basic arthimatic, the predicting is the hard part, I get that, so the question is can we use cheats to make a decent prediction that only needs to go from one body to the next?

Can you perform burns that accurately - both by thrust and time? Would you find it interesting/challenging to keep re-positioning your Kerbin commsats every few months because Eeloo has degraded their orbits (it's undeniably realistic)?

I would find mascons more interesting yes, we could very well have it that when a vehicle is not active it operates on patch conics, problem fixed.

Note particularly that of the 'variety of cheats that could be done', KSP uses patched conics because it works well and efficiently. Yes there is a mod for that, if you answers yes to the questions above.

and those mods don't work apparently.

Soon we will have full multiple threading support (1.1.0 using Unity 5) I don't see why at the least 2-body would not be possible.

Link to comment
Share on other sites

...I don't see why we would need to PREDICT that far ahead ... to go from one body to the next? ... those mods don't work apparently

The thing is one (planetary) body to the next sort of implies multi-year orbital prediction if you're measuring 'years' in Kerbin time and talking about going to Eeloo (otherwise how would you know a particular burn would get you an encounter?)

Those mods don't work, soooo - design one that does. Someone else might make it for you, but the whole issue is "why would it be better?"

I think we all agree that L-points and that sort of thing would be nice, but the practicality of it all is that even RL space-agencies don't usually bother with those sort of calculations.

BTW - 2-body is, as has been pointed out, what KSP does; your ship and the body it's orbiting. Yes, that could be made more accurate, but for any practical purposes your ship's mass, and therefore gravitational effect, is zero compared to any celestial body, hence moons and planets stay 'on rails'.

Link to comment
Share on other sites

This thread is quite old. Please consider starting a new thread rather than reviving this one.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...