summaryrefslogtreecommitdiff
path: root/sample_notebooks/NirenNegandhi/ch2_2.ipynb
blob: 9f685b2b3cf51b6c3cdd3119b8374610e544bb6d (plain)
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
{
 "metadata": {
  "name": "",
  "signature": "sha256:93b6ee47cf464df569e4895dab3158be49c4f81380cffe2b4a954430fff24e01"
 },
 "nbformat": 3,
 "nbformat_minor": 0,
 "worksheets": [
  {
   "cells": [
    {
     "cell_type": "heading",
     "level": 1,
     "metadata": {},
     "source": [
      "Chapter 2: Nuclear Models"
     ]
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 2.2.1, Page 66"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "#Variable declaration\n",
      "# For Ca(20,40), actual binding energy is ...... \n",
      "m_p = 1.007825; # Mass of proton, amu\n",
      "m_n = 1.008665; # Mass of neutron, amu\n",
      "Z = 20; # Number of protons\n",
      "N = 20;  # Number of neutrons\n",
      "M_n = 39.962591; # Mass of the nucleus, amu\n",
      "B_actual = (M_n-Z*m_p-N*m_n)*931.49; # Actual binding energy, MeV\n",
      "# For Ca(20,40), Binding energ as per semiemperical mas formula......\n",
      "Z = 20; # Number of protons\n",
      "a_v = 15.5; # Volume constant, MeV\n",
      "a_s = 16.8; # Surface constant, MeV\n",
      "a_a = 23.0; # Asymmetric constant, MeV\n",
      "a_c = 0.7; # Coulomb constant, MeV\n",
      "a_p = 34.0; # Paring constant, MeV\n",
      "A = 40; # Mass number\n",
      "\n",
      "#Calculations\n",
      "B_semi = (a_v*A-(a_s*A**(2./3))-(a_c*Z*(Z-1)/A**(1./3))-(a_a*(A-2*Z)**2/A)-(a_p*A**(-3./4))); # Binding energy as per semiemperical mass formula\n",
      "# Percentage discrepancy between actual and semiemperical mass formula values are.......\n",
      "Per_des = -(B_semi+B_actual)/B_actual*100; # Percentage discrepancy \n",
      "\n",
      "#Result\n",
      "print \"Actual binding energy = %6.2f MeV\\nBinding energy as per semiemperical mass formula = %6.2f MeV\\nPercentage discrepancy = %.2f percent\"%(B_actual, B_semi, Per_des)\n",
      "\n",
      "#answers vary due to rounding-off errors"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "Actual binding energy = -342.05 MeV\n",
        "Binding energy as per semiemperical mass formula = 343.59 MeV\n",
        "Percentage discrepancy = 0.45 percent\n"
       ]
      }
     ],
     "prompt_number": 1
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 2.2.2, Page 67"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "#Variable declaration \n",
      " # Calculation of coulomb energy for mirror nuclei : N-7 and O-8\n",
      " # For N-7 nucleus\n",
      "a_c = 0.7; # Coulomb energy constant, MeV\n",
      "Z_N = 7;  #  Atpmic no. \n",
      "A = 15; # Atomic mass\n",
      "E_C_N = a_c*Z_N*(Z_N-1)/(A**(1./3)); # Coulomb energy for N-7, MeV\n",
      "# For O-8 nucleus\n",
      "a_c = 0.7; # Coulomb energy constant, MeV\n",
      "Z_O = 8;  #  Atpmic no. \n",
      "A = 15.; # Atomic mass\n",
      "\n",
      "#Calculations\n",
      "E_C_O = a_c*Z_O*(Z_O-1)/(A**(1./3)); # Coulomb energy for O-8, MeV\n",
      "C_E_d = E_C_O-E_C_N; # Coulomb energy difference, MeV\n",
      "m_p = 1.007276*931.49; # Mass of proton, MeV\n",
      "m_n = 1.008665*931.49; # Mass of neutron, MeV\n",
      "M_d = m_n-m_p; # Mass difference of nucleons, MeV \n",
      "D_C_M = round(C_E_d-M_d); # Difference in coulomb energy and nucleon mass difference, MeV\n",
      "M_O = 15.003070*931.49; # Mass of O-8, MeV\n",
      "M_N = 15.000108*931.49; # Mass of N-7, MeV\n",
      "D_A = (M_O-M_N); # Actual mass difference, MeV\n",
      "\n",
      "#Result\n",
      "print \"Difference in Coulomb energy = %5.3f MeV\\nNucleon mass difference  = %6.4f MeV\\nDifference in Coulomb energy and nucleon mass difference = %5.3f MeV\\nActual mass difference = %.3f MeV\"%(C_E_d, M_d ,D_C_M, D_A)\n",
      "if D_A == D_C_M:\n",
      "    print \"Result is verified\"\n",
      "\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "Difference in Coulomb energy = 3.974 MeV\n",
        "Nucleon mass difference  = 1.2938 MeV\n",
        "Difference in Coulomb energy and nucleon mass difference = 3.000 MeV\n",
        "Actual mass difference = 2.759 MeV\n"
       ]
      }
     ],
     "prompt_number": 2
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 2.2.3, Page 68"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "#Variable declaration&Calculations\n",
      "# For Kr-80,  \n",
      "m_p = 1.007825; # Mass of proton, amu\n",
      "m_n = 1.008665; # Mass of neutron, amu\n",
      "Z = 36; # Number of protons\n",
      "N_80 = 44;  # Number of neutrons\n",
      "M_n_80 = 79.91628; # Mass of Kr nucleus\n",
      "BE_Kr_80 = (Z*m_p+N_80*m_n-M_n_80)*931.49; #  Binding energy for Kr-80, MeV\n",
      "# For Kr-81,\n",
      "N_81 = 45; # Number of neutrons\n",
      "M_n_81 = 80.91661; # Mass of Kr-81 nucleus\n",
      "BE_Kr_81 = (Z*m_p+N_81*m_n-M_n_81)*931.49; # Binding energy for Kr-81 nucleus\n",
      "# For Kr-82\n",
      "N_82 = 46;  # Number of neutrons\n",
      "M_n_82 = 81.913482; # Mass of Kr nucleus\n",
      "BE_Kr_82 = (Z*m_p+N_82*m_n-M_n_82)*931.49;  # Binding energy for Kr-82,MeV\n",
      "# For Kr-83 \n",
      "N_83 = 47; # Number of protons\n",
      "M_n_83 = 82.914134; # Mass of Kr-83 nucleus\n",
      "BE_Kr_83 = (Z*m_p+N_83*m_n-M_n_83)*931.49; # Binding energy for Kr-83, MeV\n",
      "E_sep_81 = BE_Kr_81-BE_Kr_80; # Energy seperation of neutron for Kr-81, MeV\n",
      "E_sep_82 = BE_Kr_82-BE_Kr_81; # Energy seperation of neutron for Kr-82, MeV\n",
      "E_sep_83 = BE_Kr_83-BE_Kr_82; # Energy seperation of neutron for Kr-83, MeV\n",
      "\n",
      "#Result\n",
      "print \"Energy seperation of neutron for Kr-81 = %4.2f MeV\\nEnergy seperation of neutron for Kr-82 = %4.2f MeV\\nEnergy seperation of  neutron for Kr-83 = %5.2f MeV\"%(E_sep_81, E_sep_82, E_sep_83)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "Energy seperation of neutron for Kr-81 = 7.76 MeV\n",
        "Energy seperation of neutron for Kr-82 = 10.99 MeV\n",
        "Energy seperation of  neutron for Kr-83 =  7.46 MeV\n"
       ]
      }
     ],
     "prompt_number": 3
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 2.2.4, Page 68"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "import sympy\n",
      "from sympy.solvers import solve\n",
      "from sympy import Symbol\n",
      "\n",
      "#Variable declaration\n",
      "a_v = 15.5; # Volume energy coefficient, MeV\n",
      "a_s = 16.8; # Surface energy coefficient MeV\n",
      "a_c = 0.7; # Coulomb energy coefficient, MeV\n",
      "a_a = 23.0; # Asymmetric energy coefficient, MeV\n",
      "a_p = 34.0; # Pairing energy coefficient, MeV\n",
      "A = 75; #  Given atomic mass \n",
      "\n",
      "#Calculations\n",
      "z = Symbol('z')\n",
      "B =solve((((-a_c*(2*z-1))/A**1./3)+((4*a_a*(A-2*z))/A)),z) # Binding energy as per liquid drop model\n",
      "\n",
      "#Result\n",
      "print \"Most stable isotope of A = 75 corresponds to Z = %.d\"%B[0]\n",
      "\n",
      "#answer varies due to usage of sympy module"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "Most stable isotope of A = 75 corresponds to Z = 37\n"
       ]
      }
     ],
     "prompt_number": 4
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 2.2.5, Page 69"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "import sympy\n",
      "from sympy.solvers import solve\n",
      "from sympy import Symbol\n",
      "\n",
      "#Variable declaration\n",
      "a_v = 15.5; # Volume energy, MeV \n",
      "a_s = 16.8; # Surface energy, MeV \n",
      "a_c = 0.7; # Coulomb energy, MeV\n",
      "a_a = 23.0; # Asymmetric energy, MeV\n",
      "a_p = 34.0; # Pairing energy, MeV\n",
      "\n",
      "z = Symbol('z')\n",
      "A = 27\n",
      "#Calculations\n",
      "# For A = 27;\n",
      "A = 27\n",
      "Z_27 = ((4*a_a)+(a_c/A**1./3))/(((2*a_c)/A**1./3)+(8*a_a/A))\n",
      "\n",
      "# For A = 118 \n",
      "A = 118\n",
      "Z_118 = ((4*a_a)+(a_c/A**1./3))/(((2*a_c)/A**1./3)+(8*a_a/A))\n",
      "\n",
      "# For A = 238\n",
      "A = 238\n",
      "Z_238 = ((4*a_a)+(a_c/A**1./3))/(((2*a_c)/A**1./3)+(8*a_a/A))\n",
      "\n",
      "#Result\n",
      "print \"Most stable isotopes for A = 27, A = 118, A = 238 corresponds to z = %d, %d and %d respectively\"%(Z_27, Z_118, Z_238)\n",
      "\n",
      "#Incorrect answers in the textbook"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "Most stable isotopes for A = 27, A = 118, A = 238 corresponds to z = 13, 58 and 118 respectively\n"
       ]
      }
     ],
     "prompt_number": 5
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 2.2.6, Page 69"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "#Variable declaration\n",
      "# Mirror nuclei : Na-11 and Mg-12 \n",
      "m_p = 1.007276; #  Mass of proton, amu\n",
      "m_n = 1.008665; # Mass of neutron, amu\n",
      "M_Mg  = 22.994124; #  Atomic mass of Mg-12, amu\n",
      "M_Na = 22.989768; # Atomic mass of Na-11, amu\n",
      "A = 23; # Mass number\n",
      "Z_Mg = 12; # Atomic number of Mg-12\n",
      "e = 1.6e-019; # Charge of the electron, C\n",
      "K = 8.98e+09; # Coulomb force constant\n",
      "\n",
      "#Calculations\n",
      "a_c = A**(1./3)/(2*Z_Mg-1)*((M_Mg-M_Na)+(m_n-m_p))*931.47; # Coulomb coefficient, MeV \n",
      "r_0 = 3./5*K*e**2/(a_c*1.6e-013); # Nuclear radius, m\n",
      "\n",
      "#Result\n",
      "print \"Coulomb coefficient = %4.2f MeV\\nNuclear radius = %3.1e m\"%(a_c, r_0)"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "Coulomb coefficient = 0.66 MeV\n",
        "Nuclear radius = 1.3e-15 m\n"
       ]
      }
     ],
     "prompt_number": 6
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 2.2.7, Page 71"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "#Variable declaration\n",
      "Z = 92; # Atomic number of U-236\n",
      "e = 1.6e-019; # Charge of an electron, C\n",
      "A = 236; # Mass number of U-236\n",
      "K = 8.98e+09; # Coulomb constant,\n",
      "r_o = 1.2e-015; # Distance of closest approach, m\n",
      "a_s = -16.8; # Surface constant\n",
      "\n",
      "#Calculations\n",
      "E_c = -(3*K*Z*(Z-1)*e**2)/(5*r_o*A**(1./3)*1.6e-013); # Coulomb energy, MeV\n",
      "E_s = a_s*A**(2./3); # Surface energy, MeV   \n",
      "\n",
      "#Result\n",
      "print \"Coulomb energy for U(92,236)  = %5.1f MeV \\nSurface energy for U(92,236) = %5.1f MeV  \"%(E_c, E_s)"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "Coulomb energy for U(92,236)  = -973.3 MeV \n",
        "Surface energy for U(92,236) = -641.6 MeV  \n"
       ]
      }
     ],
     "prompt_number": 8
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 2.3.1, Page 126"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "import math\n",
      "#Variable declaration\n",
      "t_prime =  1600; # Half life of radioactive material, years\n",
      "t = 2000; # Total time, years\n",
      "lamda = 0.6931/t_prime; # Decay constant, years^(-1)\n",
      "m0 = 1; # The mass of radioactive substance at t0, mg\n",
      "\n",
      "#Calculations\n",
      "m = m0* math.exp(-(lamda*t)); # Ratio of total number of atoms and number of atoms disintegrat, mg\n",
      "a = 1-m; # The amount of radioactive substance decayed, mg \n",
      "\n",
      "#Result\n",
      "print \"The amount of radioactive substance decayed : %6.4f mg\"%a\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "The amount of radioactive substance decayed : 0.5795 mg\n"
       ]
      }
     ],
     "prompt_number": 9
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 2.3.4, Page 126"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "import math\n",
      "#Variable declaration\n",
      "t_prime =  1600; # Half life of radioactive material, years\n",
      "t = 2000; # Total time, years\n",
      "lamda = 0.6931/t_prime; # Decay constant, years^(-1)\n",
      "m0 = 1; # The mass of radioactive substance at t0, mg\n",
      "\n",
      "#Calculations\n",
      "m = m0* math.exp(-(lamda*t)); # Ratio of total number of atoms and number of atoms disintegrat, mg\n",
      "a = 1-m; # The amount of radioactive substance decayed, mg \n",
      "\n",
      "#Result\n",
      "print \"The amount of radioactive substance decayed : %6.4f mg\"%a\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "The amount of radioactive substance decayed : 0.5795 mg\n"
       ]
      }
     ],
     "prompt_number": 10
    }
   ],
   "metadata": {}
  }
 ]
}