Jump to content

[1.0.5] GravityTurn version 1.3.1 - Automated Efficient Launches (1.1 pre-release available)


Overengineer1

Recommended Posts

Comments:

  1. You should watch for SRBs flaming out, and then doing a staging event.  Right now, I have to manually stage the SRBs because the main stage is still firing.
  2. A staging delay (ie: how long to wait before staging after stage is exhausted) would be good
  3. Being able to resize the FlightMap might be good for people with smaller monitors (not everyone has 27" monitors)
  4. Clicking the help buttons (with the ?) works, but when clicked again it brings the GravityTurn window on top of the help window.  I would expect that clicking the same ? button would hide the help window.
  5. Dynamic Pressure is not well defined, can you elaborate what the number means (in the Pressure Cutoff)

 

Link to comment
Share on other sites

31 minutes ago, FrontLineFodder said:

@Overengineer1

Can mods write log files ? It would be good to write out a log file for each launch with shipname, launch time, launch profile (settings) and final losses logged so we can compare different launches after the fact.

Yes, they can.  Either in the standard KSP log file, or whatever file you want.

If @Overengineer1does this, I would suggest creating a subdirectory either inside the mod directory or inside the main KSP directory, and put the individual files in there.

@Overengineer1Let me know if you need help with this

LGG

Link to comment
Share on other sites

3 hours ago, linuxgurugamer said:

[...] I would suggest creating a subdirectory either inside the mod directory or inside the main KSP directory, and put the individual files in there. [...]

Something of a tangent, but I actually wish KSP would save games to the user's profile directory rather than the game's directory. Granted, when the game gets updated it tend to break stuff in some form or another, so it's usually a better idea to start fresh anyway. Still, when working with mods and such (especially troubleshooting), it'd be nice to leave customizations, setting, save games, and craft designs in the user profile so that if/when you need to wipe a KSP install completely, you still have to items by default (and can delete separately if they are causing issues).

Though at the same time, many of my designs got completely broken from v0.90 to v1.05 (stock changes, unsupported/non-updated/obsolete mods, mods I no longer use, heavily revised mods, etc.)

Anyway: Yes, telemetry logs would be useful for tracking the effects of settings and design changes. I don't use rockets much, so I don't use this mod yet, but I probably would since it seems more advanced compared to MJ's function (in particular the "best guess" feature; MJ is all manual settings).

Link to comment
Share on other sites

1 hour ago, StahnAileron said:

Something of a tangent, but I actually wish KSP would save games to the user's profile directory rather than the game's directory. Granted, when the game gets updated it tend to break stuff in some form or another, so it's usually a better idea to start fresh anyway. Still, when working with mods and such (especially troubleshooting), it'd be nice to leave customizations, setting, save games, and craft designs in the user profile so that if/when you need to wipe a KSP install completely, you still have to items by default (and can delete separately if they are causing issues).

Though at the same time, many of my designs got completely broken from v0.90 to v1.05 (stock changes, unsupported/non-updated/obsolete mods, mods I no longer use, heavily revised mods, etc.)

Anyway: Yes, telemetry logs would be useful for tracking the effects of settings and design changes. I don't use rockets much, so I don't use this mod yet, but I probably would since it seems more advanced compared to MJ's function (in particular the "best guess" feature; MJ is all manual settings).

Keep in mind that KSP is multiplatform, so by keeping everything in the games' directory, they don't have to do any platform-specific coding.

You are obviously a Windows user, but Macs and Linux users also exist, and don't have the profiles the way windows does (not meant to be disparaging, just stating a fact)

Link to comment
Share on other sites

Just now, linuxgurugamer said:

Macs and Linux users also exist, and don't have the profiles the way windows does 

Of course they do.  /home/<username> is a direct parallel to C:\Users\<username>  (or C:\Documents and Settings\<username> for you XP users)

In either case I won't be writing any logs there, as KSP takes care of the file path building for me.

Link to comment
Share on other sites

37 minutes ago, Overengineer1 said:

Of course they do.  /home/<username> is a direct parallel to C:\Users\<username>  (or C:\Documents and Settings\<username> for you XP users)

In either case I won't be writing any logs there, as KSP takes care of the file path building for me.

No.  /home/<username> is equivilent to Windows C:\users\<username>

The profile is something totally different in windows

:-)

 

