diff options
Diffstat (limited to '1535/CH8/EX8.5')
-rwxr-xr-x | 1535/CH8/EX8.5/Ch08Ex5.sci | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/1535/CH8/EX8.5/Ch08Ex5.sci b/1535/CH8/EX8.5/Ch08Ex5.sci new file mode 100755 index 000000000..4d831344d --- /dev/null +++ b/1535/CH8/EX8.5/Ch08Ex5.sci @@ -0,0 +1,15 @@ +// Scilab Code Ex8.5: Page-172 (2010)
+c = 1; // For simplicity assume speed of light to be unity, m/s
+L0 = 1; // For simplicity assume length in spaceship's frame to be unity, m
+L = 1/2*L0; // Length as observed on earth, m
+// Relativistic length contraction gives
+// L = L_0*sqrt(1-v^2/c^2), solving for v
+v = sqrt(1-(L/L0)^2)*c; // Speed at which length of spaceship is observed as half from the earth frame, m/s
+tau = 1; // Unit time in the spaceship's frame, s
+t = tau/sqrt(1-(v/c)^2); // Time dilation of the spaceship's unit time, s
+printf("\nThe speed at which length of spaceship is observed as half from the earth frame = %5.3fc", v);
+printf("\nThe time dilation of the spaceship unit time = %1g*tau", t);
+
+// Result
+// The speed at which length of spaceship is observed as half from the earth frame = 0.866c
+// The time dilation of the spaceship unit time = 2*tau
|