# Chapter11-Two-Port Networks¶

## Ex16-pg11.29¶

In [1]:
##Two-Port Networks : example 11.16 :(pg11.39 )
V1s=25.;
import math
I1s=1.;
I2s=2.;
V1o=10.;
V2o=50.;
I2o=2.;
h11=(V1s/I1s);
h21=(I2s/I1s);
h12=(V1o/V2o);
h22=(I2o/V2o);
print"%s %.2f %s"%("\nh11 = V1/I1 = ",h11," Ohm");##when V2=0
print"%s %.2f %s"%("\nh21= I2/I1 = ",h21,"");##when V2=0
print"%s %.2f %s"%("\nh12 = V1/V2 =",h12,"");##when I1=0
print"%s %.2f %s"%("\nh22 = I2/V2 = ",h22," mho");##when I1=0
print("\nth h-parameters are");
print([[h11 ,h12],[h21, h22]]);

h11 = V1/I1 =  25.00  Ohm

h21= I2/I1 =  2.00

h12 = V1/V2 = 0.20

h22 = I2/V2 =  0.04  mho

th h-parameters are
[[25.0, 0.2], [2.0, 0.04]]


## Ex19-pg11.49¶

In [2]:
##Two-Port Networks : example 11.19 :(pg11.49 & 11.50)
Z11=20.;
import math
Z22=30.;
Z12=10.;
Z21=10.;
dZ=((Z11*Z22)-(Z12*Z21));
Y11=(Z22/dZ);
Y12=(-Z12/dZ);
Y21=(-Z21/dZ);
Y22=(Z11/dZ);
A=(Z11/Z21);
B=(dZ/Z21);
C=(1./Z21);
D=(Z22/Z21);
print("\nY-parameters");
print"%s %.2f %s"%("\nY11 = Z22/dZ = ",Y11," mho");
print"%s %.2f %s"%("\nY12 = -Z12/dZ = ",Y12," mho");
print"%s %.2f %s"%("\nY21 = -Z21/dZ = ",Y21," mho");
print"%s %.2f %s"%("\nY22 = Z11/dZ = ",Y22," mho");
print("\n Y-parameters are:");
print([[Y11, Y12],[Y21, Y22]]);##Y-parameters in matrix form
print("\nABCD parameters");
print"%s %.2f %s"%("\nA = Z11/Z21 = ",A,"");
print"%s %.2f %s"%("\nB = dZ/Z21 = ",B,"");
print"%s %.2f %s"%("\nC = 1/Z21 = ",C,"");
print"%s %.2f %s"%("\nD = Z22/Z21 = ",D,"");
print("\n ABCD parameters are:");
print([[A ,B],[C ,D]]);##ABCD parameters in matrix form

Y-parameters

Y11 = Z22/dZ =  0.06  mho

Y12 = -Z12/dZ =  -0.02  mho

Y21 = -Z21/dZ =  -0.02  mho

Y22 = Z11/dZ =  0.04  mho

Y-parameters are:
[[0.06, -0.02], [-0.02, 0.04]]

ABCD parameters

A = Z11/Z21 =  2.00

B = dZ/Z21 =  50.00

C = 1/Z21 =  0.10

D = Z22/Z21 =  3.00

ABCD parameters are:
[[2.0, 50.0], [0.1, 3.0]]


## Ex20-pg11.50¶

