Submitted by Jay-Tanner on Monday, December 20, 2021 - 10:55.

**PHP - Relativistic Motion Calculators**

There are three relativistic motion calculators in the archive.

The graphics show the math used by the programs.

An extremely advanced space probe is about to accelerate to a target distance of (D) light-years from Earth at a constant acceleration G-Factor (G).

The space probe or spacecraft is not expected to ever return and will coast through space forever at a final constant terminal speed when it reaches the target distance D and all acceleration terminates.

This program computes the relative times as measured on Earth and by the space probe taking into account acceleration and relativistic time dilation.

The clock aboard the space probe runs slower than an identical clock on Earth due to the relative motion of the accelerating spacecraft.

This is the simplest type of motion, simply coasting through space at a constant

relativistic speed v/c = β

This program computes the relative times as experienced on Earth and by the spacecraft taking into account the relativistic time dilation. Even a trip to the nearest star would require taking into account the effects of relativity, regardless of how we do it, for the time differential between the Earth and spacecraft clocks to make physical sense.

The clock aboard the spacecraft runs slower than an identical clock on Earth due to the relative motion of the spacecraft.

If the space probe sent back a signal when it reached distance D telling us the time of arrival according to its clock, the ship's clock would indicate that the trip took less time to reach D than it did according to the Earth clock.

This program computes the general statistics for a complete relativistic voyage to another star (or galaxy).

It takes into account acceleration and the space-time dilation predicted by the general theory.

Here are working copies of the programs in action:

http://neoprogrammics.com/!abc/math-science-tools/relativity/relativistic-linear-motion-calculators/

I have also provided a source code in this article. You can download it by clicking the **download button** below this article.

**Locally**

- Download and Install any local web server such as
**XAMPP/WAMP**to run the**PHP Script**. - Download the provided source code
**zip file**.*(download button is located below)*

**Setup & Installation**

- Open your
**XAMPP/WAMP's Control Panel**and start the**Apache**webserver. - Extract the downloaded zip file.
- Copy the extracted source code folder.
- If you using
**XAMPP**,**paste**the source code folder inside the**'htdocs'**directory ie. C:\xampp\htdocs. And if using**WAMPP**, paste it inside the**'www'**directory. - Open a new tab in your browser and browse http://localhost/relativity/relativistic-linear-motion-calculators/.

That's it! You can now test the **Relativistic Motion Calculators** on your end.

I hope this will help you with what you are looking for.

**Enjoy :)**

Note: Due to the size or complexity of this submission, the author has submitted it as a .zip file to shorten your download time. After downloading it, you will need a program like Winzip to decompress it.

Virus note: All files are scanned once-a-day by SourceCodester.com for viruses, but new viruses come out every day, so no prevention program can catch 100% of them.

FOR YOUR OWN SAFETY, PLEASE:

1. Re-scan downloaded files using your personal virus checker before using it.

2. NEVER, EVER run compiled files (.exe's, .ocx's, .dll's etc.)--only run source code.

- 502 views