Jump to content

[WIN/MAC/LINUX] KSP Trajectory Optimization Tool v1.6.9 [New MATLAB Version!]


Recommended Posts

13 hours ago, Constan7ine said:

Any idea why this might be the case?

How far out into the future are you uploading your maneuver node? I'm not sure if Gaiiden or Arrowstar has ever confirmed this to be a requirement, but I would do all of my computations and upload the output orbit as close as possible to the departure time as possible. In the past, I would often wait until I was within one orbit of departure, then pause the game to do everything in KSPTOT before uploading and unpausing. This usually gives much more accurate maneuver nodes, though there is still a little wiggle room.

Link to comment
Share on other sites

14 hours ago, Constan7ine said:

Any idea why this might be the case?

 

1 hour ago, SpacedInvader said:

How far out into the future are you uploading your maneuver node? I'm not sure if Gaiiden or Arrowstar has ever confirmed this to be a requirement, but I would do all of my computations and upload the output orbit as close as possible to the departure time as possible. In the past, I would often wait until I was within one orbit of departure, then pause the game to do everything in KSPTOT before uploading and unpausing. This usually gives much more accurate maneuver nodes, though there is still a little wiggle room.

Yea pretty much this. I can't say what's wrong with your orbit without seeing how you loaded it into Mission Architect. Setting up the Initial Orbit was always the most confusing thing for me when I first started. If your initial orbital state is wrong it will completely throw things off. Realistically, you would have orbital parameters within a certain margin to use for planning your mission but in KSP we don't really have any ascent tools yet to give us an orbit from a planned launch trajectory (Arrowstar started working on this but hasn't been able to give it the attention needed as of yet). So the best way is to launch a craft into orbit first so you can import that to the Initial State and plan from there.

Link to comment
Share on other sites

9 hours ago, Gaiiden said:

 

Yea pretty much this. I can't say what's wrong with your orbit without seeing how you loaded it into Mission Architect. Setting up the Initial Orbit was always the most confusing thing for me when I first started. If your initial orbital state is wrong it will completely throw things off. Realistically, you would have orbital parameters within a certain margin to use for planning your mission but in KSP we don't really have any ascent tools yet to give us an orbit from a planned launch trajectory (Arrowstar started working on this but hasn't been able to give it the attention needed as of yet). So the best way is to launch a craft into orbit first so you can import that to the Initial State and plan from there.

I time warped until about 10 minutes prior to the burn as stated in KSPTOT, computed a departure burn by loading in the vessels orbital information, and then uploaded the burn, and once again it was wrong. And once again if I shift it backward about 10 minutes I get somewhat of an encounter with jool.

There appears to be little to no difference whether I do this in the mission architect or straight from the "Compute Departure Burn" screen. In the latter case all I'm doing is getting a porkchop for kerbin to jool, setting my estimated arrival time about 2 years ahead of the departure time. And then computing a departure burn from oribtal information loaded from the active vessel.

Oh by the way, thanks for your help, I'm much appreciative.

Link to comment
Share on other sites

2 hours ago, Constan7ine said:

I time warped until about 10 minutes prior to the burn as stated in KSPTOT, computed a departure burn by loading in the vessels orbital information, and then uploaded the burn, and once again it was wrong. And once again if I shift it backward about 10 minutes I get somewhat of an encounter with jool.

If you can recreate this with nothing but stock post the MAT file with just the initial orbital data and I'll see if I can replicate.

However I notice you said "computed a departure burn by loading in the vessels orbital information, and then uploaded the burn" - if those were the only steps you took then it's possible you're not going to get an intercept. You have to take the orbit into Mission Architect and optimize it to ensure you find a trajectory to Jool. Note that on a recent Eve mission planning plugging the burn numbers straight into Mission Architect after setting up my initial orbital state to match that which generated the transfer burn got me an SOI hit without needing to optimize, but that won't always be the case

Link to comment
Share on other sites

 

11 hours ago, Gaiiden said:

If you can recreate this with nothing but stock post the MAT file with just the initial orbital data and I'll see if I can replicate.

I recreated this as you asked, using the MA_example_MissionToLaythe.mat file that comes with the KSPTOT. The only mods involved were mechjeb which I used to put the rocket in a 100km orbit for me, and some visual mods (scatterer, EVE and DistantObjEn). The rocket was the base Kerbal X, and I did it in a new save file on KSP 1.0.5.

