#importing modules
import math
from __future__ import division
#Variable declaration
h=6.626*10**-34; #plancks constant(J s)
c=3*10**8; #velocity of light(m/s)
lamda=6943*10**-10; #wavelength of emission(m)
k=1.38*10**-23; #boltzmann constant
T=300; #temperature(K)
#Calculation
new=c/lamda; #frequency(Hz)
x=h*new/(k*T);
N1byN2=math.exp(x); #relative population in laser transition levels
#Result
print "relative population in laser transition levels is",round(N1byN2/10**30,3),"*10**30"
print "answer given in the book is wrong"
#importing modules
import math
from __future__ import division
#Variable declaration
h=6.626*10**-34; #plancks constant(J s)
P=2.3*10**-3; #output power(W)
t=1; #time(sec)
new=4.74*10**14; #frequency(Hz)
s=1*10**-6; #spot area(m**2)
#Calculation
n=P*t/(h*new); #number of photons emitted in each second
Pd=P/s; #power density(W/m**2)
#Result
print "number of photons emitted is",round(n/10**15,3),"*10**15 photons/second"
print "power density is",Pd/10**3,"kW/m**2"
#importing modules
import math
from __future__ import division
#Variable declaration
h=6.626*10**-34; #plancks constant(J s)
c=3*10**8; #velocity of light(m/s)
Eg=1.44*1.6*10**-19; #band gap(J)
#Calculation
lamda=h*c/Eg; #wavelength of emission(m)
#Result
print "wavelength of emission is",int(round(lamda*10**10)),"angstrom"