The Lorentz Transformation
The Lorentz Transformation
The Lorentz transformation is the relativistic replacement for the Galilean transformation. It tells you how to convert spacetime coordinates measured in frame into coordinates measured in frame , where moves at velocity along the -axis relative to :
The factor appears in both equations — space and time are mixed together. This is the mathematical heart of special relativity: there is no absolute time, only spacetime.
The Inverse Transformation
To go back from to , replace with (the primed frame moves at relative to , so moves at relative to ):
Key Example (v = 0.6c, γ = 1.25)
Consider an event at m, s. In the moving frame:
The spatial separation vanishes in the moving frame — both events happen at the same location.
Your Task
Implement lorentz_x(x, t, v) returning the transformed position , and lorentz_t(x, t, v) returning the transformed time . Use m/s defined inside each function.