E has the coordinates x=4, t=5 in the statinary frame, and x’=1.73, t’=3.46 in the other frame.
In relativity theory, axises need to tilt an angle. Let \(\theta\) be the tilting angle, and \(v\) be the relative speed, \(c\) is the light speed. \(v/c\) is tangent of the angle \(\theta\), then we have \[\theta=tan^{-1}(v/c)=arctan(v/c)\]
If \(v=c/2\), then \(\theta=26.56505\) in degrees
c0=1 # one unit is 300000km per sec
v=c0/2
theta=atan(v/c0)
theta/pi*180
## [1] 26.56505
With tilting, we can draw \(x'\) and \(ct'\) axises. Suppose we have a point \(E=\{4,5\}\) in the stationary frame. By drawing parallel lines, we can get points \(A=\{2,4\}\) and \(B=\{2,1\}\) to intersect \(x'\) and \(ct'\) axises.
get_intercept <- function(x1, y1, slope) {
# Point slope formula (y - y1) = slope(x - x1)
y_intercept = slope * (- x1) + y1
return(y_intercept)
}
intersection_point <- function(m1,m2){
a <- m1-m2
x=-a[1]/a[2]
y=m1[2]*x + m1[1]
return(c(x,y))
}
E=c(4,5)
slope1=v/c0
slope2=tan(pi/2-theta)
line1=c(get_intercept(E[1],E[2],slope1),slope1)#{intercept,slope}
line2=c(get_intercept(E[1],E[2],slope2),slope2)
line.xprime=c(0,slope2)
line.ctprime=c(0,slope1)
A = intersection_point(line.xprime,line1) #{2,4}
B = intersection_point(line.ctprime,line2)#{2,1}
x.axis=c(0,0)
C = intersection_point(x.axis,line2) #{1.5,0}
The gamma factor is computed as \(\gamma=1/\sqrt{1-v^2/c^2}\). We can get \(x'\) and \(t'\) in the primed frame \[x'=B_x/\gamma\] \[t'=A_{ct}/\gamma\]
gamma=1/sqrt(1-v^2/c0^2)
x.prime=B[1]/gamma
t.prime=A[2]/gamma
c(x.prime,t.prime)
## [1] 1.732051 3.464102
Let’s verify the result by using Lorentz transforms. \[\beta=v/c\] \[\gamma=1/\sqrt{1-\beta^2}\] \[ x' = \gamma (x-\beta ct)\] \[ ct' =\gamma (ct-\beta x) \]
beta=v/c0
#gamma=1/sqrt(1-beta^2)
x.prime2=gamma*(E[1]-beta*E[2])
t.prime2=gamma*(E[2]-beta*E[1])
c(x.prime2,t.prime2)
## [1] 1.732051 3.464102
Another calculation, draw the 2 parallel lines on point E with the tilting angle. These parallel lines intersect with the stationary frame. Intersections on the stationary frame time gamma also can get Lorentz transformations.
line1[1]*gamma
## [1] 3.464102
C[1]*gamma
## [1] 1.732051