Arrowstar

[WIN/MAC] KSP Trajectory Optimization Tool v1.5.8 [MFMS Updates and RSS Compatibility]

Recommended Posts

KSP Trajectory Optimization Tool v1.5.8

OLyKyt1.png


Link to images because forum Imgur functionality is broken...

Description

The KSP Trajectory Optimization Tool (KSP TOT) is a piece of MATLAB-based software I've written to help plan and execute space missions. It's functions are many:

  • Using a Lambert solver, generate "porkchop plots" that assist with determining proper departure and arrival times of interplanetary transfer orbits.
  • Using the data in (1), determine an optimal hyperbolic departure orbit and compute the burn magnitude and direction (that is, the delta-v vector) as well as the burn location in the initial orbit about the departure planet.
  • Compute optimal planetary flybys to cheaply get to those hard-to-reach destinations (Moho, Eeloo, etc).
  • Generate delta-v optimal rendevzous maneuvers to another spacecraft.
  • Find the optimal two-burn orbit change maneuvers to adjust your orbit cheaply!
  • Fully sequence a mission from start to finish, including coasts, burns, aerobraking, and more.

This thread is a continuation of a related thread over in the add-on dev forum.

Download & Installation Instructions

To install and run KSP TOT, do the following:

  1. Download the Windows 64-bit 2015b MATLAB Compiler Runtime (MCR).
  2. Install the MCR package on your computer. You may need to restart your PC after installing in order to use KSPTOT.
  3. Download the KSP TOT package.  (Push download button in upper right corner.)
  4. Unzip the KSP TOT package to a directory of your choosing.
  5. Copy the KSPTOTConnect folder to your KSP Gamedata folder.
  6. Run the KSPTOT application.
  7. To update from a previous version, just repeat steps 3-5. There is no need to re-download the MCR.

Mac Users: Follow these instructions instead. (Current Mac Version: KSP TOT v1.1.7)

  1. Download the Mac 64-bit 2013a MATLAB Compiler Runtime (MCR).
  2. Install the MCR package on your computer. You may need to restart your PC after installing in order to use KSPTOT.
  3. Download the KSP TOT package(Push download button in upper right corner.)
  4. Unzip the KSP TOT package to a directory of your choosing.
  5. Copy the KSPTOTConnect folder to your KSP Gamedata folder.
  6. Run "run_KSPTOT.command".
  7. Run the KSPTOT application.
  8. To update from a previous version, just repeat steps 3-6. There is no need to re-download the MCR.
  9. Bk2w is building and maintaining the Mac versions. If you have technical issues with installing or running the application, please see him for questions.

Usage Instructions

NOTE: I've put together a tutorial on how to use KSP TOT for a basic Kerbin-Duna flight. See this post here for the tutorial.

Running on Linux

It has been suggested that it is possible to run the Windows version of KSPTOT on Linux using WINE.  Here are the steps.  I have not tried them personally, so you follow them at your own risk.

