Jump to content

Min, max distances betwen planets


Recommended Posts

I am trying to make a RemoteTech network.

spreadsheet that I'm using (if anyone will be able to read it)

But I need min and max distances betwen Kerbin and all other planets.

Max(distance)= Ap(kerbin)+Ap(x)

Min(distance)= Pe(kerbin)+Pe(x) (exemple: minD betwen Kerbin and Moho is 9.389.329.628m)

I juts figure it out that for inner planets (moho, eve) it should go like this:

Min(distance)= Pe(kerbin)+Ap(x) (exemple: minD betwen Kerbin and Moho actually is 7.284.074.276m)

Is my math correct?

This is true for cases where Ap and Pe of both planets are in line. (because Kerbin Ap=Pe, no problem) For other planets (like Eloo and Dres) this is not the case.

Is there a tool that calculates Min and Max distance between any two planets? Could someone make it please?

I may be pushing it but could it also take in to account planets orbital inclination?

Thanks :)

Edited by sralica
Link to comment
Share on other sites

I think you're going to a bit too much trouble over this ... just use sum of the apoapses and have done, the actual number can't exceed that but will probably be fairly close.

By the way, the minimum distance too high, it's more like the difference of the two.

Link to comment
Share on other sites

I am trying to make a RemoteTech network.

Best Answer for this is Wuphon's response:

Short answer: Worst-case distance is the sum of Ap values.

For links between Kerbin and the inner planets -- Comm 88-88 for Duna/Eve/Moho, KR-14 for Dres, GX-128 for Jool/Eeloo.

With the addition that the CommTech-1 has a similar range to the GX-128, and 88-88 is probably the best dish for intra-system communication in the Jool system.

I think you're going to a bit too much trouble over this ... just use sum of the apoapses and have done, the actual number can't exceed that but will probably be fairly close.

By the way, the minimum distance too high, it's more like the difference of the two.

Kryxal is right on both counts.

Overall, it's really better to design your RT system to link directly between the target and Kerbin ("Kerbin" meaning a satellite relay in the Kerbin system). Bouncing between the planets gets messy and really doesn't save your any effort.

Link to comment
Share on other sites

    Minimum
(km)
Maximum
(km)
Moho Eve 3,546,900 16,117,600
Moho Kerbin 7,289,400 19,913,500
Moho Duna 14,641,100 26,768,900
Moho Dres 30,052,400 51,629,500
Moho Jool 60,949,000 76,594,200
Moho Eeloo 60,715,300 119,514,300
Eve Kerbin 3,668,900 23,530,800
Eve Duna 9,792,200 31,665,400
Eve Dres 25,237,900 56,462,800
Eve Jool 55,583,200 81,962,500
Eve Eeloo 56,927,000 123,317,100
Kerbin Duna 6,069,300 35,383,000
Kerbin Dres 21,402,600 60,320,600
Kerbin Jool 51,735,000 85,811,900
Kerbin Eeloo 53,183,400 127,081,700
Duna Dres 13,732,500 68,079,200
Duna Jool 44,584,600 92,947,000
Duna Eeloo 45,095,900 135,224,000
Dres Jool 24,543,300 113,355,000
Dres Eeloo 28,733,500 151,339,300
Jool Eeloo 11,617,100 169,943,700

It sounds like what you want is the minimum/maximum distance between the orbits of the planets, which would be the theoretical minimum/maximum distance between the planets. I'm sure that can be determined mathematically, but that's not what I did. I projected the motions of all the planets over a 1000-year period and searched for the minimum and maximum true separations. These results are tabulated above.

 

Edited by OhioBob
Revised numbers to fix error in formula
Link to comment
Share on other sites

... I projected the motions of all the planets over a 1000-year period and searched for the minimum and maximum true separations. These results are tabulated above.

OOoo great! that is what I need. I think 1000 years will be enough.

Did you simulate this in-game, or in another program?

Link to comment
Share on other sites

It sounds like what you want is the minimum/maximum distance between the orbits of the planets, which would be the theoretical minimum/maximum distance between the planets. I'm sure that can be determined mathematically, but that's not what I did. I projected the motions of all the planets over a 1000-year period and searched for the minimum and maximum true separations. These results are tabulated above.

+1 internets and/or cookies or whatever for you sir. That's definitely going the extra mile. :)

(My own solution back in the day was just a very simplistic and pessimistic comparison of PEs and APs, but it resulted in some impossible combinations)

Link to comment
Share on other sites

OOoo great! that is what I need. I think 1000 years will be enough.

