From b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b Mon Sep 17 00:00:00 2001 From: priyanka Date: Wed, 24 Jun 2015 15:03:17 +0530 Subject: initial commit / add all books --- 1535/CH8/EX8.5/Ch08Ex5.sci | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100755 1535/CH8/EX8.5/Ch08Ex5.sci (limited to '1535/CH8/EX8.5') 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 -- cgit