On 5/3/2016 at 12:39 PM, salajander said:
  1. Install WINE (I installed the latest staging build from https://www.winehq.org/download/)
  2. Install cabextract and ensure it's in your PATH
    1. On OS X, use homebrew or macports; e.g., 'brew install cabextract'
    2. On Linux, use your distro's package manager (apt, yum, etc.)
  3. Install winetricks: https://wiki.winehq.org/Winetricks
  4. Install the native VC++ runtime: 'winetricks vcrun2012'
  5. Install the (Windows!) MCR: 'wine  MCR_2015b_win64_installer.exe'
  6. Launch KSPTOT! : 'wine KSPTrajectoryOptimizationTool.exe'

Source Code

Source code for KSPTOT itself is available onGithub at the following location: KSPTOT Github

Found a Bug or Issue?

Please file a bug report here.

FAQ

Q: I don't have MATLAB! Can I still use KSP TOT?

A: Yes! MATLAB is not required to use KSP TOT, only the MATLAB Compiler Runtime, which is freely available at the link I provide above in the download instructions.

Q: I use Real Solar System / Kopernicus / Outer Planets Mod /etc. Can I use KSP TOT with it?

A: Yes! To do so, you'll need to create a bodies.ini file with the information of the new planets included. Simply install the KSPTOTConnect plugin into your KSP / Gamedata folder, start KSP, get into the flight scene (where you can see your spacecraft in space, for example), and then open KSP TOT. Use the File -> Create New Bodies File From KSP and follow the instructions. Then load the file you create with File -> Load Bodies From File. All done! While you'll only need to create the bodies file once, you have to load it each time KSP TOT starts to use it.

Q: Do I really have to enter dates and times in seconds? That sounds awful.

A: Nope! Right click on any time field, select "Enter UT as Date/Time", and fill in the year/day/hour/minute/second in the box that comes up. That's all there is to it!

Q: I'm having problems running KSP TOT. The program doesn't run and just turns into a temp file when I double click it. What is going on?

A: Check to see if your anti-virus software is interfering. Provide an exception for the KSP TOT executable if you need to. Avast has been known to cause problems.

Q: I can't get the KSP TOT real time system or maneuver node upload to connect. What can I do?

A: Check the following conditions: KSP must be running in a windowed mode, you must be in the flight scene (not tracking station or space center scene, but the scene where you can fly your vessel), and you must have a firewall exception for KSP. If these are all true and you're still having problems, let me know.

Q: Mission Architect is hard! How do I use it?

A: First, check out the PDF tutorial packaged with the KSP TOT download. If you still have questions after (or while) going through that, please post the questions in this thread and I'll get back to you as soon as I can. :)

Change Log

Version 0.1
[LIST]
[*]Initial public release. 
[/LIST]
Version 0.2
[LIST]
[*]Added departure information screen. 
[*]Added ability to input time (UT) as a date/time by right-clicking on those text boxes 
[/LIST]
Version 0.3
[LIST]
[*]Fixed bugs 
[*]Included basic computational options, accessible from Edit->Options, 
[*]Dixed a bug where datatips on the main porkchop plot would not always display estimated delta-v, 
[*]Added a custom display for datatips on the porkchop plot, 
[*]Added time past periapse to the burn information on the departure display GUI. 
[/LIST]
 Version 0.4
[LIST]
[*]Fixed bug where departure calculation window would not refocus after selecting departure/arrival times from porkchop plot. 
[*]In departure calculation input GUI, added ability to right-click on arrival time input and select option to optimize that time based on what's in the departure time box. 
[*]Added application-wide input checking. 
[/LIST]
Version 0.5
[LIST]
[*]Added ability to optimize departure for given arrival date in Departure Calc window. 
[*]Added ability to find earliest arrival date based on maximum allowable delta-v. 
[*]When generating a porkchop plot,  data cursor now appears at the optimal location. 
[*]Apse markers have been added to the transfer orbit display in the departure information window. 
[*]A "global optimum" method has been written and runs after generating a porkchop plot, but it currently doesn't output anything anywhere.  I'm still working on what to do with it. 
[*]Added new bodies to the application's database.  Corrected existing information where needed. 
[*]Lots and lots of bug fixes. 
[/LIST]
Version 0.6
[LIST]
[*]Lone Wolfling's "minimize arrival time" with variable departure time optimizer; 
[*]The ability to input arithmetic statements (2+2 for example) into  numeric text boxes and have them evaluate (so if you enter 2+2, the box  changes to read 4) 
[*]"Optimize Departure for Input Arrival" now uses  the input departure time as a lower bound.  Useful for when you're in  the middle of a game and you clearly can't go back in time to find that  "better" solution. 
[*]Some bug fixes and tweaks under the hood. 
[/LIST]
Version 0.7
[LIST]
[*]A[B] Flyby Maneuver Sequencer[/B](FMS)that is capable  of searching for optimal flybys (gravity assist maneuvers) around  planets.  Spending too much fuel on that trip to Moho?  Try a flyby  around Eve first! 
[*]Optimal launch/arrival date is now the default setting in the Compute Departure GUI. 
[*]"Time  To Periapse" is now shown alongside "Time After Periapse" in the DV  Maneuver Information boxes in the Departure Information GUI and the FMS  GUI.  Useful for using maneuver node editors mostly. 
[*]Some minor visual changes/tweaks to the plots. 
[*]Some bug fixes and a code reoganization on the back-end. 
[/LIST]
Version 0.8
[LIST]
[*]A[B] two-burn optimal orbit change planner[/B].  This allows  you to change your current orbit from any one given orbit to another  with two engine firings.  Very useful for adjusting your inbound  hyperbolic orbit to set up that ideal Kethane scanning orbit. 
[*]The ability to port in orbits from SFS files.  Right click  an orbit panel, hit the appropriate menu item, select the SFS file, and  go!  Eliminates the need to hand-enter orbits from MechJeb displays or  whatnot. 
[*]The addition of the orbital period to some output data. 
[*]The Compute Departure Burn GUI now accepts hyperbolic  orbits.  (I've left the wording on Elliptical in there for now until I'm  satisfied that it works just as well with hyperbolic as well as  elliptical orbits.) 
[*]Various minor bug fixes and tweaks. 
[/LIST]
Version 0.9
[LIST]
[*]Changes to the departure calculation code and the flyby maneuver sequencer in order to[B] better determine burn times and true anomalies[/B] when provided with an orbit epoch and mean anomaly at that epoch. 
[*]Right-clicking on the porkchop plot will now bring up a context menu that will allow you to recenter the plot on a particular point on the graph. 
[*]A few minor bug fixes and tweaks. 
[/LIST]
Version 0.10
[LIST]
[*]New application: [B]Maneuver Execution Assistant[/B]. This helps pilots properly time the start of burns to center the delta-v across the maneuver node. 
[*]New application: [B]Rendezvous Maneuver Sequencer[/B]. Useful for meeting up with other craft in orbit, as well as moons. 
[*]KSP TOT can now[B] ingest custom celestial bodies files [/B]and parse them. Useful for doing stuff in other solar systems you define. 
[*]Added some tooltips to input fields. 
[*]Bug fix: Fixed issue where GUI elements could become distorted and/or shift position 
[*]Bug fix: Fixed issue with code that converts r/v vectors to keplerian elements: now handles 0 eccentricity and inclination much better 
[*]Bug fix: Code now remembers where last opened SFS file was retrieved from. 
[*]Bug fix: Optimization runs now include some scaling of constrains and the objective function. 
[*]Lots of backend changes to support the above. 
[/LIST]
Version 0.11
[LIST]
[*]New application: [B]KSPTOT Mission Control Center.  [/B]Connects to KSPTOT using the new KSPTOT Connect plugin (see below).  Offers users on different PCs the ability to act as mission controllers by providing console screens with subsystem data on them.
[LIST]
[*]Console pages available in the MCC: 
[*]Orbital Operations 
[*]ACS/Dynamics (attitude control and pointing) 
[*]Power/Thermal 
[*]Propulsion 
[*]Telemetry Monitor 
[/LIST]

[*]New plugin: [B]KSPTOT Connect[/B].  Allows users to connect KSPTOT to KSP (running on the same PC) to perform various tasks:
[LIST]
[*]Grab the orbit and game UT from straight from KSP! 
[*]Upload maneuver nodes from the various applications! 
[*]Place in your GameData directory in your KSP directory. 
[/LIST]

[*]A handful of minor fixes on the KSP TOT side.
[LIST]
[*]Importing orbits from SFS now works for 0.23. 
[*]Some other fixes 
[/LIST]

[/LIST]
Version 0.11.1
[LIST]
[*]Bug fix: Plots in the flyby maneuver sequencer should render correctly now.  Before, an error was thrown fairly consistently. 
[*]Bug fix: Plotting in the Compute Departure window has been corrected.  Before only the red dv vector was shown. 
[*]Bug fix: Uploading a maneuver to a ship in KSP is now restricted to localhost. 
[/LIST]
Version 0.11.2
[LIST]
[*]Bug fix: The remaining plot rendering issues should be resolved. 
[/LIST]
Version 0.12 
[LIST]
[*]New Application: [B]KSP TOT Mission Architect[/B]
[LIST]
[*]Allows for the planning of complete missions from Kerbin injection orbit to anywhere in the solar system. 
[*]Plan ballistic trajectories, gravity assist maneuvers, injection orbits and more using the same basic orbital mechanics and patched conics system that KSP uses!  No more infinitesimal sphere of influence approximations to ruin your burn planning. 
[*]Tracks spacecraft mass and fuel usage so you ensure you always have enough fuel to return to Kerbin. 
[*]Built in mission optimizer can goal seek to target celestial bodies, minimize fuel usage, or hit inclination/eccentricity targets -- all optimally. 
[*]Full orbit visualization means that you'll know precisely where you're going and how you're going to get there. 
[*]Mission state log provides the complete spacecraft state at effectively any point along the mission, from initial get-go to the final injection burn. 
[*]And more! 
[/LIST]

[*]Improvements to the astrodynamics code:
[LIST]
[*]Orbit propagation code has been vectorized to allow for faster execution. 
[*]Orbit RV/Keplerian conversion has been vectorized for MUCH faster execution.  Code is also far more robust! 
[/LIST]

[*]Improvements/fixes to the rendezvous application. 
[*]Other minor fixes/improvements too small to note here. 
[/LIST]
Version 0.12.1
[LIST]
[*]Fixed issue with vectorized kepler solver; 
[*]Added lower periapse warning and low propellant warnings; 
[*]Added zoom slider to orbit display; 
[*]Added tooltips; 
[*]Updated colormaps for bodies in bodies.ini:
[LIST]
[*]Jool 
[*]Moho 
[*]Gilly 
[*]Vall 
[*]Bop 
[*]Pol 
[*]Eeloo 
[/LIST]

[*]Added an unsaved work check upon closing MA; 
[*]Fixed bug with the Advance Script To Selected Event function; 
[*]Added scroll bar to Alerts/Warnings box; 
[*]Fixed rare display issue with Mission Optimizer; 
[*]Numeric constraints may now have an associated reference body; 
[*]Active constraint listbox tooltip now displays information on active constraints; 
[*]Arrow buttons on orbit visualization now wrap; 
[*]Fixed bug that occured when mission had more than 11 events; 
[*]Fixed bug that could cause infinite propagator recursion when going to true anomaly of 0. 
[/LIST]
Version 0.12.2
[LIST]
[*]Added new constraints to the MA Mission Optimizer
[LIST]
[*]Orbital Period 
[*]Non-singular H1 
[*]Non-singular K1 
[*]Non-singular H2 
[*]Non-singular K2 
[/LIST]

[*]Added Mission Architect Celestial Body Catalog that displays celestial body information 
[*]Added ability to plot state and state-derived quantities using MATLAB plotting capabilities
[LIST]
[*]Classical (Keplerian) orbit elements 
[*]Vector (position/velocity) elements 
[*]Equinoctial elements 
[*]Spacecraft masses (propellants, dry, total) 
[*]Spacecraft eclipse state 
[*]Other spacecraft state and state-derived values 
[*]Generates CSV output on command 
[*]Shows orbital events such as DV maneuvers and apse crossings on the plots 
[*]Numerous graphical plotting options
[LIST]
[*]Colors, grids, line width, sub-plots, etc 
[/LIST]

[/LIST]

[*]Initial implementation of body rotation code
[LIST]
[*]MA now computes longitude and latitude
[LIST]
[*]Optimizer constraint 
[*]Graphical analysis variable 
[*]State readout output 
[/LIST]

[/LIST]

[*]Added "Other Spacecraft" and "Ground Stations"
[LIST]
[*]User can define a spacecraft in orbit or a ground station on a body surface 
[*]Can be used for optimization ("minimize distance to s/c") 
[*]Can be used for plotting in Graphical Analysis 
[/LIST]

[*]Added burn UT to Rendezvous Maneuver Sequencer 
[*]Improved MA SoI transition robustness for elliptical orbits 
[*]Increased optimizer speed for missions with many events 
[*]Fixed bug with retrieving orbit from KSPTOTConnect 
[*]Fixed issue with Rendezvous Maneuver Sequencer when trying to compute manenuvers between orbits with similar geometry 
[*]Fixed issue that could cause script execution to slow with many events 
[*]Fixed issue with MA mission plan file sizes being >10 MB 
[*]Fixed issue that caused saving and opening of MA mission plans to be slow 
[/LIST]
Version 0.12.3
[LIST]
[*]Two new constraints in Mission Architect:
[LIST]
[*]Altitude of periapsis 
[*]Altitude of apoapsis 
[/LIST]

[*]Bug fix to graphical analysis' text output when mission plan had not yet been saved 
[*]Major change to MA constraint system (now possible to change assigned event after creating constraint) 
[*]Bug fixes to KSPTOT main functionality, flyby maneuver sequencer, and in other places 
[*]Bug fixes to Mission Architect 
[/LIST]

Version 1.0.0
[LIST]
[*][B]New Application: Multi-Flyby Maneuver Sequencer[/B].  Replacing the Flyby Maneuver Sequencer, this application is capable of generating flyby trajectories around an arbitrary number of celestial bodies.  It's also 100x times faster than FMS and tends to generate solutions which are more balanced and achievable.  Really, try it out, it's a real work of art and arguably the best set of code I've ever written. 
[*][B]Mission Architect[/B] has received a number of upgrades:
[LIST]
[*]GUI now actively indicates when no errors are present in the execution of the missions script. 
[*]It is not possible to generate orbit constraints based on the current state of the mission and its associated events.  See "Script" menu. 
[*]Two new script execution settings (see "Script" menu):
[LIST]
[*]Strict SoI Search is an attempt to speed up the execution time of long missions by restructuring the way high->low SoI transitions are found.  It can, in some cases, speed up execution and optimization by a factor of 2x. 
[*]Parallel Script Optimization allows users to take advantage of MATLAB's sophisticated parallel computing abilities to speed up the optimization of the mission script in most cases. 
[*]Both of these options default to "off" but are available in the "Script" menu. 
[/LIST]

[*]A number of improvements to SoI search in general that increase its robustness. 
[*]Many, many bug fixes and improvements. 
[/LIST]

[*]A number of other minor fixes and improvements to various other elements of KSP TOT. 
[/LIST]

Version 1.1.0
[LIST]
[*][B]New Application: Flyby Porkchop Plotter.  [/B]Generates a delta-v contour map for an arbitrary flyby mission sequencer in a similar manner to that of the porkchop plot featured on main GUI.  Inspired by diomedea, this application is great for getting the big picture and finding flybys through a more "brute-force" technique. 
[*]Updates to the [B]Multi-Flyby Maneuver Sequencer[/B][B]:[/B]
[LIST]
[*]Now accepts a minimum of two waypoints (previously, three) and computes the optimal ballastic trajectory between them.  This is basically a way to find optimal, no flyby trajectories using a genetic algorithm. 
[*]GUI now allows users to specify bound on flight time for each waypoint leg.  Previously only the launch window could be specified. 
[*]Bug fixes and some other minor tweaks to the underlying algorithm. 
[/LIST]

[*]A new[B] splash screen[/B] now appears when loading the application.  Features a new KSP TOT logo inspired by the Voyager I and II missions.
[LIST]
[*]Also fixed the issue where the main GUI would half load, displaying filler/placeholder information for a moment before loading the full GUI. 
[/LIST]

[*]A new [B]Help -> About[/B] menu in the main GUI with application development credits. 
[*]Fixed a regression in [B]Mission Architect[/B] that made it hard to find SoI transitions in some cases. 
[/LIST]

Version 1.1.1
[LIST]
[*]Fixed a bug in [B]Multi-Flyby Maneuver Sequencer[/B] such that the wrong burn true anomaly was being displayed at flyby periapses. 
[*]Added the ability to import masses of the active spacecraft in KSP straight into [B]Mission Architect[/B] by right-clicking the mass panel in the Insert State dialog box.  Must have KSPTOTConnect plugin installed in KSP and KSP must be running in the flight scene for this to work. 
[*]Added ability to tap Enter/Return on keyboard to save and close the Insert State/Coast/DV_Maneuver/Mass_Dump dialog boxes in [B]Mission Architect[/B]. 
[/LIST]

 Version 1.1.2
[LIST]
[*]Fixed issue with launch windows in [B]MFMS.[/B] 
[/LIST]

Version 1.1.3
[LIST]
[*]Fixed issue with editing thrusters in [B]Mission Architect.[/B] 
[/LIST]

Version 1.1.4
[LIST]
[*]The pork chop plot now requests an increase in the maximum delta-v to plot if the minimum delta-v in the data points computed is greater than that value. 
[*][B]Added the ability to generate bodies.ini files from KSP! [/B] In the File menu of the main GUI, select "Create Bodies File From KSP." 
[*]Added a note in the generic time entry dialog box clarifying that those times are Earth times, not Kerbin times. 
[*]Added a new constraint to [B]Mission Architect[/B]: Universal Time constraint.  Restricts event end times to the universal times specified by the user. 
[/LIST]

Version 1.1.5
[LIST]
[*]Vessels no longer have parts disappear upon loading a save when using the KSP TOT MCC suite. 
[*]Asteroids are no longer selectable from the MCC Vessel Selection dialog box. 
[/LIST]

Version 1.1.6
[LIST=1]
[*]Thanks to bk2w, I now have a vectorized version of the porkchop plot  code implemented.  Based on his trials, it runs something like 280x  faster than before.  Needless to say, this is a great improvement!   Thank you to bk2w! 
[*]Implemented an "orbit clipboard" across the whole KSP TOT application, including Mission Architect, Multi-Flyby Manuever Sequencer, etc.  Right click on any orbit entry panel to get a menu for copy/pasting an orbit to the KSP TOT orbit clipboard.  You can also right click on any orbit state log panel in Mission Architect to copy the orbit from what you're seeing.  This works on the main GUI and in the State Log window, too! 
[*]Added Mean Anomaly to the Mission Architect state log tooltips. 
[*]Fixed a bug with using the Mission Architect State Log with only one event in the mission script. 
[*]In the Mission Architect Insert Coast dialog box, when inserting a Go To UT coast, you can now right click the UT value, min UT value, and max UT value boxes to enter a UT as a Date/Time string, as you can everywhere else in the GUI. 
[*]One or two other minor things I found along the way. 
[/LIST]

Version 1.1.7
[LIST]
[*][B]Major improvements to the KSPTOTConnect netcode courtesy of RadarManFromTheMoon[/B].  These improvements significantly increase the robustness and speed of KSP TOT Connect, making it much more enjoyable to use.  Thanks, RadarManFromTheMoon! 
[*][B]New Mission Architect Tool: Mission Animator[/B].  Mission Animator is a multi-purpose visualizer and animation creation tool for Mission Architect. 
[*]Three new objective functions in Mission Architect: maximize inclination, maximize eccentricity, and "satisfy constraints". 
[*]2x speed up of Mission Architect script execution when using Strict SoI Search 
[*][B]Time may now be specified in Earth units or Kerbin units.[/B]  NOTE: Kerbin units are HIGHLY experimental.  Report any issues with KSP TOT while using Kerbin units immediately. 
[*]Bug fixed with MA Graphical Analysis tool when plotting against MET. 
[*]New "Distance Traveled" option in MA Graphical Analysis. 
[*]Fixed two bugs with Maneuver Exec Assistant 
[/LIST]

Version 1.1.8
[LIST]
[*]A new aerobraking event for Mission Architect; 
[*]A huge set of new options in Mission Animator; and 
[*]Lots of little bug fixes and tweaks. 
[/LIST]

Version 1.1.9
[LIST]
[*]New Features for [B]Mission Architect[/B];
[LIST]
[*]A new finite duration burn model that takes into account the duration of a burn, and thrust and Isp of the engine; 
[*]Aerobraking updated to include both stock and NEAR/FAR models; 
[*]A new launch window analysis tool; 
[*]A new delta-v budget tool; 
[*]Improvements to mission optimizer behavior; 
[*]Improvements to undo/redo functionality (was causing some slow-downs after many actions); 
[*]Bug fixes and other minor improvements; 
[/LIST]

[*]Compiled [B]KSPTOTConnect [/B]against KSP v0.90; 
[*]Added a search window length input to [B]Rendezvous Maneuver Sequencer[/B]; 
[*]Some minor fixes to the [B]KSPTOT Real Time System (RTS).[/B] 
[/LIST]

Version 1.2.0
[LIST]
[*]Upgraded [B]MATLAB Compiler Runtime to version R2014b x64[/B]. 
[*]Added a search parameter slider to [B]Rendezvous Maneuver Sequencer[/B] that allows the user to adjust the way the optimizer works. 
[*]Added ability to split impulsive DV maneuvers in [B]Mission Architect.[/B] 
[*]Changed aerobraking models away from the impulsive approximation and replaced those with numerical integration that should be much more accurate. 
[*]Added a function to [B]Mission Architect Graphical Analysis[/B] that allows the user to draw lines at specified points on the plots 
[*]Lots of other bug fixes and minor tweaks to [B]Mission Architect[/B]. 
[/LIST]

Version 1.2.1
[LIST]
[*]Fixes an issue with the rotation rate of Kerbin in the bodies.ini file. 
[*]Fixes an issue with the way spacecraft are displayed in the Mission Animator. 
[*]Fixes an issue with lat/long calculations. 
[/LIST]

Version 1.3.0
[LIST]
[*]Added the ability to specify the line style of Other Spacecraft orbits in [B]Mission Architect[/B] when rendering. 
[*]Added ability to plot the orbits of Other Spacecraft in the main [B]Mission Architect[/B] render window. 
[*]Added option to replace small children bodies with circular markers in main [B]Mission Architect[/B] render window to improve their visibility. 
[*]Added ability to open MATLAB FIG files right from [B]Mission Architect[/B]'s file menu. 
[*]Added ability to close most [B]Mission Architect[/B] windows using the Esc key (will not save any input, is equivalent to hitting the X in the window corner). 
[*]Updated [B]KSPTOTConnect [/B]plugin for [B]KSP v1.0[/B]! 
[*]Removed previous stock drag model from [B]Mission Architect[/B]'s aerobraking event code. 
[*]Many, many bug fixes and other small improvements/enhancements.  Thanks to Gaiiden for his help in identifying many of these! 
[/LIST]

Version 1.3.1
[LIST]
[*]Resolved an issue with axis scale in Mission Animator cutting off orbits; 
[*]Resolved a few issues with KSPTOTConnect plugin that prevented a bodies.ini file from being generated correctly; 
[*]Updated bodies.ini file to use GM values and atmospheric values from KSP v1.0.x; 
[*]Resolved an issue with the Keplierian -> Vector elements conversion subroutine that caused an issue when eccentricity was 0.0 and inclination was greater than 0.0. 
[*]One or two other minor bug fixes and tweaks. 
[/LIST]

Version 1.3.2
[LIST]
[*]10x decrease in run time on the Kepler solver.  This is due to  eliminating the use of fzero() for both elliptical and hyperbolic cases.   Should reduce total run time by 15-20%. 
[*]Eliminated a findObj() call that should reduce total runtime by 5%-10%. 
[*]Enabled strict SoI search by default, which should reduce total run time  by 10%-20%. (I've also seen it do nothing, though, so it's very  situation dependent.) 
[*]Added a selective SoI search feature which can be used to further reduce run time as requested by the user. 
[*]A few other bug fixes and tweaks. 
[/LIST]

Version 1.3.3
[LIST]
[*]Fixed a bug that occurred occasionally when propagating a mission plan; 
[*]Added a "Get Orbit for Active Vessel" feature to Get Orbit context menus. 
[/LIST]

Version 1.4.0
[LIST]
[*]Added a [B]Communications Network Analysis tool[/B] to Mission Architect.  This feature allows you to assess communication node visibility, total comm path distance, and network node utilization. 
[*]Added a [B]ground station elevation angle[/B] task to Mission Architect's Graphical Analysis tool.  This is useful for assessing when comm spacecraft go below or rise above the horizon (and therefore become useful). 
[*]Added a series of [B]astrodynamics calculators[/B] to Mission Architect's suite of tools. 
[*]One or two minor bug fixes here and there. 
[/LIST]

Version 1.5.0
[LIST]
[*]Added a Mission Notes section under the Edit menu, let's you record text or whatever you want and store it for later.
[*]Added a Staging event to the Events menu. This is basically a Mass-only Set State: you tell it what your post staging dry mass, fuel/ox mass, etc masses are and it sets them for you. Useful for when you're dropping partially used stages, and very complementary to the existing MASS_DUMP event.
[*]Added commentary to the bodies.ini file.
[*]Added the KSP v1.0 atmospheric model to KSP TOT Mission Architect.
[*]Some performance optimizations related to the redo/undo menu and its backend data.
[*]Four new DV maneuver types, all of which use spherical coordinates. Spherical coordinates use an azimuth (angle in a plane) and elevation (angle out of the plane) and DV magnitude to define the maneuver. There are inertial and orbit impulse maneuver types as well as inertial and orbit finite burn duration maneuver types. The best use for these new types to allow you to specify the min and maximum delta-v magnitude for the optimizer.
[*]Resolved an issue where the GUI would rapidly slow down after running the optimizer multiple times. This issue was around since v1.0.0 but was exasperated by v1.4.0. The actual root cause of the issue is probably a bug in MATLAB's memory management, but I actually like the fix better than the old way I was doing things, so I'm going to keep it permanent.
[*]Resolved an issue where variables not marked for optimization in a burn (or any multi-variable event) would get changed by the optimizer.
[*]"Re-optimize Mission" in the Mission Architect Optimization menu now actually serves a purpose and is useful. Before it would just run the exact same case again, providing the same answer you already got. Now it runs the current script with the same optimization settings/constraints/objective/etc, which was its original purpose.
[*]Some other minor speed improvements here and there.
[*]Other minor fixes and optimizations.
[/LIST]

Version 1.5.1
[LIST]
[*] KSPTOTConnect compatibility with KSP v1.1.2
[*] Lots of bug fixes and stability work.
[/LIST]

Version 1.5.2
[LIST]
[*] Resolved an issue with Mission Architect erroring when creating a constraint.
[*] Added EXPERIMENTAL support for bodies.ini files that include spaces and special characters in body names.
[/LIST]

Version 1.5.3
[LIST]
[*] Resolved an issue with loading in bodies.ini files from Outer Planets and other KSP mods.
[/LIST]

Version 1.5.4
[LIST]
[*] KSPTOT now runs on a new MATLAB Compiler Runtime, R2015b x64!  This requires an install of this runtime to use KSPTOT.  Please see the OP or this link to download the new MCR.
[*] Bug fixes for the Mission Architect Comm. Network Analysis Tool's pathfinding algorithm;
[*] A bug fix in the Multi-Flyby Maneuver Sequencer's use of the compiled Lambert solver when using Kerbin time;
[*] Fixes to a bug in Mission Architect orbit angle constraints (RAAN, argument, etc).
[*] Additions of new constraints in Mission Architect: prograde/normal/radial distance from Other Spacecraft, and Relative Velocity to Other Spacecraft
[*] Addition of new Mission Architect Graphical Analysis tasks: prograde/normal/radial distance from Other Spacecraft, and Relative Velocity to Other Spacecraft
[*] A few other minor tweaks here and there.
[/LIST]

Version 1.5.5
[LIST]
[*] Fixed issue with starting parallel pool in Mission Architect (matlabpool -> parpool)
[*] Added ability to remove mass at a constant rate from spacecraft during coasts
[*] Added ability to rename propellant types
[*] Mass dump GUI now shows fuel type being dumped for delta-v dump
[*] DV maneuvers now have a line color for plotting similar to coasts
[*] Added ability to run multiple MFMS runs in sequence in a hands-off manner
[*] Added ability to save the text output from MFMS runs to file without manual copy/paste
[*] Added function to Mission Architect to create a "trajectory map" similar to what MFMS outputs (Tools -> Create Trajectory Map)
[*] Replaced the previous end-of-optimization prompt with a scorecard that allows the user to choose between the final optimization result, the optimization iteration with the best objective function value, or the optimization iteration with the best constraint value.
[*] Added "Copy Orbit After Selected Event" item to MA script context menu
[*] Lists of celestrial bodies which contain the full body list are now arranged in a hierarchical order with appropriate indenting
[*] Fixed bug with MFMS in which the waypoint panel header did not update when the central body is changed
[*] Fixed bug with other spacecraft and ground targets related to their body.  May need to recreate these items if you're on a v1.5.5 pre-release.
[*] Added initial orbit epoch and mean anomaly to the Multi-Flyby Maneuver Sequencer input
[*] Fixed a bug with the algorithm that adjusts departure time to account for mean anomaly and epoch in the "Compute Departure" tool.
[*] Fixed a bug with MFMS "Get Orbit from SFS File" functionality
[/LIST]

Version 1.5.6
[LIST]
[*] Added hyperbolic velocity unit vector constraints to Mission Architect
[*] Added hyperbolic velocity unit vector component tasks to Mission Architect Graphical Analysis
[*] Added ability in Mission Architect for impulsive maneuvers to be split by burn duration as well as delta-v
[*] Fixed bugs in Mission Architect's Convert Impulsive Maneuver and Split Impulsive Maneuver functions
[*] Added solar beta angle task to Mission Architect Graphical Analysis
[*] Fixed bug with computing event duration in Mission Architect
[*] Added stock comm max range model (sqrt(r1*r2)) to Mission Architect comm network analysis tool.
[*] Resolved issue with Mission Architect where trying to open up two sessions of MA would kill the first session without any prompting.
[*] Resolved issue with Mission Architect where the number of revolutions in a coast would be computed incorrectly when opening the Edit Coast dialog box.
[*] KSPTOTConnect updated for KSP v1.2.
[*] KSPTOT Real Time System now uses skin temperature in the thermal console screen.
[*] Open Mission Plan and New Mission Plan menu items in Mission Architect no longer prompt about unsaved work if the mission plan is fulled saved with no outstanding changes.
[*] Fixed: Issue with missing matlabrc file.
[*] Fixed: "Other Spacecraft window stays open on loading new project"
[*] Fixed: "Enabling script->parallel throws error"
[*] Fixed: "Copy/Paste orbit data does not include orbiting body"
[*] Fixed: "Mission Architect optimization window no longer forces itself to front"while optimizing.
[*] Fixed: "f(x) going from positive to negative messes up the middle chart in the Mission Optimizer window"
[*] Implemented: "Notify user of successful tabular text output when using a saved mission file"
[*] Fixed: "KSP TOT still expects anomalies in the range of [0, 360]"  KSPTOT no longer returns anomalies outside of [0, 360]
[*] Updated: "bodies.ini GM/Atmosphere/Rotational periods"
[*] Fixed: "No trajectory plotted through Kerbin SOI for asteroid coming from sun orbit"
[*] Updated: Mission Architect SoI search mode no longer starts out "strict"
[*] Fixed: "Mun SOI intercept not found on trajectory that passes through Mun’s SOI"
[*] Fixed: "KSPTOT will get orbit info, but will not read maneuver nodes"
[*] Implemented: "Other Spacecraft dialog has disabled input if no vessels listed until Add Spacecraft button is clicked"
[*] Implemented: "In the execution assistant, add ability to right-click and read next maneuver node from KSP"
[*] Implemented: "In the Orb Ops console, display the maneuver node's True Anomaly, to match what the execution assistant wants"
[*] Implemented: "MA save dialog notes if save file is dirty or not"
[*] Fixed: Resolved issue where pasting an orbit into the MA Other Spacecraft window would not apply that orbit to the selected spacecraft.
[/LIST]

Version 1.5.7
[LIST]
[*] Mission Architect: New experimental N-body coast event.  This event models N-body gravity for selected bodies.  Allows for basic Principia compatibility.
[*] Mission Architect: New event "Docking" that models the user spacecraft being docked to another spacecraft by propagating the user spacecraft along the same orbit as the other spacecraft.
[*] Mission Architect: New event "Landing" that fixes your spacecraft relative to the rotating surface of the current central body.  Can be used to model landings on the surface.
[*] Mission Architect: New initial state type "Estimate Launch."  Allows for users to model a launch into a circular parking orbit at a desired altitude.  Useful for determining initial orbits when that information is otherwise hard to guess or not available.
[*] Mission Architect: Initial state parameters may now be optimized like burn and coast parameters.
[*] Mission Architect: Relative in-track, cross-track, and radial positions of other spacecraft are now represented more correctly in Graphical Analysis.
[*] Mission Architect: Major update to the optimizer contraint system that allows for nearly all Graphical Analysis tasks to be used as constraints.
[*] A number of bug fixes in Mission Architect and the KSPTOTConnect plugin.
[/LIST]

Version 1.5.8
[LIST]
[*] [Implemented] MFMS now allows for multiple revolutions around the central body for each leg of the tour.
[*] [Implemented] RSS-like propagation of celestial bodies is now usable throughout the application.  The code will handle SoI transitions correctly in Mission Architect.
[*] [Implemented] KSPTOT main UI options are now stored in the appOptions file and persist through sessions.
[*] [Implemented] Minor quality of life improvements in Mission Architect.
[*] [Fix] Resolved issues with the way SoI transitions are computed that could cause an SoI transition to be missed.
[*] [Fix] Fixed rare bug with loading mission plans in Mission Architect.
[*] [Fix] Numerous bugs contained in the Compute Departure function.
[*] [Fix] Resolved many other issues with Mission Architect.
[/LIST]

License

88x31.png

KSP Trajectory Optimization Tool is licensed under a Creative Commons Attribution-NonCommercial-NoDerivs 3.0 United States License.

Edited by Arrowstar
KSP TOT v1.5.8 release

Share this post


Link to post
Share on other sites

Hey, you're back. Didn't notice the recent activity in your old thread, whoops.

For those of us who have Matlab, could you put up your source on Github or similar? Besides the needing the MCR deployment issue, I'm glad you switched to a language I can read.

So if you're going for a higher-featured version of Alexmun's Javascript porkchop plotter, you may have noticed he has a 2-burn transfer mode using an ecliptic-projection initial ejection burn and a mid-course plane change, that actually ends up noticeably more efficient in some cases (take a look at the first Dres transfer for example).

And if you don't have access to Mac or Linux machines with Matlab on them, I could possibly help out there.

Edited by tavert

Share this post


Link to post
Share on other sites

Ah, source code and licensing, two things I forgot about. Whoops! I will package source with my application executable (would rather not put it up on Github) tonight. I'll also get a license together tonight and package that in as well. Thanks for the reminder. :)

Yes, testing on Linux and Mac would be appreciated as I have no access to those platforms. However, my plan is still to only formally support Windows for major issues because I have no means of verifying the code on any other platform, and debugging on an OS you don't have is a pain. :)

I know the MCR is big, but once you install it, you never have to do so again. That's why I package the program separately, so you don't have to keep downloading to get updates. :)