I'm glad I could help. I stopped searching when I reached the end of year 1000. There may be closer/farther distances in later years, but I figured it would take a seriously addicted individual to play the game that far into the future. (In fact, I know Jool and Eeloo have closer encounters in the second millennia but I had to stop somewhere.)

Did you simulate this in-game, or in another program?

I put all the orbital parameters into an Excel spreadsheet and computed the planet positions vs. time, from which I calculated the separation distances. I then just searched for the minimums and maximums.

Link to comment
Share on other sites

And looking just at the Kerbin -> X numbers:

[TABLE=class: cms_table_grid, width: 500, align: center]

[TR]

[TD]Kerbin[/TD]

[TD]Duna[/TD]

[TD=align: center]6,069,400[/TD]

[TD=align: center]35,383,000[/TD]

[/TR]

[TR]

[TD]Kerbin[/TD]

[TD]Dres[/TD]

[TD=align: center]21,400,100[/TD]

[TD=align: center]60,322,000[/TD]

[/TR]

[TR]

[TD]Kerbin[/TD]

[TD]Jool[/TD]

[TD=align: center]51,737,900[/TD]

[TD=align: center]85,810,200[/TD]

[/TR]

[TR]

[TD]Kerbin[/TD]

[TD]Eeloo[/TD]

[TD=align: center]53,145,700[/TD]

[TD=align: center]127,108,600[/TD]

[/TR]

[/TABLE]

Kerbin Ap/Pe = 13.600 Mm / 13.600 Mm

Jool Ap/Pe = 72.212 Mm / 65.335 Mm

72.212 + 13.600 = 85.812 Mm (max distance)

65.335 - 13.600 = 51.735 Mm (min distance)

Eeloo = 66.688 Mm Pe / 113.550 Mm Ap

113.550 + 13.600 = 127.15 Mm (max distance)

66.688 - 13.600 = 53.088 (Min distance)

So the simple method of looking at just the Ap/Pe numbers is accurate to under 1% with any differences likely due to rounding.

Link to comment
Share on other sites

So the simple method of looking at just the Ap/Pe numbers is accurate to under 1% with any differences likely due to rounding.

That works for Kerbin because Kerbin's orbit is circular. It's not so simple when both orbits have a significant eccentricity.

Link to comment
Share on other sites

Well, for worst-case it holds true:

[TABLE=class: cms_table_grid, width: 500, align: center]

[TR]

[TD]Jool[/TD]

[TD]Eeloo

[/TD]

[TD=align: center]13,455,800[/TD]

[TD=align: center]183,859,900[/TD]

[/TR]

[/TABLE]

Jool Ap/Pe = 72.212 Mm / 65.335 Mm

Eeloo = 66.688 Mm Pe / 113.550 Mm Ap

Jool Ap + Eeloo Ap = 185.762 Mm (within about 1%)

The 13.455 Mm number is more difficult to match because it takes more then 1000 years for Jool and Eeloo to get within touching distance. (Technically, they could collide at some undetermined point in the future because Jool's Ap > Eeloo's Pe value.)

For Moho to Jool/Eeloo:

[TABLE=class: cms_table_grid, width: 500, align: center]

[TR]

[TD]Moho[/TD]

[TD]Jool[/TD]

[TD=align: center]61,128,600[/TD]

[TD=align: center]78,522,500[/TD]

[/TR]

[TR]

[TD]Moho[/TD]

[TD]Eeloo[/TD]

[TD=align: center]62,496,600[/TD]

[TD=align: center]119,839,800[/TD]

[/TR]

[/TABLE]

Moho = 6.316 Mm (Ap) / 4.210Mm (Pe)

Jool Ap/Pe = 72.212 Mm / 65.335 Mm

Eeloo = 66.688 Mm Pe / 113.550 Mm Ap

Moho-Jool Maximum = 6.316+72.212 = 78.528 (almost spot on)

Moho-Eeloo Maximum = 6.316+113.550 = 119.866 (pretty close as well)

Moho-Jool Minimum = 65.335 - 6.316 = 59.019 (might take > 1000 years to line up)

Moho-Eeloo Minimum = 66.688 - 6.316 = 60.372 (might take > 1000 years to line up)

So "minimum within a defined time range" may or may not line up with the "larger Pe minus smaller Ap" number. It depends heavily on resonance of the two orbits.

Link to comment
Share on other sites

Technically, they could collide at some undetermined point in the future because Jool's Ap > Eeloo's Pe value.

Technically, they could never collide because Jool and Eeloo are in 3:2 resonance and also their orbits don't intersect.

Edited by strongest_2hu
Link to comment
Share on other sites

  • 6 years later...
