## Abstract:

This lab is model the data of a spaceship traveling to Proxima Centauri. The spaceship travels at a constant acceleration for half of the journey and has an equal but opposite acceleration the second half. To model this data I used Heun's Method. After using Huend method, I compared the modeled Kinetic Energy and the expected work and the uncertainty was +/- 6.146E+15 J.

## Description

In this project, Heun's Method was used to track the motion and data of a spaceship traveling to Proxima Centauri which is 4.24 light-years away from Earth. In this project, there were many assumptions:

- Humans have the technology to make this trip
- There is an advanced propulsion unit that is able to use little fuel and run the entire time
- The acceleration is low enough for humans to survive, 4 times the speed of gravity
- Everything weighed 1 kilogram
- Gravitational forces are negligable and do not act on the spaceship.

With all of these assumptions, the problem is pretty simple if you understand simple physics and a little bit of relativity. The data that was calculated was the position, the momentum, the dialated time, the gamma variable, the velocity, and the kinetic energy. Below were the equations used:

Position: Heun's Model was used, so $$\frac{dx}{dt} = v$$

Momentum: Heun's Model was used, so $$\frac{dp}{dt} = F*m$$

Dialated time: Heun's Model was used, so $$\frac{dtau}{dt} = \frac{1}{gamma}$$

Gamma: $$\frac{1}{\sqrt(1-(\frac{v}{c})^2)}$$

Velocity: $$\frac{p*c}{\sqrt(p^2-m^2 c^2)}$$

Kinetic Energy: $$c^2(gamma - 1)$$

During this project, the focus was not exactly on relativity but more on Heun's Method. Even though this was the case, I still learned a lot about relativity and had to do a lot of research to relearn and learn about it. It is interesting to see how things change once they reach these relativistic speeds. Below will be graphs of how things work in relation to time.

## Algorith and Discussion

As noted in the description, this project focuses on Heun's Method. In this experiment a coupled system was used, a system with multiple variables. A coupled system works exactly the same as any other system. The good thing about the Heun Method is that is very similar to Euler's Method, it just takes things one step farther for better accuracy. Below are the steps for this algorithm:

- First find the rate of change/derivative equation: $$f_1 = f(s_1, x_1)$$
- Second, update the origional x value: $$x_2 = x_1 + \Delta x$$
- Third, estimate the new value of s: $$s_2 = s_1 + f(s_1,x_1) \Delta x$$
- Fourth, the new postion will be evaluated: $$f_2 = f(s_2, x_2)$$
- Finally, find the average of the two values to find the final value: $$s_3 = s_1 + \frac{1}{2}(f_1 + f_2) \Delta x$$

After this, the algorith is finished. It is helpful to create a derivs function so you can do all of the math before throwing it into the Heun Algorithm. Once the derivs function and the Algorith is completed, the only thing needed is extra code to analyze the data, but that has nothing to do with the Heun's Method.

## Implementation and code

## Results

Above are the graphs of data using Heun's Method. The momentum graph, the position graph, and the tau graph were directly influenced by Heun's Method, while velocity, gamma, and kinetic energy used values of updated data. It is good to point out that most graphs look similar on the first half and the second half. This is because the only thing changing is the direction of acceleration, but everything else is the same. One graph I want to point out is the velocity graph. The graph shoots up, but then the slope starts to approach zero at 3e8 m/s. This is because nothing can go faster than the speed of light, if you take a look at the equations this makes sense. Next I want to take a look at the kinetic energy graph and compare is to work. It is known that work equals force times distance and that work equals kinetic energy is true. Since this is true I was able to see if Heun's Method was valid and if it was I was able to compare the results. To do this, I found the work and kinetic energy after traveling half the distance. In the code above I did these calculations and printed the results. The results showed that the uncertainty was +/- 6.146E+15 J. This might seem like a big number, but compared to the original values it is not, the percent error is only 0.78 %. Currently I do not know a better way to improve this calculation, but it it a lot better than the Euler Method.

## Conclusion

The goal of this report was to use Heun's method to model the travel of a spaceship to Proxima Centauri. The equations used included momentum, gamma, velocity, position, tau, and kinetic energy. After conducting the calculations, the error was +/- 6.146E+15 J, which is only an error of 0.78 %. This error was found by comparing the kinetic energy to the work. Even though the equations themselves were a little complicated, Heun's method was able to model the data very well. I would say this is a good model to use for these kinds of calculations.