summaryrefslogtreecommitdiff
path: root/Engineering_Physics_Marikani/Chapter_9.ipynb
blob: 4524cd7cc5cb466f7efb984fb4219b74c3da2bfe (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
{
 "metadata": {
  "name": "Chapter 9"
 },
 "nbformat": 3,
 "nbformat_minor": 0,
 "worksheets": [
  {
   "cells": [
    {
     "cell_type": "heading",
     "level": 1,
     "metadata": {},
     "source": "Semiconducting materials"
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": "Example number 9.1, Page number 266"
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": "#To calculate the number of charge carriers\n\n#Variable declaration\nmew_e=0.36;    #mobility of electrons in m^2/Vs\nmew_h=0.14;    #mobility of holes in m^2/Vs\nsigma=2.2;    #conductivity in ohm-1 m-1\nT=300;     #temperature in K\ne=1.6*10**-19;   #electron charge in C\n\n#Calculation\nni=sigma/(e*(mew_e+mew_h));    #carrier concentration per m^3\n\n#Result\nprint(\"carrier concentration of an intrinsic semiconductor per m^3 is\",ni);",
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": "('carrier concentration of an intrinsic semiconductor per m^3 is', 2.75e+19)\n"
      }
     ],
     "prompt_number": 1
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": "Example number 9.2, Page number 266"
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": "#To calculate the band gap\n\n#importing modules\nimport math\nimport numpy as np\nfrom __future__ import division\n\n#Variable declaration\nT1=20;    #temperature in C\nT2=100;    #temperature in C\nsigma_i20=250;     #conductivity in ohm-1 m-1\nsigma_i100=1100;     #conductivity in ohm-1 m-1\nk=1.38*10**-23;\n\n#Calculation\nT1K=T1+273;     #temperature in K\nT2K=T2+273;     #temperature in K\nT_1K=T1K**(-1);\nT_2K=T2K**(-1);\nT_1=T_2K-T_1K;\nT_2=T2K/T1K;\nTk=T_1**(-1);\nT_k=(T_2)**(3/2);\n#intrinsic carrier concentration at T1K is ni20 = 2*((2*math.pi*k*m*293)/h**2)**(3/2)*((me*mh)/m**2)**(3/4)*math.exp(-Eg/(2*k*293))\n#intrinsic carrier concentration at T2K is ni100 = 2*((2*math.pi*k*m*373)/h**2)**(3/2)*((me*mh)/m**2)**(3/4)*math.exp(-Eg/(2*k*373))\n#dividing ni20/ni100 = (293/373)**(3/2)*(math.exp(-Eg/(2*k*293))/math.exp(-Eg/(2*k*373)))\n#ni20/ni100 = (293/373)**(3/2)*math.exp((-Eg/(2*k))((1/293)-(1/373)))\n#sigma_i20/sigma_i100 = (ni20*e*(mew_e+mew_h))/(ni100*e*(mew_e+mew_h)) = ni20/ni100\n#therefore sigma_i20/sigma_i100 = ni20/ni100 = (293/373)**(3/2)*math.exp((-Eg/(2*k))((1/293)-(1/373)))\n#math.exp((-Eg/(2*k))*((1/293)-(1/373))) = (sigma_i20/sigma_i100)*(373/293)**(3/2)\n#by taking log on both sides we get (-Eg/(2*k))*((1/293)-(1/373)) = np.log((sigma_i20/sigma_i100)*(373/293)**(3/2))\n#Eg=2*k*(((1/373)-(1/293))**(-1))*np.log((sigma_i20/sigma_i100)*(373/293)**(3/2))\nEg=2*k*Tk*np.log((sigma_i20/sigma_i100)*T_k);   #band gap in J\nEgeV=Eg*6.241*10**18;    #converting J to eV\nEgeV=math.ceil(EgeV*10**4)/10**4;   #rounding off to 4 decimals\n\n#Result\nprint(\"band gap of the semiconductor in J is\",Eg);\nprint(\"band gap of the semiconductor in eV is\",EgeV);\n\n#answer for band gap in eV given in the book is wrong in the 4th decimal point",
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": "('band gap of the semiconductor in J is', 4.2210259829756855e-20)\n('band gap of the semiconductor in eV is', 0.2635)\n"
      }
     ],
     "prompt_number": 3
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": "Example number 9.3, Page number 267"
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": "#To calculate the Hall voltage\n\n#Variable declaration\nI=10**-2;    #current in Ampere\nl=100;    #length in mm\nd=1;     #thickness in mm\nw=10;    #breadth in mm\nB=0.5;   #magnetic field in Wb/m^2\nRH=3.66*10**-4;    #hall coefficient in m^3/C\n\n#Calculation\nw=w*10**-3;    #width in m\nVH=(B*I*RH)/w;    #hall voltage\nVH=VH*10**4;\n\n#Result\nprint(\"Hall voltage in V is\",VH,\"*10**-4\");",
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": "('Hall voltage in V is', 1.83, '*10**-4')\n"
      }
     ],
     "prompt_number": 1
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": "Example number 9.4, Page number 268"
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": "#To calculate the concentration of holes and electrons\n\n#importing modules\nimport math\n\n#Variable declaration\nsigma=300;   #conductivity in S/cm\nT=300;   #temperature in K\nni=1.5*10**10    #carrier concentration per cm^3\nmew_e=1300;   #mobility of electrons in cm^2/Vs\nmew_h=500;    #mobility of holes in cm^2/Vs\ne=1.6*10**-19;    #electron charge in C\n\n#Calculation\nsigma=sigma*10**2;    #sigma in S/m\nmew_e=mew_e*10**-4;   #mobility of electrons in m^2/Vs\nND=sigma/(e*mew_e);   #concentration of electron per m^3\nni=ni*10**6;         #carrier concentration per m^3\np=ni**2/ND;     #hole concentration per m^3\np=p/10**8;\np=math.ceil(p*10**3)/10**3;   #rounding off to 3 decimals\nmew_h=mew_h*10**-4;    #mobility of holes in m^2/Vs\nNA=sigma/(e*mew_h);   #concentration of hole per m^3\nn=ni**2/NA;     #electron concentration per m^3\nn=n/10**7;\n\n#Result\nprint(\"concentration of electron for N-type semiconductor per m^3\",ND);\nprint(\"hole concentration per m^3\",p,\"*10**8\");\nprint(\"concentration of hole for P-type semiconductor per m^3\",NA);\nprint(\"electron concentration per m^3\",int(n),\"*10**7\");",
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": "('concentration of electron for N-type semiconductor per m^3', 1.4423076923076921e+24)\n('hole concentration per m^3', 1.561, '*10**8')\n('concentration of hole for P-type semiconductor per m^3', 3.7499999999999995e+24)\n('electron concentration per m^3', 6, '*10**7')\n"
      }
     ],
     "prompt_number": 11
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": "Example number 9.5, Page number 269"
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": "#To find the type of charge carriers and the carrier concentration\n\n#importing modules\nimport math\n\n#Variable declaration\nRH=-3.68*10**-5;    #hall coefficient in m^3/C\ne=1.6*10**-19;    #electron charge in C\n\n#Calculation\n#hall coefficient is negative implies charge carriers are electrons\nn=(3*math.pi)/(8*(-RH)*e);     #carrier concentration\n\n#Result\nprint(\"charge carriers are electrons\");\nprint(\"carrier concentration per m^3 is\",n);",
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": "charge carriers are electrons\n('carrier concentration per m^3 is', 2.000844505937792e+23)\n"
      }
     ],
     "prompt_number": 13
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": "Example number 9.6, Page number 269"
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": "#To compare the intrinsic carrier density\n\n#importing modules\nimport math\nfrom __future__ import division\n\n#Variable declaration\nEg1=0.36;    #energy gap of 1st material in eV\nEg2=0.72;   #energy gap of 2nd material in eV\nT=300;     #temperature in K\nmh=9*10**-31;\nme=9*10**-31; \n#given that 2*k*T=0.052;    \n#consider X=2*k*T\nX=0.052;\n\n#Calculation\n#intrinsic carrier concentration for A niA = 2*((2*math.pi*k*T*m)/h**2)**(3/2)*((me*mh)/m**2)**(3/4)*math.exp(-0.36/(2*k*T))\n#intrinsic carrier concentration for B niB = 2*((2*math.pi*k*T*m)/h**2)**(3/2)*((me*mh)/m**2)**(3/4)*math.exp(-0.72/(2*k*T))\n#dividing niA/niB = math.exp(-0.36/(2*k*T))*math.exp(0.72/(2*k*T))\n#let niA/niB be A\nA = math.exp(-0.36/X)*math.exp(0.72/X);\nA=A/10**3;\nA=math.ceil(A*10**5)/10**5;   #rounding off to 5 decimals\n\n#Result\nprint(\"ratio of intrinsic carrier densities of A and B is\",A,\"*10**3\");",
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": "('ratio of intrinsic carrier densities of A and B is', 1.01544, '*10**3')\n"
      }
     ],
     "prompt_number": 16
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": "Example number 9.7, Page number 270"
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": "#To calculate the mobility of electrons\n\n#importing modules\nimport math\n\n#Variable declaration\nND=2*10**22;     #concentration of electron per m^3\nsigma=112;     #conductivity in ohm-1 m-1\ne=1.6*10**-19;    #electron charge in C\n\n#Calculation\nmew=sigma/(ND*e);    #mobility of electrons \nmew=math.ceil(mew*10**3)/10**3;   #rounding off to 3 decimals\n\n#Result\nprint(\"mobility of electrons in m^2/Vs is\",mew);",
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": "('mobility of electrons in m^2/Vs is', 0.035)\n"
      }
     ],
     "prompt_number": 17
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": "Example number 9.8, Page number 270"
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": "#To calculate the Hall voltage\n\n#importing modules\nimport math\n\n#Variable declaration\nw=500;     #thickness  in micrometre\nA=2.5*10**-3;    #area of cross section in cm^-2\nIx=1;     #current in ampere\nBz=10;    #magnetic field in Wb/cm^2\nn=10**16;    #donor concentration in m^-3\ne=1.6*10**-19;    #electron charge in C\n\n#Calculation\nBz=Bz*10**-4;    #magnetic field in Wb/m^2\nw=w*10**-6;    #thickness in m\nRH=(3*math.pi)/(8*n*e);     #hall coefficient\nVH=(Bz*Ix*RH)/w;    #hall voltage\nVH=VH/10**3;\nVH=math.ceil(VH*10**4)/10**4;   #rounding off to 4 decimals\n\n#Result\nprint(\"hall voltage in V is\",VH,\"*10**3\");",
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": "('hall voltage in V is', 1.4727, '*10**3')\n"
      }
     ],
     "prompt_number": 23
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": "Example number 9.9, Page number 271"
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": "#To find the ratio between conductivity of intrinsic semiconductor\n\n#importing modules\nimport math\nfrom __future__ import division\nimport numpy as np\n\n#Variable declaration\nEg=1.2;    #energy gap in eV\nT1=300;    #temperature in K\nT2=600;    #temperature in K\nk=1.38*10**-23;\n\n#Calculation\nT_1=T1**(-1);\nT_2=T2**(-1);\nT=T_1-T_2;\nEg=Eg*1.602*10**-19;    #Eg in J\n#sigma_300=ni300*e*(mew_e+mew_h)\n#sigma_600=ni600*e*(mew_e+mew_h)\n#sigma_600/sigma_300 = ni600/ni300\n#ni600/ni300 =((T2/T1)**(3/2))*math.exp(-Eg/(2*k*T2))*math.exp(Eg/(2*k*T1));\n#ni600/ni300 =((T2/T1)**(3/2))*math.exp((Eg/(2*k))*T;\n#let ni600/ni300 be X\nX=((T2/T1)**(3/2))*math.exp((Eg/(2*k))*T);\n\n\n#Result\nprint(\"ratio between the conductivity of material is\",int(X));\n\n#answer given in the book is wrong",
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": "('ratio between the conductivity of material is', 311270)\n"
      }
     ],
     "prompt_number": 25
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": "Example number 9.10, Page number 272"
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": "#To calculate the intrinsic carrier concentration\n\n#importing modules\nimport math\n\n#Variable declaration\nsigma=10**-6;    #electrical conductivity in ohm-1 m-1\nmew_e=0.85;    #electron mobility in m^2/Vs\nmew_h=0.04;    #hole mobility in m^2/Vs\ne=1.6*10**-19;    #electron charge in C\n\n#Calculation\nni=sigma/(e*(mew_e+mew_h));     #intrinsic carrier concentration\nni=ni/10**12;\nni=math.ceil(ni*10**4)/10**4;   #rounding off to 4 decimals\n\n#Result\nprint(\"intrinsic carrier concentration per m^3 is\",ni,\"*10**12\");",
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": "('intrinsic carrier concentration per m^3 is', 7.0225, '*10**12')\n"
      }
     ],
     "prompt_number": 27
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": "Example number 9.11, Page number 272"
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": "#To calculate the density of impurity atoms and concentration of minority carriers\n\n#importing modules\nimport math\n\n#Variable declaration\nrho_p=10;   #resistivity of p-type Si in ohm cm\nrho_n=10;   #resistivity of n-type Si in ohm cm\nmew_e=1350;   #electron mobility in cm^2/Vs\nmew_h=480;    #hole mobility in cm^2/Vs\nni=1.5*10**10;    #carrier concentration in cm^-3\ne=1.6*10**-19;    #electron charge in C\n\n#Calculation\nrho_p=rho_p*10**-2;#resistivity of p-type Si in ohm m\nsigma_p=1/rho_p;   #electrical conductivity\nmew_h=mew_h*10**-3;\nNA=sigma_p/(e*mew_h);   #acceptor concentration\nni=ni*10**6;    #carrier concentration in m^-3\nn=ni**2/NA;    #concentration of minority carriers in m^-3\nn=n/10**12;\nn=math.ceil(n*10**4)/10**4;   #rounding off to 4 decimals\nrho_n=rho_n*10**-2;      #resistivity of n-type Si in ohm m\nsigma_n=1/rho_n;   #electrical conductivity\nmew_e=mew_e*10**-3;\nND=sigma_n/(e*mew_e);   #donor concentration\np=(ni**2)/ND;    #concentration of minority carriers in m^-3\np=p/10**12;\np=math.ceil(p*10**3)/10**3;   #rounding off to 3 decimals\n\n#Result\nprint(\"donor concentration per m^3 is\",ND);\nprint(\"concentration of minority carriers per m^3\",p,\"*10**12\");\nprint(\"acceptor concentration per m^3 is\",NA);\nprint(\"concentration of minority carriers per m^3 is\",n,\"*10**12\");",
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": "('donor concentration per m^3 is', 4.6296296296296284e+19)\n('concentration of minority carriers per m^3', 4.861, '*10**12')\n('acceptor concentration per m^3 is', 1.3020833333333331e+20)\n('concentration of minority carriers per m^3 is', 1.7281, '*10**12')\n"
      }
     ],
     "prompt_number": 33
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": "",
     "language": "python",
     "metadata": {},
     "outputs": []
    }
   ],
   "metadata": {}
  }
 ]
}