I uploaded my initial parameters and saved them in this mat file, which is essentially the same as the base MissionToLaythe file.

https://dl.dropboxusercontent.com/u/53792213/With_Initial_Parameters_MissionToLaythe.mat

Thanks for doing this!

EDIT: I tried this with absolutely no mods at all, excluding KSPTOT connect. And it behaved exactly the same.

Edited by Constan7ine
More info.
Link to comment
Share on other sites

@Constan7ine sorry I did mean to look at this earlier this week. I was able to get a Jool intercept based on what you gave me - can you upload the actual MAT file you optimized and showed you a Jool intercept before you loaded the maneuver into KSP?

Edited by Gaiiden
tagged user because I didn't quote him in case he was waiting for a notification
Link to comment
Share on other sites

Has anyone gotten this to work on Windows 10?  When I try to run KSPTOT.exe it gives me an error saying "Could not find version 8.4 of MCR."  However when I try to get that version of MCR I can't run it because it gives me an error saying "This app can't run on your PC"  So if anyone has any ideas on how to solve this issue that'd be great.  Also, I have tried compatibility modes trying to get the MCR to install.

Link to comment
Share on other sites

So Im having some issues trying to use this. I suspect my worries stem from not using the stock solar system. My install has the Outer Planets Mod, Trans-Keptunian Objects, and Sigma Binary (and quite a lot besides, but those are the only ones that adjust the planets). In trying to generate a bodies.ini, it seems to have worked, in that I can open the generated bodies.ini (well, I called it bodies_opm.ini) and it has all the bodies in it. However, loading it in the program doesnt do anything other than play a windows error message sound after a while. If I rename the new file to be bodies.ini (and rename the standard one also) and restart, KSPTOT played the error message that Plock-Karen was an invalid name. No matter, I edited the name using notepad. Now I get another error, that X, Y, and Weight must not be equal to NaN on line 18 of the main file. I guess I am missing something, or possibly KSPTOT does not support Sigma Binary?

Cheers for the help.

 

EDIT: well, I sorted the problem out, by removing the dash in the Plock-Karen name. Now it loads! Cheers anyway!

Edited by blu3wolf
Link to comment
Share on other sites

What's the proper way to get Mission Architect to calculate a burn to put the periapsis at a specific altitude over a specific longitude? I'm setting constraints for both in the optimizer, but I'm not sure what to put in the coast before the DV maneuver to get it to wait whatever amount of time is necessary to do that.

Link to comment
Share on other sites

57 minutes ago, dlrk said:

What's the proper way to get Mission Architect to calculate a burn to put the periapsis at a specific altitude over a specific longitude? I'm setting constraints for both in the optimizer, but I'm not sure what to put in the coast before the DV maneuver to get it to wait whatever amount of time is necessary to do that.

Coast to Ap, save and then re-edit it to a coast to True Anomaly so the optimizer can move around your burn point from there, use Minimize Distance to Body with the Pe Alt and lng constraints and that could work

@blu3wolf coulda just copied my working OPM .ini file in the post above yours :P

Edited by Gaiiden
Link to comment
Share on other sites

5 hours ago, Gaiiden said:

 

@blu3wolf coulda just copied my working OPM .ini file in the post above yours :P

In fact, it was seeing your working OPM file that clicked me as to where the fault was in mine. I had guessed the characters as being the fault, but I missed seeing that Plock was much higher up in the file, so I didnt end up fixing it correctly. Once I saw Plock much higher up in your file, I worked out what I had done, and made a fresh file and fixed it correctly. So!

Now I just need to work out how to use this Mission Architect Tool! Ive done the mission to Laythe tutorial, and I think I have the hang of it... Im going to try find a flyby using Flyby Finder (is that an apt name or what?), and then see if I can throw its numbers into Mission Architect and use the optimizer to 'goal-seek' as the tutorial calls it. I cant run the mission just yet, as I am not yet at the interplanetary stage of my career (would need either bigger life support stuff or an interplanetary RT dish at a minimum), but it would be great just to be able to open up more frequent launch windows than the direct Hohmann transfers that AlexMoon's porkchop plotter gives me. Also flybys are cool. It does seem like a tutorial on those could be helpful, but I think there was enough info in the first tutorial to work it out. Wish me luck!

Link to comment
Share on other sites

