Jump to content

[WIN/MAC/LINUX] KSP Trajectory Optimization Tool v1.6.10 [Major LVD Improvements!]


Recommended Posts

I'm using the latest 1.5.6 prerelase 3 and get the following when I try to enable script->parallel.  Anyone have ideas of what might be wrong?  I'm using the Win64 MCR linked in the first post (MCR_R2015b_win64_installer.exe).


 

Error using parpool (line 103)
'size' is not the name of a profile.  Valid names are:
local

Error in ma_MainGUI>parallelizeScriptOptimizationMenu_Callback (line 1361)


Error in gui_mainfcn (line 95)


Error in ma_MainGUI (line 42)


Error in matlab.graphics.internal.figfile.FigFile/read>@(hObject,eventdata)ma_Ma
inGUI('parallelizeScriptOptimizationMenu_Callback',hObject,eventdata,guidata(hOb
ject))


Error while evaluating Menu Callback

 

Edited by KC_073
added exact MCR version
Link to comment
Share on other sites

Oh, and one more while I'm thinking of it.  Looks like the issue is f(x) going from positive to negative and messing up the middle chart in the Mission Optimizer window.  I get this warning early on :

 

 Iter F-count            f(x)  Feasibility   optimality         step
    0      13   -1.818768e-03    0.000e+00    3.318e-01
    1      26    3.140060e-03    3.620e+00    8.329e+02    6.792e-02
Warning: Negative data ignored
> In optimplotfval>plotscalar (line 48)
  In optimplotfval (line 24)
  In ma_OptimOutputFunc>generatePlots (line 76)
  In ma_OptimOutputFunc (line 22)
  In ma_ObserveOptimGUI>@(x,optimValues,state)ma_OptimOutputFunc(x,optimValues,state,handles,problem,celBodyData,recorder) (line 76)
  In callAllOptimOutputFcns (line 13)
  In barrier>callOutputAndPlotFcns
  In barrier/nlpInterfaceFcn
  In barrier
  In fmincon (line 796)
  In ma_ObserveOptimGUI>executeOptimProblem (line 93)
  In ma_ObserveOptimGUI>ma_ObserveOptimGUI_OpeningFcn (line 78)
  In gui_mainfcn (line 220)
  In ma_ObserveOptimGUI (line 42)
  In ma_MissionOptimizerGUI>optimizeMissionButton_Callback (line 577)
  In gui_mainfcn (line 95)
  In ma_MissionOptimizerGUI (line 42)
  In matlab.graphics.internal.figfile.FigFile/read>@(hObject,eventdata)ma_MissionOptimizerGUI('optimizeMissionButton_Callback',hObject,eventdata,guidata(hObject))
  In uiwait (line 81)
  In ma_MissionOptimizerGUI>ma_MissionOptimizerGUI_OpeningFcn (line 78)
  In gui_mainfcn (line 220)
  In ma_MissionOptimizerGUI (line 42)
  In ma_MainGUI>optimizeMenu_Callback (line 875)
  In gui_mainfcn (line 95)
  In ma_MainGUI (line 42)
  In matlab.graphics.internal.figfile.FigFile/read>@(hObject,eventdata)ma_MainGUI('optimizeMenu_Callback',hObject,eventdata,guidata(hObject))
    2      39    1.890565e-03    1.947e+00    1.829e+02    5.516e-02

Then at iteration 21 f(x) goes negative again. At that point the Current Function Value chart stops updating even though everything else keeps working.  Looks like just a cosmetic bug but figured I'd mention it.

Link to comment
Share on other sites

@Arrowstar I have a MAT for you to look at - download.

