#importing module
import math
from __future__ import division
#Variable declaration
Nd=5*10**16 #in cm**-3
Na=10**19 #in cm**-3
d=1.2*10**-4 #in cm
e=1.6*10**-19# in J
epsilon_r=11.7 #in F/cm
epsilon_0=8.85*10**-14 #in F/cm
L=18*10**-4 #in cm
W=80*10**-4 #in micro-W
myu_n=1350 #in cm**2/V*s
ni=1.5*10**10 #in cm**3
VGS=0 #in V
Const=0.026 #constant for kT/e in V
#Calculations
Vp=(e*Nd*d**2)/(2*epsilon_r*epsilon_0) #Pitch-off voltage in V
Ip=(W*myu_n*e**2*Nd**2*d**3)/(epsilon_r*epsilon_0*L) #Pitch-off current in A
Vbi=Const*math.log((Na*Nd)/ni**2) #in V
ID=Ip*(1/3-((VGS+Vbi)/Vp)+(2/3)*((VGS+Vbi)/Vp)**3/2)
#Result
print("a) Pitch-off voltage= %1.1f V\n" %Vp)
print("b) Pitch-off current= %.1f*10**-3 A\n" %(Ip*10**3))
print("c) Drain current at pinch-off= %i*10**-3 A" %(ID*10**3)) #The answers vary dueto round off error
#importing module
import math
from __future__ import division
#Variable declaration
e=1.6*10**-19 #in eV
epsilon_r=13.1 #in F/cm
epsilon_0=8.85*10**-14 #in F/cm
Nc=4.7*10**17 #in cm**-3
Nd=3*10**15 #in cm**-3
phi_Bn=0.9 #barrier height in V
VT=0.3 #threshold voltage in V
Const=0.026 #constant for kT/e in V
#Calculations
phi_n=Const*math.log(Nc/Nd) #in V
Vbi=phi_Bn-phi_n #built-in voltage in V
Vp=Vbi-VT #pinch-off voltage in V
d=math.sqrt((2*epsilon_r*epsilon_0*Vp)/(e*Nd))
#Result
print("Channel thickness= %0.3f micro-m" %round(d/10**-4,3))
#importing module
import math
from __future__ import division
#Variable declaration
e=1.6*10**-19 #in J
epsilon_r=11.7 #in F/cm
epsilon_0=8.85*10**-14 #in F/cm
Na=5*10**16 #in cm**-3
ni=1.5*10**10 #in cm**-3
Const=0.026 #constant for kT/e in V
#Calculations
phi_pF=Const*math.log(Na/ni) #in V
WdT=((4*epsilon_r*epsilon_0*phi_pF)/(e*Na))**0.5
#Result
print("Maximum space-charge width= %0.3f micro-meter" %round(WdT/10**-4,3))
#The answer provided in the textbook is wrong
#importing module
import math
from __future__ import division
#Variable declaration
phi_m=3.20 #in V
Na=10**15 #in cm**-3
ni=1.5*10**10 #in cm**-3
x=3.25
Eg=1.11 #in eV
e=1.6*10**-19 #in J
Const=0.026 #constant for kT/e in V
#Calculations
phi_pF=Const*math.log(Na/ni) #in V
phi_ms=(phi_m-(x+(Eg/2)+phi_pF))
#Result
print("work-function difference= %0.3f V" %phi_ms)
#importing module
import math
from __future__ import division
#Variable declaration
ID_sat=5*10**-3 #in mA
L=1.3*10**-4 #in micro-m
myu_n=660 #in cm**2/V*s
Cox=7*10**-8 #in F/cm**2
VGS=5 #in V
VT=0.66 #in V
#Calculations
Z=(ID_sat*2*L)/(myu_n*Cox*(VGS-VT)**2)
#Result
print("Channel width= %.1f micro-m" %round(Z/10**-4,1))
#importing module
import math
from __future__ import division
#Variable declaration
epsilon_0=8.854*10**-14 #in F/cm
epsilon_r=11.8 #in F/cm
epsilon_i=3.9 #in F/cm
d=100*10**-8 #gate oxide thickness in cm
phi_ms=-1.5 #in V
Qi=5*10**10*1.6*10**-19 #fixed oxide charge in C/cm**2
Na=10**18 #in cm**-3
ni=1.5*10**10 #in cm**-3
e=1.6*10**-19 #in J
VB=2.5 #in V
const=0.0259 #value for kT/e in V
#Calculations
Ci=(epsilon_0*epsilon_i)/d #in F/cm**2
VFB=phi_ms-(Qi/Ci) #in V
phi_F=const*math.log(Na/ni) #in V
W=math.sqrt((2*epsilon_0*epsilon_r*(2*phi_F))/(e*Na)) #in cm
Qd=-e*Na*W #in C
VT=VFB+(2*phi_F)-(Qd/Ci) #in V
Wm=math.sqrt((2*epsilon_0*epsilon_r*((2*phi_F)+VB))/(e*Na)) #in cm
Qd1=-e*Na*Wm #in C
VT1=VFB+(2*phi_F)-(Qd1/Ci) #in V
#Result
print("Voltage of n-channel Si(1)= %1.2f V\n" %VT)
print("Voltage of n-channel Si(2)= %1.3f V" %VT1) #The answers vary due to round off error
#importing module
import math
from __future__ import division
#Variable declaration
epsilon_0=8.854*10**-14 #in F/cm
epsilon_r=11.8 #in F/cm
epsilon_i=3.9 #in F/cm
d=80*10**-8 #gate oxide thickness in cm
phi_ms=-0.15 #work-function difference in V
Qi=10**11*1.6*10**-19 #fixed oxide charge in C/cm**2
Nd=5*10**17 #in cm**-3
ni=1.5*10**10 #in cm**-3
e=1.6*10**-19 #in J
const=0.0259 #value for kT/e in V
#Calculations
phi_F=const*math.log(Nd/ni) #in V
Wm=2*math.sqrt((epsilon_0*epsilon_r*abs(phi_F))/(e*Nd)) #in cm
Qd=e*Nd*Wm #depletion charges in C
Ci=(epsilon_0*epsilon_i)/d #in F/cm**2
VT=phi_ms-(Qi/Ci)-(Qd/Ci)-(2*phi_F)
#Result
print("Voltage of n-channel= %1.2f V" %VT)