1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
|
{
"metadata": {
"name": ""
},
"nbformat": 3,
"nbformat_minor": 0,
"worksheets": [
{
"cells": [
{
"cell_type": "heading",
"level": 1,
"metadata": {},
"source": [
"Chapter 1: Relativistic Mechanics"
]
},
{
"cell_type": "heading",
"level": 2,
"metadata": {},
"source": [
"Example 1.2, Page 26"
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"from math import *\n",
"\n",
"#Variable declaration\n",
"c = 3e+008; # Speed of light in vacuum, m/s\n",
"delta_x = 2.45e+03; # Space difference, m\n",
"delta_t = 5.35e-06; # Time difference, s\n",
"\n",
"#Calculations\n",
"v = 0.855*c; # Speed of frame S_prime, m/s\n",
"delta_x_prime = 1/sqrt(1-v**2/c**2)*(delta_x - v*(delta_t))*1e-03; # Distance between two flashes as measured in S_prime frame, km\n",
"delta_t_prime = 1/sqrt(1-v**2/c**2)*(delta_t - v/c**2*delta_x)*1e+006; # Time between two flashes as measured in S_prime\n",
"\n",
"#Results\n",
"print \"The distance between two flashes as measured in S_prime frame = %4.2f km\"%delta_x_prime\n",
"print \"The time between two flashes as measured in S_prime frame = %4.2f micro-second\"%delta_t_prime\n",
"\n"
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "stream",
"stream": "stdout",
"text": [
"The distance between two flashes as measured in S_prime frame = 2.08 km\n",
"The time between two flashes as measured in S_prime frame = -3.15 micro-second\n"
]
}
],
"prompt_number": 3
},
{
"cell_type": "heading",
"level": 2,
"metadata": {},
"source": [
"Example 1.4, Page 27"
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"from sympy import *\n",
"c = Symbol('c')\n",
"\n",
"#Variable declaration\n",
"c = 1; # Speed of light in vacuum, m/s\n",
"u_x_prime = c; # Velocity of photon as measured in S_prime frame, m/s\n",
"v = c; # Velocity of frame S_prime relative to S frame, m/s\n",
"\n",
"#Calculations\n",
"u_x = (u_x_prime + v)/(1+v*u_x_prime/c**2);\n",
"if u_x == 1: \n",
" ux = 'c';\n",
"else: \n",
" ux = string(u_x)+'c'; \n",
"\n",
"\n",
"#Result\n",
"print \"The speed of one photon as observed by the other is %c\"%ux\n"
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "stream",
"stream": "stdout",
"text": [
"The speed of one photon as observed by the other is c\n"
]
}
],
"prompt_number": 8
},
{
"cell_type": "heading",
"level": 2,
"metadata": {},
"source": [
"Example 1.6, Page 28"
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"import math\n",
"\n",
"#Variable declaration\n",
"a = 1; # For simplicity assume length of semi minor axis to be unity, m\n",
"c = 3e+08; # Speed of light, m/s\n",
"\n",
"\n",
"#Calculations\n",
"#From equation 1-v^2/c^2=1/4, we derive the following expression\n",
"v = math.sqrt(3*c**2/4) # Velocity at which surface area of lamina reduces to half in S-frame, m/s\n",
"\n",
"\n",
"print \"The velocity at which surface area of lamina reduces to half in S-frame = %4.2e m/s\"%v\n"
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "stream",
"stream": "stdout",
"text": [
"The velocity at which surface area of lamina reduces to half in S-frame = 2.60e+08 m/s\n"
]
}
],
"prompt_number": 3
},
{
"cell_type": "heading",
"level": 2,
"metadata": {},
"source": [
"Example 1.7, Page 29"
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"#Variable declaration\n",
"m0 = 1; # For simplicity assume the rest mass of stick to be unity, kg\n",
"m = 1.5*m0; # Mass of the moving stick, kg\n",
"L0 = 1; # Assume resting length of the stick to be unity, m\n",
"\n",
"#Calculations\n",
"# As m = m0/sqrt(1-v^2/c^2) = m0*gama, solving for gama\n",
"gama = m/m0; # Relativistic factor\n",
"L = L0/gama; # Contracted length of the metre stick, m\n",
"\n",
"#Result\n",
"print \"The contracted length of the metre stick = %4.2f m\"%L\n",
" \n"
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "stream",
"stream": "stdout",
"text": [
"The contracted length of the metre stick = 0.67 m\n"
]
}
],
"prompt_number": 13
},
{
"cell_type": "heading",
"level": 2,
"metadata": {},
"source": [
"Example 1.8, Page 29"
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"from math import *\n",
"\n",
"#Variable declaration\n",
"c = 3e+008; # Speed of light in vacuum, m/s\n",
"tau0 = 2e-008; # Mean lifetime of meson at rest, m/s\n",
"\n",
"#Calculations\n",
"v = 0.8*c; # Velocity of moving meason, m/s\n",
"tau = tau0/sqrt(1-v**2/c**2); # Mean lifetime of meson in motion, m/s\n",
"\n",
"#Result\n",
"print \"The mean lifetime of meson in motion = %4.2e s\"%tau\n"
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "stream",
"stream": "stdout",
"text": [
"The mean lifetime of meson in motion = 3.33e-08 s\n"
]
}
],
"prompt_number": 14
},
{
"cell_type": "heading",
"level": 2,
"metadata": {},
"source": [
"Example 1.9, Page 30"
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"from math import *\n",
"\n",
"#Variable declaration\n",
"c = 3e+008; # Speed of light in vacuum, m/s\n",
"delta_t0 = 59; # Reading of the moving clock for each hour, min\n",
"delta_t = 60; # Reading of the stationary clock for each hour, min\n",
"\n",
"#Calculations\n",
"# As from Time Dilation, delta_t = delta_t0/sqrt(1-v^2/c^2), solving for v\n",
"v = sqrt(((delta_t**2-delta_t0**2)*c**2)/delta_t**2)\n",
"\n",
"#Result\n",
"print \"The speed at which the moving clock ticks slow = %4.2e m/s\"%v\n"
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "stream",
"stream": "stdout",
"text": [
"The speed at which the moving clock ticks slow = 5.45e+07 m/s\n"
]
}
],
"prompt_number": 8
},
{
"cell_type": "heading",
"level": 2,
"metadata": {},
"source": [
"Example 1.10, Page 30"
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"from math import *\n",
"\n",
"#Variable declaration\n",
"c = 3e+008; # Speed of light in vacuum, m/s\n",
"tau0 = 2.5e-008; # Mean lifetime of meson at rest, m/s\n",
"\n",
"#Calculations\n",
"v = 0.8*c; # Velocity of moving meason, m/s\n",
"tau = tau0/sqrt(1-v**2/c**2); # Mean lifetime of meson in motion, m/s\n",
"N0 = 1; # Assume initial flux of meson beam to be unity, watt/Sq.m\n",
"N = N0*exp(-2); # Meson flux after time t, watt/Sq.m\n",
"# As N = N0*e^(-t/tau), which on comparing gives\n",
"t = 2*tau; # Time during which the meson beam flux reduces, s\n",
"d = 0.8*c*t; # The distance that the meson beam can travel before reduction in its flux, m\n",
"\n",
"#Result\n",
"print \"The distance that the meson beam can travel before reduction in its flux = %2d m\"%d\n"
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "stream",
"stream": "stdout",
"text": [
"The distance that the meson beam can travel before reduction in its flux = 20 m\n"
]
}
],
"prompt_number": 17
},
{
"cell_type": "heading",
"level": 2,
"metadata": {},
"source": [
"Example 1.11, Page 31"
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"from math import *\n",
"\n",
"#Variable declaration\n",
"c = 3e+008; # Speed of light in vacuum, m/s\n",
"E0 = 1; # Rest energy of particle, unit\n",
"\n",
"#Calculations\n",
"E = 3*E0; # Energy of relativistically moving particle, unit\n",
"# E = m*c^2 and E0 = m0*c^2\n",
"# With m = m0/sqrt(1-v^2/c^2), we have\n",
"v = c*sqrt(1-(E0/E)**2); # Velocity of the moving particle, m/s\n",
"\n",
"#Result\n",
"print \"The velocity of the moving particle = %4.2e m/s\"%v\n",
"#answer differs due to rounding-off errors"
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "stream",
"stream": "stdout",
"text": [
"The velocity of the moving particle = 3.00e+08 m/s\n"
]
}
],
"prompt_number": 14
},
{
"cell_type": "heading",
"level": 2,
"metadata": {},
"source": [
"Example 1.12, Page 32"
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"from math import *\n",
"\n",
"#Variable declaration\n",
"c = 3e+008; # Speed of light in vacuum, m/s\n",
"m0 = 9.1e-031; # Rest mass of electron, kg\n",
"\n",
"#Calculations\n",
"m = 11*m0; # Mass of relativistically moving electron, kg\n",
"E_k = (m-m0)*c**2/(1.6e-019*1e+06); # Kinetic energy of moving electron, MeV\n",
"# As m = m0/sqrt(1-v^2/c^2), solving for v\n",
"v = c*sqrt(1-(m0/m)**2); # The velocity of the moving electron, m/s\n",
"p = m*v; # Momentum of moving electron, kg-m/s\n",
"\n",
"#Results\n",
"print \"The kinetic energy of moving electron = %4.2f MeV\"%E_k\n",
"print \"The momentum of moving electron = %4.2e kg-m/s\"%p\n"
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "stream",
"stream": "stdout",
"text": [
"The kinetic energy of moving electron = 5.12 MeV\n",
"The momentum of moving electron = 2.99e-21 kg-m/s\n"
]
}
],
"prompt_number": 19
},
{
"cell_type": "heading",
"level": 2,
"metadata": {},
"source": [
"Example 1.13, Page 32"
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"from math import *\n",
"\n",
"#Variable declaration\n",
"c = 3e+008; # Speed of light in vacuum, m/s\n",
"E0 = 0.5; # Rest energy of the electron, MeV\n",
"\n",
"#Calculations\n",
"v1 = 0.6*c; # Initial velocity of the electron, m/s\n",
"v2 = 0.8*c; # Final velocity of the electron, m/s\n",
"W = (1/sqrt(1-v2**2/c**2)-1/sqrt(1-v1**2/c**2))*E0; # The amount of work to be done to increase the speed of the electron, MeV\n",
"\n",
"#Result\n",
"print \"The amount of work to be done to increase the speed of an electron = %4.2e J\"%(W*1e+06*1.6e-019)\n"
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "stream",
"stream": "stdout",
"text": [
"The amount of work to be done to increase the speed of an electron = 3.33e-14 J\n"
]
}
],
"prompt_number": 20
},
{
"cell_type": "heading",
"level": 2,
"metadata": {},
"source": [
"Example 1.14, Page 33"
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"from math import *\n",
"\n",
"#Variable declaration\n",
"c = 1; # Assume speed of light in vacuum to be unity, unit\n",
"m0 = 1; # For simplicity assume rest mass of the particle to be unity, unit\n",
"\n",
"#Calculations\n",
"v = c/sqrt(2); # Given speed of the particle, m/s\n",
"gama = 1/sqrt(1-v**2/c**2); # Relativistic factor\n",
"m = gama*m0; # The relativistic mass of the particle, unit\n",
"p = m*v; # The relativistic momentum of the particle, unit\n",
"E = m*c**2; # The relativistic total eneryg of the particle, unit\n",
"E_k = (m-m0)*c**2; # The relativistic kinetic energy of the particle, unit\n",
"\n",
"#Results\n",
"print \"The relativistic mass of the particle = %5.3fm\"%m\n",
"print \"The relativistic momentum of the particle = %1.0gm0c\"%p\n",
"print \"The relativistic total energy of the particle = %5.3fm0c^2\"%E\n",
"print \"The relativistic kinetic energy of the particle = %5.3fm0c^2\"%E_k\n",
" "
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "stream",
"stream": "stdout",
"text": [
"The relativistic mass of the particle = 1.414m\n",
"The relativistic momentum of the particle = 1m0c\n",
"The relativistic total energy of the particle = 1.414m0c^2\n",
"The relativistic kinetic energy of the particle = 0.414m0c^2\n"
]
}
],
"prompt_number": 15
},
{
"cell_type": "heading",
"level": 2,
"metadata": {},
"source": [
"Example 1.15, Page 34"
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"from math import *\n",
"\n",
"#Variable declaration\n",
"c = 3e+008; # Speed of light in vacuum, unit\n",
"m0 = 9.1e-031; # Rest mass of the electron, kg\n",
"m = 1.67e-027; # Rest mass of the proton, kg\n",
"\n",
"#Calculations\n",
"# As m = m0/sqrt(1-v^2/c^2), solving for v\n",
"v = c*sqrt(1-(m0/m)**2); # Velocity of the electron, m/s\n",
"\n",
"#Result\n",
"print \"The velocity of the electron to have its mass equal to mass of the proton = %5.3e m/s\"%v\n"
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "stream",
"stream": "stdout",
"text": [
"The velocity of the electron to have its mass equal to mass of the proton = 3.000e+08 m/s\n"
]
}
],
"prompt_number": 23
},
{
"cell_type": "heading",
"level": 2,
"metadata": {},
"source": [
"Example 1.17, Page 35"
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"from math import *\n",
"\n",
"#Variable declaration\n",
"c = 3e+008; # Speed of light in vacuum, unit\n",
"m0 = 9.1e-031; # Rest mass of the electron, kg\n",
"E_k = 0.1*1e+006*1.6e-019; # Kinetic energy of the electron, J\n",
"\n",
"#Calculations&Results\n",
"v = sqrt(2*E_k/m0); # Classical speed of the electron, m/s\n",
"print \"The classical speed of the electron = %5.3e m/s\"%v\n",
"# As E_k = (m-m0)*c^2 = (1/sqrt(1-v^2/c^2)-1)*m0*c^2, solving for v\n",
"v = c*sqrt(1-(m0*c**2/(E_k+m0*c**2))**2); # Relativistic speed of the electron, m/s\n",
"print \"The relativistic speed of the electron = %5.3e m/s\"%v\n"
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "stream",
"stream": "stdout",
"text": [
"The classical speed of the electron = 1.875e+08 m/s\n",
"The relativistic speed of the electron = 1.644e+08 m/s\n"
]
}
],
"prompt_number": 24
}
],
"metadata": {}
}
]
}
|