Jump to content

Mechjeb relative inclination


Recommended Posts

Hello,

When I select moon as a target then in Mechjeb's "Rndezvous Planner" i can see relative inclination. When it reaches 0 it means that my rocket on landing pad is inside moon's orbital plane. This mean that if I launch when relative inclination is 0 I will be able to match moon's orbital inclination with least delta-v. That much I understand. The queston is how do I calculate relative inclination without using Mechjeb? I want to write a program in kOS that will automatically launch when relative inclination is near 0.

Link to comment
Share on other sites

Hmmmm. Well, there are two possibilities -- either you are doing a direct (pure vertical) launch, or you are doing a gravity turn into LKO. But in either case, I don't think you are going to get what you want.

The condition you are talking about is "being at the ascending or descending node".

But if you are doing a gravity turn into LKO, then what matters is that you are at the node when you do your transfer burn to the target -- it doesn't matter at all what your inclination is when you launch. In fact, if you launch at the node, then you will be late for the transfer burn (you will be past the node) once you've done an orbit around Kerbin.

OTOH, if you are doing a direct ascent, then you are already doing a non-optimal launch profile from a deltaV perspective. And one of the benefits of direct launches is that you can launch once per day and it only takes a small course correction to account for any inclination differences.

 

Link to comment
Share on other sites

Well it's called "relative inclination" in Mechjeb and I was wondering what does it have to do with inclination. Obviously I want to do a gravity turn to LKO with the inclination matching the Moon's inclination. In order to do that I need to launch before the point when my position on the launchpad is below Moon's orbit. Then I would launch making dogleg maneuver to match moons orbital inclination. The question is how do I know (mathematically) when I'm exactly at that spot below Moon's orbit?

Link to comment
Share on other sites

What 'relative inclination' has to do with inclination:

If inclination is the angle of your orbital plane compared to the equatorial plane (or ecliptic, or whatever), relative inclination is your inclination relative to the orbital plane of whatever you want to rendezvous with.  Its only relationship to your orbital inclination is that both compare the tilt of your orbital plane to something else.  Orbital inclination compares it to the parent body; relative inclination compares it to another satellite.  The Mun is a bad example for this because it orbits at zero inclination already; a standard eastward launch puts you in a matched orbital plane automatically.  Minmus is a better example; twice per day, the KSC passes through Minmus's orbital plane.  This is true of every point on Kerbin's surface up to six degrees of latitude away from the equator, six degrees being Minmus's orbital inclination.  At points further north and south, it costs far too much fuel to try to match inclinations while launching; you are better off launching and then correcting your inclination later.

How to match your orbits:

What you need to calculate is the longitude of the ascending node.  Here is another discussion about a related topic (writing a kOS script to launch satellites into specific orbits for contracts), but the basic idea is this:  let us consider an object orbiting Kerbin in an inclined orbit.  The points of intersection between the inclined orbital plane and the equatorial plane--where the orbiting object 'bursts through' the equatorial plane, so to speak, are called the ascending and descending nodes.  The ascending node is the one where the object breaks the plane in a positive normal (north) direction.  But where is it in 3-D space?  If I launch a rocket into LKO with a ten-degree inclination, and launch another one an hour later, the two resulting orbits are not coplanar.  The two rockets' ascending nodes are at different points along Kerbin's celestial 'equator'.

The longitude of the ascending node tells the angle of the ascending node with respect to a line drawn from Kerbin's centre to a fixed point in space.  In reality, we use a far-away star for Earth-orbiting satellites, but KSP has no far-away stars, so it's a direction in space that points to nothing.  The important part is that it is Kerbin-centric, but no co-rotating:  in other words, it only pays attention to Kerbin's location, not its orientation.  All objects orbiting Kerbin at a nonzero inclination have a longitude of the ascending node with respect to Kerbin's reference direction, and the value of that longitudinal angle is a fixed property of their orbits.

To match for a launch, you need to find out what the longitude of the ascending node is, figure out your own celestial longitude (surface longitude will not do, because it rotates) and, when the two are equal, launch into an orbit matching the inclination of your target.

Once you know what the reference direction is, you can calculate KSC's current orientation using the time of day.  I do not know whether the reference direction precesses with Kerbin's orbit around the Sun or is utterly absolute; if it is absolute, you will also need to factor the time of year.  You may also be able to calculate it based on the UP direction, but this is only if you have a core or command pod that faces up (I leave what to do with exotic spaceplanes and other craft as an exercise for the reader).

Link to comment
Share on other sites

Presumably this is not in the stock universe, otherwise in stock the question would be moot for the scenario you describe.  (In stock, the Mun is in an equatorial orbit, and the KSC launchpad is on the equator, so you're always in the Mun's orbital plane whenever you launch.  Clearly you're using one of the many mods that changes the solar system a bit, but your post didn't mention which one.).

If you're launching from the equator, then your relative inclination vs the Mun should be static no matter where you are in the day.  Your "orbit" is an equatorial one at that point, albeit one that has a periapsis deep inside the planet (you have an "orbit" because of the rotation of the planet, but the ground beneath you is preventing you from following it and you always stay at the apoapsis of it).  If you're launching from somewhere north or south of the equator (again, you didn't tell us which mod you're using or where you're launching from so I don't know), then your relative inclination would indeed change through the day, because your "orbit" isn't a naturally possible one you could have achived up in space.  Your "orbit" stays at the same fixed non-equatorial latitude all the time, which wouldn't happen to a ship in an actual space orbit (it would cycle back and forth across the equator).  The effect of this is that your landed "orbit" is essentially constant being changed to a new "orbit" by the ground "pushing" you to keep you up at the same latitude.  Because it keeps changing the orbit, your relative inclination to the Mun would indeed always change in this case.  HOWEVER, that doesn't guarantee it will ever hit zero.  To get that you'd have to coincidentally have a launchpad at just the right latitude that you're at the peak of where the Mun's orbit's latitude is, so that as you kiss the Mun's orbit, the Mun's orbit happens to be aimed straight east at that point.

What you proably actually want is one of two things:

Finding not the point where the relative inclination is exactly zero, since that won't happen unless you've got lucky circumstances, but rather the point where it hits its minimum and would start rising again.

or

The point where you cross orbits with the Mun, not where you have the same relative inclination as it.  That would be your ascending node or descending node with the Mun.  Then instead of launching due east, you launch a bit north or south of due east, to match the direction the mun's orbit would have at that point.

Link to comment
Share on other sites

Apoogies I didn't say I play RSS. I though when I refer to Moon instead of Mun it will be clear. Mea Culpa. So the case was that I was launching above the equator. I definitely understand that while I'm landed my ship's orbital inclination is not constans but Moon's inclination is. I did all the visualisation in my head. Very good point that I have to find the minimum of the relative inclination instead of zero that is not always possible. And yes the idea is to launch east facing my ship in the direction of moon's orbit. This of course would be done before that sweetspot so that I have time to match my ship velocity vector with the orbit.
Anyway ... I actually found my solution under link below. I don't yet fully understand how it works but It works. I'm going to figure it out eventually. Thank for your help.
https://www.reddit.com/r/Kos/comments/4nxkfh/mechjebs_relative_inclination_in_kos/

 

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...