Set your SOI search revs to max to show a Kerbin intercept for event 2 on this orbit (it's an asteroid). It tells me in the Final Spacecraft State popup that there is a 21,401km periapsis altitude, but if I coast for just 1 second I'm back out into the Sun's SOI. Not sure what's going on here but I can't get it to show any orbital plot around Kerbin. If you delete the Coast to Next SOI (event 2) and do a Coast event to periapsis with Kerbin as the reference body it'll take you to the next encounter, and still show no orbital plot for Kerbin on the first encounter.

Link to comment
Share on other sites

4 hours ago, panzerwaffe044 said:

The tutorial tells only about interplanetary. 

Don't skimp on the tutorial just because it only handles interplanetary. The steps are pretty much the same for what you want just applied differently. Go through the tutorials to learn the ins-and-outs which can then be applied generally to other missions.

If you've read through the tutorials, play around on your own and still need help, come on back

Edited by Drew Kerman
Link to comment
Share on other sites

I used KSPTOT with KSP 1.1 with no troubles. With the latest version 1.5.6 and KSP 1.2.1, KSPTOT will get orbit info, but will not read maneuver nodes. It just goes "ding", no error message. Maneuver nodes created in TOT will correctly upload.

Here's the relevant (?) error from the log:

Quote

Error in ma_MainGUI>getManeuverNodesFromKSPActiveVessel_Callback (line 1455)


Error in gui_mainfcn (line 95)


Error in ma_MainGUI (line 42)


Error in matlab.graphics.internal.figfile.FigFile/read>@(hObject,eventdata)ma_MainGUI('getManeuverNodesFromKSPActiveVessel_Callback',hObject,eventdata,guidata(hObject))


Error while evaluating Menu Callback

Any ideas?

 

Edited by Aler
Link to comment
Share on other sites

  • 2 weeks later...

hrrrmmm... so I've been messing around with the tabular text output of the graphic analysis tool and I wanted to get 60s per row in the output so I figured I'd output data for a period of 2001*60 since there are 2001 data points generated for each run (for determining line of sight to a ground station). However when I looked at the results the start of the output for mission elapsed time said 0 and 60.03 and yet somehow the last two rows say 120000 and 120060 so by the end it was outputting at 60.0 each

Ultimately if possible it would be cool to specify how many seconds there are between outputted values, so that even if I only have a timespan of like 28 minutes but want data every 60s then I would get an output sheet with only 28 values instead of 2001 (but of course the plotter would still calculate 2001 points)

Edited by Drew Kerman
Link to comment
Share on other sites

  • 2 weeks later...

hope work/life allows @Arrowstar a chance to come back soon. Just logging a few more issues for his eventual return.

Some interesting behavior with the tabular text output I never noticed before is that if you have a saved mission file, the text output is automatically saved to the folder where the mission file is saved. I assume this is proper? I actually thought the tabular text output was broken for some of my mission files because it wouldn't pop up the save folder dialog so I had to copy some orbits to a new mission file to get the dialog to show. I also saw some errors in the log, though not consistently so I thought this was a problem. Just now when I went to zip up the MAT file to post for you, I saw all the outputted CSV files! I guess I never realized all the times I asked for tabular text output and it popped up the dialog I hadn't actually saved the mission yet.

Suggestion

If this is proper behavior I would suggest at least an alert popup letting the user know the output was generated properly? Although, clearing that every time could get annoying. Hrm.... maybe there's a way you can inject some text into the output plot that the file was generated? I just think others may get confused like me and wonder if the data got generated, and where it ended up.

Bug Report

Also the Other Spacecraft window stayed open when I started a new project. Not sure how that could screw things up I didn't try it :P Just closed it when I realized it was still open. It and any other child windows to MA should probably close on a new project or opening another project

Edited by Drew Kerman
Link to comment
Share on other sites

On 12/16/2016 at 11:53 AM, Drew Kerman said:

hope work/life allows @Arrowstar a chance to come back soon. Just logging a few more issues for his eventual return.

Some interesting behavior with the tabular text output I never noticed before is that if you have a saved mission file, the text output is automatically saved to the folder where the mission file is saved. I assume this is proper? I actually thought the tabular text output was broken for some of my mission files because it wouldn't pop up the save folder dialog so I had to copy some orbits to a new mission file to get the dialog to show. I also saw some errors in the log, though not consistently so I thought this was a problem. Just now when I went to zip up the MAT file to post for you, I saw all the outputted CSV files! I guess I never realized all the times I asked for tabular text output and it popped up the dialog I hadn't actually saved the mission yet. If this is proper behavior I would suggest at least an alert popup letting the user know the output was generated properly? Although, clearing that every time could get annoying. Hrm.... maybe there's a way you can inject some text into the output plot that the file was generated? I just think others may get confused like me and wonder if the data got generated, and where it ended up.

Also the Other Spacecraft window stayed open when I started a new project. Not sure how that could screw things up I didn't try it :P Just closed it when I realized it was still open. It and any other child windows to MA should probably close on a new project or opening another project

Thanks for the report!  I do read every post in this thread (I'm subscribed) but yeah, life has been busy lately.  I am taking a few weeks off from work for Christmas and New Year's Day, though.  @Drew Kerman, if you wanted to be a super awesome guy, what would really help me get a release out this year yet would be to organize the various suggestions you've made into one post, ranked by priority/severity/etc.  I can then see what I can do around the holidays and get something out.  If you'd be up for it, feel free to include posts others have made.  And if not, no worries, I'll still see if I can get something useful done besides. :)

Link to comment
Share on other sites

4 minutes ago, Arrowstar said:

if you wanted to be a super awesome guy, what would really help me get a release out this year yet would be to organize the various suggestions you've made into one post, ranked by priority/severity/etc.  I can then see what I can do around the holidays and get something out.  If you'd be up for it, feel free to include posts others have made.  And if not, no worries, I'll still see if I can get something useful done besides

Consider it done! I have it on my list for sometime this week.

BTW the Pegasus launch was sooo cool. Def have plans to do that w/KSA once we have jets capable of flying that high and hauling that much cargo :)

Link to comment
Share on other sites

3 minutes ago, Drew Kerman said:

Consider it done! I have it on my list for sometime this week.

BTW the Pegasus launch was sooo cool. Def have plans to do that w/KSA once we have jets capable of flying that high and hauling that much cargo :)

