# Variables
f = 1.*10**6; #Hz
# Calculations and Results
lembda = 3.*10**8/f; #m
print 'The free space wavelength is = %i m '%(lembda);
l = .1*lembda;
print ' Length , l = %i m'%(l);
# Variables
f = 1.*10**8; #Hz
# Calculations and Results
lembda = 3.*10**8/f; #m
print 'The free space wavelength is = %i m '%(lembda);
l = .1*lembda;
print ' Length ,l = %.1f m'%(l);
# Variables
f = 1.*10**9; #Hz
# Calculations and Results
lembda = 3.*10**8/f; #m
print 'The free space wavelength is = %i cm '%(lembda*100);
l = .1*lembda;
print ' Length , l = %i cm'%(l*100);
import math
# Variables
L = 320.*10**-9; #H/m
C = 90.*10**-12; #F/m
# Calculations
R0 = math.sqrt(L/C);
# Results
print 'The characteristc impedance, R0 = %.2f ohm '%(R0);
import math
# Variables
L = 320.*10**-9; #H/m
C = 90.*10**-12; #F/m
# Calculations
v = 1/math.sqrt(L*C);
# Results
print 'The velocity of propagation is, v = %.3f 10**8 m/s '%(v*10**-8);
import math
# Variables
L = 320*10**-9; #H/m
C = 90*10**-12; #F/m
# Calculations
v = 1./math.sqrt(L*C); #from Ex14.5
Er = (3*10**8/v)**2;
# Results
print 'The dielectic constant is, Er = %.2f '%(Er);
import math
# Variables
d = .3; #cm
D = 1.02; #cm
Er = 2.25;
# Calculations and Results
x = math.log(D/d); #variable
L = 2*10**-7*x;
print 'a)The inductance per unit length is, L = %.1f nH/m '%(L*10**9);
C = 55.56*10**-12*Er/x;
print ' b)The capacitance per unit length is, C = %.2f nH/m '%(C*10**12);
R0 = 60/math.sqrt(Er)*x;
print ' c)The characteristic impedance is, R0 = %.3f ohm '%(R0);
c = 3*10**8;
v = c/math.sqrt(Er);
print ' d)The velocity of propagation is, v = %i*10**8 m/s '%(v*10**-8);
#prob no. 14.7;
# Variables
Rin = 50. #ohm
Rout = 50.; #ohm
Vrms = 400.; #V
# Calculations and Results
Zin = Rin;
print 'a)The input impedance is, Zin = %i ohm'%(Zin);
Irms = Vrms/(Rin+Rout); #A
print ' b)The rms current , Irms = %i A '%(Irms);
Pin = Irms**2*Rin;
print ' c)The input power is, Pin = %i W '%(Pin);
Pl = Pin;
print ' d)The load power is, Pl = %i W '%(Pl);
# Variables
Rin = 50. #ohm
Rout = 50.; #ohm
Vrms = 400.; #V
l = 50.; #m
# Calculations and Results
Ldb = .01*l; #dB
L = 10**(Ldb/10);
print 'The abslute loss is, L = %f '%(L);
Irms = Vrms/(Rin+Rout); #A
Pin = Irms**2*Rin;
PL = Pin/L;
print ' The actual Power reaching the load is, PL = %.1f W '%(PL);
from numpy import angle
# Variables
ZL = complex(50,100);
R0 = 50.;
def R2P(x):
return abs(x), angle(x)
# Calculations and Results
TauL = (ZL-R0)/(ZL+R0);
print 'a)The reflection coefficient at load is',
print (TauL);
R,theta = R2P(TauL) #polar(TauL);
print 'OR , %.4f angle %i'%(R,theta*180/math.pi);
S = (1+R)/(1-R);
print ' b) The stading wave ratio is, S = %.3f '%(S);
# Variables
ZL = 100.; #ohm
RL = ZL;
R0 = 300.; #ohm
# Calculations and Results
TauL = (RL-R0)/(RL+R0);
print 'a)The reflection coefficient at load is = %0.2f'%(TauL);
S = R0/RL;
print ' b) The stading wave ratio is, S = %.0f '%(S);
import math
# Variables
ZL = 100.; #ohm
RL = ZL;
R0 = 300; #ohm
# Calculations
TauL = (RL-R0)/(RL+R0);
mismatch_loss_dB = -10*math.log10(1-TauL**2);
# Results
print ' The mismatch loss dB , S = %.2f dB'%(mismatch_loss_dB);
import math
# Variables
Ex = 3. #V/m
n0 = 377.;
# Calculations and Results
Hy = Ex/n0;
print 'a) The vaulue of Hy is, Hy = %.3f * 10**-3 A/m'%(Hy*10**3);
Px = Ex**2/n0;
print ' b) The power density Px is, Px = %.3f * 10**-3 W/m**2'%(Px*10**3);
A = 10*30;
P = Px*A;
print ' c) The net power transmitted is, P = %.3f W '%(P);