On 2/24/2015 at 5:38 PM, OhioBob said:

I'm glad I could help. I stopped searching when I reached the end of year 1000. There may be closer/farther distances in later years, but I figured it would take a seriously addicted individual to play the game that far into the future. (In fact, I know Jool and Eeloo have closer encounters in the second millennia but I had to stop somewhere.)

I put all the orbital parameters into an Excel spreadsheet and computed the planet positions vs. time, from which I calculated the separation distances. I then just searched for the minimums and maximums.

 

On 2/24/2015 at 1:24 AM, OhioBob said:
    Minimum
(km)
Maximum
(km)
Moho Eve 3,546,900 16,117,600
Moho Kerbin 7,289,400 19,913,500
Moho Duna 14,641,100 26,768,900
Moho Dres 30,052,400 51,629,500
Moho Jool 60,949,000 76,594,200
Moho Eeloo 60,715,300 119,514,300
Eve Kerbin 3,668,900 23,530,800
Eve Duna 9,792,200 31,665,400
Eve Dres 25,237,900 56,462,800
Eve Jool 55,583,200 81,962,500
Eve Eeloo 56,927,000 123,317,100
Kerbin Duna 6,069,300 35,383,000
Kerbin Dres 21,402,600 60,320,600
Kerbin Jool 51,735,000 85,811,900
Kerbin Eeloo 53,183,400 127,081,700
Duna Dres 13,732,500 68,079,200
Duna Jool 44,584,600 92,947,000
Duna Eeloo 45,095,900 135,224,000
Dres Jool 24,543,300 113,355,000
Dres Eeloo 28,733,500 151,339,300
Jool Eeloo 11,617,100 169,943,700

It sounds like what you want is the minimum/maximum distance between the orbits of the planets, which would be the theoretical minimum/maximum distance between the planets. I'm sure that can be determined mathematically, but that's not what I did. I projected the motions of all the planets over a 1000-year period and searched for the minimum and maximum true separations. These results are tabulated above.

 

Hi OhioBob !
 

I'm looking to create a web app for satellite constellation calculation for KSP and KSP2. I saw that you simulated on Excel the planets orbits.

Would it be possible to have this Excel file please ?

Edited by Negana
Link to comment
Share on other sites

4 hours ago, Negana said:

Would it be possible to have this Excel file please ?

I'll have to look and see if I still have it.  I don't remember how user friendly it is, because it was never made to share.  If I find it, I'll send you a private message.

Link to comment
Share on other sites

  • 1 year later...

@OhioBob, I got bored this afternoon and went down this rabbit hole after seeing this question on reddit: 

I remembered your spreadsheet which I used to get the min/max distances over the first 1000 years for my CommNet spreadsheet but couldn't remember how granular the calculation was with respect to the time steps during calculation...

...

...

... ended up just writing a python script to calculate the distances where you can change the time step by editing it in the script. Ran it for 1000 years at a time step of 1 hour between Kerbin and Duna. It took just under 20 seconds to calculate and I got the results of:

Enter name of the first body: Kerbin
Enter name of the second body: Duna
Enter the number of Kerbin years to run for: 1000
Minimum Distance: 6069286587.329437 meters
Maximum Distance: 35383027778.77004 meters
Calculation Time: 18s

Made a repo for the script here: https://github.com/Poodmund/KSP-Celestial-Body-Distances-Calculator

From your spreadsheet we got:

  • Min: 6,069,326,656 meters
  • Max: 35,382,969,611 meters

So they are very close, with the difference probably being due to the duration of the calculation step. If we wanted to do it on a per second iteration, it'd take about 10 days for me to calculate Kerbin - Duna over 1000 years. :D 

Edited by Poodmund
Link to comment
Share on other sites

Ah, nice. I will like edit the script to take in all the bodies and then crunch the numbers and spit the distances out in a nice format... and then see how small I can make the time step without turning my PC into an inferno. :D 

EDIT: Well it seems it works well:

>calcAll.py
Enter name of the first body: Kerbin
Enter the number of Kerbin years to run for: 1000
Minimum Distance between Kerbin and Moho: 7289394665.366949 meters
Maximum Distance between Kerbin and Moho: 19913537675.695507 meters
Minimum Distance between Kerbin and Eve: 3668829002.2021995 meters
Maximum Distance between Kerbin and Eve: 23530850549.623432 meters
Minimum Distance between Kerbin and Duna: 6069286587.329437 meters
Maximum Distance between Kerbin and Duna: 35383027778.77004 meters
Minimum Distance between Kerbin and Dres: 21402499252.618446 meters
Maximum Distance between Kerbin and Dres: 60320788648.104256 meters
Minimum Distance between Kerbin and Jool: 51735044326.640366 meters
Maximum Distance between Kerbin and Jool: 85812057514.17293 meters
Minimum Distance between Kerbin and Eeloo: 53183312062.062584 meters
Maximum Distance between Kerbin and Eeloo: 127081686577.7892 meters
Minimum Distance between Kerbin and Sarnus: 105481066687.77617 meters
Maximum Distance between Kerbin and Sarnus: 146115998963.23166 meters
Minimum Distance between Kerbin and Urlum: 229218369395.3892 meters
Maximum Distance between Kerbin and Urlum: 279415565156.50653 meters
Minimum Distance between Kerbin and Neidon: 390533362776.5709 meters
Maximum Distance between Kerbin and Neidon: 428177031309.7583 meters
Minimum Distance between Kerbin and Plock: 382964985022.1354 meters
Maximum Distance between Kerbin and Plock: 688705050769.595 meters
Total Calculation Time: 3m 3s

EDIT EDIT: I've projected it for 1000 years for all bodies and noticed that some min/max distances occur around the 1000 year limit... especially the minimum encounter between Jool and Eeloo... which occurs at Y999:D30 only 11,617,098km apart.
 

Edited by Poodmund
Link to comment
Share on other sites

