summaryrefslogtreecommitdiff
path: root/A_Textbook_Of_Engineering_Physics/Chapter16.ipynb
blob: 0852b1beddb35f3ee4f674e5401c7bb5b6e21f8c (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
{
 "metadata": {
  "name": "",
  "signature": "sha256:d811f941685df0c27130d7c823a224d6aa75e253b0c49d58341e9220ca07cdb5"
 },
 "nbformat": 3,
 "nbformat_minor": 0,
 "worksheets": [
  {
   "cells": [
    {
     "cell_type": "heading",
     "level": 1,
     "metadata": {},
     "source": [
      "Chapter16-Structure of Solids"
     ]
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Ex1-pg483"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "import math\n",
      "##Example 16.1\n",
      "##calculation of density\n",
      "\n",
      "##given values\n",
      "a=3.36*10**-10;##lattice constant in m\n",
      "M=209.;##atomicmass of polonium in kg\n",
      "N=6.02*10**26;##avogadro's number\n",
      "z=1.;##no of atom\n",
      "##calculation\n",
      "d=z*M/(N*a**3)\n",
      "\n",
      "print'%s %.2f %s'%('density (in kg/m^3) is',d,'');\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "density (in kg/m^3) is 9152.34 \n"
       ]
      }
     ],
     "prompt_number": 7
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Ex2-pg483"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "import math\n",
      "##Example 16.2\n",
      "##calculation of no of atoms\n",
      "\n",
      "##given values\n",
      "a=4.3*10**-10;##edge of unit cell in m\n",
      "d=963.;##density in kg/m**3\n",
      "M=23.;##atomicmass of sodium in kg\n",
      "N=6.02*10**26;##avogadro's number\n",
      "\n",
      "##calculation\n",
      "z=d*N*a**3./M;\n",
      "\n",
      "print'%s %.2f %s'%('no of atoms is',z,'');\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "no of atoms is 2.00 \n"
       ]
      }
     ],
     "prompt_number": 3
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Ex3-pg483"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "import math\n",
      "##Example 16.3\n",
      "##calculation of distance\n",
      "\n",
      "##given values\n",
      "z=4.;##no of atoms in fcc\n",
      "d=2180.;##density in kg/m**3\n",
      "M=23+35.3;##atomicmass of sodium chloride in kg\n",
      "N=6.02*10**26;##avogadro's number\n",
      "\n",
      "##calculation\n",
      "a1=z*M/(N*d);\n",
      "a=a1**(1/3.);\n",
      "l=a/2.;##in m\n",
      "\n",
      "print'%s %.2f %s'%('distance between adjacent chlorine and sodium atoms in armstrong is',l*10**10,'');\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "distance between adjacent chlorine and sodium atoms in armstrong is 2.81 \n"
       ]
      }
     ],
     "prompt_number": 4
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Ex4-pg495"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "import math\n",
      "##Example 16.4\n",
      "##calculation of interatomic spacing\n",
      "\n",
      "##given values\n",
      "alpha=30*math.pi/180.;##Bragg angle in degree\n",
      "h=1;\n",
      "k=1;\n",
      "l=1;\n",
      "m=1;##order of reflection\n",
      "x=1.75*10**-10;##wavelength in m\n",
      "\n",
      "##calculation\n",
      "d=m*x/(2.*math.sin(alpha));\n",
      "a=d*math.sqrt(h**2+k**2+l**2.);##in m\n",
      "\n",
      "print'%s %.2f %s'%('interatomic spacing in armstrong is',a*10**10,'');\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "interatomic spacing in armstrong is 3.03 \n"
       ]
      }
     ],
     "prompt_number": 6
    }
   ],
   "metadata": {}
  }
 ]
}