Chapter4:MICROWAVE WAVEGUIDES AND COMPONENTS

Eg4.1.1:pg-128

In [32]:
#(a)program to find the cut-off frequency (fc) of an air-filled rectangular waveguide in TE10 mode.
a=0.07          #wave-guide dimension in meters
b=0.035         #wave-guide dimension in meters
f=3.5*(10**9)   #operating frequency in Hz 
c=3*(10**8)     # c is the speed of the light (m/s)
m=1             #Given that guide operates in the dominant mode TE10
n=0
fc=c/(a*2)      #since,fc=(c/2)*sqrt(((m/a)**2)+((n/b)**2)). For TE10 mode m=1,n=0,fc=c/2*a 
print"Cut-off frequency for TE10 mode (in GHz)is=",round(fc/10**9,2),"GHz"#print fc ,fc is divided by 10**9 to obtain frequency in GHZ

#(b) program to find the phase velocity of the wave in the guide at a frequency of 3.5GHZ
              
vg=c/(sqrt(1-((fc/f)**2)))  #since , phase velocity=c/(sqrt(1-((fc/f)**2))) 
print"Phase velocity for a wave at a frequency of 3.5GHZ  (m/s)is=","{:.2e}".format(vg),"m/s"  #print the phase velocity

# (c) program to find the guideD wavelength(lg of the wavE at a frequency of 3.5GHZ)
lo=c/f                                # lo= wavelength in an unbounded dielectric and lo is in meters
lg_in_metres=lo/(sqrt(1-((fc/f)**2))) #since ,lg=lo/sqrt(1-((fc/f)**2)) guide wavelength(lg) is in meter
lg_in_cm=100*lg_in_metres             #guided wavelength (lg) is in centimeters
print"Guided wavelength for a wave at frequency of 3.5GHZ (cm)is=",round(lg_in_cm,1),"cm"  
Cut-off frequency for TE10 mode (in GHz)is= 2.14 GHz
Phase velocity for a wave at a frequency of 3.5GHZ  (m/s)is= 3.79e+08 m/s
Guided wavelength for a wave at frequency of 3.5GHZ (cm)is= 10.8 cm

Eg4.1.2:pg-133

In [35]:
from scipy.integrate import dblquad
import math
#Program to find the peak value of the electric field occuring in the guide.
m=1     #given guide transports energy in the TE10 mode.
n=0
f=30*(10**9)     #The impressed frequency in Hertz
uo=(4*(math.pi))*(10**-7)  #scientific value of permeability of free space
eo=8.854*(10**(-12))     #permittivity of free space in F/m
a=0.02  # dimensions of wave-guide given in metres
b=0.01
energyrate=0.5*746 #given ,the rate of transport of energy =0.5 hp,1 horse power(1 hp)= 746 watts.
kc=math.pi/a #kc is cutoff wave number ,kc=sqrt((m*pi/a)**2+(n*pi/b)**2),For m=1,n=0 we get kc=pi/a
bg=sqrt((((2*math.pi*f)**2)*(uo*eo)) -(kc**2)) #bg is the phase constant in radian/metre, bg=sqrt(((w**2)*(uo*eo))-(kc**2))  where w=2*pi*f
Zg=((2*math.pi*30*(10**9))*uo)/bg  #Zg is the characteristic wave impedence ,Zg=(w*uo)/bg  where w=2*pi*f

#Defining the variables
Ex=0    #For TE10 mode Ex=0
#Ey = Eoy*sin((pi*x)/a)*exp(-1j*bg*z) (for TE10 mode) 
Ez=0    #For TE10 mode Ez=0 
#since, Hx=(Eoy/Zg)*sin(pi*x)/a)*exp(-1j*bg*z) (for TE10 mode)
Hy = 0  #For TE10 mode Hy=0
#Hz=Hoz*cos((pi*x)/a)*exp(-1j*bg*z) (for TE10 mode).
p=dblquad(lambda x, y :(sin((math.pi*x)/a))**2, 0, b, lambda x:0 ,lambda x:a )
p=p[0]
c=(bg*p)/(4*math.pi*f*uo)
p=c*(eoy)**2
p=373.
eoy=sqrt(p/c)
print"The peak value of the electric intensity is=","Eoy=", round(eoy/1000,2),"KV/m"
The peak value of the electric intensity is= Eoy= 53.87 KV/m

Eg4.2.1:pg-144

In [4]:
import math
# (a) program to find the cut off frequency (fc) of circular waveguide in TE11 mode
radius=0.05               #Given .Here radius is in meters. 
f=3*(10**9)               #operating frequency in Hertz
uo=(4*(math.pi))*(10**-7) #scientific value of permeability of free space 
eo=8.85*(10**(-12))       #permittivity of free space in F/m
n=1                       #Given that a TE11 mode is propagating.
p=1 
X=1.841                   #For TE11 mode in circular waveguide X= (kc*radius) =1.841
kc=X/radius               #cut-off wave number
fc=kc/((2*math.pi)*(sqrt(uo*eo)))        #since fc=kc/((2*pi)*(sqrt(uo*eo))) 
print"Cut-off frequency for TE11 mode (in Hz)is=","{:.3e}".format(fc),"Hz"  

