#importing modules
import math
from __future__ import division
#Variable declaration
d=2.82*10**-10; #lattice spacing(m)
theta=10; #glancing angle(degree)
n=1; #order
#Calculation
theta=theta*math.pi/180; #angle(radian)
lamda=2*d*math.sin(theta)/n; #wavelength(m)
#Result
print "wavelength is",round(lamda*10**10,5),"angstrom"
#importing modules
import math
from __future__ import division
#Variable declaration
d=3.035*10**-10; #lattice spacing(m)
theta=12; #glancing angle(degree)
n=1; #order
#Calculation
theta=theta*math.pi/180; #angle(radian)
lamda=2*d*math.sin(theta)/n; #wavelength(m)
#Result
print "wavelength is",round(lamda*10**10,3),"angstrom"
#importing modules
import math
from __future__ import division
#Variable declaration
d=2.81; #lattice spacing(angstrom)
theta1=15.1; #glancing angle(degree)
theta2=17.1; #glancing angle(degree)
#Calculation
theta1=theta1*math.pi/180; #angle(radian)
lamda1=2*d*math.sin(theta1); #wavelength(angstrom)
theta2=theta2*math.pi/180; #angle(radian)
lamda2=2*d*math.sin(theta2); #wavelength(angstrom)
#Result
print "wavelengths are",round(lamda1,3),"angstrom and",round(lamda2,4),"angstrom"
print "answer varies due to rounding off errors"
#importing modules
import math
from __future__ import division
#Variable declaration
lamda=1.54; #wavelength(angstrom)
theta=11; #glancing angle(degree)
#Calculation
theta=theta*math.pi/180; #angle(radian)
d=lamda/(2*math.sin(theta)); #separation between lattice planes(angstrom)
#Result
print "separation between lattice planes is",round(d,3),"angstrom"
#importing modules
import math
from __future__ import division
#Variable declaration
lamdaB=0.92; #wavelength(angstrom)
theta1=30; #glancing angle(degree)
theta2=60; #glancing angle(degree)
#Calculation
theta1=theta1*math.pi/180; #angle(radian)
theta2=theta2*math.pi/180; #angle(radian)
lamdaA=2*lamdaB*math.sin(theta1)/math.sin(theta1); #wavelength of line A(angstrom)
#Result
print "wavelength is",lamdaA,"angstrom"
print "answer in the book is wrong"
#importing modules
import math
from __future__ import division
#Variable declaration
d=0.4086*10**-10; #lattice spacing(m)
theta=65; #glancing angle(degree)
h=6.6*10**-34; #plank's constant(Js)
m=9.1*10**-31; #mass(kg)
n=1;
#Calculation
theta=theta*math.pi/180; #angle(radian)
lamda=2*d*math.sin(theta)/n; #debroglie wavelength(m)
v=h/(m*lamda); #velocity(m/sec)
#Result
print "debroglie wavelength is",round(lamda*10**10,4),"*10**-10 metre"
print "velocity is",round(v/10**6,3),"*10**6 m/sec"
print "answer in the book is wrong"
#importing modules
import math
from __future__ import division
#Variable declaration
d=2.82*10**-10; #lattice spacing(m)
sintheta=1;
n=1;
#Calculation
lamda_max=2*d*sintheta/n; #longest wavelength(m)
#Result
print "longest wavelength is",lamda_max*10**10,"angstrom"
#importing modules
import math
from __future__ import division
#Variable declaration
d=0.842*10**-10; #lattice spacing(m)
theta1=8+(35/60); #glancing angle(degree)
n1=1; #order
n2=3; #order
#Calculation
theta1=theta1*math.pi/180; #angle(radian)
theta3=math.asin(n2*math.sin(theta1)); #glancing angle(radian)
theta3=theta3*180/math.pi; #glancing angle(degree)
#Result
print "glancing angle is",round(theta3,3),"degree"
#importing modules
import math
from __future__ import division
#Variable declaration
lamda=0.58; #wavelength(angstrom)
theta1=6+(45/60); #glancing angle(degree)
theta2=9+(15/60); #glancing angle(degree)
theta3=13; #glancing angle(degree)
#Calculation
theta1=theta1*math.pi/180; #angle(radian)
theta2=theta2*math.pi/180; #angle(radian)
theta3=theta3*math.pi/180; #angle(radian)
x1=lamda/(2*math.sin(theta1));
x2=lamda/(2*math.sin(theta2));
#Result
print "interplanar spacing is",round(x2,3),"angstrom"
print "answer varies due to rounding off errors"
#importing modules
import math
from __future__ import division
#Variable declaration
lamda=1.3922; #wavelength(angstrom)
n=1;
theta=14+(27/60)+(26/(60*60)); #glancing angle(degree)
M=58.454; #molecular weight
rho=2163; #density(kg/m**3)
#Calculation
theta=theta*math.pi/180; #angle(radian)
d=n*lamda/(2*math.sin(theta)); #lattice spacing(angstrom)
d_m=d*10**-10; #lattice spacing(m)
N=M/(2*rho*d_m**3); #avagadro number(mol/k-mole)
#Result
print "lattice spacing is",round(d,4),"angstrom"
print "avagadro number is",round(N/10**26,4),"*10**26 mol/k-mole"
print "answer varies due to rounding off errors"
#importing modules
import math
from __future__ import division
#Variable declaration
lamda=0.586*10**-10; #wavelength(m)
theta1=5+(58/60); #glancing angle(degree)
theta2=12+(10/60); #glancing angle(degree)
theta3=18+(12/60); #glancing angle(degree)
#Calculation
theta1=theta1*math.pi/180; #angle(radian)
theta2=theta2*math.pi/180; #angle(radian)
theta3=theta3*math.pi/180; #angle(radian)
x1=math.sin(theta1);
x2=math.sin(theta2);
x3=math.sin(theta3);
d1=lamda/(2*math.sin(theta1)); #spacing for 1st order(m)
d2=2*lamda/(2*math.sin(theta2)); #spacing for 2nd order(m)
d3=3*lamda/(2*math.sin(theta3)); #spacing for 3rd order(m)
d=(d1+d2+d3)/3; #spacing(m)
#Result
print "ratio of angles of incidence are",round(x1,3),":",round(x2,4),":",round(x3,4),"which is nothing but",round(x1,1)*10,":",round(x2,1)*10,":",round(x3,1)*10
print "angles of incidence should be 1st, 2nd and 3rd orders"
print "spacing is",round(d*10**10,3),"*10**-10 m"
print "answer varies due to rounding off errors"
#importing modules
import math
from __future__ import division
#Variable declaration
theta1=5+(23/60); #glancing angle(degree)
theta2=7+(37/60); #glancing angle(degree)
theta3=9+(25/60); #glancing angle(degree)
#Calculation
theta1=theta1*math.pi/180; #angle(radian)
theta2=theta2*math.pi/180; #angle(radian)
theta3=theta3*math.pi/180; #angle(radian)
x1=math.sin(theta1);
X1=1/(10*x1);
x2=math.sin(theta2)/x1;
x3=math.sin(theta3)/x1;
#Result
print "ratio of angles of incidence are",int(x1),":",round(x2,3),":",round(x3,3)
print "the crystal is a simple cubic crystal"
#importing modules
import math
from __future__ import division
#Variable declaration
h=6.62*10**-34; #planck's constant(J sec)
e=1.6*10**-19; #charge(coulomb)
m=9*10**-31; #mass(kg)
E=344; #energy(volts)
n=1;
theta=60; #angle(degrees)
#Calculation
lamda=h/math.sqrt(2*m*e*E); #wavelength(m)
theta=theta*math.pi/180; #angle(radian)
d=n*lamda*10**10/(2*math.sin(theta)); #spacing of crystal(angstrom)
#Result
print "spacing of crystal is",round(d,2),"angstrom"
#importing modules
import math
from __future__ import division
#Variable declaration
h=2;
k=2;
l=0;
n=1;
theta=32; #angle(degrees)
lamda=1.54*10**-10; #wavelength(m)
#Calculation
theta=theta*math.pi/180; #angle(radian)
d=n*lamda*10**10/(2*math.sin(theta)); #spacing of crystal(angstrom)
a=d*math.sqrt(h**2+k**2+l**2); #lattice parameter(angstrom)
r=a/(2*math.sqrt(2)); #radius of atom(angstrom)
#Result
print "lattice parameter is",round(a,1),"angstrom"
print "radius of atom is",round(r,2),"angstrom"