@dlrk In MA otherwise the True Anomaly value won't be properly converted (in case you didn't notice, changing a coast state will convert the value where possible. Simple example is change a delta time to UT)

@blu3wolf Note Arrowstar hasn't gotten back to me on the implications of OPM's binary systems from that post I made, so if you have any enabled you may have issues there

Link to comment
Share on other sites

On 12/19/2015 at 9:08 PM, Gaiiden said:

@Constan7ine sorry I did mean to look at this earlier this week. I was able to get a Jool intercept based on what you gave me - can you upload the actual MAT file you optimized and showed you a Jool intercept before you loaded the maneuver into KSP?

Sorry I haven't replied in ages. That is the actual file I used, the one I previously uploaded. I just uploaded the maneuver from the DV Maneuver part of the Mission architect, straight into KSP.

Is this the procedure you used to upload the burn to KSP?

Link to comment
Share on other sites

7 hours ago, Constan7ine said:

Sorry I haven't replied in ages. That is the actual file I used, the one I previously uploaded. I just uploaded the maneuver from the DV Maneuver part of the Mission architect, straight into KSP.

Is this the procedure you used to upload the burn to KSP?

If that was the MA file you constructed I'm not sure why you're confused it didn't work since you don't even have a Jool intercept in it, so of course you're not going to get a Jool intercept in the game. I'm not going to be able to help further until I get home on the 3rd unless Arrowstar or maybe @diomedea have some time. Have another look at the Laythe tutorial to optimize your trajectory to find a Jool intercept

Link to comment
Share on other sites

I confess, so far I am not having much luck using the optimizer to 'goal-seek', as the tutorial puts it. I am trying to nail down the figures from FlybyFinder, for a Kerbin-Eve-Kerbin-Duna mission, and the optimizer is having trouble finding it. The first part, the Kerbin-Eve portion, worked - I was able to get an Eve intercept with the MA tool, with almost exactly the same numbers that FlybyFinder had. Optimizing from that to a Kerbin intercept afterwards is less successful.

Any tips on how to get the most out of the Optimizer?

EDIT: well Ive just worked out my current issue - the flyby Im currently looking at is on the wrong side of the planet, sending me further inwards towards Kerbol rather than back outwards towards Kerbin. Im not really sure how to fix that, so I guess Ill mess around with the Optimizer some more...

EDIT: well, looks like I should have held off a bit on posting for help with that aspect of the flyby. Will report back with results, but I think the optimizer should have more luck now that the trajectory will be the right way out from Eve. Setting a RAAN constraint 180 off from the current worked a charm!

Edited by blu3wolf
Link to comment
Share on other sites

Nope, ultimately still no luck getting the optimizer to calculate a gravity assist trajectory just yet. Getting to another body works, but using that body to slingshot me to a different one without a massive corrective burn is not happening yet.

Anyone else been able to do this? Got any tips if so?

Link to comment
Share on other sites

you're beyond my help - never done any flyby maneuvers. Just remember the optimizer works best with narrow constraints. So you should do as much manual work as possible and then let it "sand down" the rough edges to give you whatever precision you need

Link to comment
Share on other sites

Mmm. Uploading a maneuver with KSPTOTConnect has resulted in me not being able to make maneuver nodes with the map. Possibly it changed the conics mode also, because now I cannot see past the SOI change in KSP?

The node itself uploaded, but I couldnt actually see it in the map view - although in the vessel view, and using RPM, from the IVA, I could see the maneuver.

Guess Ill have to go mess with the save file to get my maneuver nodes and conics sections back.

EDIT: restarting KSP fixed the issue, no save file changes needed to be made. Guess Ill have to work out if its the uploading a manuever that triggers it, or just the KSPTOTConnect or something else entirely.

Edited by blu3wolf
Link to comment
Share on other sites

Interesting. Adding the maneuver appears to have no effect on the flight path - but the maneuver is definitely there; the values for it can be seen in PreciseNode, and the time to burn and burn vector are displayed in the craft view. It just doesnt want to show its effects on my flight path for some reason.

EDIT: for some reason it seems to be working as intended now? Im not sure what happened, but the flight path effects are now shown correctly. Perhaps it was screwing up before from my first (failed) attempt to add a maneuver node which happened to be in the past.

Edited by blu3wolf
Link to comment
Share on other sites

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