Thanks!  I appreciate it. :)

And yeah, Pegasus is a neat little machine, isn't it?  I think it's one of the more nifty ways we have to put spacecraft into orbit, don't you?  I look forward to seeing the KSA version!

Link to comment
Share on other sites

1 minute ago, Arrowstar said:

I think it's one of the more nifty ways we have to put spacecraft into orbit, don't you?

oh yea, that's definitely what makes it neat. Very unique form of launch. I hadn't realized it has been so long since it was last used. If you missed this on reddit, here's a good fail attempt :P

1 minute ago, Arrowstar said:

I look forward to seeing the KSA version!

don't forget it'll take a few years :P

Link to comment
Share on other sites

will post a compiled list of all issues/suggestions at the end of the week, since I'll be playing up till then and finding new stuff. Just came across a Mun intercept that is completely failing to show up when I try to coast to next SOI even tho when I manually coast ahead by UT and show Mun's position and SOI I see the orbit line going right through it :huh: - you want any info besides the MAT file for that @Arrowstar?

Link to comment
Share on other sites

I've had success with doing crazy flybys and grandtours with KSP TOT in stock, but I'm having trouble porting it over to RSS, although in the description says there compatible. Specifically, even when using the orbital values given by this the orbit is widely different from that need to insert into the transfer burn. I haven't actually done a mission to another planet in RSS but I assumed you waited for your transfer window and did your burn from the ecliptic. Is that right? Putting in 180 for the LAN (which I just guessed) seems to work better, but other tests worked better with other values, so I don't think TOT just uses a different value for the LAN of the ecliptic.

Here are some pictures to help clarify, sorry if I'm being a little confusing. Im using KSP 1.1.3.

Edited by Chriguana
Link to comment
Share on other sites

37 minutes ago, Chriguana said:

I've had success with doing crazy flybys and grandtours with KSP TOT in stock, but I'm having trouble porting it over to RSS, although in the description says there compatible. Specifically, even when using the orbital values given by this the orbit is widely different from that need to insert into the transfer burn. I haven't actually done a mission to another planet in RSS but I assumed you waited for your transfer window and did your burn from the ecliptic. Is that right? Putting in 180 for the LAN (which I just guessed) seems to work better, but other tests worked better with other values, so I don't think TOT just uses a different value for the LAN of the ecliptic.

Here are some pictures to help clarify, sorry if I'm being a little confusing. Im using KSP 1.1.3.

I think we had the same issue, read a few of these posts

 

Link to comment
Share on other sites

Ooookay, here's the whole shebang. Everything that was posted since the last posted release. I will let you determine the priority of these things. They are simply listed in the order I found them as I read through the thread. Except for the barycenter compatibility. That's from me and def low-priority and I can't recall if you said that just wasn't really feasible - I know I asked about it before.

Bug Reports