# (b) program to find the guide wavelength(lg) of the wave  at operating frequency of 3GHZ
bg=sqrt((((2*math.pi*f)**2)*(uo*eo)) - (kc**2)) #bg is the phase constant in radian/metre, bg=sqrt(((w**2)*(uo*eo))-(kc**2)) where w=2*pi*f
lg_in_metres=(2*math.pi)/bg                     #Guide wavelength is in meters
lg_in_cm=100*lg_in_metres                       #Guide wavelength is in centimeters
print"Guide wavelength for a wave at a frequency of 3GHz(in cm)is=",round(lg_in_cm,1),"cm"   # print Guide wavelength for TE11 mode

# (c) program to find the wave impedance zg in the guide
zg=(2*math.pi*f*uo)/bg #Zg is the characteristic wave impedence ,Zg=(w*uo)/bg  where w=2*pi*f
print"Wave impedance zg in the wave guide(in ohm)=",int(round(zg)),"ohm" #print wave impedance in the wave guide
Cut-off frequency for TE11 mode (in Hz)is= 1.757e+09 Hz
Guide wavelength for a wave at a frequency of 3GHz(in cm)is= 12.3 cm
Wave impedance zg in the wave guide(in ohm)= 465 ohm

Eg4.2.2:pg-147

In [16]:
import math
#program to find all the TE(n,p) and TM(n,p)modes for which energy transmisssion is possible.

radius=0.02                  #Given. Here radius is in metres. 
uo=(4*(math.pi))*(10**-7)    #scientific values of permeability of free space
eo=8.85*(10**(-12))          #permittivity of free space in F/m
f=(10**10)                   #operating frequency in Hertz
wc=(2*math.pi*f)             #since, wc=(2*pi*f) is the angular frequency in Hertz
kc=wc*sqrt(uo*eo)            #kc is cut-off wave number  
X=kc*radius                  #the product X=(kc*radius) for a given mode is constant
print"The value of the product X=(kc*radius)is =",round(X,2)  #print the product X=(kc*a)
print"Any mode having a product (kc*radius) less than or equal to 4.19 will propagate the wave with a frequency of 10 GHZ .This is \n","(kc*radius)< =4.19"
print"The possible modes are" 
print"TE11(1.841)   TM01(2.405)  \n","TE21(3.054)   TM11(3.832)  \n","TE01(3.832)"   
The value of the product X=(kc*radius)is = 4.19
Any mode having a product (kc*radius) less than or equal to 4.19 will propagate the wave with a frequency of 10 GHZ .This is 
(kc*radius)< =4.19
The possible modes are
TE11(1.841)   TM01(2.405)  
TE21(3.054)   TM11(3.832)  
TE01(3.832)

Eg4.5.1:pg-170

In [37]:
#(a)program to find the amount of the power dissipated in the load Zl
PT4=8           #Given.Transmitted power to Bolometer 1 at port 4 in mW
s=2             #Given.VSWR of 2.0 is introduced on arm 4 by Bolometer 1 in mW   
r4=(s-1)/(s+1)  #reflection coefficient at port 4(r4)
PR4=8/8         #(r4**2)=PR4/PI4=PR4/(PR4+PT4)=PR4/PR4+8=1/9 so we get 8PR4=8 
PI4=PT4 + PR4   #PI4=power incident at port 4  PT4=power transmitted at port 4 PR4=power reflected at port 4 
#Since port 3 is matched and the Bolometer at port 3 reads 2mw ,then 1 mw must be radiated through the holes. 
#Since 20 dB is equivalent to a power of 100:1,the power input at port 2 is given by PI2
PI2=100*PI4     
PR2=100.0*PR4  #power reflected from the load at port 2 is given by (mW)
PT2=PI2-PR2    #power dissipated in the load = incident power - reflected power
print"power dissipated in the load at port 2 is given by (mW) =",int(PT2),"mW"   

#(b)Program to find the VSWR on arm 2
r=sqrt(PR2/PI2)                     #reflection coefficient at port 2
s=(1+r)/(1-r)                       #VSWR ON ARM 2                                                   
print"value of VSWR ON ARM 2 is=",s 
power dissipated in the load at port 2 is given by (mW) = 800 mW
value of VSWR ON ARM 2 is= 2.0

Eg4.5.2:pg-174

In [36]:
import math
#(a)Program to find out the input and output VSWRs.
s11=0                   #for balanced amplifier s11=(1/2)*(s11a-s11b) where s11a=s11b is given in question
s=(1+s11)/(1-s11)       #Input VSWR
print"Input vswr=",s 
s22=0                   #for balanced amplifier s22=(1/2)*(s22a-s22b) where s22a=s22b is given in question
s=(1+s22)/(1-s22)       #output VSWR
print"Output vswr=",s 

#(b)Program to find out the output power in watts
Pg=10                   #power gain of each GaAs chip(dB)
n=2                     #number of GaAs chip
pin=200               #input signal power in mW
PO=pin*Pg*n             #output power(PO)=[power input]*[power gain of each GaAs chip]*[n],here n=2
print"Output POWER (in Watt)=",PO/1000,"W"  #print power in watts by dividing PO by 1000

#(C)Program to find out the linear output power gain in db 
GAIN=10*math.log10(2)   #BECAUSE TWO CHIPS ARE IN PARALLEL. Gain=(power gain of each GaAs chip)*log(n),n=2.
print"Linear output power gain (in db)=",int(round(GAIN)),"dB"   #print linear output power gain in db
Input vswr= 1
Output vswr= 1
Output POWER (in Watt)= 4 W
Linear output power gain (in db)= 3 dB