Space Math

The following forms use javascript to perform their calculations. Changing one variable or unit will force a recalculation. The process converts all units into MKS and the back to the desired results. This always creates rounding errors, so be aware that the results are good only to a few decimal places.

Javascript is limited to the size of the numbers it can handle and you will see that some of these calculators break down when using large accelerations for long periods of time. The universe is larger than java script can handle. Meters and seconds are pitifully small units for doing calculations involving millions of light years.

I first wrote some of these calculators about 15 years ago, and the code style reflects this. The code is fragile and every time I fix a bug I create another. If you find a bug, please let me know.

Newtonian Constant Acceleration in g's.
Use this to calculate how far a spaceship will go in a certain time at a certain acceleration. A ship going at a rate of 1g for 100 seconds will travel 49000 meters. If you put in distance traveled it will tell you the time needed to travel that distance at the specified g force. G force here is the force of gravity at the earth's surface. This does not take into account relativistic effects, so use this for interplanetary travel.
Acceleration Time Distance v=0

Acceleration in g's on a cylinder such as a space station or space colony.
Use this to find out how fast a space station must spin (period of rotation time in seconds) to maintain a certain force of gravity. You can vary the radius to get a new acceleration or vary the period to get a new radius. Changing the g force will recalculate the period. G force here is the force of gravity at the earth's surface.

Period Radius Acceleration

Period and radius of a circular orbit around a planet.
This gives you the distance from the center of planet and the time it takes for one circular orbit. The units are in terms of planet mass. I've given Earth, Jupiter and the sun for examples. (remember the earth is 6,378 km in radius so subtract that out to get distance from the surface.) Click these links to pre load set diameters Earth, Venus, Mars, Jupiter, The Moon

Period Radius Planet Mass

Escape velocity at a planet's surface
This is the speed that will allow an object to leave the gravitational field of a planet. Anything slower will be slowed down enough by gravity to fall backwards to the planet. Radius is is the radius of the planet. Click these links to pre load set diameters Earth, Venus, Mars, Jupiter, The Moon

Velocity Radius Planet Mass

Relativistic effects

Length Contraction.

The length of things shrinks in the direction of the motion. This is measurable at relativistic speeds. Enter the Rest length and a Velocity and get the contracted length. Enter the Contracted length and get the Velocity. How long will a yard stick be at 1/2 the speed of light? The answer is about 2.6 feet. This calculation is based on an Earth Observer.
Velocity Earth length Moving Length

Time Dilation.
At relativistic speeds time slows down. Enter the Rest interval and a Velocity and get the dilated time. For example how long will ten seconds appear to be when traveling at 1/2 C? Answer=11.57 seconds. This is a Little confusing. Time slows down for a fast moving space traveller which means that it looks like more seconds pass on Earth than for the traveller. This calculation is based on an observer from earth.

Velocity Moving Time Earth Time

Long Relativistic Journeys
Going to a star requires that you speed up and then slow down. It is a double calculation. Half of the trip you accelerate, but if you need to slow down for the second half so that you reach the star, not splat against it. A traveler experiences the trip at one time rate and an observer on one of the stars will experience much longer time. At 1 G acceleration, it is possible to travel to a near galaxy within a generation, but when you will come back it will be millions of years later.
Use this calculator to figure the time it takes to get to a star at constant acceleration and then constant deceleration. Counter to what we might expect, a voyager can make it to a star 20 light years away in 6 years. This is not a violation of Relativity, but a side effect.
Note: unlike the other functions I didn't include the calculation where you plug in time and get distance. That acosh got me.
Note 2: If you try for really long distances the trip time shows infinity - this is due to limitations of JavaScript.

Acceleration Distance
Trip Time Earth Time

Size of Black Holes

The Swarzchilde radius is calculated as r=2*G*M/c^2. The actual size of black holes is tiny.


Mass Radius

Conversions

Here are some conversions of units which might be used in space travel

Length Conversions

 

Energy Conversions

 