In [11]:
##Two-Port Networks : example 11.20 :(pg11.50 & 11.51)
a=0.5;
import math
b=-0.2;
d=1.
print("\nI1 =0.5V1-0.2V2 \nI2=-0.2V1+V2");
print"%s %.2f %s"%("\n Y11 =I1/V1 = ",a,"mho");##when V2 is 0 in the 1st eqn
print"%s %.2f %s"%("\n Y21 =I2/V1 = ",b," mho");##when V2 is 0 in the 1st eqn
print"%s %.2f %s"%("\n Y12 =I1/V2 = ",b," mho");##when V1 is 0 in the 2nd eqn
print"%s %.2f %s"%("\n Y22 =I2/V2 = ",d," mho");##when V1 is 0 in the 2nd eqn
print("\nY-parameters are");
print([[a, b],[b ,d]]);
dY=((a*d)-(b*b));
Z11=(d/dY);
Z12=(-b/dY);
Z21=(-b/dY);
Z22=(a/dY);
A=(-d/b);
C=(-dY/b);
D=(-a/b);
print"%s %.2f %s"%("\ndY=Y11.Y22-Y12.Y21 =",dY,"");
print"%s %.2f %s"%("\nZ11 = Y22/dY = ",Z11," Ohm");
print"%s %.2f %s"%("\nZ12 = -Y12/dY = ",Z12," Ohm");
print"%s %.2f %s"%("\nZ21 = -Y21/-dY = ",Z21," Ohm");
print"%s %.2f %s"%("\nZ22 = Y11/dY = ",Z22," Ohm");
print("\nZ-parameters :");

x=([[Z11, Z12],[Z21, Z22]])

print(x)
print"%s %.2f %s"%("\nA =-Y22/Y21 =",A,"");
print"%s %.2f %s"%("\nB = -1/Y21 =",A,"");
print"%s %.2f %s"%("\nC = -dY/Y21 =",C,"");
print"%s %.2f %s"%("\nD = -Y11/Y21 =",D,"");
print("\nABCD parameters :");
print([[A, A],[C ,D]]);

#due to round off error

I1 =0.5V1-0.2V2
I2=-0.2V1+V2

Y11 =I1/V1 =  0.50 mho

Y21 =I2/V1 =  -0.20  mho

Y12 =I1/V2 =  -0.20  mho

Y22 =I2/V2 =  1.00  mho

Y-parameters are
[[0.5, -0.2], [-0.2, 1.0]]

dY=Y11.Y22-Y12.Y21 = 0.46

Z11 = Y22/dY =  2.17  Ohm

Z12 = -Y12/dY =  0.43  Ohm

Z21 = -Y21/-dY =  0.43  Ohm

Z22 = Y11/dY =  1.09  Ohm

Z-parameters :
[[2.173913043478261, 0.4347826086956522], [0.4347826086956522, 1.0869565217391306]]

A =-Y22/Y21 = 5.00

B = -1/Y21 = 5.00

C = -dY/Y21 = 2.30

D = -Y11/Y21 = 2.50

ABCD parameters :
[[5.0, 5.0], [2.3, 2.5]]


## Ex22-pg11.52¶

In [4]:
##Two-Port Networks : example 11.22 :(pg11.52 & 11.53)
print("\nApplying KVL to Mesh 1 \nV1 = I1 - I3 - - - -(i)");
print("\nApplying KVL to Mesh 2 \nV2 = -4I2 + 2I3 - - - -(ii)");
print("\nApplying KVL to Mesh 3 \nI3 = (1/5)I1 + (4/5)I2 - - - -(iii)");
##substituting (iii) in (i) & (ii),we get
print("\nV1 = (4/5)I1 - (4/5)I2 \nV2 = (2/5)I1 - (12/5)I2");
print("\nZ-parameters:");
a=4./5.;b=-4/5.;c=2/5.;d=-12/5.;
print([[a, b],[c, d]]);
dZ=(a*d)-(b*c);
Y11=(d/dZ);
Y12=(-b/dZ);
Y21=(-c/dZ);
Y22=(a/dZ);
print("\nY-parameters are:");
print"%s %.2f %s"%("\ndZ = Z11.Z22 - Z12.Z21 = ",dZ,"");
print"%s %.2f %s"%("\nY11 = Z22/dZ = ",Y11," mho");
print"%s %.2f %s"%("\nY12 = -Z12/dY = ",Y12," mho");
print"%s %.2f %s"%("\nY21 = -Z21/-dY = ",Y21," mho");
print"%s %.2f %s"%("\nY22 = Z11/dY = ",Y22," mho");
print([[Y11, Y12],[Y21, Y22]]);

Applying KVL to Mesh 1
V1 = I1 - I3 - - - -(i)

Applying KVL to Mesh 2
V2 = -4I2 + 2I3 - - - -(ii)