Have you had a chance to try the application yet? I'd like to nail down my existing functionality before I move on to other methods. :)

Share this post


Link to post
Share on other sites

I'm a little low on hard drive space to install MCR just for this, so haven't tried running it yet. I'd rather run it inside Matlab so I can profile, debug, maybe use it programmatically, so if you put up m files I'll probably look at it that way.

Share this post


Link to post
Share on other sites

Source code and license have been added to the ZIP file. Please re-download as necessary. Tavert, please let me know if you have any feedback. :)

Share this post


Link to post
Share on other sites

I've updated the application to version 0.2. (The URL location of the KSP TOT package remains the same, however.) This update is primarily focused on providing additional information for analyzing departure orbits from a particular planet. I've provided a new dialog box that is used for this purpose:

11wTrCHl.png

This is accessed by computing a porkchop plot and then tapping the "compute departure orbit" information. Enter the information in the box that comes up and away you go. Protip: in this dialog box there is a button labeled "Select Departure/Arrival Date." If you tap this and then click on the porkchop plot you previously generated, it will fill in the departure/arrival times with the point you clicked on the plot (so aim for somewhere blue!).

As usual, feedback and comments are always welcome and requested. Please let me know what you think!

Edited by Arrowstar

Share this post


Link to post
Share on other sites

