import math
# Variables
#The probability that a particular quantum state at energy E is filled, is given by
#f(E) = 1/(1+exp(E-E_f)/kT)
e = 1.6*10**(-19); #charge on the electron
dE = 0.5*e; #E-E_f in joule
# Calculation
#0.01 = 1/(1+exp(x))
#1+exp(x) = 100
x = math.log(99);
k = 1.38*10**(-23); #consmath.tant
T = dE/(x*k); #temperature
# Results
print 'temperature at which there is one per cent probability that a state with an energy\
0.5 eV above the Fermi energy will be \noccupied by an electron in = %.0f K'%round(T)
# rounding off error
import math
# Variables
n = 10**19; #electrons per m**3
V = 0.017; #applied voltage
d = 0.27*10**-2; #dismath.tance with material
e = 1.602*10**-19; #in coulomb
m = 9.1*10**-31; #mass of an electron(in kg)
# Calculation
conductivity = 0.01; #in mho.m**-1)
E = V/d; #Electric field(in V/m)
v = (conductivity*E/(n*e))*10**2; #drift velocity of carriers(in meter/sec)
# Results
print 'drift velocity of carriers in = %.2f m/s'%v
import math
# Variables
T = 300; #Temperature(in Kelevin)
t = 2*10**-14; #time(in sec)
V_c = 8.9; #volume of 63.54gm of copper(in cc)
Aw_c = 63.54; #Atomic weight of copper(in a.m.u)
e = 1.6*10**(-19);
m = 9.1*10**-31;
N_a = 6.023*10**23; #avogadro's number
# Calculation
n = (N_a/(Aw_c/V_c))*10**6; #Number of electrons per m**3
conductivity = (e**2)*n*t/m; #conductivity of copper at 300K(in mho/m)
# Results
print 'conductivity of copper at 300K in = %.2e mho/m'%conductivity
# note : answer in book is wrong.
import math
# Variables
t = 10**(-14); #mean free time between the collisions(in second)
e = 1.6*10**-19;
m = 9.1*10**-31;
# Calculation
Mobility = e*t/m; #in m**2/V-s
# Results
print 'mobility of condution electron in = %.2e m**2/V-s'%Mobility
import math
# Variables
n = 6.*10**23; #conduction electron per m**3
conductivity = 6.5*10**7; #in mho/m
E = 1.; #electric field intensity (in V/m)
e = 1.602*10**-19;
m = 9.1*10**-31;
# Calculation
Mobility = conductivity/(n*e); #in m**2/V-s
v = Mobility*E; #drift velocity(in m/sec)
# Results
print 'mobility of condution electron in = %.2e m**2/V-s'%Mobility
print 'drift velocity in = %.2e m/sec'%v
import math
# Variables
d = 10.5; #density of silver(in gm/cc)
At_w = 107.9; #atomic weight
e = 1.6*10**-19;
conductivity = 6.8*10**5; #in mho/centimeter
# Calculation
N = 6.023*10**23;
n = N*d/At_w; #number of free electrons
Mobility = conductivity/(n*e); #mobility of electrons(in cm**2/V-s);
# Results
print 'number of free electrons = %.2e'%n
print 'mobility of electrons in = %.2f cm**2/V-s'%Mobility
# rounding off error
import math
# Variables
E_f = 3.75; #Fermi energy(in eV)
e = 1.602*10**-19;
W_f = e*E_f; #fermi energy in joules
t = 10**-14; #mean free time between the collisions(in second)
# Calculation
m = 9.1*10**-31; #mass of electron
v_f = ((2*W_f)/m)**(1./2); #maximum velocity of an electron in a metal(in m/s)
mobility = e*t/m; #mobility of electrons(in m**2/V-s)
# Results
print 'maximum velocity of an electron in a metal in = %.2e m/s'%v_f
print 'mobility of electrons in = %.2e m**2/V-s'%mobility
# incorrect answer in the textbook
import math
# Variables
E_f = 2.1; #fermi energy(in eV)
e = 1.602*10**-19;
m = 9.1*10**-31;
# Calculation
W_f = e*E_f; #fermi energy in joules
v_f = (2*W_f/m)**(1./2); #velocity of an electrons at fermi level(in m/sec)
# Results
print 'velocity of an electrons at fermi level in = %.1e m/sec'%v_f
import math
# Variables
t = 10**-9; #collision time(in seconds)
E_f = 7; #fermi energy(in eV)
e = 1.6*10**-19;
m = 9.1*10**-31;
# Calculation
W_f = E_f*e; #fermi energy(in joules)
v_f = (2*W_f/m)**(1./2); #velocity of an electrons at fermi level(in m/sec)
P = v_f*t; #Mean free path(in meter)
# Results
print 'Mean free path in = %.2e m'%P
import math
# Variables
N_a = 6.023*10**23;
V_c = 8.9; #volume of 63.54gm of copper(in cc)
Aw_c = 63.54; #Atomic weight of copper(in a.m.u)
# Calculation
n = (N_a/(Aw_c/V_c))*10**6; #Number of electrons per m**3
e = 1.6*10**-19;
m = 9.1*10**-31;
t = 2*10**-14; #collision time
conductivity = n*(e**2)*t/m; #conductivity of copper
# Results
print 'conductivity of copper in = %.1e ohm**-1/m'%conductivity