Applying KVL to Mesh 3
I3 = (1/5)I1 + (4/5)I2 - - - -(iii)

V1 = (4/5)I1 - (4/5)I2
V2 = (2/5)I1 - (12/5)I2

Z-parameters:
[[0.8, -0.8], [0.4, -2.4]]

Y-parameters are:

dZ = Z11.Z22 - Z12.Z21 =  -1.60

Y11 = Z22/dZ =  1.50  mho

Y12 = -Z12/dY =  -0.50  mho

Y21 = -Z21/-dY =  0.25  mho

Y22 = Z11/dY =  -0.50  mho
[[1.5, -0.5000000000000001], [0.25000000000000006, -0.5000000000000001]]


## Ex23-pg11.53¶

In [5]:
##Two-Port Networks : example 11.23 :(pg11.53 & 11.54)
print("\nApplying KVL to Mesh 1 \nV1 = 4I1 - 2I3 - - - -(i)");
print("\nApplying KVL to Mesh 2 \nV2 = 4I2 + 2I3 - - - -(ii)");
print("\nApplying KVL to Mesh 3 \n-2I3 = I1 + I2 - - - -(iii)");
##substituting (iii) in (i) & (ii),we get
print("\nV1 = 5I1 + I2 \nV2 = -I1 + 3I2");
print("\nZ-parameters:");
a=5.;b=1.;c=-1.;d=3.;
print([[a, b],[c ,d]]);
dZ=(a*d)-(b*c);
h11=(dZ/d);
h12=(b/d);
h21=(-c/d);
h22=(.1/d);
print"%s %.2f %s"%("\ndZ = Z11.Z22 - Z12.Z21 =",dZ,"");
print"%s %.2f %s"%("\nh11 = dZ/Z22 =  ",h11,"");
print"%s %.2f %s"%("\nh12 = Z12/Z22 = ",h12,"");
print"%s %.2f %s"%("\nh21 = -Z21/Z22 = ",h21,"");
print"%s %.2f %s"%("\nh22 = 1/Z22 = ",h22,"");
print("\nh-parameters are:");
print([[h11 ,h12],[h21 ,h22]]);

Applying KVL to Mesh 1
V1 = 4I1 - 2I3 - - - -(i)

Applying KVL to Mesh 2
V2 = 4I2 + 2I3 - - - -(ii)

Applying KVL to Mesh 3
-2I3 = I1 + I2 - - - -(iii)

V1 = 5I1 + I2
V2 = -I1 + 3I2

Z-parameters:
[[5.0, 1.0], [-1.0, 3.0]]

dZ = Z11.Z22 - Z12.Z21 = 16.00

h11 = dZ/Z22 =   5.33

h12 = Z12/Z22 =  0.33

h21 = -Z21/Z22 =  0.33

h22 = 1/Z22 =  0.03

h-parameters are:
[[5.333333333333333, 0.3333333333333333], [0.3333333333333333, 0.03333333333333333]]


## Ex24-pg11.54¶

In [6]:
##Two-Port Networks : example 11.24 :(pg11.54 & 11.55)
print("\nApplying KCL to Node 3 \nV3 = V2/3 - - - -(i)");
print("\nI1 = 2V1 - (2/3)V2 - - - -(ii)");
print("\nI2 = 3V2 - (V2/3) = (8/3)V2 - - - -(iii)");
##Comparing (iii) & (ii) ,we get
print("\nY-parameters:");
a=2;b=(-2/3.);c=0;d=(8/3.);
print([[a, b],[b ,d]]);
dY=((a*d)-(b*c));
Z11=(d/dY);
Z12=(-b/dY);
Z21=(c/dY);
Z22=(a/dY);
print"%s %.2f %s"%("\ndY=Y11.Y22-Y12.Y21 =",dY,"");
print"%s %.2f %s"%("\nZ11 = Y22/dY =",Z11," Ohm");
print"%s %.2f %s"%("\nZ12 = -Y12/dY = ",Z12," Ohm");
print"%s %.2f %s"%("\nZ21 = -Y21/-dY = ",Z21," Ohm");
print"%s %.2f %s"%("\nZ22 = Y11/dY = ",Z22," Ohm");
print("\nZ-parameters :");
print([[Z11, Z12],[Z21, Z22]]);