I took a little time tonight to work on two aspects of the code that needed attention. First, I added context menus to the time entry fields on both the main GUI and the departure calculation GUI. If you right click those fields, you'll be presented with an option to enter date/times as year/day/hour/minute/second combinations exactly as they are shown in KSP. This should make working with those fields much easier.

Second, I did some validation of the calculations. I must say, I am pleasantly surprised by just how close I got. A quick screenshot of my results:

mSLdUbd.jpg?1

The main thing to note is that by entering the burn values into MechJeb's node editor, I was able to get the targeted intercept with Duna. I had to eyeball the true anomaly of the burn, of course, and use MechJeb to adjust it until I was close enough. That didn't pose much of a problem, though, and was quite easy. I did notice that the flight time was a bit different from what I predicted, but I put that down to my orbit and departure time not being exactly entered into KSP TOT. It was within a few days, which is "close enough" in my book.

I'll probably try a trip to Eeloo tomorrow as another form of validation. Since it's inclined, I expect it will make a more interesting challenge.

Thoughts? :)

Share this post


Link to post
Share on other sites

I've completed another update to the code and updated the ZIP archive containing the relevant files in the first post. Changes includes:

  • inclusion of basic computational options, accessible from Edit->Options,
  • fixed a bug where datatips on the main porkchop plot would not always display estimated delta-v,
  • added a custom display for datatips on the porkchop plot,
  • added time past periapse to the burn information on the departure display GUI.

