[1.4][1.7.7] GravityTurn continued - Automated Efficient Launches

Recommended Posts

I just wanted to share some off-label use I've been getting out of GT. I've been using it to implement constant vertical velocity takeoffs. (Only recommended for vacuum launches, also I've been using 10x rescale and SMURFF so I have DV costs that are about sqrt(10) times larger, but I have much better mass fractions.)

The idea is to use just enough vertical thrust to keep from crashing into the terrain. In terms of GT settings, I set the starting velocity to 10m/s (or something small, but enough  to give the vehicle time to get truly vertical) time to AP I set to 20s for both start and end. I set sensitivity to 1. I set the desired target orbit. For the starting angle, I use the maximum angle that keeps a vertical TWR of 1. (so Cos(A) TWR = 1 or A = arcsec(TWR) )

When I execute this the rocket goes up, turns to the angle I indicate, vertical velocity stays at about 10m/s (a little more due to the time to turn), and starts to build up horizontal speed. I think GT keeps the vehicle at the starting pitch until prograde drifts down to that pitch.Then it looks to see if the time to Ap (TTA) is under or over the desired amount. If it is over, GT follows prograde, if it is under, it pitches up to push the TTA up. This results in the craft pitching up and down (because of the PID controller I guess) around an ideal pitch angle of arccsc( Thrust/ (mass * (g - centrifugal force))) which decreases as horizontal velocity goes up and mass goes down. Eventually this angle decreases to below prograde and the rocket follows prograde to orbit. Prograde at this point is usually at most a degree or two above horizontal.

The only way this fails is if there is higher terrain downrange. Then I just increase the time to AP setting enough to clear the terrain. Once past the terrain, I set it back down to 20s or so.

This method is very reliable for me. It usually works on the first short and gets better DV to an actual gravity turn performed by GT. I've done some simulations in mathematica, (single stage) and get that a perfectly executed version of this (TTA fixed to 10s) slightly outperforms gravity turns for initial TWR of 1.5 to 3 on the Mun. (for example with an ISP of 345 and an initial TWR for 2 on the MUN simulation indicates 645 m/s to a 14km orbit, including circularization for a constant vertical velocity, vs 657 for best possible gravity turn)

Just thought I would share.

Share on other sites
18 minutes ago, Nicias said:

I just wanted to share some off-label use I've been getting out of GT.

Thanks for the detailed explanation, and congrats on the achievement! Hopefully, there's something there that @AndyMt can make use of as well.

If the 'like' system was working, I'd give you one.

Share on other sites

I need a little help, my Gravity turn plugin has picked up some bad habits.  I'm not sure what I did, but the last few launches have been extremely steep, to the point where the final stage doesn't have enough Delta-V to circularize.  If I understand the tooltips right, the AP hold settings should control steepness, but they don't seem to make a difference in this.

How can I correct this?  If i reinstall GT, will it reset the plugin to the default profile?

Share on other sites
42 minutes ago, Capt. Hunt said:

I need a little help, my Gravity turn plugin has picked up some bad habits.  I'm not sure what I did, but the last few launches have been extremely steep, to the point where the final stage doesn't have enough Delta-V to circularize.  If I understand the tooltips right, the AP hold settings should control steepness, but they don't seem to make a difference in this.

How can I correct this?  If i reinstall GT, will it reset the plugin to the default profile?

Is this happening to just one craft, or any craft?

If for all craft, then deleting the GT folder and reinstalling may be the solution.

If just this one craft, then you have a couple of options, the first one being as described by @AndyMt in an earlier post:

Quote

keep the alt-key pressed while pressing "previous best guess". This resets every parameter which is not locked to defaults. This also causes the stats window to show more stuff (for debugging), so don't be surprised.

Alternatively, you could just delete the setting for that one craft, and start the 'training' process over again. You can find the individual craft settings in:  GameData\GravityTurn\Plugins\PluginData\GravityTurn\ and just delete the gt_launchdb_SHIPNAME_Kerbin.cfg file with the name of the ship in question. You could also back up your other craft settings files before deleting the installation, if you go that route. That would save you having to 're-train' any other craft you've already dialed-in with GT.

Edited by JAFO

Share on other sites
20 hours ago, JAFO said:

Is this happening to just one craft, or any craft?

If for all craft, then deleting the GT folder and reinstalling may be the solution.

If just this one craft, then you have a couple of options, the first one being as described by @AndyMt in an earlier post:

Alternatively, you could just delete the setting for that one craft, and start the 'training' process over again. You can find the individual craft settings in:  GameData\GravityTurn\Plugins\PluginData\GravityTurn\ and just delete the gt_launchdb_SHIPNAME_Kerbin.cfg file with the name of the ship in question. You could also back up your other craft settings files before deleting the installation, if you go that route. That would save you having to 're-train' any other craft you've already dialed-in with GT.

thanks!

It does seem to happen for most if not all crafts, so I will try reinstalling GT.

Share on other sites

It's possible it's somewhere in the 30+ pages of this thread, but how do you take back control from Gravity Turn once it's reached orbit? There's no abort button but it still has control.

It automatically plans the circularizing burn and executes it and I have a hard time stopping it, even if it overshot the AP due to solid boosters and I don't necessarily want to circularize at that altitude.

Also, what's a good pressure for the fairing release? People say around 45km but I don't know how that relates. Mine aren't releasing, I'm doing them manually instead.

Share on other sites
8 minutes ago, Kchinger said:

It's possible it's somewhere in the 30+ pages of this thread, but how do you take back control from Gravity Turn once it's reached orbit? There's no abort button but it still has control.

It automatically plans the circularizing burn and executes it and I have a hard time stopping it, even if it overshot the AP due to solid boosters and I don't necessarily want to circularize at that altitude.

Also, what's a good pressure for the fairing release? People say around 45km but I don't know how that relates. Mine aren't releasing, I'm doing them manually instead.

That's not Gravity Turn- that'll be MechJeb. Gravity Turn is programmed to turn over control to MechJeb once it's done. Not sure how the fairing trigger works- I've never touched that, and it works for me.

Share on other sites

That's not Gravity Turn- that'll be MechJeb. Gravity Turn is programmed to turn over control to MechJeb once it's done. Not sure how the fairing trigger works- I've never touched that, and it works for me.

That makes sense, I didn't realize it handed off. So I need to go into mechjeb to take back control then. I should be able to figure that out. Thanks.

Share on other sites
Just now, Kchinger said:

That makes sense, I didn't realize it handed off. So I need to go into mechjeb to take back control then. I should be able to figure that out. Thanks.

No problem.

Share on other sites

Sorry for what is probably another dumb question but I'm not finding it (partly because the name of this mod is very hard to search for, you just get people talking about gravity turns in general).

My ships routinely overshoot the desired AP. Do I just need to always launch a new craft 2 or 3 times all the way to "success", just revert to launch after that point and let it iterate closer to ideal? Or should I change something in the inputs to help it out? I think it's because of all the boosters it can't throttle down enough, but it also seems to keep the main engine throttle high for way too long (I get aerodynamic and heating effects pretty early, which I hear is not ideal). If I'm aiming for 80km, it would be more efficient if it was more aggressive with the turn early instead of going high, right? But I guess that's going to make my speed even higher and less efficient. Maybe it's my design that sucks...

Share on other sites
9 hours ago, Kchinger said:

Sorry for what is probably another dumb question but I'm not finding it (partly because the name of this mod is very hard to search for, you just get people talking about gravity turns in general).

My ships routinely overshoot the desired AP. Do I just need to always launch a new craft 2 or 3 times all the way to "success", just revert to launch after that point and let it iterate closer to ideal? Or should I change something in the inputs to help it out? I think it's because of all the boosters it can't throttle down enough, but it also seems to keep the main engine throttle high for way too long (I get aerodynamic and heating effects pretty early, which I hear is not ideal). If I'm aiming for 80km, it would be more efficient if it was more aggressive with the turn early instead of going high, right? But I guess that's going to make my speed even higher and less efficient. Maybe it's my design that sucks...

Try reducing the value on the sensitivity- the smaller that number, the lower the mod can take the throttle without just turning the engine off.

Share on other sites
On 10/14/2019 at 7:18 PM, Paaaad said:

Try reducing the value on the sensitivity- the smaller that number, the lower the mod can take the throttle without just turning the engine off.

So that did what you said, but the issue was actually with the rocket. I tried to fly it manually and after a certain speed (or altitude maybe?) it would want to stand up, not sure why. I put some control fins on and it's much better now, although I ended up flying manually because now even the first guess goes way too low and either burns up or starts going negative climb.

Share on other sites

One other thing I did notice is that auto staging doesn't seem to trigger if the stage still has fuel in the disabled state.

I often set my craft up with a probe core and chutes, etc, on expensive stages so that I can recover them (with FMRS).  I've started leaving a little fuel by disabling the flow in the hope of giving a little more control.

Would this prevent auto-staging, and is there a workaround anyone can think of?

Thanks,

Share on other sites

Gravity Turn just worked for me in v1.8.0; I launched the KerbalX rocket into orbit in sandbox mode.
Note: I'm also using MechJeb-Dev.

Share on other sites

Is there a best practice for adjusting SRB throttle in the VAB and letting GTc calculate new parameters when designing a mostly solid-fuelled rocket (think Vega-like) that only has a small liquid-fuelled upper stage for circularisation and manoeuvering?

Share on other sites
7 hours ago, Angstinator said:

Is there a best practice for adjusting SRB throttle in the VAB and letting GTc calculate new parameters when designing a mostly solid-fuelled rocket (think Vega-like) that only has a small liquid-fuelled upper stage for circularisation and manoeuvering?

The best way is probably just messing around with the amount of fuel. I’m trying to do the same thing and since it can’t throttle down, you’ll just have to limit the fuel in the booster.

Share on other sites
27 minutes ago, Elro2k said:

The best way is probably just messing around with the amount of fuel. I’m trying to do the same thing and since it can’t throttle down, you’ll just have to limit the fuel in the booster.

I've also found (and should have a lot sooner) that it's most efficient to maintain constant TWR between stages, i.e. set the hard throttle so that when a stage ends, the next stage will ignite at the same or slightly greater TWR.

Share on other sites
18 hours ago, Angstinator said:

Is there a best practice for adjusting SRB throttle in the VAB and letting GTc calculate new parameters when designing a mostly solid-fuelled rocket (think Vega-like) that only has a small liquid-fuelled upper stage for circularisation and manoeuvering?

Yes, there's one procedure I've implemented that helps considerably, which might be regarded as 'best practice'. Firstly, you need to understand a little about how GTc works. GTc is incapable of knowing if you've made significant changes to a design, and doesn't actually "calculate new parameters" after you make a change. All it does is start from an initial 'best guess' (which is often surprisingly accurate) and then use a series of iterative launches to try and narrow down the best settings. The initial parameters are never changed after the first launch.

Therefore, if you've made changes based on those launch tests, GTc will continue to use the old parameters on subsequent launches, which may no longer be optimal. While it's not always easy to determine what constitutes a "significant" design change, my rule of thumb is that adding or removing large parts, changes to fuel load or thrust settings, etc, (which your SRB throttle changes count as) are likely to significantly alter launch parameters, and therefore require a GTc 'launch parameter reset'.

So, my normal procedure used to be as follows. Any time I made a significant design change, I made a change to the name of the craft. (GTc uses craft names to identify and save settings for each craft.) For example, Test_craft became Test_craftA, Test_craftB, etc. What this does is force GTc to ignore the results of previous launches, and treat it as a completely new craft, starting over with a new initial 'best guess', and needing to undergo a new set of test launches. (Or, instead, you could go to GameData\GravityTurn\Plugins\PluginData\GravityTurn\ and delete the gt_launchdb_SHIPNAME_Kerbin.cfg file with the name of the ship in question, but this is a pretty long-winded and awkward way to go about things.)

Alternatively, (and this is the best and simplest way to do so, and is now my preferred method) the same thing can be accomplished by simply telling GTc to drop its old parameters and start over. This is done by keeping the alt-key pressed while clicking "previous best guess". This resets every parameter which is not locked back to defaults. After this, you will need to click on 'First Guess' again. I learned about this method from @AndyMt after I made a feature request for a 'reset launch data' button.

Edited by JAFO
grammar

Share on other sites
7 hours ago, JAFO said:

Yes, there's one procedure I've implemented that helps considerably, which might be regarded as 'best practice'. Firstly, you need to understand a little about how GTc works. GTc is incapable of knowing if you've made significant changes to a design, and doesn't actually "calculate new parameters" after you make a change. All it does is start from an initial 'best guess' (which is often surprisingly accurate) and then use a series of iterative launches to try and narrow down the best settings. The initial parameters are never changed after the first launch.

Therefore, if you've made changes based on those launch tests, GTc will continue to use the old parameters on subsequent launches, which may no longer be optimal. While it's not always easy to determine what constitutes a "significant" design change, my rule of thumb is that adding or removing large parts, changes to fuel load or thrust settings, etc, (which your SRB throttle changes count as) are likely to significantly alter launch parameters, and therefore require a GTc 'launch parameter reset'.

So, my normal procedure used to be as follows. Any time I made a significant design change, I made a change to the name of the craft. (GTc uses craft names to identify and save settings for each craft.) For example, Test_craft became Test_craftA, Test_craftB, etc. What this does is force GTc to ignore the results of previous launches, and treat it as a completely new craft, starting over with a new initial 'best guess', and needing to undergo a new set of test launches. (Or, instead, you could go to GameData\GravityTurn\Plugins\PluginData\GravityTurn\ and delete the gt_launchdb_SHIPNAME_Kerbin.cfg file with the name of the ship in question, but this is a pretty long-winded and awkward way to go about things.)

Alternatively, (and this is the best and simplest way to do so, and is now my preferred method) the same thing can be accomplished by simply telling GTc to drop its old parameters and start over. This is done by keeping the alt-key pressed while clicking "previous best guess". This resets every parameter which is not locked back to defaults. After this, you will need to click on 'First Guess' again. I learned about this method from @AndyMt after I made a feature request for a 'reset launch data' button.

I'm not a smart man. I read about the alt button and used it some for specific things, but I didn't extend that knowledge to stop having 18 versions of a craft cluttering up my file with 1a, 1b, 2a...

Share on other sites

GT seems to work fine in 1.8... any chance of updating the CKAN file to reflect this.

Share on other sites
1 hour ago, Atlas Gaming said:

GT seems to work fine in 1.8... any chance of updating the CKAN file to reflect this.

"working" may only be one sense of certification --  but I'll take it!

Share on other sites

It seems that the save settings button does not save the window position of the launch map. I'd like to request that it should.

Share on other sites

How many launches does it usually take for a small to medium sized early career rocket to reliably make orbit?

5 doesn't seem to be enough.

Share on other sites
1 hour ago, TonedMite133805 said:

How many launches does it usually take for a small to medium sized early career rocket to reliably make orbit?

5 doesn't seem to be enough.

Something's wrong in your design if it's not making orbit after 5 tries.

Share on other sites
On 11/2/2019 at 6:49 AM, TonedMite133805 said:

How many launches does it usually take for a small to medium sized early career rocket to reliably make orbit?

5 doesn't seem to be enough.

I generally expect a design to make orbit on the first attempt.  If it doesn't then normally that means something is wrong with the design.  But I always set the turn parameters myself, and don't let gravity turn attempt to optimise.

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.

×   Pasted as rich text.   Paste as plain text instead

Only 75 emoji are allowed.

×   Your previous content has been restored.   Clear editor

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