Applying KCL to Node 3
V3 = V2/3 - - - -(i)

I1 = 2V1 - (2/3)V2 - - - -(ii)

I2 = 3V2 - (V2/3) = (8/3)V2 - - - -(iii)

Y-parameters:
[[2, -0.6666666666666666], [-0.6666666666666666, 2.6666666666666665]]

dY=Y11.Y22-Y12.Y21 = 5.33

Z11 = Y22/dY = 0.50  Ohm

Z12 = -Y12/dY =  0.12  Ohm

Z21 = -Y21/-dY =  0.00  Ohm

Z22 = Y11/dY =  0.38  Ohm

Z-parameters :
[[0.5, 0.125], [0.0, 0.375]]


## Ex25-pg11.55¶

In [7]:
##Two-Port Networks : example 11.25 :(pg11.55 & 11.56)
print("\nApplying KCL to Node 1 \nI1 = (-3/2)V1 - V2- - -(i)");
print("\nApplying KCL to Node 2 \nI2 = 2V1 + 2V2 - - - -(ii)");
##observing (i) & (ii)
print("\nY-parameters:");
a=(-3/2.);b=(-1);c=2.;d=2.;
print([[a, b],[c ,d]]);
dY=((a*d)-(b*c));
Z11=(d/dY);
Z12=(-b/dY);
Z21=(-c/dY);
Z22=(a/dY);
print"%s %.2f %s"%("\ndY=Y11.Y22-Y12.Y21 =",dY,"");
print"%s %.2f %s"%("\nZ11 = Y22/dY = ",Z11," Ohm");
print"%s %.2f %s"%("\nZ12 = -Y12/dY =",Z12," Ohm");
print"%s %.2f %s"%("\nZ21 = -Y21/-dY = ",Z21," Ohm");
print"%s %.2f %s"%("\nZ22 = Y11/dY = ",Z22," Ohm");
print("\nZ-parameters :");
print([[Z11 ,Z12],[Z21, Z22]]);

Applying KCL to Node 1
I1 = (-3/2)V1 - V2- - -(i)

Applying KCL to Node 2
I2 = 2V1 + 2V2 - - - -(ii)

Y-parameters:
[[-1.5, -1], [2.0, 2.0]]

dY=Y11.Y22-Y12.Y21 = -1.00

Z11 = Y22/dY =  -2.00  Ohm

Z12 = -Y12/dY = -1.00  Ohm

Z21 = -Y21/-dY =  2.00  Ohm

Z22 = Y11/dY =  1.50  Ohm

Z-parameters :
[[-2.0, -1.0], [2.0, 1.5]]


## Ex26-pg11.56¶

In [8]:
##Two-Port Networks : example 11.22 :(pg11.52 & 11.53)
print("\nApplying KVL to Mesh 1 \nV1 = 2I1 + I2 - - - -(i)");
print("\nApplying KVL to Mesh 2 \nV2 = 10I1 + 11I2 - - - -(ii)");
##observing (i) & (ii)
print("\nV1 = (4/5)I1 - (4/5)I2 \nV2 = (2/5)I1 - (12/5)I2");
print("\nZ-parameters:");
a=2.;b=1.;c=10.;d=11.;
print([[a, b],[c ,d]]);
dZ=(a*d)-(b*c);
Y11=(d/dZ);
Y12=(-b/dZ);
Y21=(-c/dZ);
Y22=(a/dZ);
print("\nY-parameters are:");
print"%s %.2f %s"%("\ndZ = Z11.Z22 - Z12.Z21 = ",dZ,"");
print"%s %.2f %s"%("\nY11 = Z22/dZ = ",Y11," mho");
print"%s %.2f %s"%("\nY12 = -Z12/dY = ",Y12," mho");
print"%s %.2f %s"%("\nY21 = -Z21/-dY = ",Y21," mho");
print"%s %.2f %s"%("\nY22 = Z11/dY = ",Y22," mho");
print([[Y11, Y12],[Y21, Y22]]);

