The question is very simple, but complicated to solve. I am looking for a genera form solution to this problem. Thus there will be no numbers, just variables. What I mean by that is often in physics you have equations like $F = ma$. I don't have the numbers to the problem yet, because that will vary based on the spaceship, its engine, the distance, etc.
Newtonian physics works as an approximation, however its allows the spaceship to exceed $c$ during its travels. I would like to add relativity, with the frame of reference being the spaceship.
I can already solve this problem in discrete time steps programatically, but it would be nice to have a general form solution that would be more accurate. (Because discrete time stepping is expensive computationally, and a general form solution would be much much faster.)
From my current algorithm the variables are:
- $M$ = base mass of spaceship in kkg (ie 1000kg)
- $C$ = cargo space of spaceship kkg
- $D$ = distance to be traveled in km
- $T$ = thrust of the engines in kN
- $F$ = fuel consumed per year in kkg/year
- $E$ = food consumed per year in kkg/year
- $A$ = maximum velocity you can possibly achieve {$A < c$} in m/s
- $B$ = maximum velocity you are willing to achieve {$B <= A$} in m/s
Some notes.
- Cargo space can be used to be store fuel and/or food.
- The way I solved this problem before, was calculated fuel costs first, and then decided if there was enough food afterwards. Based on $C_{remaining} > t_{travel} * E$
- Loaded cargo adds to $M$ so $M_{total} = M + C_{fuel} + C_{food}$
- As you fly the mass of the fuel is consumed, reducing the weight of the spaceship, allowing you accelerate faster.
- Engine efficiency is not part of the equation. The engine produces $T$ thrust and consumes $F$ fuel per year. (unless I am wrong, I shouldn't have to worry about it, if it does matter, lets say 100%; its ideal.)
- The ship needs to spend fuel accelerating (to the halfway point or until B it achieved), and then spend fuel decelerating on the other end. the $t_{accelerating} \neq t_{decelerating}$ due to the change in mass during voyage. This also means less fuel will be consumed to decelerate as well.
- As length inversely dilates with velocity, the length of the trip shrinks as the spaceship nears $c$ and expands as you decelerate as you near the destination.
What I am looking for is a function that determines if the one-way trip is possible, how long it will take, and how much fuel is consumed in the process, in the form of
$$f(M, C, D, T, F, E, A, B) -> (isPossible, t_{total}, C_{fuel-consumed})$$
I realize that with B there will be conditionals.
As far as I can tell, there are 3 rate of change problems (more?)
- Mass increases as velocity increases $M_{relative} = M_{current} * \gamma$
- Mass decreases as fuel is expended $M_{current} = M + C_{fuel} - C_{fuel-consumed}$
- $C_{fuel-consumed} = F * t_{running-engines}$
- Distance decreases as velocity increases $D_{relative} = D_{base} / \gamma$
- Am I missing something?
Some references:
- http://en.wikipedia.org/wiki/Speed_of_light#Upper_limit_on_speeds
- $\gamma = \dfrac{1}{\sqrt{1-v^2/c^2}}$
- $a = \dfrac{T}{M_{relative}}$ Note: $a$ will change as $M_{relative}$ changes, but $T$ remains constant