My test with Eeloo yesterday went well. I've noticed that occasionally to get an intercept you need to adjust the departure time by +/- a few fractions of a second. The smaller the SOI you're aiming for (and Eeloo's is small), the more likely it is you'll need to adjust the departure time. This is to account for the fact that the patched conics assumption assumes that the SOIs of the body you're leaving and arriving at are very small (essentially 0 volume), whereas in reality they do have some size. Also, you never truly depart at the exact moment you planned to, so error creeps in there as well.

Last major item of business is input checking. Right now you can enter anything into any GUI box and it'll try to work with it. This obviously is not good. I'll fix this up tomorrow most likely.

Really now, the functionality is all there and working as far as I can tell. What I really need are testers and feedback. Anyone game? I can't offer much except my appreciation and thanks in the program's future README, but any help would be appreciated. :)

Edited by Arrowstar

Share this post


Link to post
Share on other sites

I can't wait to use this tool, it looks great. Though, is there a way to get a standalone exe eventually? Having multiple files to install increases complexity, and may dissuade potential users.

Share this post


Link to post
Share on other sites

Hi there!

You can use the tool now, it's ready to go. :) I'm going to make some updates today w.r.t. input error checking and a Secret Feature I've thought about adding since I started using the tool myself. Should make it even more useful to use. :)