·         Maneuver upload does not result in SOI hit – Reference | Additional conversation

·         Copy/Paste orbit data does not include orbiting body - Reference

·         Enabling script->parallel throws error - Reference

·         f(x) going from positive to negative messes up the middle chart in the Mission Optimizer window - Reference

·         No trajectory plotted through Kerbin SOI for asteroid coming from sun orbit - Reference

·         KSPTOT will get orbit info, but will not read maneuver nodes - Reference

·         Tabular text output interval not constant - Reference

·         Other Spacecraft window stays open on loading new project - Reference

·         Mun SOI intercept not found on trajectory that passes through Mun’s SOIReference

Feedback/Feature Requests

·         MA save dialog notes if save file is dirty or not [implemented in unreleased version] – Reference

·         Edit what bodies are included in the MAT save file - Reference

·         Show position of Other Spacecraft by rendering a fraction of their trajectory - Reference

·         Other Spacecraft dialog has disabled input if no vessels listed until Add Spacecraft button is clicked - Reference

·         In the execution assistant, add ability to right-click and read next maneuver node from KSP – Reference

·         In the Orb Ops console, display the maneuver node's True Anomaly, to match what the execeution assistant wants (same reference as previous suggestion)

·         Figure window maintains plot box position on rotation after panning - Reference

·         Specify interval of tabular text output - Reference

·         Notify user of successful tabular text output when using a saved mission file - Reference

·         Barycenter compatibility with Sigma Binary for flight plotting

KSP v1.2 Compatibility

·         GM/Atmosphere/Rotational periods – Reference

·         KSP TOT still expects anomalies in the range of [0, 360] - Reference

Documentation

·         Updated Mac install instructions - Reference

