# How do I calculate the delta-v with patched conics?

I am trying to calculate the delta-v between Kerbin and Duna from a 70 km circular orbit around Kerbin just to do a flyby of Duna. However, I am running into a couple of difficulties with my calculations. Everything that I read tells me to deal with the heliocentric transfer orbit first, and that is where my problem lies.

The periapsis of the transfer orbit between Kerbin and Duna is the orbit of Kerbin which is 13,599,840,256 m.

the transfer apoapsis is Duna's semimajor axis: 20,726,155,264 m.

This gives a semimajor axis of the transfer orbit of 17,162,997,760 m.

To find the delta-v of the transfer, I need to find the velocity at periapsis of the transfer orbit and subtract Kerbin's orbital velocity from that.

Using $v^2=GM(2/r-1/a)$, I get a transfer velocity at periapsis of 10203 m/s. Kerbin's orbital velocity is 9284.5 m/s.

This gives me a delta-v of 919 m/s. However, the delta-v maps that I am reading say it is 130 m/s from Kerbin escape to Duna intercept.

What am I doing wrong? Why do my numbers not match?

The numbers on the map are not actually independent, you should treat it as saying "950+130" from LKO to Duna flyby.

The number you got, 919 m/s, is the amount of dV you'd need if you were going for a Duna intercept from an orbit similar to Kerbin's, but not actually from Kerbin. The number on the map, 1080 m/s, is a single burn at the right point in the right direction from LKO to Duna intercept. This is taking into account your orbital velocity around Kerbin, Kerbin's gravity and Oberth gains from doing the burn in a gravity well.

We should actually be able to calculate an optimistic estimate of that number:

1. You already calculated that at the point of leaving Kerbin's sphere of influence (SOI), we should be going 919 m/s relative to Kerbin.

2. Since this is patched conics, we have a discrete point of changing SOI - 84 159 271 m, at which we should be going at 919 m/s.

3. Our starting point is LKO, which, from the top of my head, I'm going to say is 80 km high (for an orbital radius of 680 000 m) at a speed of 2 300 m/s.

4. At this point we use the orbital energy conservation equation on step 2, so the orbit energy is $\epsilon = v^2/2 - \mu/r = 380317$.

5. Plugging this into step 3, we know that in LKO $\epsilon_p = 5193527$, so $v = \sqrt{2(\epsilon+\epsilon_p)} = 3339 m/s$

6. The estimated required delta-V is then $3339 - 2300 = 1039 m/s$

Our number does not match the map exactly, but it is an optimistic estimate. Then again, the KSP wiki suggests that we need 1060 m/s to get to Duna, not 1080 m/s. And there will probably be inefficiencies in implementation, e.g. the burn will not be instant, the starting orbit will vary a bit, we probably won't be going in exactly the right direction upon leaving Kerbin's SOI, and we'll probably be at a bit lower periapsis than Kerbin's. These will likely eat up 20-40 m/s.