h11=(dZ/d);
h12=(b/d);
h21=(-c/d);
h22=(1/d);

print"%s %.2e %s"%("\ndZ = Z11.Z22 - Z12.Z21 =",dZ,"");
print"%s %.2e %s"%("\nh11 = dZ/Z22 =  ",h11,"");
print"%s %.2f %s"%("\nh12 = Z12/Z22 = ",h12,"");
print"%s %.2e %s"%("\nh21 = -Z21/Z22 = ",h21,"");
print"%s %.2e %s"%("\nh22 = 1/Z22 = ",h22,"");
print("\nh-parameters are:");
print([[h11 ,h12],[h21 ,h22]]);

Applying KVL to Mesh 1
V1 = 2I1 + I2 - - - -(i)

Applying KVL to Mesh 2
V2 = 10I1 + 11I2 - - - -(ii)

V1 = (4/5)I1 - (4/5)I2
V2 = (2/5)I1 - (12/5)I2

Z-parameters:
[[2.0, 1.0], [10.0, 11.0]]

Y-parameters are:

dZ = Z11.Z22 - Z12.Z21 =  12.00

Y11 = Z22/dZ =  0.92  mho

Y12 = -Z12/dY =  -0.08  mho

Y21 = -Z21/-dY =  -0.83  mho

Y22 = Z11/dY =  0.17  mho
[[0.9166666666666666, -0.08333333333333333], [-0.8333333333333334, 0.16666666666666666]]

dZ = Z11.Z22 - Z12.Z21 = 1.20e+01

h11 = dZ/Z22 =   1.09e+00

h12 = Z12/Z22 =  0.09

h21 = -Z21/Z22 =  -9.09e-01

h22 = 1/Z22 =  9.09e-02

h-parameters are:
[[1.0909090909090908, 0.09090909090909091], [-0.9090909090909091, 0.09090909090909091]]


## Ex27-pg11.58¶

In [9]:
##Two-Port Networks : example 11.27 :(pg11.58)
print("\nApplying KCL to Node 1 \nI1 = 4V1 - 3V2- - -(i)");
print("\nApplying KCL to Node 2 \nI2 = -3V1 + 1.5V2 - - - -(ii)");
##observing (i) & (ii)
print("\nY-parameters:");
a=4.;b=(-3);c=(-3);d=1.5;
print([[a ,b],[c ,d]]);
dY=((a*d)-(b*c));
Z11=(d/dY);
Z12=(-b/dY);
Z21=(-c/dY);
Z22=(a/dY);
print"%s %.2f %s"%("\ndY=Y11.Y22-Y12.Y21 =",dY,"");
print"%s %.2f %s"%("\nZ11 = Y22/dY = ",Z11," Ohm");
print"%s %.2f %s"%("\nZ12 = -Y12/dY =",Z12," Ohm");
print"%s %.2f %s"%("\nZ21 = -Y21/-dY = ",Z21," Ohm");
print"%s %.2f %s"%("\nZ22 = Y11/dY = ",Z22," Ohm");
print("\nZ-parameters :");
print([[Z11 ,Z12],[Z21, Z22]]);

Applying KCL to Node 1
I1 = 4V1 - 3V2- - -(i)

Applying KCL to Node 2
I2 = -3V1 + 1.5V2 - - - -(ii)

Y-parameters:
[[4.0, -3], [-3, 1.5]]

dY=Y11.Y22-Y12.Y21 = -3.00

Z11 = Y22/dY =  -0.50  Ohm

Z12 = -Y12/dY = -1.00  Ohm

Z21 = -Y21/-dY =  -1.00  Ohm

Z22 = Y11/dY =  -1.33  Ohm

Z-parameters :
[[-0.5, -1.0], [-1.0, -1.3333333333333333]]


## Ex28-pg11.58¶