I guess I'm a bit confused: there is a standalone executable (no need to run the MATLAB .m files by themselves). Unless you're talking about needing to grab and install the MCR package? In that case, no, sadly, the MCR must be installed separately. It's a large package, unfortunately, but you only have to install it once. I don't want to package them together because it will make updating to a new version of KSP TOT more painful (having to re-download the MCR each time would suck). That's why I leave it as two separate packages.

Do you have any suggestions on how I could simplify the install process for users?

Share this post


Link to post
Share on other sites

Hmmm, it seems I should hold off on commenting until I have a better understanding of what's going on. As it stands this looks like a wonderful tool, and I'd like to congratulate you and thank you for giving us the chance to use it.

As for suggestions... is there a way to have the program automatically download the needed files on first run?

I imagine most people who come across this are going to be trying to find a tool that simplifies their playing experience. While giving them a strong planning tool is great, many may not see past the hurdle of downloading multiple files as it feels like making things more complicated instead (I know I was putting off downloading it for this very reason). Would your program need everything found in the MCR package? Maybe it could contain just the files it needs? As it stands I get the impression that I need to install this big bulky complex thing, to be able to use this little, simple tool that would make my life easier.

I'll go ahead and go through the installations and try this out before I say anything else.

Edit one: Just downloading the two files heightens my impressions. While your package downloaded in under 5 seconds, I still have 26 minutes left on MCR, no doubt with a lengthy install process in store when it's done. It makes me wonder just how much of this download your program will actually use, and how much will be wasted space? I know that I'll probably never use the compiler aspects of the file I'm downloading.