Body 1 Body 2 Minimum (km) Time Min (Kerbal) Maximum (km) Time Max (Kerbal)
Moho Eve 3,546,908 Y5553:D356:3h:0m:40s 16,117,621 Y6108:D68:3h:3m:33s
Moho Kerbin 7,289,385 Y8871:D45:2h:0m:40s 19,913,539 Y6528:D48:2h:59m:47s
Moho Duna 14,641,065 Y7765:D233:4h:1m:57s 26,768,895 Y5796:D117:2h:2m:2s
Moho Dres 30,052,322 Y7554:D306:2h:56m:14s 51,629,702 Y7906:D21:2h:0m:34s
Moho Jool 60,949,012 Y9406:D10:1h:2m:50s 76,594,332 Y528:D176:4h:56m:58s
Moho Eeloo 60,715,266 Y7873:D316:4h:1m:28s 119,514,349 Y9434:D365:0h:7m:39s
Moho Sarnus 113,689,188 Y1873:D58:0h:59m:14s 137,899,413 Y8359:D46:4h:57m:25s
Moho Urlum 238,529,726 Y412:D357:4h:3m:40s 270,103,862 Y9916:D226:2h:56m:8s
Moho Neidon 397,824,635 Y7373:D239:4h:3m:5s 420,885,782 Y2500:D406:4h:56m:10s
Moho Plock 390,654,083 Y2225:D425:1h:50m:11s 681,013,388 Y9523:D98:3h:0m:8s
Eve Kerbin 3,668,829 Y643:D75:4h:1m:41s 23,530,852 Y2430:D23:4h:3m:46s
Eve Duna 9,792,174 Y6246:D255:3h:49m:44s 31,665,478 Y8507:D237:5h:1m:37s
Eve Dres 25,237,843 Y7185:D136:0h:58m:58s 56,462,866 Y3612:D76:0h:1m:57s
Eve Jool 55,583,201 Y841:D232:0h:42m:9s 81,964,576 Y2234:D379:3h:46m:37s
Eve Eeloo 56,926,652 Y7191:D155:2h:8m:48s 123,317,186 Y921:D130:1h:51m:13s
Eve Sarnus 109,151,911 Y5080:D95:1h:52m:43s 142,445,164 Y704:D276:1h:7m:30s
Eve Urlum 233,057,384 Y6479:D216:4h:1m:10s 275,576,891 Y5953:D330:2h:6m:51s
Eve Neidon 394,262,257 Y6877:D28:1h:51m:22s 424,448,344 Y3160:D279:2h:50m:47s
Eve Plock 386,792,768 Y8905:D30:1h:18m:47s 684,877,156 Y9770:D357:4h:9m:50s
Kerbin Duna 6,069,283 Y4808:D380:0h:56m:24s 35,383,028 Y3095:D225:5h:59m:26s
Kerbin Dres 21,402,402 Y1558:D365:1h:19m:1s 60,320,789 Y728:D290:3h:8m:53s
Kerbin Jool 51,735,042 Y7427:D91:1h:3m:13s 85,812,078 Y2212:D47:4h:13m:57s
Kerbin Eeloo 53,183,306 Y844:D229:4h:22m:10s 127,081,754 Y9554:D161:5h:5m:20s
Kerbin Sarnus 105,481,041 Y1028:D97:2h:13m:47s 146,116,001 Y8020:D300:5h:0m:21s
Kerbin Urlum 229,218,312 Y6722:D38:2h:10m:41s 279,415,713 Y8218:D173:0h:0m:7s
Kerbin Neidon 390,533,330 Y9355:D83:3h:53m:48s 428,177,052 Y3987:D26:3h:4m:41s
Kerbin Plock 382,964,603 Y3463:D39:2h:44m:18s 688,705,350 Y7049:D362:1h:42m:20s
Duna Dres 13,732,281 Y3208:D290:5h:24m:11s 68,080,257 Y8645:D69:4h:57m:23s
Duna Jool 44,584,550 Y2205:D371:0h:4m:2s 92,947,049 Y7841:D347:0h:41m:9s
Duna Eeloo 45,090,424 Y6781:D388:0h:35m:54s 135,225,589 Y7165:D338:3h:5m:41s
Duna Sarnus 99,018,997 Y8288:D250:1h:56m:38s 152,572,434 Y6783:D67:1h:58m:55s
Duna Urlum 222,352,244 Y8015:D19:3h:24m:52s 286,277,601 Y1342:D107:0h:48m:56s
Duna Neidon 382,771,145 Y1100:D248:3h:2m:30s 435,937,665 Y8450:D349:2h:58m:50s
Duna Plock 374,816,799 Y2721:D10:5h:22m:54s 696,857,247 Y1360:D211:5h:21m:27s
Dres Jool 24,526,513 Y2232:D114:5h:43m:56s 113,360,807 Y5605:D65:0h:19m:35s
Dres Eeloo 28,689,105 Y2020:D420:5h:25m:50s 151,339,309 Y5305:D185:5h:15m:26s
Dres Sarnus 72,640,229 Y156:D34:0h:4m:43s 179,121,564 Y536:D22:1h:45m:6s
Dres Urlum 204,800,506 Y1471:D189:0h:41m:34s 303,705,198 Y1997:D39:4h:24m:49s
Dres Neidon 359,526,182 Y5538:D197:4h:7m:40s 459,178,956 Y3638:D295:4h:39m:2s
Dres Plock 358,888,476 Y5935:D149:1h:12m:44s 712,736,293 Y3338:D60:1h:8m:23s
Jool Eeloo 11,420,136 Y9973:D153:0h:24m:24s 169,943,756 Y19:D260:2h:19m:15s
Jool Sarnus 47,661,437 Y6544:D293:0h:30m:21s 203,907,221 Y1972:D83:0h:0m:59s
Jool Urlum 177,434,493 Y9634:D54:2h:32m:35s 331,199,563 Y9998:D45:3h:12m:3s
Jool Neidon 332,155,657 Y1587:D25:4h:37m:19s 486,552,250 Y3486:D243:4h:36m:41s
Jool Plock 327,504,530 Y246:D376:3h:13m:15s 744,265,120 Y8038:D103:4h:23m:55s
Eeloo Sarnus 16,988,828 Y547:D272:0h:47m:43s 243,123,110 Y6722:D324:0h:23m:39s
Eeloo Urlum 135,614,911 Y1961:D2:3h:52m:19s 373,212,340 Y9928:D273:5h:41m:37s
Eeloo Neidon 299,993,717 Y4675:D131:3h:17m:10s 519,198,233 Y3105:D287:3h:46m:23s
Eeloo Plock 331,236,639 Y247:D163:1h:53m:4s 740,539,150 Y9767:D230:3h:41m:42s
Sarnus Urlum 112,410,337 Y3:D415:0h:22m:37s 396,177,919 Y8051:D352:4h:15m:28s
Sarnus Neidon 276,249,934 Y7567:D31:5h:38m:35s 542,407,147 Y6328:D421:5h:41m:2s
Sarnus Plock 267,100,128 Y9648:D224:4h:28m:3s 804,676,295 Y4330:D99:3h:51m:23s
Urlum Neidon 138,500,523 Y5550:D274:0h:0m:16s 680,197,580 Y1667:D336:1h:6m:41s
Urlum Plock 140,799,541 Y3461:D218:5h:29m:17s 932,918,586 Y1358:D314:3h:6m:14s
Neidon Plock 227,326,991 Y9812:D74:0h:21m:34s 1,079,565,277 Y129:D372:5h:26m:45s

Manage to get this down to a 1 second resolution projected over the first 10,000 years. I think the game gets all wonky when you start getting to these dates as precision starts getting reduced so I don't think we need to go any further in time. Also, I expanded the calcs to incorporate all of the OPM bodies too.

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