I will be in Dubai starting Dec 26th to help wrap up (or as you space-types would probably say, close out) work on New Years fireworks displays so while I'll have internet and be checking in I won't be able to play KSP (my planned funds for a Surface Book got eaten up by some of life's more expensive necessities this season) so can't test any new releases until I get back Jan 3rd.

Edited by Drew Kerman
Link to comment
Share on other sites

  • 2 weeks later...

Hi everyone, Brand new to Kerbal here... looked into the available add-ons, seems like the Trajectory Optimization Tool was the one I was most interested it. So it is my first mod that I am installing. Seems like I am having problems. I did search the forum for it without any success.

It seems like I keep getting a MS-Windows sound (indicating an error) everytime I try to launch the program. Still the first time I tried it, it did work somewhat initially and I was able to see the user interface.

The log file shows “Undefined function or variable 'matlabrc'.” This log file is updated with this message every attempt.

 

Wondering if anyone can help? Detailed information below.

 

Thanks…

***********************************************************

I followed the instructions below

 

  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.

  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.

 

I did make one mistake though, it was to run the program before I was able to copy the KSPTOTConnect folder .

Any way, I ran the program ... it did execute once and I saw the interface. But then when I tried to go to mission architect it failed (It kept playing one of the MS-Windows sound). I then launched Kerbal Space Program game to see if that would make a difference, without success.

I was not able to close program either, got the same MS-Windows sound. So I had to force-close with the windows task manager. I rebooted. No success.

I have deleted the KSP TOT folder and created a new one from the zip file, without any success.

I execute the program by double-clicking the .exe file. There was no installation for the program, I just double-click the executable file in the unzipped folder.

I have Windows 10, with all updates, using windows Defender anti-virus. I did add an exception for the executable file just in case.

 

Specs below.

Operating System

            Windows 10 Home 64-bit

CPU

            Intel Core i7 6700K @ 4.00GHz       34 °C

            Skylake 14nm Technology

RAM

            16.0GB Dual-Channel Unknown @ 1069MHz (15-15-15-35)

Motherboard

            ASUSTeK COMPUTER INC. Z170-A (LGA1151) 46 °C

Graphics

            ASUS VW266H (1920x1200@59Hz)

            AL2223W (1680x1050@59Hz)

            4095MB NVIDIA GeForce GTX 960 (EVGA)        42 °C

Storage

            931GB Western Digital WDC WD1003FZEX-00RLFA0 (SATA)  42 °C

Optical Drives

            ASUS DRW-24F1ST c

Audio

            NVIDIA High Definition Audio

 

 

 

 

 

 

Link to comment
Share on other sites

23 hours ago, bcote689 said:

It seems like I keep getting a MS-Windows sound (indicating an error) everytime I try to launch the program. Still the first time I tried it, it did work somewhat initially and I was able to see the user interface.

Looking through your details I can't see any problems that should be occurring. Delete everything you installed as per the instructions and re-install. Otherwise, you'll have to wait for @Arrowstar to swing by and check into that error message in your log file. He said he'd have time over vacation to work on this but things change and his real job is so close to this I'd not be surprised if he just wanted to step away from all related work for the holidaze

Link to comment
Share on other sites

On 3/1/2017 at 8:55 PM, bcote689 said:

It seems like I keep getting a MS-Windows sound (indicating an error) everytime I try to launch the program. Still the first time I tried it, it did work somewhat initially and I was able to see the user interface.

The log file shows “Undefined function or variable 'matlabrc'.” This log file is updated with this message every attempt.

...

I am no expert with MatLab, but certainly it is not being started correctly (or not at all). While KSPTOT is running, it depends on a very large number of MatLab .dlls (the pic below shows only about 25% of the whole list of MatLab .dlls while KSPTOT runs on my system), you may check similarly if they are loaded.

Spoiler

Wu6VDaV.png

Digging info about "matlabrc" found this, it seems the function is a simple command that points at the actual startup.m file, which cares for all MatLab initialization. Can't tell why it doesn't work on your system, but seems a misplaced startup.m file could be the cause of an aborted initialization. Clearly KSPTOT remains stuck until all required assets are loaded, I guess that's the reason for the sound you hear and inability to close the program.

My advice is to reinstall the MCR package, and also check that nothing interferes with it (e.g., a false positive from the Antivirus can ruin the install and/or the working of the package).

No need to have KSPTOTConnect correctly installed to start KSPTOT, you may move that folder in /GameData later so to allow KSP to share data, missing to do so only doesn't enable KSP-KSPTOT data sharing.

Link to comment
Share on other sites

On 2017-01-03 at 2:55 PM, bcote689 said:

It seems like I keep getting a MS-Windows sound (indicating an error) everytime I try to launch the program. Still the first time I tried it, it did work somewhat initially and I was able to see the user interface.

Thanks Drew and Diomedea for your help. It is much appreciated.

 

So I did a full unininstall, added an exception to the matlab installer, and did a fresh re-install. I made sure prior that I had indeed the 2015b 64bit version of the matlab library.

It appears none of the matlab processes are running.....good find Diomedea!! That has to be the source of the problem.

I will keep looking for a solution, but if there are any other hints for me, that would be great!!

 

Thanks,

 

 

 

 

 

 

 

 

 

 

 

 

Link to comment
Share on other sites

8 hours ago, bcote689 said:

Thanks Drew and Diomedea for your help. It is much appreciated.

 

So I did a full unininstall, added an exception to the matlab installer, and did a fresh re-install. I made sure prior that I had indeed the 2015b 64bit version of the matlab library.

It appears none of the matlab processes are running.....good find Diomedea!! That has to be the source of the problem.

I will keep looking for a solution, but if there are any other hints for me, that would be great!!

 

Thanks,

Hi there:

Can you try this build and see if it helps?

https://dl.dropboxusercontent.com/u/29126891/KSPTOT_v156_prerelease3_debug.zip

I included what is apparently the file you're missing.  Not sure why no one else is seeing your issue, of course, but we'll give this a try anyway.  Please let me know.

Regarding updates: I've had a small amount of time to work on the next release, 1.5.6, and I'm hoping to push something out this weekend.  I know I say that a lot but I actually do have time some Saturday. :)

Link to comment
Share on other sites

14 hours ago, Arrowstar said:

Hi there:

Can you try this build and see if it helps?

 

It seems to working very well.

Thanks a Million, from what I saw the add-on has even more possibilities than I was hoping for .... really looking forward to try it in detail !!

 

 

 

 

 

 

Edited by bcote689
Link to comment
Share on other sites

6 hours ago, bcote689 said:

It seems to working very well.

Thanks a Million, from what I saw the add-on has even more possibilities than I was hoping for .... really looking forward to try it in detail !!

No problem, glad it worked out.  I'll be keeping the fix for the next release version, thanks for reporting.

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