Simulating relativity in a velocity verlet algorithm

Click For Summary

Discussion Overview

The discussion revolves around simulating relativistic effects in a turn-based computer game focused on space combat. Participants explore how to integrate a lightspeed limit into a velocity verlet algorithm while maintaining energy conservation, addressing challenges related to inertia, gravity, and relativistic physics.

Discussion Character

  • Exploratory
  • Technical explanation
  • Debate/contested
  • Mathematical reasoning

Main Points Raised

  • One participant proposes using the relativistic factor (1 / sqrt(1 - v^2/c^2)) to modify the acceleration of spacecraft, suggesting this would limit acceleration at high speeds while keeping gravitational effects unchanged.
  • Another participant questions the effectiveness of using relativistic mass in the velocity verlet algorithm, expressing doubt that the algorithm can accurately simulate relativistic scenarios.
  • Further inquiries are made about the expected gravitational acceleration on an object at different velocities relative to a star, highlighting concerns about how these would differ based on the object's speed.
  • Participants also seek to understand the time it would take for an object to fall into the sun from various distances, indicating a curiosity about the dynamics involved in such scenarios.
  • A reference to an equation in a textbook is provided as a potential resource for addressing the simulation challenges.

Areas of Agreement / Disagreement

Participants express differing views on the applicability of the velocity verlet algorithm for relativistic simulations, with some proposing modifications while others doubt its feasibility. The discussion remains unresolved regarding the best approach to accurately simulate relativistic effects.

Contextual Notes

There are uncertainties regarding the assumptions made about gravitational effects at relativistic speeds, the role of time dilation, and how to accurately incorporate these factors into the simulation without losing energy conservation.

cephron
Messages
123
Reaction score
0
(Skip to the * mark if you would like to see my question without the background)

Hi,

I'm trying to write a turn-based computer game which simulates space combat at relativistic speeds, but I'm a beginner at programming and I don't know much physics beyond the high school level. The game consists of spacecraft flying through a 30 lightyear-by-30 lightyear 2-dimensional space roughly reminiscent of the Local Cloud, trying to destroy their opponents while dealing with the lightspeed delay and a realistic simulation of the ship's inertia and the gravity of nearby stars.

*
My current inertia-and-gravity simulation is based on the velocity verlet algorithm ( http://en.wikipedia.org/wiki/Velocity_Verlet#Velocity_Verlet ), which is purely Newtonian. Obviously, this won't do, because this puts no limit on the speeds ships can attain.
I think converting the whole simulation to general relativity would be completely above my head. I'm wanting to know if there's any simple or medium-difficulty way of simulating a lightspeed limit of the velocity of the ships - without losing kinetic/potential energy - that can be integrated into the velocity verlet algorithm.

Any help would be most welcome!

(If this is outright impossible for some obvious reason, I apologize for the blatant ignorance!)

cephron
 
Physics news on Phys.org
Ok, here's what I'm thinking of doing, so far. It seems like an obvious solution, but I'm unsure of its accuracy.

Whenever I'm calculating the acceleration of the particle for the next timestep, I'll use the base mass multiplied by the relativistic factor of change ( 1 / sqrt(1 - v^2/c^2) ).

This would end up leaving acceleration due to stars' gravity unchanged, since the mass term cancels from the equation, but it would greatly diminish the acceleration of the drive when the ship is at high velocities. One of my main concerns with this is that, if a ship was accelerating towards a star, it's drive might bring it to 0.99c and the star's gravity - with the relativistically increased mass cancelling out - might push it over the edge.

Would this accomplish the goal? Or would it be screwed up because I'm not also including the time dilation and lorentz transformation? Or perhaps I need to include the relativistic factor in the acceleration due to star gravity, somehow?

Thanks in advance for any input.
 
Last edited:
Since my broad questions don't seem to interest people (which is fine, lol), I'll try to break it down into simpler questions:

1)
RelativeGravity.jpg

Using the above figure as a reference (the units are only meant to be guides, change them if it becomes more convenient), what kind of acceleration due to gravity according to the star's reference frame would one expect on the 1kg-object in the case where:
a) The object is at rest or traveling at low velocity?
b) The object is traveling at .99c perpendicular to the source of the gravity?
c) The object is traveling at .99c towards the source of gravity?
Main point being, would they be different?

2)
What sort of time would it take for an object in the edge of the solar system (say, in the near edge of the kuiper belt) to fall into the sun, if it starts out at rest relative to the sun? Years, decades? A century? How about if it started a light year from the sun?
 
Ther'es an equation on p. 34 of http://www.worldscibooks.com/etextbook/6833/6833_02.pdf" that might help you.
 
Last edited by a moderator:
You won't get the right answer by plugging in relativistic mass. In fact, I doubt very much that this algorithm will work at all - the expansion assumes a is independent of v, right? Sorry.
 

Similar threads

  • · Replies 2 ·
Replies
2
Views
1K
  • · Replies 10 ·
Replies
10
Views
1K
  • · Replies 12 ·
Replies
12
Views
2K
  • · Replies 3 ·
Replies
3
Views
2K
  • · Replies 8 ·
Replies
8
Views
3K
  • · Replies 19 ·
Replies
19
Views
4K
  • · Replies 28 ·
Replies
28
Views
3K
  • · Replies 8 ·
Replies
8
Views
2K
  • · Replies 8 ·
Replies
8
Views
4K
  • · Replies 23 ·
Replies
23
Views
2K