In [11]:
##Two-Port Networks : example 11.28 :(pg11.58 & 11.59)
("\nApplying KCL to Node 1 \nI1 = 1.5V1 - 0.5V2- - -(i)");
print("\nApplying KCL to Node 2 \nI2 = 4V1 - 0.5V2 - - - -(ii)");
##observing (i) & (ii)
print("\nY-parameters:");
a=1.5;b=(-0.5);c=(4);d=(-0.5);
print([[a ,b],[c ,d]]);
dY=((a*d)-(b*c));
Z11=(d/dY);
Z12=(-b/dY);
Z21=(-c/dY);
Z22=(a/dY);
print"%s %.2f %s"%("\ndY=Y11.Y22-Y12.Y21 =",dY,"");
print"%s %.2f %s"%("\nZ11 = Y22/dY = ",Z11," Ohm");
print"%s %.2f %s"%("\nZ12 = -Y12/dY =",Z12," Ohm");
print"%s %.2f %s"%("\nZ21 = -Y21/-dY = ",Z21," Ohm");
print"%s %.2f %s"%("\nZ22 = Y11/dY = ",Z22," Ohm");
print("\nZ-parameters :");
print([[Z11 ,Z12],[Z21, Z22]]);

Applying KCL to Node 2
I2 = 4V1 - 0.5V2 - - - -(ii)

Y-parameters:
[[1.5, -0.5], [4, -0.5]]

dY=Y11.Y22-Y12.Y21 = 1.25

Z11 = Y22/dY =  -0.40  Ohm

Z12 = -Y12/dY = 0.40  Ohm

Z21 = -Y21/-dY =  -3.20  Ohm

Z22 = Y11/dY =  1.20  Ohm

Z-parameters :
[[-0.4, 0.4], [-3.2, 1.2]]


## Ex29-pg11.59¶

In [13]:
##Two-Port Networks : example 11.29 :(pg11.59 & 11.60)
print("\nApplying KCL to Node 1 \nI1 = 3V1 - 2V2- - -(i)");
print("\nApplying KCL to Node 2 \nI2 = 3V2 - V3 - - - -(ii)");
print("\nApplying KCL to Node 3 \nV3 = (1/3)V2 - - - -(ii)");
##substituting (iii) in (i) & (ii),we get
print("\nI1 = 3V1 - (2/3)V2 \nI2 = 0V1 + (8/3)V2");
print("\nY-parameters:");
a=3.;b=(-2/3.);c=(0.);d=(8/3.);
print([[a ,b],[c ,d]]);

dY=((a*d)-(b*c));
Z11=(d/dY);
Z12=(-b/dY);
Z21=(c/dY);
Z22=(a/dY);

print"%s %.2f %s"%("\ndY=Y11.Y22-Y12.Y21 =",dY,"");
print"%s %.2f %s"%("\nZ11 = Y22/dY = ",Z11," Ohm");
print"%s %.2f %s"%("\nZ12 = -Y12/dY =",Z12," Ohm");
print"%s %.2f %s"%("\nZ21 = -Y21/-dY = ",Z21," Ohm");
print"%s %.2f %s"%("\nZ22 = Y11/dY = ",Z22," Ohm");
print("\nZ-parameters :");
print([[Z11 ,Z12],[Z21, Z22]]);

Applying KCL to Node 1
I1 = 3V1 - 2V2- - -(i)

Applying KCL to Node 2
I2 = 3V2 - V3 - - - -(ii)

Applying KCL to Node 3
V3 = (1/3)V2 - - - -(ii)

I1 = 3V1 - (2/3)V2
I2 = 0V1 + (8/3)V2

Y-parameters:
[[3.0, -0.6666666666666666], [0.0, 2.6666666666666665]]

dY=Y11.Y22-Y12.Y21 = 8.00

Z11 = Y22/dY =  0.33  Ohm

Z12 = -Y12/dY = 0.08  Ohm

Z21 = -Y21/-dY =  0.00  Ohm

Z22 = Y11/dY =  0.38  Ohm

Z-parameters :
[[0.3333333333333333, 0.08333333333333333], [0.0, 0.375]]


## Ex30-pg11.60¶

