# Chapter10-Network Functions¶

## Ex35-pg10.35¶

In [1]:
## Network Functions : example 10.35 : (pg 10.35)
import math
m=(2./(math.sqrt(2.)*math.sqrt(10.)));
a=90.;
x=(a-math.atan(3.)*57.3-math.atan(1)*57.3);
print("\nF(s) =(4s/s^2+2s+2) = 4s/(s+1-j)*(s+1-j)");
print("\n At s=j2");
##pmag = phasor magnitudes
print("\n|F(j2)|=Product of pmag from all zeros to j2/Product of pmag from all poles to j2");
print"%s %.2f %s"%("\n = ",m,"");
print"%s %.2f %s"%("\nf(w) = atand(2/0)-atand(3)-atand(1)= ",x," degrees");

F(s) =(4s/s^2+2s+2) = 4s/(s+1-j)*(s+1-j)

At s=j2

|F(j2)|=Product of pmag from all zeros to j2/Product of pmag from all poles to j2

=  0.45

f(w) = atand(2/0)-atand(3)-atand(1)=  -26.57  degrees


## Ex36-pg10.35¶

In [2]:
## Network Functions : example 10.36 : (pg 10.35 & 10.36)

import math
m=((5.*math.sqrt(17.))/(math.sqrt(20.)*4.));
a=90.;
w=(math.atan(4.)*57.3+math.atan(4/3.)*57.3-(a)-math.atan(4/2.)*57.3);
print("\nF(s) = (s+1)(s+3)/s(s+2))");
print("\nAt s=j4");
##vmag = vector magnitudes
print("\nPrduct of vmag from all zeros to j4/ Product of vmag from all poles to j4");
print"%s %.2f %s"%("\n =",m,"");
print("\nphi(w)= atand(4)+atand(4/3)-atand(4/0)-atand(4/2)");
print"%s %.2f %s"%("\n = ",w," degrees");

F(s) = (s+1)(s+3)/s(s+2))

At s=j4

Prduct of vmag from all zeros to j4/ Product of vmag from all poles to j4

= 1.15

phi(w)= atand(4)+atand(4/3)-atand(4/0)-atand(4/2)

=  -24.34  degrees