Edited by aquilux

Share this post


Link to post
Share on other sites

Thanks for the feedback.

So here's the thing: I didn't come up with or put together the MCR. The nice folks over at The MathWorks developed it as a way for people like me (who write awesome MATLAB code) to distribute products to people without MATLAB. I don't have any control over what goes into the MCR, sadly. It's large size is an outstanding issue that people have complained about to The MathWorks developers.

I wish I could have my application download the file at first run. However, since the application requires the MCR to run, having it try to download and run the MCR would be a bit of a catch-22. :)

That said, you are correct in noting that most of the features in the MCR are features that my application doesn't use. (In fact, all I really need is access to the core MATLAB runtime evnviroment plus the optimization toolbox.) This is something we MATLAB developers have complained about, but like I said, there's not much I can do about it. Some type of runtime library is needed to execute MATLAB code, and unless someone comes up with a solution to customize the MCR package at compile time, we're stuck with the all-inclusive solution we've got now. I wish I could do something about it. :(

I would urge you (and everyone else) to not give up on this useful little application just because of file size. I realize it's big, but if you're interested in working with the most accurate and detailed maneuver planning software on the KSP market, stick with it and you won't be disappointed. :)

Share this post


Link to post
Share on other sites

Sorry, looks neat, but I'm on a slow connection - I'm not going to download a 388MB runtime solely for a tool that I can approximate elsewhere.

Share this post


Link to post
Share on other sites

Hi The Lone Wolfling,

And that's perfectly fine. I realize that it's a bit big and not everyone has the bandwidth and time to download the MCR. For those people, there are a plethora of other tools out there that offer approximations to what my code can do. No worries. :)

Share this post


Link to post
Share on other sites

I've updated the application 0.4. As the change log in the OP indicates, the following has been added:

  • Fixed bug where departure calculation window would not refocus after selecting departure/arrival times from porkchop plot.
  • In departure calculation input GUI, added ability to right-click on arrival time input and select option to optimize that time based on what's in the departure time box.
  • Added application-wide input checking.

The second point is pretty big. What this means is that all you have to do is enter the departure time you want, right click the arrival time box, select the optimization option, and wait a few seconds. It's pretty handy. I've checked the results against the porkchop plots and they look pretty good, minor variance in optimizer results aside. It's a feature I wanted myself and really like now that I have it.

To demonstrate:

Right click on the arrival time box, select optimize option.

YrHkCSE.png

Wait a bit...

SEe7Q6R.png

Voila! The best time is computed and input into the box. That's all there is to it. :)

yKVpFHH.png

As always, comments, suggestions, and bug report welcome.

Share this post


Link to post
Share on other sites

Can it be used to plan gravitty-assisted voyager like missions? Like Kerbin -> Eve -> Duna etc flybys?

Share this post


Link to post
Share on other sites
Can it be used to plan gravitty-assisted voyager like missions? Like Kerbin -> Eve -> Duna etc flybys?

Yes that is a planned feature. I have the math already worked out, just need to implement. It's probably a few releases off yet. Give me a week or two. :)

Share this post


Link to post
Share on other sites

Yesterday I put together a new feature in the Departure Information window: a map of your orbital trajectory during transfer orbit from one body to another.

pWNeYFS.png

It does two things: first, it shows you that the trajectory you're on actually does what you want it to (namely, finds the target body); and second, it can be used while playing the game to verify you're on the right path.

I realize at the moment it's a bit sparse. I could use some suggestions for additional information to annotate the map with. Anyone have any thoughts?

Share this post


Link to post
Share on other sites
I could use some suggestions for additional information to annotate the map with. Anyone have any thoughts?

Apoapsis, periapsis, ascending and descending nodes (All for the transfer orbit). Possibly also something showing where the target is on the initial burn. And maybe a "side-on" view, where the origin's orbit (Kerbin in this case) shows up as a horizontal line, and you can see the transfer orbit and the target's orbit.

Also, I finally downloaded the runtime, and this tool looks great!

Another feature request: could you add a way to search for the best departure time given a target arrival time? And/or a way to find the earliest arrival time possible given a certain amount of delta-v? And/or a way to find the best global delta-v. Also, it would be nice if the tooltip pre-populated the departure burn parameters.