92 Responses to “Space Math”

  1. adrian says:

    would have been nice to go the other way with some of these like i know the 2 lengths of time but don’t know the velocity

  2. admin says:

    Most of them you can. Change one and another one will change. I’ve tried to make it work that way. I have a half done page of a more of these with some of the formulas fixed to make them easier to use.

    Keith

  3. These are fabulous! Thanks!

  4. Graham says:

    These look good. But what I’m looking for is a calculator that you can input the planets gravity & radius and determine the planets mass.

  5. N Kalanaga says:

    The gravity calculation is easy, as long as you settle for Earth-units. The formula is Mass/(Radius^2)=Gravity, with Mass in Earth masses, Radius in Earth radii, and Gravity in Earth gees. If you need meters/sec multiply the result by 9.8, or as accurate as you want to take it.

  6. Benjamin says:

    I like the calculator for long planetary voyages. The relativity threw me off though. How much time passes if the ship makes a round trip? If a ship goes from Earth to Tau Ceti (about 20 ly) and back, it should take more than 12 years even if it just seems like 12 years to the crew on the ship.

  7. Keith says:

    You double it for round trip. The trip to Tau Ceti takes 12 years. That’s the time that passes for the crew. An observer form Earth will think that it took longer, but the crew doesn’t “seem” to take 12 years, they actually do take 12 years. It takes 12 years, or it takes more than 20 years depending on where you are standing. Time is not constant.

    A calculator to figure how long it takes to get to a planet and back based on a constant acceleration on the ship can be done, but I’d have to think about it. It is probably as simple as turning the relativistic trip calculator inside out.

  8. Benjamin says:

    Keith, I meant how old is the other twin in the twin paradox? How much time passes for the observer on Earth when his brother on the ship returns.

  9. GrimAura says:

    Just wanted to say thanks. Took me 4 hrs to find these. Although being a math idiot I think I learned some stuff trying to find it.

    G®îMÅü®Å <<<<<<Hates formulas :)

  10. Jon B says:

    Thanks for posting! I wish some idiots would answer the Yahoo questions correctly regarding relativistic travel. The major misconceptions about it should be corrected! Glad to see somebody is publishing correct information though.

  11. Jon B says:

    Awesome! If you travel at the highest known non-light speed acceleration (which would land you anywhere infinitely instantaneously from the travelers perspective at least), you would accelerate at 10^12 g’s, the acceleration experienced in free fall into a neutron star. If you accelerated at a constant rate for ~2 minutes 49, then decelerated with the same force for the same amount of time, you would reach the end of the known universe, 13 billion light years from home. Of course, by then, the Earth and our solar system would have long since passed into dust (just a few seconds after launch, from the travelers perspective), but you would have lived to see the physical boundary of space!

  12. Chuck says:

    In your formula for Long Relativistic Journeys, what percentage of speed of light (c) did you max out at? Also, theoretically, how would Length Contraction affect a living organism?

  13. Keith says:

    You can’t max out. At the end you accelerate all that you want and only make it a little closer to C. C is the boundary and you can very close, but no patter how you push you can only get little closer. In a long trip you might get to 99.999… with 1000 nines, but you can’t hit C.

    A person or animal or any object that is under length contraction can’t tell and will think everything is normal. Even yardsticks will shrink so as far as they are concerned, they are not contracted.

    Keith

  14. Chuck says:

    Thanks for the answer. The reason I was wondering was that I found that using the Newtonian Constant Acceleration in G’s put me at 99.99% of c at 354 days of 1g acceleration. The story I am writing involves communication between a person on Earth and another in a ship traveling to another solar system. I’m using speed of light communication and having to determine distance at various points of the journey and calculating time needed to receive transmissions.

    Thanks again – this is a great site!

  15. Will says:

    Great site thank you very much. My question is in regards to your first calculator; does it calculate the trip time based on accelerating at Xgs half way, turning around, and decelerating? Or is it just a straight shot past whatever destination? I am not great at math but is it safe to assume I can cut the distance in half, double the time and arrive at my destination at 0c relative to that position?

  16. Mike Hriczo says:

    For space travel conversion I PUT IN 36,000,000 Miles ( MIN. TO MARS) at i G.
    It gave a time of NaN. What is NaN? Also Is the G force additive to the human
    body at a constant acceleration? Could human body survive or would a constant
    velocity at a high speed with no G force be best way to travel ?

  17. Keith says:

    NaN is Not a Number. Either your used commas in your numbers or there was a divide by zero or a number was too big.

  18. Mike Hriczo says:

    OK , at 1 G constant acceleration it says 1.2 days to reach Mars at its closest point to Earth. Not counting deceleration to reach surface. My question still is if G force is additive at constant acceleration humans would perish at 30 Gs right? Therefore a reasonable cruising speed is need at which point constant velocity would yiled 0 G force until time to deceleration or make turns. Some one guide me on this please. the new show on Discovery Channel ” Bad Universe” seems to have got this wrong.

  19. Benjamin says:

    G force is not additive at constant acceleration. G force is constant at constant acceleration. If a ship is traveling at one G, then the occupants feel earth like gravity the whole way. If the ship is traveling at two G, then the occupants feel twice as heavy the whole way. If you have them travel at 0 g then they will be weightless and the ship will coast in the direction you sent it, but not accelerate at all.

    What you really want to do is go half the distance between Earth and Mars accelerating at N G, then turn the ship around and accelerate at N G, where N is the acceleration you are traveling. (I don’t recommend above 2 G with humans on board. It makes walking around the ship difficult.) You should end up at rest in the orbit of Mars. 1 g will take 1.8 days.

  20. Carl says:

    These calculators are awesome!

    I’d like to point out human jet fighter pilots routinely experience G forces in the 9G range. A G suit is required, and they can only handle it for a few minutes without blacking out. Humans have survived G forces over 50, for a very short time–but with permanent damage to the brain and eyes.

  21. Brian says:

    In the “long relativistic journeys” part, you need to add a line feed; the far right part of the calculator is not visible.

  22. haysoos says:

    Just found this site. Excellent stuff!

    I didn’t see an answer to Will’s question – whether or not the first calculator was for the trip under constant acceleration the whole way, or for the trip with deceleration at half way, so the ship arrives at 0 velocity. I’m assuming it’s constant acceleration (since that’s what it actually says).

    Also, it would be great if Astronomical Units (AUs) was an option under the units of distance.

  23. roobub says:

    could you make a program for it in c please? x x

  24. Keith says:

    I haven’t coded in C for 20 years. JavaScript is easy enough to translate to C, though. You should give it a try.

    Keith

  25. Brian says:

    Keith/admin, please, please put in a carriage return/line feed at the end of the “relativistic journeys” one!!! The “earth time” is not visible; it does not appear to be visible in either Firefox or IE. Although I think it would just be the same as the distance in light years, right?

    –Brian

  26. Keith says:

    It is done.

    Keith

  27. Brian says:

    Thanks! :)

  28. Mark says:

    Are your relativistic calculations made using four-dimensional acceleration w=c^2du/ds or are they made by small increments of velocity under Lorenz transforms?

  29. Keith says:

    see: http://en.wikipedia.org/wiki/Proper_acceleration

    For constant unidirectional proper-acceleration, similar relationships exist between rapidity η and elapsed proper time Δτ, as well as between Lorentz factor γ and distance traveled Δx. To be specific:

    \alpha=\frac{\Delta w}{\Delta t}=c \frac{\Delta \eta}{\Delta \tau}=c^2 \frac{\Delta \gamma}{\Delta x},

    where the various velocity parameters are related by

    \eta = \sinh^{-1}\left(\frac{w}{c}\right) = \tanh^{-1}\left(\frac{v}{c}\right) = \pm \cosh^{-1}\left(\gamma\right) .

    These equations describe some consequences of accelerated travel at high speed. For example, imagine a spaceship that can accelerate its passengers at “1 gee” (or 1.0 lightyears per year squared) halfway to their destination, and then decelerate them at “1 gee” for the remaining half so as to provide earth-like artificial gravity from point A to point B over the shortest possible time.[8][9] For a map-distance of ΔxAB, the first equation above predicts a mid-point Lorentz factor (up from its unit rest value) of γmid=1+αxAB/2)/c2. Hence the round-trip time on traveler clocks will be Δτ = 4(c/α) cosh−1(γmid), during which the time elapsed on map clocks will be Δt = 4(c) sinh[cosh−1(γmid)].

    This imagined spaceship could offer round trips to Proxima Centauri lasting about 7.1 traveler years (~12 years on Earth clocks), round trips to the Milky Way‘s central black hole of about 40 years (~54,000 years elapsed on earth clocks), and round trips to Andromeda Galaxy lasting around 57 years (over 5 million years on Earth clocks).

  30. Mark says:

    Thanks, Keith.

    This is much more accurate than my rough approximations. I’ll be making use of this in a month or two in my Gail Scott comic. I’ll be sure to put in some references on the site.

  31. roobub says:

    i need for a school project a program for a relativistic travel calculator, i have no idea how to do it. if someone knows how to do one could you please post or mail it.?
    thanks X X

  32. ValZ says:

    I have a relativity qustion… Suppose planets Earth and Woozle are basically stationary with respect to one another. Suppose you have two spaceships, A and B. Suppose A leaves Earth for Woogle (to set up a base), and then six months later in earth’s frame of reference, B leaves Earth for Woogle (resupply mission). Both ships have the same acceleration schedule (say, 1g acceleration first half of trip, 1g deceleration second half of trip). Will B arrive at Woogle six months after A does, by the Woogle base’s chronometers? If not, why not?

  33. Keith says:

    You are right. The second ship will arrive 6 months after the first. The time it takes to get to Woozle will be the same for both ships.

    Keith

  34. Chuck says:

    Does the long distance relativistic calculation assume that your top speed is just short of the speed of light?

  35. Keith says:

    You plug in the speed.

    It can be from 1mph to 99.99999% of C. You enter what you like and see how long it takes.

    Keith

  36. Tom says:

    Can’t thank you enough for putting these up. Only issue is that the “conversions” calculators seem to be broken. Everything else works perfectly with FF v4.0.1 but the last two don’t seem to want to update anything.

    Or, *Much More Likely*, am I doing something blatantly stupidly wrong?

    ¡Muchas Gracias!

  37. Keith says:

    Thanks,

    Every time I upgrade the site, something new breaks.

    I’ll work on that – in the morning.

    Keith

  38. branx says:

    Hello and thanks for the wonderful calculator!

    Would it be possible to have a long relativistic journey calculator based on propulsion force instead of constant acceleration?

    If i’m not mistaken the mass gets bigger when velocity goes towards c.
    I think if the spacecraft could reach c, the mass would be infinite?

    I have no idea how hard that would be to do script or if I am even correct.

    thanks anyway,
    Branx

  39. Keith says:

    I am not sure what you mean. The constant acceleration is probably necessary because of people living on the ship would not be able to live long on high acceleration (gravity like force). The calculations take the increase in mass into account.

    The motive force, however is not specified and would involve technology that we do not have at this time. The huge amount of energy needed to produce the constant acceleration is beyond humans.

    Reaching C is not an issue. You can only approach C. Increasing the acceleration only gets you closer. There is no way to obtain C as a speed. It is a limit not a target. It is not a technological issue. The C limit is a property of the universe, not something that is hard to do. The universe makes it impossible.

    In Science Fiction, C is usually sidestepped by leaving normal space/time and traveling outside of the normal universe (eg. Warp Drive in trek). Unfortunately, Warp Drive, is meaningless term and although there are some ideas, there is no proven way to accomplish it. None of the theories even look likely to be practical.

    Keith

  40. John B says:

    I don’t agree with all these scientific hypothesis that a ship accelerating at 1G shrinks or grows in size/ becomes heavier or lighter. passes one year of time while 2 years pass back on earth etc etc.. Where do any of these people get one shred of evidence for all of these mathematical theory claims? Non scientifically a ship at 1G constant acceleration reaches the speed of light in 300-400 days? then it turns around – slows down for 300-400 days. Then it repeats the process in the opposite direction and ends up back here on Earth at the same day / same time on it’s on board clocks and Calendars. None of you have any proof that time or mass changes. When they develop the ability to travel that way they’ll look back at all your far out inaccurate undecipherable scientific double talk theories you had to that effect in this time and laugh at you.

    Also the one parameter I think would be helpful on the first calculator (Which is great by the way,excellent job)Is.. What speed would you be going after say a 10 day 1G acceleration. Not how many billions of milimeters did you travel.

  41. Bryan with a Why says:

    John – your GPS device has to correct for the theories that you claim that there is no evidence. There is empirical evidence for time dilation. http://en.wikipedia.org/wiki/Time_dilation#Experimental_confirmation

  42. Keith says:

    If you want to find how fast your are traveling at the end, just multiply acceleration times the time traveled. I should have made final velocity the fourth box, but it is easy enough to figure in your head.

    No one is asking you to agree. The evidence is overwhelming, though, with thousands of experiments proving general relativity. You might say that the atomic bomb is impossible, but many people know otherwise, and the atomic bomb would be impossible if the calculators here gave different results.

    Observations of the planet Mercury, whose mass and size are altered by the relativistic effects of the Sun’s gravity, proves Einstein’s relativity with a great deal of accuracy.

    Don’t express your opinions around anyone who knows a little about physics, or you may get teased.

    Keith

  43. John B says:

    I probably shouldn’t be so condescending but I won’t believe it until the day (decade?) I actually climb on a 1G perpetually accelerating self contained spacecraft and perform that 4+ year experiment myself. I’ll arrive back here at Earth and the clocks and calendars in my spacecraft will be the same as the clocks and calendars on Earth. Time travel is science fiction. Anyways – I’ll never be around to see that day. Thanks for the way to calculate the speed at the end.

  44. Steve says:

    Hi, I have a question about the “1G” used in the constant acceleration calculater:

    Which reference frame are you using to hang the “1G” in? I think maintaining 1G in the earth reference frame would be impossible but not necessarilly in the traveler’s reference frame (if they have a magic fuel source). Within their reference frame 1G always requires the same energy/time input no matter what so it stays manageable from their perspective. The same energy input (for them) yields the same acceleration “G” experience for them regardless.

    From the earth reference though I think energy input is dropping the longer they accelerate (as they approach C) because their time is slowing down. Eventually their clock is running so slow that what they call “1G” is negligable in our reference frame. Maybe the Lorentz transform cancels it all out with the mass increase, I’m not too sure of that.

    But I do think you have to use the traveler’s frame to calculate the 1G, otherwise they get smooshed as their time slows relative to earth frame and they experience relative acceleration much higher than it looks to us. If you’re not using the traveler’s reference to calculate the 1G then the travel time calculation is probably giving a shorter answer than it should.

    I’m guessing you did the right thing because this all looks pretty thorough but wanted to ask the question.

    To everyone who thinks relativity isn’t real – it’s already been said – throw away your GPS because if relativity isn’t real, GPS won’t work. All the calculations for GPS require precision time for every satellite in the constellation, and all of these GPS satellites experience enough relativistic time dilation (all traveling in different directions) to screw up your GPS, unless they adjust the calculations to accomodate relativity. Every time you use a GPS, you prove Einstein was right.

  45. Keith says:

    The acceleration is from the reference frame of the ship. 1G is convenient because the people in the ship would feel a “normal” gravity and get all of the health benefits of this on a long trip.

    Keith

  46. Steve says:

    Beautiful! Just had to ask… Thanks for such an amazing resource!

  47. Mark Toner says:

    The 1G in spaceship frame is the best idea as it helps get around all those medical problems they have on the ISS. That’s why I’m adopting this calculator for an up and coming episode of my web comic. I may get to that bit before the end of the year. :)

  48. D says:

    The first calculator “Newtonian Constant Acceleration in g’s.” seems to be displaying the wrong units for v in the velocity result listed as meters/hour when I use it. It should be meters/second.

  49. D says:

    Ah, I see where your calculator seems to be screwing up. I input my units and selected hours from the drop down for time. This changed the units in the v output, but did not change the actual value.

  50. Keith says:

    I am not seeing it. It uses the time from the time duration and the distance unit from the distance. The answer should be the acceleration times time and it should correct for units. I will try some different calculations and see if it breaks.

    Keith

    Ok, I see where it is not converting back to the correct unit. It works correctly for meters and seconds, but it is not converting back to feet correctly.

Leave a Comment

 

 

 

 

 

 

 




 
About/Contact