Link to comment
Share on other sites

Nice mod. I've gotten quite good at manual GT's now but it is getting tiresome to repeat over and over so I like the idea of setting params to automate it..

I have a couple of questions. I've used your best guess option, and honestly it doesn't quite behave like a proper gravity turn, and I'm finding it to be less efficient. My usual MO is I wait to 50m/s tilt to 5degrees and then keep the AoA to around 5 degrees of prograde. If I have my TWR set correctly then that will get me to 45 degrees at around 12km without having to touch the controls. If it's perfect I can leave it and it will slowly tip over to horizontal at around 50km, but usually I have to control it slightly.

Is there a way to set the AoA in this mod? I'm noticing it is quite aggressive with the turn and loses quite a bit of efficiency to drag from over-steering. The curve I'm getting in the map shows that it gains horizontal speed, then vertical (but not enough), then horizontal again, kind of a recurve shape, whereas a true gravity turn is just one straight curve which gains vertical speed and then horizontal speed.(roughly shown in red)

gasNFna.png

RF3kmJe.png The aggressive AoA used by this mod

Edit: The more I play with this the more I wonder if the X axis on this graph actually represents horizontal distance at all. In the early part of the flight just after launch, when the vessel is still travelling straight up, the graph shows a lot of horizontal movement. Could it be showing time or some other parameter?

Edited by KerBlam
more info
Link to comment
Share on other sites

14 hours ago, linuxgurugamer said:

Keep in mind that KSP is multiplatform, so by keeping everything in the games' directory, they don't have to do any platform-specific coding.

You are obviously a Windows user, but Macs and Linux users also exist, and don't have the profiles the way windows does (not meant to be disparaging, just stating a fact)

No offense taken. You make a perfectly valid point. I would like to think the modifications needed to make platform-specific, profile-directory-based saving would be relatively minor, but I'm not a programmer by trade by any stretch.