One final request for now: would it be possible to either define a custom color gradient for the porkchop plot, and/or compress the low end? Currently the center of the porkchop plots are one big blob, even when there's a significant difference (.99 - 1.9km/s for departure delta-v to Duna, for example.)

Edited by The Lone Wolfling

Share this post


Link to post
Share on other sites
Apoapsis, periapsis, ascending and descending nodes (All for the transfer orbit). Possibly also something showing where the target is on the initial burn. And maybe a "side-on" view, where the origin's orbit (Kerbin in this case) shows up as a horizontal line, and you can see the transfer orbit and the target's orbit.

Sounds good, thanks for the suggestions. I can probably add the apses and the nodes. The location of the target at the burn time is also very doable. I shouldn't need to show another view, since the transfer orbit map is actually 3D. I just didn't show that. :)

Also, I finally downloaded the runtime, and this tool looks great!

Thanks! Glad you took the jump and downloaded it. It is a fun little tool, yep. :)

Another feature request: could you add a way to search for the best departure time given a target arrival time?

Certainly. I'll add this to the feature list of 0.5. This isn't something I'd usually look for because I usually pick my departure and go from there. But this could be useful too. Great suggestion!

And/or a way to find the earliest arrival time possible given a certain amount of delta-v?

Also possible and I can see the utility of this. Sounds good! Added to 0.5 feature list.

And/or a way to find the best global delta-v.

This is actually the point of the porkchop plot, so I would suggest looking at that. :)

Also, it would be nice if the tooltip pre-populated the departure burn parameters.

Good suggestion. I'll do this tonight. EDIT: Nevermind, finished it. If you have more than one data tip on the plot, it will take the last tooltip you created. Coming in v0.5.

One final request for now: would it be possible to either define a custom color gradient for the porkchop plot, and/or compress the low end? Currently the center of the porkchop plots are one big blob, even when there's a significant difference (.99 - 1.9km/s for departure delta-v to Duna, for example.)

This is a bit trickier, but I'll see what I can do. I'm not sure how capable MATLAB is in this regard. I'll investigate.

Thanks for the great suggestions! :)

Edited by Arrowstar

Share this post


Link to post
Share on other sites

This is a pretty cool tool, I can't wait to try it out! :)

Would it be possible to get some measurement of the sensitivity of the transfer orbit with respect to errors in the departure hyperbola? Such as, say, how sensitive the parameters for that orbit and for the intercept with the target are to changes in the argument of periapsis, departure time, eccentricity, inclination, closest approach, etc. This would be very useful for launching large, low-TWR vehicles to other planets and trying to figure out how much piloting errors could interfere with getting a proper transfer orbit.

I'd also suggest adding Ascending and Descending Nodes, argument of periapsis, etc. to the target orbits (using Kerbin's orbit as a datum plane). Perhaps you could make the parts of the orbit above the datum plane solid lines and below that plane dashed lines for added clarity?

Share this post


Link to post
Share on other sites

This is actually the point of the porkchop plot, so I would suggest looking at that. :)

I am aware of this.

However, currently there is no way to automatically select the best global trajectory, and trying to select it manually by trial and error gets tedious, especially given the gradient issues.

Share this post


Link to post
Share on other sites
This is a pretty cool tool, I can't wait to try it out! :)

Would it be possible to get some measurement of the sensitivity of the transfer orbit with respect to errors in the departure hyperbola? Such as, say, how sensitive the parameters for that orbit and for the intercept with the target are to changes in the argument of periapsis, departure time, eccentricity, inclination, closest approach, etc. This would be very useful for launching large, low-TWR vehicles to other planets and trying to figure out how much piloting errors could interfere with getting a proper transfer orbit.

I'd also suggest adding Ascending and Descending Nodes, argument of periapsis, etc. to the target orbits (using Kerbin's orbit as a datum plane). Perhaps you could make the parts of the orbit above the datum plane solid lines and below that plane dashed lines for added clarity?

Thanks! Please let me know what you like and dislike so I can make improvements as necessary. :)

It might be possible for me to perform some sort of sensitivity analysis. To be honest, though, I guess I don't see the purpose. True, it would show you when your "long" burn might significantly change your answer, but this is KSP... aren't we all just going to go for it anyway? :P

I've added the apses to the orbit transfer map tonight. I'll have to think about the nodes, because you need to pick the correct plane for them to make sense. There's a fair bit of thought, design, and math that needs to go into plotting those. Honestly, they will probably come about later, if only because they're a very small feature that requires a lot of work.

Thanks for the suggestions! I'd be happy to hear more if/when you have them. :)

I am aware of this.

However, currently there is no way to automatically select the best global trajectory, and trying to select it manually by trial and error gets tedious, especially given the gradient issues.

Indeed. I apologize, I wasn't intending to come across as cheeky. It just struck me that what you were asking for is exactly what the porkchop plot is for in the first place. :)

In any event, I think you're right and some sort of indication of an optimized departure/arrival date/time is a good idea. Tonight I wrote the code to actually perform the optimization. It's just a matter of how to let the user call that. Right now I have it tied to the porkchop plot generator method: it generates the plot, then finds the optimal point within the plot. (Or, really, within 1 synodic period of the best point in the porkchop plot.) Do you have any suggestions on how I might present this "optimized" information to the user? I'm not sure I can use the data cursor thing I've got showing the best point computed for the porkchop plot, but I'll investigate anyway. Assuming that's a no-go, any thoughts? I'm thinking I either write it to the text box below the porkchop plot or bring up a pop-up box with the times in it. Would either of those be acceptable?

Time markers, as seen here.

Thanks for the suggestion! I'll consider it, though I have to admit, the plot is getting pretty cluttered with just the orbits and transfer orbit periapse/apoapse. We'll see. :)

Some updates:

I implemented the following requested features tonight:

  • Find optimal departure for given arrival;
  • Add transfer orbit periapse & apoapse to the orbit plot; and
  • Find optimal arrival/departure on a generated porkchop plot (partial: result of optimization run needs to be displayed to user still).

Tomorrow's agenda is the following request:

  • Find earliest arrival for provided delta-v. Btw, I'm assuming that the delta-v provided is for the full round trip: departing one place and arriving at another. If I just use the departure dv, that could make things a bit optimistic in some cases. Do you guys have any thoughts on this? Which delta-v (the departure + arrival delta-v or just the departure delta-v) would be more intuitive for you?

I'm also going to rewrite the Lambert solver at some point using the code I gave to R4m0n for MechJeb (yep, that's my Lambert solver) as a base. The current solver I have now is fine, but it seems to die at odd times and I'm sick of troubleshooting it. :)

Thanks for the great suggestions/ideas, guys. Keep them coming! If I have time tomorrow night, I'll put out the v0.5 (pre-)release for people to play with. :)

Share this post


Link to post
Share on other sites
Do you guys have any thoughts on this? Which delta-v (the departure + arrival delta-v or just the departure delta-v) would be more intuitive for you?

Allow either via a toggle setting. For destinations with atmospheres, departure only makes the most sense, but for destinations without, you care about the total.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now