summaryrefslogtreecommitdiff
path: root/Solid_state_physics/Chapter_2.ipynb
blob: 99284878570bd075dca614ecf582870302fc08c2 (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
{
 "metadata": {
  "name": "",
  "signature": "sha256:64e1fbee0e1d9b8157cae12a98a7773b847a3c5e842a9d3f124a5485fe931875"
 },
 "nbformat": 3,
 "nbformat_minor": 0,
 "worksheets": [
  {
   "cells": [
    {
     "cell_type": "heading",
     "level": 1,
     "metadata": {},
     "source": [
      "Chapter 2: Crystal Structure"
     ]
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 2.1, Page number 2.16"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "\n",
      "from math import sqrt \n",
      "\n",
      "#Variable declaration\n",
      "#Assuming r=1 for simpliciy in calculations\n",
      "r = 1\n",
      "\n",
      "#Calculations\n",
      "a = (4*r)/sqrt(3)\n",
      "#Let R be the radius of interstitial sphere that can fit into the void,therefore,\n",
      "R = (a-2*r)/2     \n",
      "\n",
      "#Result\n",
      "print \"The maximum radius of interstitial sphere is\",round(R,3),\"r\""
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "The maximum radius of interstitial sphere is 0.155 r\n"
       ]
      }
     ],
     "prompt_number": 2
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 2.2, Page number 2.17"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "\n",
      "from math import sqrt\n",
      "\n",
      "#Variable declaration\n",
      "r1 = 1.258*10**-10   #atomic radius(m)\n",
      "r2 = 1.292*10**-10   #atomic radius(m)\n",
      "\n",
      "#Calculations\n",
      "#In BCC\n",
      "a_bcc = (4*r1)/sqrt(3)\n",
      "v_bcc = a_bcc**3          #volume of unit cell(m^3)\n",
      "n1 = ((1./8.)*8.)+1\n",
      "V1 = v_bcc/n1             #volume occupied by 1 atom(m^3)\n",
      "\n",
      "#In FCC\n",
      "a_fcc = 2*sqrt(2)*r2\n",
      "v_fcc = a_fcc**3          #volume of unit cell(m^3)\n",
      "n2 = ((1./2.)*6.)+((1./8.)*8.)\n",
      "V2 = v_fcc/n2             #volume occupied by 1 atom(m^3)\n",
      "\n",
      "del_v = ((V1-V2)/V1)*100  #change in volume\n",
      "\n",
      "#Result\n",
      "print \"During the conversion of iron from BCC to FCC, the decrease in volume is\",round(del_v,1),\"%\""
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "During the conversion of iron from BCC to FCC, the decrease in volume is 0.5 %\n"
       ]
      }
     ],
     "prompt_number": 3
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 2.3, Page number 2.17"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "\n",
      "from math import sqrt\n",
      "\n",
      "#Variable declaration\n",
      "a = 0.27*10**-9   #nearest neighbour distance(m)\n",
      "c = 0.494*10**-9  #height of unit cell(m)\n",
      "M = 65.37         #atomic weight of zinc\n",
      "N = 6.023*10**26  #Avogadro's number(k/mol)\n",
      "\n",
      "#Calculations\n",
      "V = (3*sqrt(3)*a**2*c)/2  #volume of unit cell\n",
      "rho = (6*M)/(N*V)         #density of crystal\n",
      "\n",
      "#Results\n",
      "print \"Volume of unit cell =\",round((V/1E-29),2),\"*10^29 m^3\"\n",
      "print \"Density of zinc =\",round(rho),\"kg/m^3\"\n",
      "print \"\\nThe solution differs because of rounding-off of the digits in the textbook\""
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "Volume of unit cell = 9.36 *10^29 m^3\n",
        "Density of zinc = 6960.0 kg/m^3\n",
        "\n",
        "The solution differs because of rounding-off of the digits in the textbook\n"
       ]
      }
     ],
     "prompt_number": 4
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 2.4, Page number 2.18"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "\n",
      "from math import sqrt\n",
      "\n",
      "#Varaible declaration\n",
      "#Let r be the radius of atom and R be the radius of sphere\n",
      "#For simplicity in calculations, let us assume r =1\n",
      "r = 1\n",
      "\n",
      "#Calculations\n",
      "#For FCC structure\n",
      "a = (4*r)/sqrt(2)\n",
      "R = (a/2)-r\n",
      "\n",
      "print \"Maximum radius of sphere =\",round(R,3),\"r\""
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "Maximum radius of sphere = 0.414 r\n"
       ]
      }
     ],
     "prompt_number": 5
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 2.5, Page number 2.19"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "\n",
      "#Variable declaration\n",
      "a = 0.356*10**-9  #cube edge(m)\n",
      "M = 12.01         #atomic weight of carbon\n",
      "N = 6.023*10**26  #Avogadro's number(k/mol)\n",
      "na = 1.77*10**29  #no. of atoms per meter cube\n",
      "\n",
      "#Calculations\n",
      "#Diamond has 2 interpenetrating FCC lattices. Since each FCC unit cell has 4 atoms, the total no. of atoms per unit cell is 8\n",
      "n = 8/a**3\n",
      "m = M/N\n",
      "rho = m*na\n",
      "\n",
      "#Result\n",
      "print \"Number of atoms =\",round((n/1E+29),3),\"*10^29\"\n",
      "print \"The density of diamond is\",round(rho,1),\"kg/m^3(Calculation mistake in the textbook)\""
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "Number of atoms = 1.773 *10^29\n",
        "The density of diamond is 3529.4 kg/m^3(Calculation mistake in the textbook)\n"
       ]
      }
     ],
     "prompt_number": 58
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 2.6, Page number 2.19"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "\n",
      "#Variable declaration\n",
      "rho = 2.18  #density of NaCl(gm/cm^3)\n",
      "N = 6.023*10**23  #Avogadro's number(/mol)\n",
      "\n",
      "#Caculations\n",
      "w = 23+35.5  #molecular weight of NaCl\n",
      "m = w/N      #mass of NaCl molecule\n",
      "nm = rho/m    #no. of molecules per unit volume(molecule/cm^3)\n",
      "#Since NaCl is diatomic\n",
      "n = 2*nm\n",
      "#Let a be the distance between adjacent atoms in NaCl and\n",
      "#    n be the no. of atoms along the edge of the cube\n",
      "#length of an edge = na\n",
      "#volume of unit cube = n^3*a^3\n",
      "a = (1/n)**(1./3.)\n",
      "\n",
      "#Result\n",
      "print \"The distance between two adjacent atoms is\",round((a/1E-8),2),\"A\""
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "The distance between two adjacent atoms is 2.81 A\n"
       ]
      }
     ],
     "prompt_number": 4
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 2.7, Page number 2.20"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "\n",
      "from math import sqrt\n",
      "\n",
      "#Variable declaration\n",
      "w = 63.5           #atomic weight of copper\n",
      "r = 1.278*10**-8   #atomic rdius(m)\n",
      "N = 6.023*10**23   #Avogadro's number(/mol)\n",
      "\n",
      "#Calculations\n",
      "m = w/N    #mass of each copper atom(gm)\n",
      "#Since copper has FCC structure lattice constant\n",
      "a = (4*r)/sqrt(2) \n",
      "n = 4      #no. of atoms in unit cell of FCC structure\n",
      "M = n*m    #mass of unit cell\n",
      "rho = M/a**3  #density\n",
      "\n",
      "#Result\n",
      "print \"Density of copper =\",round(rho,2),\"gm/cm^3\""
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "Density of copper = 8.93 gm/cm^3\n"
       ]
      }
     ],
     "prompt_number": 3
    }
   ],
   "metadata": {}
  }
 ]
}