In [14]:
##Two-Port Networks : example 11.30 :(pg11.60 & 11.561)
print("\nApplying KVL to Mesh 1 \nV1 = 4I1 + (0.05)I2 - - - -(i)");
print("\nApplying KVL to Mesh 2 \nV2 = 2I1 - 10I2 - - - -(ii)");
##substituting (i) in (ii),
print("\nV2 = -40I1 + (1.5)I2");
print("\nZ-parameters:");
a=4;b=0.05;c=-40;d=1.5;
print([[a ,b],[c ,d]]);
dZ=(a*d)-(b*c);
Y11=(d/dZ);
Y12=(b/dZ);
Y21=(-c/dZ);
Y22=(a/dZ);
print("\nY-parameters are:");
print"%s %.2f %s"%("\ndZ = Z11.Z22 - Z12.Z21 = ",dZ,"");
print"%s %.2f %s"%("\nY11 = Z22/dZ = ",Y11," mho");
print"%s %.2f %s"%("\nY12 = -Z12/dY = ",Y12," mho");
print"%s %.2f %s"%("\nY21 = -Z21/-dY = ",Y21," mho");
print"%s %.2f %s"%("\nY22 = Z11/dY = ",Y22," mho");
print([[Y11, Y12],[Y21, Y22]]);

Applying KVL to Mesh 1
V1 = 4I1 + (0.05)I2 - - - -(i)

Applying KVL to Mesh 2
V2 = 2I1 - 10I2 - - - -(ii)

V2 = -40I1 + (1.5)I2

Z-parameters:
[[4, 0.05], [-40, 1.5]]

Y-parameters are:

dZ = Z11.Z22 - Z12.Z21 =  8.00

Y11 = Z22/dZ =  0.19  mho

Y12 = -Z12/dY =  0.01  mho

Y21 = -Z21/-dY =  5.00  mho

Y22 = Z11/dY =  0.50  mho
[[0.1875, 0.00625], [5.0, 0.5]]


## Ex31-pg11.61¶

In [18]:
##Two-Port Networks : example 11.31 :(pg11.61 & 11.62)
print("\nApplying KVL to Mesh 1 \nV1 = 3I1 + 5I2 - - - -(i)");
print("\nApplying KVL to Mesh 2 \nV2 = 2I1 + 4I2 - 2I3 - - - -(ii)");
print("\nApplying KVL to Mesh 3 \nI3 = 2V3 - - - -(iii)");
##substituting (iii) in (i) & (ii),we get
print("\n2V3 = 4I1 + 4I2 \nV2 = -6I1 + 4I2");
print("\nZ-parameters:");
a=3.;b=5.;c=-6.;d=-4.;
print([[a ,b],[c ,d]]);
dZ=(a*d)-(b*c);
Y11=(d/dZ);
Y12=(-b/dZ);
Y21=(-c/dZ);
Y22=(a/dZ);
print("\nY-parameters are:");
print"%s %.2f %s"%("\ndZ = Z11.Z22 - Z12.Z21 = ",dZ,"");
print"%s %.2f %s"%("\nY11 = Z22/dZ = ",Y11," mho");
print"%s %.2f %s"%("\nY12 = -Z12/dY = ",Y12," mho");
print"%s %.2f %s"%("\nY21 = -Z21/-dY = ",Y21," mho");
print"%s %.2f %s"%("\nY22 = Z11/dY = ",Y22," mho");
print([[Y11, Y12],[Y21, Y22]]);

Applying KVL to Mesh 1
V1 = 3I1 + 5I2 - - - -(i)

Applying KVL to Mesh 2
V2 = 2I1 + 4I2 - 2I3 - - - -(ii)

Applying KVL to Mesh 3
I3 = 2V3 - - - -(iii)

2V3 = 4I1 + 4I2
V2 = -6I1 + 4I2

Z-parameters:
[[3.0, 5.0], [-6.0, -4.0]]

Y-parameters are:

dZ = Z11.Z22 - Z12.Z21 =  18.00

Y11 = Z22/dZ =  -0.22  mho

Y12 = -Z12/dY =  -0.28  mho

Y21 = -Z21/-dY =  0.33  mho

Y22 = Z11/dY =  0.17  mho
[[-0.2222222222222222, -0.2777777777777778], [0.3333333333333333, 0.16666666666666666]]