However, thinking about some other multi-platform indie games I have, I make the counterpoint that those games do save to a user directory in Windows (C:\user\<username>\documents\my games\<gamename> or whatnot). I would imagine they do something similar on the other platforms (of which I am only familiar with Linux's directory structure; I have yet to touch OSX in any meaningful way.)

Still, I admit it's kinda a minor thing at this point. I have gotten used to digging through the KSP directory anyway due to mods. (It just irks me that when I need to update or troubleshoot mods, I sometimes inadvertently delete my settings for those mods in the process because they save their setting in their own folders.)

Anyway, I'll shut up now. Apologies for the thread derailment...

Link to comment
Share on other sites

57 minutes ago, StahnAileron said:

No offense taken. You make a perfectly valid point. I would like to think the modifications needed to make platform-specific, profile-directory-based saving would be relatively minor, but I'm not a programmer by trade by any stretch.

However, thinking about some other multi-platform indie games I have, I make the counterpoint that those games do save to a user directory in Windows (C:\user\<username>\documents\my games\<gamename> or whatnot). I would imagine they do something similar on the other platforms (of which I am only familiar with Linux's directory structure; I have yet to touch OSX in any meaningful way.)

Still, I admit it's kinda a minor thing at this point. I have gotten used to digging through the KSP directory anyway due to mods. (It just irks me that when I need to update or troubleshoot mods, I sometimes inadvertently delete my settings for those mods in the process because they save their setting in their own folders.)

Anyway, I'll shut up now. Apologies for the thread derailment...

I don't think anyone minds a detour (rather than derailment).

Having written cross-platform code (back when it was said to be impossible, in the early 80's), I can say that in general, you are correct.  But, once you start descending into the rabbit warren of differences, it can start to become a maintenance nightmare.  Granted, the main differences are usually (especially in the case of using a base platform like Unity/Mono,.Net) minor, as in the forward slash vs backslash (and yes, I know that Windows understands forward slashes), now you have to start thinking about home directories, profile directories, roaming profiles, etc.

One advantage of putting everything into a single directory is ease of backing up the entire game (this is independent of the platform).  For example, last night I finished setting up a new Linux platform.  I was able to copy the entire game directory from my Windows system onto the Linux box, and other than the linux-specific binaries, the game started right up.  No problems, and I saw that I was able to have unlimited memory (effectively) without any crashes.  If games and/or saves had been stored elsewhere, it would have been much more difficult to move over

Link to comment
Share on other sites

@KerBlam The x-axis is horizontal distance, but it's not surface distance, it's orbital.  You start at launch with 175m/s of horizontal velocity because the planet is spinning.  What you describe as holding a 5 degree AoA is not a gravity turn.  That's just a turn.  That 5 degrees causes you to present more of your vessel to the wind, so it increases your air resistance.  It also spends some of your thrust changing direction instead of going faster, which is wasteful.

The shape of the curve depends entirely on the capabilities of the ship.  Ships with very high TWR can indeed follow a nice smooth curve.  This one has a launch TWR of 4.0, and gets to orbit in only 2840m/s, just barely avoiding overheating, and uses a very aggressive turn of close to 30 degrees at 10m/s:

qTRTdxJ.png

This is an extreme example.  I would hardly call this rocket efficient; even though it only uses 2800m/s, it only carries a single Kerbal and burns enough fuel to send a dozen 1.25 meter ships to orbit.  The example you picture however is a very low TWR rocket, so the mod decided it was not able to pitch down without risking falling.  With a TWR even as low as 2.0 GT is able to make a launch curve that looks similar to the one here.

What you describe as an aggressive angle of attack is not actually an angle of attack.  You are at an altitude where the atmosphere starts to really thin out.  Because you're going so slow, the dynamic pressure on your vehicle fell below the default cutoff of 2500, so the potential for atmospheric drag is very low.  At this point the craft changes from surface velocity to orbital velocity.  The angle of attack is zero throughout the entire launch with the exception of the initial turn.  A faster ship will maintain a higher dynamic pressure for higher through the atmosphere.

We switch to orbital prograde as soon as possible because, like I said earlier, every bit of thrust we spend in a direction other than prograde is wasted.  To be more specific, every bit of thrust we spend in a direction other than orbital prograde is wasted.  Your slow ship does it a bit earlier than average.  If you want to do it later, set a lower pressure cutoff.    However I doubt that would make your launch more efficient.

Link to comment
Share on other sites

Thanks for the reply, I had wondered if it had something to do with the planetary rotation, so that explains that.
 

on advice, I always try to keep my launch TWR at around 1.5, but I'll try higher and see what happens.

Link to comment
Share on other sites

@KerBlam I don't mean to say that higher TWR launches are better.  But GT is able to make better use of higher TWR to avoid some of the losses.  It's a more efficient launch for a less efficient ship, at the end of the day you'll have burned more fuel.  Like I said above, in my extreme example that ship burns enough fuel to send a dozen smaller ships to orbit.

Link to comment
Share on other sites

Ok.. Yes I tried and it seemed about the same or a little more thirsty.

I'm witnessing it climb nearly vertical (80-85 deg) to around 22,000m and then suddenly and very aggressively lay it over and sideslip until the prograde marker catches up at around 40km. What I'm seeing is the craft burn nearly sideways at around 22000m. That's still definitely in atmosphere and you can see on my Navball it is still on Surface velocity. 

It then flattens out and burns horizontal for *ages* until the AP reaches 80km, which is about 10 minutes away (because it decides to ignore the time to AP limit) and goes to coast, but it's still in atmosphere so the AP is dropping and it keeps making small burns just to keep the AP stable. I would like it to reach at least 50k before it flattens out horizontally and I don't want to be coasting that long to AP. Then when it reaches AP the PE is at around 56km so I still need a small circularisation burn but in my mind it could have lifted this to at least 72km during that massive coast even if it blew the AP out a bit.

Please understand I'm not trying to find fault with your mod. I realise that what I'm describing may come from the design of my ship, but is any of this correctable through parameters I can set?

I'd like it to try and smooth the curve out earlier rather than have it jam it sideways at 22,000 ft.

I'd like it to go higher before levelling out to horizontal.

I'd like the PE to be higher than 72km before it reaches AP.

 

Link to comment
Share on other sites

16 hours ago, KerBlam said:

and I'm finding it to be less efficient.

Relative to what?  Are you saying that if you launch your usual way you will end up with more fuel after finishing circularization for a 80 km orbit than if you use this mod with the best guess?  Just Curious.  Could you quantify please?

Edited by mcirish3
Link to comment
Share on other sites

@KerBlam Some of your issues sound like you just have a very low TWR rocket: flying vertical for a long time, suddenly changing to orbital prograde at 22km, this is because you are going so slow and not able to go faster.  The mod is trying to do what you told it to do, and your ship just isn't capable of it.  You probably want to decrease your start angle (so you don't end up burning up), decrease your Start AP Time, and increase your Finish AP Time so that the mod isn't trying and failing to keep up with settings that your ship is not capable of.

The rest of your issues are just your own misconceptions about what the most efficient launch path will be.  No, leveling out at 50km is not more efficient.  The atmospheric drag above about 38km is miniscule, and the increased vector loss and gravity drag from burning up higher to 50km will way more than take up what you save in air drag.  I mean probably by 10 times, you will lose 10 times as much fuel by shifting your curve higher than you save by reducing air resistance.  With just about any rocket-shaped rocket, you will burn up before you find a curve that is too low to be efficient.

If you want to burn all the way to AP, then you need an upper stage that has an unreasonably low TWR.  This is just not reasonable to accomplish in an efficient way with a planet of Kerbin's dimensions.  If your curve tops out at 70km, then sure, your PE will be about 70km when the burn stops.  But this will burn a lot more fuel than necessary.  I have done a LOT of testing on this, and I have all the numbers to back it up:  Having your curve top out at 40km and slowly climbing to an 80km AP halfway around the planet from where you launched is in every reasonable case by far the most efficient launch path with a stock atmosphere.

If you want the mod to overshoot the AP to get a higher PE...   Well, no, I'm not going to do that.  The mod is going to do what you tell it to do.  If you want it to overshoot 80km, then you need to tell it to go to 85km.

Link to comment
Share on other sites

11 minutes ago, Overengineer1 said:

@KerBlam Some of your issues sound like you just have a very low TWR rocket: flying vertical for a long time, suddenly changing to orbital prograde at 22km, this is because you are going so slow and not able to go faster.  

As I said my TWR is at 1.5 at launch, then it gets progressively lower. My 3rd stage (the final stage in atmo) is around 1.3. I build this way on purpose I don't see any point having values much higher than this as typically I just end up going too fast and getting heating effects, so I'm not sure what is meant by "so slow" unless you feel that re-entry effects on ascent are somehow desirable? It also does not appear to change to orbital prograde as you describe until much higher than the 22km sideslip.

 

Link to comment
Share on other sites

@KerBlam Yes, reentry effects while ascending are definitely desirable, I see them on all my most efficient launches.  If you want to get to orbit having burned <3000m/s, you will absolutely see heating effects, and that's a very routine number for GT. Bump your lower stage TWR up to 1.8 (atmo, not vacuum) or so, sacrificing some of your upper stage TWR down to 1.0 (vacuum) if you have to.  Then compare the actual numbers, either remaining fuel or remaining m/s from KER.

Link to comment
Share on other sites

Did a little comparitive test

My turn > http://imgur.com/a/5b3Mt

Gravity turns turn > http://imgur.com/a/OLHUU
2 hours ago, mcirish3 said:

Relative to what?  Are you saying that if you launch your usual way you will end up with more fuel after finishing circularization for a 80 km orbit than if you use this mod with the best guess?  Just Curious.  Could you quantify please?

Yep that's exactly what I'm saying.

 

Edited by KerBlam
link broke in a funny way
Link to comment
Share on other sites

@KerBlam So, like I said already, your ship is underpowered for the settings you have entered.  I already told you the settings to change.  The sudden shift in angle of attack is actually a shift to zero angle of attack to orbital prograde.  Check it yourself.  The mod is trying to reach 40 seconds Time To AP, because you told it to, and it's trying to get there as soon as possible, because you told it to.  Your ship is not capable of doing that before 1 minute and 30 seconds into launch, which is an extremely slow launch.  Your lifter stage is only 1.4 TWR, and that goes down almost immediately in the next stage, so it's no wonder that the mod is having trouble keeping up with the default settings.

Your ship has a lot of non-stock parts, so I'm not able to load it.  But I think a Hold AP Time Start of 30 seconds, and a Hold AP Time Finish of 60 seconds is a good place to start.

Link to comment
Share on other sites

This thread is quite old. Please consider starting a new thread rather than reviving this one.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...