diff options
author | prashantsinalkar | 2017-10-10 12:27:19 +0530 |
---|---|---|
committer | prashantsinalkar | 2017-10-10 12:27:19 +0530 |
commit | 7f60ea012dd2524dae921a2a35adbf7ef21f2bb6 (patch) | |
tree | dbb9e3ddb5fc829e7c5c7e6be99b2c4ba356132c /3793/CH13 | |
parent | b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b (diff) | |
download | Scilab-TBC-Uploads-7f60ea012dd2524dae921a2a35adbf7ef21f2bb6.tar.gz Scilab-TBC-Uploads-7f60ea012dd2524dae921a2a35adbf7ef21f2bb6.tar.bz2 Scilab-TBC-Uploads-7f60ea012dd2524dae921a2a35adbf7ef21f2bb6.zip |
initial commit / add all books
Diffstat (limited to '3793/CH13')
-rw-r--r-- | 3793/CH13/EX13.1/exp_13_1.sce | 23 | ||||
-rw-r--r-- | 3793/CH13/EX13.2/exp_13_2.sce | 53 | ||||
-rw-r--r-- | 3793/CH13/EX13.3/exp_13_3.sce | 61 | ||||
-rw-r--r-- | 3793/CH13/EX13.4/exp_13_4.sce | 10 | ||||
-rw-r--r-- | 3793/CH13/EX13.6/exp_13_6.sce | 62 | ||||
-rw-r--r-- | 3793/CH13/EX13.7/exp_13_7.sce | 69 | ||||
-rw-r--r-- | 3793/CH13/EX13.8/exp_13_8.sce | 58 | ||||
-rw-r--r-- | 3793/CH13/EX13.9/exp_13_9.sce | 68 |
8 files changed, 404 insertions, 0 deletions
diff --git a/3793/CH13/EX13.1/exp_13_1.sce b/3793/CH13/EX13.1/exp_13_1.sce new file mode 100644 index 000000000..6d1e5e86f --- /dev/null +++ b/3793/CH13/EX13.1/exp_13_1.sce @@ -0,0 +1,23 @@ +clear;
+clc;
+Yb=[complex(1.14,-4.19) complex(-.59,2.35) complex(0,0) complex(-0.55,1.83);complex(-0.59,2.35) complex(3.76,-9.4) complex(-.77,3.85) complex(-2.4,3.2);complex(0,0) complex(-0.77,3.85) complex(1.77,-6.85) complex(-1,3);complex(-.55,1.83) complex(-2.4,3.2) complex(-1,3) complex(4.19,-8.03)];
+v=[1.02 1 .98 1.04]';
+
+Zb=inv(Yb);
+Zbus=imag(Zb);
+
+Z12={Zbus(1,1)-Zbus(1,2)-(Zbus(2,1)-Zbus(2,2))};
+Z34={Zbus(3,3)-Zbus(3,4)-(Zbus(4,3)-Zbus(4,4))};
+z11=Zbus(1,1)-Zbus(1,2)-(Zbus(2,1)-Zbus(2,2))+0.4;
+z12=Zbus(1,3)-Zbus(1,4)-(Zbus(2,3)-Zbus(2,4));
+z21=Zbus(3,1)-Zbus(3,2)-(Zbus(4,1)-Zbus(4,2));
+z22=Zbus(3,3)-Zbus(3,4)-(Zbus(4,3)-Zbus(4,4))+0.3;
+z=[z11 z12;z21 z22];
+V=[(v(1,1)-v(2,1));(v(3,1)-v(4,1))];
+Ic=inv(z)*V;
+A=[1 -1 0 0;0 0 1 -1];
+delV=-Zbus*A'*Ic;
+VV=v+delV;
+mprintf("Thevenin impedences are Z12=%f Z34=%f\n",Z12,Z34);
+mprintf("New Bus voltages are\n");
+disp(VV);
diff --git a/3793/CH13/EX13.2/exp_13_2.sce b/3793/CH13/EX13.2/exp_13_2.sce new file mode 100644 index 000000000..c64c08433 --- /dev/null +++ b/3793/CH13/EX13.2/exp_13_2.sce @@ -0,0 +1,53 @@ +clear;
+clc;
+Yb=[complex(1.14,-4.19) complex(-.59,2.35) complex(0,0) complex(-0.55,1.83);complex(-0.59,2.35) complex(3.76,-9.4) complex(-.77,3.85) complex(-2.4,3.2);complex(0,0) complex(-0.77,3.85) complex(1.77,-6.85) complex(-1,3);complex(-.55,1.83) complex(-2.4,3.2) complex(-1,3) complex(4.19,-8.03)];
+v=[1.02 1 .98 1.04]';
+
+Zb=inv(Yb);
+Zbus=imag(Zb);
+
+Z12={Zbus(1,1)-Zbus(1,2)-(Zbus(2,1)-Zbus(2,2))};
+Z34={Zbus(3,3)-Zbus(3,4)-(Zbus(4,3)-Zbus(4,4))};
+//case1
+z11=Z12-.4;
+z12=Zbus(1,3)-Zbus(1,4)-(Zbus(2,3)-Zbus(2,4));
+z21=Zbus(3,1)-Zbus(3,2)-(Zbus(4,1)-Zbus(4,2));
+z22=Z34-.3;
+z=[z11 z12;z21 z22];
+V=[(v(1,1)-v(2,1));(v(3,1)-v(4,1))];
+Ic=inv(z)*V;
+A=[1 -1 0 0;0 0 1 -1];
+delV=-Zbus*A'*Ic;
+VV=v+delV;
+disp(z)
+
+mprintf(" Bus voltages for case1 are\n");
+disp(VV);
+//case2
+z11=Z12-.4;
+z12=Zbus(1,3)-Zbus(1,4)-(Zbus(2,3)-Zbus(2,4));
+z21=Zbus(3,1)-Zbus(3,2)-(Zbus(4,1)-Zbus(4,2));
+z22=Z34+.3
+z=[z11 z12;z21 z22];
+V=[(v(1,1)-v(2,1));(v(3,1)-v(4,1))];
+Ic=inv(z)*V;
+A=[1 -1 0 0;0 0 1 -1];
+delV=-Zbus*A'*Ic;
+VV=v+delV;
+
+mprintf(" Bus voltages for case2 are\n");
+disp(VV);
+//case3
+z11=Z12+.4;
+z12=Zbus(1,3)-Zbus(1,4)-(Zbus(2,3)-Zbus(2,4));
+z21=Zbus(3,1)-Zbus(3,2)-(Zbus(4,1)-Zbus(4,2));
+z22=Z34-.3;
+z=[z11 z12;z21 z22];
+V=[(v(1,1)-v(2,1));(v(3,1)-v(4,1))];
+Ic=inv(z)*V;
+A=[1 -1 0 0;0 0 1 -1];
+delV=-Zbus*A'*Ic;
+VV=v+delV;
+
+mprintf(" Bus voltages for case3 are\n");
+disp(VV);
diff --git a/3793/CH13/EX13.3/exp_13_3.sce b/3793/CH13/EX13.3/exp_13_3.sce new file mode 100644 index 000000000..988ad844d --- /dev/null +++ b/3793/CH13/EX13.3/exp_13_3.sce @@ -0,0 +1,61 @@ +clear;
+clc;
+Ybusa=zeros(4,4);
+Ybusb=zeros(4,4);
+Ybusa(1,1)=1/(complex(0,4))+1/(complex(0,.8))+1/(complex(0,.5))+1/(complex(0,.4));
+Ybusa(1,2)=-1/(complex(0,.8));
+Ybusa(2,1)=Ybusa(1,2);
+Ybusa(1,3)=-1/(complex(0,.5));
+Ybusa(3,1)=Ybusa(1,3);
+Ybusa(1,4)=-1/(complex(0,.4));
+Ybusa(4,1)=Ybusa(1,4);
+Ybusa(2,2)=1/(complex(0,.8));
+Ybusa(3,3)=1/(complex(0,.5))+1/(complex(0,.1));
+Ybusa(3,4)=-1/(complex(0,.1));
+Ybusa(4,3)=Ybusa(3,4);
+Ybusa(4,4)=1/(complex(0,.1))+1/(complex(0,.4));
+Ybusb(1,1)=1/(complex(0,.2))+1/(complex(0,.4));
+Ybusb(1,2)=-1/(complex(0,.2));
+Ybusb(2,1)=Ybusb(1,2);
+Ybusb(2,3)=-1/(complex(0,.5));
+Ybusb(3,2)=Ybusb(2,3);
+Ybusb(1,4)=-1/(complex(0,.4));
+Ybusb(4,1)=Ybusb(1,4);
+Ybusb(2,2)=1/(complex(0,.2))+1/(complex(0,.5));
+Ybusb(3,3)=1/(complex(0,5))+1/(complex(0,.5))+1/(complex(0,.25));
+Ybusb(3,4)=-1/(complex(0,.25));
+Ybusb(4,3)=Ybusb(3,4);
+Ybusb(4,4)=1/(complex(0,.25))+1/(complex(0,.4));
+Zbusa=inv(Ybusa);
+Zbusb=inv(Ybusb);
+
+Zbusa(1,:)=[];
+Zbusa(:,1)=[];
+Zbusb(4,:)=[];
+Zbusb(:,4)=[];
+Zbusb(3,:)=[];
+Zbusb(:,3)=[];
+
+AA=[1 0 0;1 0 0;0 0 1];
+Zbounda=AA*Zbusa*AA';
+AB=[-1 0;0 -1;0 -1];
+Zboundb=AB*Zbusb*AB';
+Ztie=[complex(0,.1) 0 0;0 complex(0,.2) 0; 0 0 complex(0,.3)];
+Z=Zbounda+Ztie+Zboundb;
+Va=[complex(1,0); complex(1.0086,-.0529); complex(.9794,-.0342);complex(.999,-.0436)];
+Vb=[complex(.994,-0.0349); complex(1.0047,-.0263); complex(1,0);complex(.9898,.0173)];
+Vdiff=[Va(2)-Vb(1);Va(2)-Vb(2);Va(4)-Vb(2)];
+Itie=inv(Z)*Vdiff;
+Abusa=[0 1 0 0;0 1 0 0;0 0 0 1];
+Vadash=Va-inv(Ybusa)*Abusa'*(-Itie);
+Abusb=[ -1 0 0 0;0 -1 0 0;0 -1 0 0];
+Vbdash=Vb-inv(Ybusb)*Abusb'*(-Itie);
+mprintf("Bus voltages of A power system are");
+disp(Vadash);
+mprintf("Bus voltages of B power system are");
+disp(Vbdash);
+
+
+
+
+
diff --git a/3793/CH13/EX13.4/exp_13_4.sce b/3793/CH13/EX13.4/exp_13_4.sce new file mode 100644 index 000000000..722bc2901 --- /dev/null +++ b/3793/CH13/EX13.4/exp_13_4.sce @@ -0,0 +1,10 @@ +clear;
+clc;
+a=[complex(0,4.8) complex(0,4);complex(0,4) complex(0,4.24)];
+b=[complex(0,5.337) complex(0,5.2407);complex(0,5.2407) complex(0,5.3148)];
+wa=inv(a);
+wb=inv(b);
+mprintf("Ward eqiwalents for power system A is");
+disp(wa);
+mprintf("Ward equivalent for power system B is");
+ disp(wb);
diff --git a/3793/CH13/EX13.6/exp_13_6.sce b/3793/CH13/EX13.6/exp_13_6.sce new file mode 100644 index 000000000..69407faaf --- /dev/null +++ b/3793/CH13/EX13.6/exp_13_6.sce @@ -0,0 +1,62 @@ +clear;
+clc;
+Ybus=zeros(4,4);
+Za=%i*.1;
+Z12=%i*.25;
+Z14=%i*.4;
+Z43=%i*.1;
+Z42=%i*.2;
+Z32=%i*.1;
+Z13=%i*.5;
+Zg=%i*4;
+
+V1=1;
+V2=complex(.9787,-.0513);
+V3=complex(1.019,.0445);
+V4=complex(1.0098,-.0176);
+Ybus(1,1)=1/Zg+1/Z12+1/Z13+1/Z14;
+Ybus(1,2)=-1/Z12;
+Ybus(2,1)=Ybus(1,2);
+Ybus(1,3)=-1/Z13;
+Ybus(3,1)=Ybus(1,3);
+Ybus(1,4)=-1/Z14;
+Ybus(4,1)=Ybus(1,4);
+Ybus(2,2)=1/Z12+1/Z32+1/Z42;
+Ybus(2,3)=-1/Z32;
+Ybus(3,2)=Ybus(2,3);
+Ybus(2,4)=-1/Z42;
+Ybus(4,2)=Ybus(2,4);
+Ybus(3,3)=1/Z13+1/Z43+1/Z32;
+Ybus(3,4)=-1/Z43;
+Ybus(4,3)=Ybus(3,4);
+Ybus(4,4)=1/Z14+1/Z43+1/Z42;
+Z=inv(Ybus);
+Zt34=Z(3,3)+Z(4,4)-2*Z(3,4);
+V=[V1;V2;V3;V4];
+I12=(V1-V2)/Z12;
+I13=(V1-V3)/Z13;
+I14=(V1-V4)/Z14;
+I23=(V2-V3)/Z32;
+I24=(V2-V4)/Z42;
+I34=(V3-V4)/Z43;
+Zaa=-Za;
+Zden=Zt34-Zaa;
+L1234=Zaa/Z12*((Z(1,3)-Z(1,4))-(Z(2,3)-Z(2,4)))/Zden;
+L1334=Zaa/Z13*((Z(1,3)-Z(1,4))-(Z(3,3)-Z(3,4)))/Zden;
+L1434=Zaa/Z14*((Z(1,3)-Z(1,4))-(Z(4,3)-Z(4,4)))/Zden;
+L2334=Zaa/Z32*((Z(2,3)-Z(2,4))-(Z(3,3)-Z(3,4)))/Zden;
+L2434=Zaa/Z42*((Z(2,3)-Z(2,4))-(Z(4,3)-Z(4,4)))/Zden;
+I112=I12+L1234*I34;
+I113=I13+L1334*I34;
+I114=I14+L1434*I34;
+I223=I23+L2334*I34;
+I224=I24+L2434*I34;
+L12=abs(I112)/(4*abs(I12))*100;
+L13=abs(I113)/(4*abs(I13))*100;
+L14=abs(I114)/(4*abs(I14))*100;
+L23=abs(I223)/(1.3333*abs(I23))*100;
+L24=abs(I224)/(1.3333*abs(I24))*100;
+mprintf(" Line-outage distribution factors are L1234=%.3f, L1334=%.3f, L1434=%.3f, L2334=%.3f and L2434=%.3f\n",L1234,L1334,L1434,L2334,L2434);
+mprintf("New values of line current are I12=%.3f %.3f, I13=%.3f+%.3f, I14=%.3f+%.3f, I23=%.3f+%.3f and I24=%.3f+%.3f\n",real(I112),imag(I112),real(I113),imag(I113),real(I114),imag(I114),real(I223),imag(I223),real(I224),imag(I224));
+mprintf("Loading after tripping in percentage is L12=%.3f percent,L13=%.3f percent, L14=%.3f percent, L23=%.3f percent and L24=%.3f percent",L12,L13,L14,L23,L24);
+
diff --git a/3793/CH13/EX13.7/exp_13_7.sce b/3793/CH13/EX13.7/exp_13_7.sce new file mode 100644 index 000000000..d90293d80 --- /dev/null +++ b/3793/CH13/EX13.7/exp_13_7.sce @@ -0,0 +1,69 @@ +clear;
+clc;
+Ybus=zeros(4,4);
+Za=%i*.1;
+Z12=%i*.25;
+Z14=%i*.4;
+Z43=%i*.1;
+Z42=%i*.2;
+Z32=%i*.1;
+Z13=%i*.5;
+Zg=%i*4;
+
+V1=1;
+V2=complex(.9787,-.0513);
+V3=complex(1.019,.0445);
+V4=complex(1.0098,-.0176);
+Ybus(1,1)=1/Zg+1/Z12+1/Z13+1/Z14;
+Ybus(1,2)=-1/Z12;
+Ybus(2,1)=Ybus(1,2);
+Ybus(1,3)=-1/Z13;
+Ybus(3,1)=Ybus(1,3);
+Ybus(1,4)=-1/Z14;
+Ybus(4,1)=Ybus(1,4);
+Ybus(2,2)=1/Z12+1/Z32+1/Z42;
+Ybus(2,3)=-1/Z32;
+Ybus(3,2)=Ybus(2,3);
+Ybus(2,4)=-1/Z42;
+Ybus(4,2)=Ybus(2,4);
+Ybus(3,3)=1/Z13+1/Z43+1/Z32;
+Ybus(3,4)=-1/Z43;
+Ybus(4,3)=Ybus(3,4);
+Ybus(4,4)=1/Z14+1/Z43+1/Z42;
+Z=inv(Ybus);
+Zt34=Z(3,3)+Z(4,4)-2*Z(3,4);
+V=[V1;V2;V3;V4];
+I12=(V1-V2)/Z12;
+I13=(V1-V3)/Z13;
+I14=(V1-V4)/Z14;
+I23=(V2-V3)/Z32;
+I24=(V2-V4)/Z42;
+I34=(V3-V4)/Z43;
+Zaa=-Za;
+Zden=Zt34-Zaa;
+L1234=Zaa/Z12*((Z(1,3)-Z(1,4))-(Z(2,3)-Z(2,4)))/Zden;
+L1334=Zaa/Z13*((Z(1,3)-Z(1,4))-(Z(3,3)-Z(3,4)))/Zden;
+L1434=Zaa/Z14*((Z(1,3)-Z(1,4))-(Z(4,3)-Z(4,4)))/Zden;
+L2334=Zaa/Z32*((Z(2,3)-Z(2,4))-(Z(3,3)-Z(3,4)))/Zden;
+L2434=Zaa/Z42*((Z(2,3)-Z(2,4))-(Z(4,3)-Z(4,4)))/Zden;
+I112=I12+L1234*I34;
+I113=I13+L1334*I34;
+I114=I14+L1434*I34;
+I223=I23+L2334*I34;
+I224=I24+L2434*I34;
+Iinj=Ybus*V;
+S1=V(1)*conj(Iinj(1));
+S2=V(2)*conj(Iinj(2));
+S3=V(3)*conj(Iinj(3));
+S4=V(4)*conj(Iinj(4));
+K321=(Z(3,1)-Z(2,1))/Z32;
+K323=(Z(3,3)-Z(2,3))/Z32;
+delIinj1=.8340;
+delIinj3=-delIinj1;
+delI32=K321*delIinj1+K323*delIinj3;
+I32d=I23+delI32;
+In=[(Iinj(1,1)+delIinj1);Iinj(2,1);(Iinj(3,1)+delIinj3);Iinj(4,1)];
+Vnew=inv(Ybus)*In;
+I32n=(Vnew(3)-Vnew(2))/Z32;
+mprintf("Power at each bus are S1=%.4f+%.4f, S2=%.4f%.4f, S3=%.4f+%.4f and S4=%.4f+%.4f\n",real(S1),imag(S1),real(S2),imag(S2),real(S3),imag(S3),real(S4),imag(S4));
+mprintf("Change in current is I32=%.4f%.4f",real(I32n),imag(I32n));
diff --git a/3793/CH13/EX13.8/exp_13_8.sce b/3793/CH13/EX13.8/exp_13_8.sce new file mode 100644 index 000000000..91072a828 --- /dev/null +++ b/3793/CH13/EX13.8/exp_13_8.sce @@ -0,0 +1,58 @@ +clear;
+clc;
+Ybus=zeros(4,4);
+Za=%i*.1;
+Z12=%i*.25;
+Z14=%i*.4;
+Z43=%i*.1;
+Z42=%i*.2;
+Z32=%i*.1;
+Z13=%i*.5;
+Zg=%i*4;
+
+V1=1;
+V2=complex(.9787,-.0513);
+V3=complex(1.019,.0445);
+V4=complex(1.0098,-.0176);
+Ybus(1,1)=1/Zg+1/Z12+1/Z13+1/Z14;
+Ybus(1,2)=-1/Z12;
+Ybus(2,1)=Ybus(1,2);
+Ybus(1,3)=-1/Z13;
+Ybus(3,1)=Ybus(1,3);
+Ybus(1,4)=-1/Z14;
+Ybus(4,1)=Ybus(1,4);
+Ybus(2,2)=1/Z12+1/Z32+1/Z42;
+Ybus(2,3)=-1/Z32;
+Ybus(3,2)=Ybus(2,3);
+Ybus(2,4)=-1/Z42;
+Ybus(4,2)=Ybus(2,4);
+Ybus(3,3)=1/Z13+1/Z43+1/Z32;
+Ybus(3,4)=-1/Z43;
+Ybus(4,3)=Ybus(3,4);
+Ybus(4,4)=1/Z14+1/Z43+1/Z42;
+Z=inv(Ybus);
+Zt34=Z(3,3)+Z(4,4)-2*Z(3,4);
+V=[V1;V2;V3;V4];
+I12=(V1-V2)/Z12;
+I13=(V1-V3)/Z13;
+I14=(V1-V4)/Z14;
+I23=(V2-V3)/Z32;
+I24=(V2-V4)/Z42;
+I34=(V3-V4)/Z43;
+Zaa=-Za;
+Zden=Zt34-Zaa;
+L1234=Zaa/Z12*((Z(1,3)-Z(1,4))-(Z(2,3)-Z(2,4)))/Zden;
+L1334=Zaa/Z13*((Z(1,3)-Z(1,4))-(Z(3,3)-Z(3,4)))/Zden;
+L1434=Zaa/Z14*((Z(1,3)-Z(1,4))-(Z(4,3)-Z(4,4)))/Zden;
+L2334=Zaa/Z32*((Z(2,3)-Z(2,4))-(Z(3,3)-Z(3,4)))/Zden;
+L2434=Zaa/Z42*((Z(2,3)-Z(2,4))-(Z(4,3)-Z(4,4)))/Zden;
+Zb=-Za;
+Zt23=Z(2,2)+Z(3,3)-2*Z(2,3);
+Zden1=Zt23-Zb;
+L1423=Zb/Z14*((Z(1,2)-Z(1,3))-(Z(4,2)-Z(4,3)))/Zden1;
+L3423=Zb/Z43*((Z(3,2)-Z(3,3))-(Z(4,2)-Z(4,3)))/Zden1;
+L11=(L1423+L1434*L3423)/(1-L2334*L3423);
+L12=(L1434+L1423*L2334)/(1-L2334*L3423);
+I14d=I14+(L11*I23+L12*I34);
+mprintf("Change in current line connected buses 1-4 is %.4f+%.4f",real(I14d),imag(I14d));
+
diff --git a/3793/CH13/EX13.9/exp_13_9.sce b/3793/CH13/EX13.9/exp_13_9.sce new file mode 100644 index 000000000..994cb6333 --- /dev/null +++ b/3793/CH13/EX13.9/exp_13_9.sce @@ -0,0 +1,68 @@ +clear;
+clc;
+Ybus=zeros(4,4);
+Za=%i*.1;
+Z12=%i*.25;
+Z14=%i*.4;
+Z43=%i*.1;
+Z42=%i*.2;
+Z32=%i*.1;
+Z13=%i*.5;
+Zg=%i*4;
+
+V1=1;
+V2=complex(.9787,-.0513);
+V3=complex(1.019,.0445);
+V4=complex(1.0098,-.0176);
+Ybus(1,1)=1/Zg+1/Z12+1/Z13+1/Z14;
+Ybus(1,2)=-1/Z12;
+Ybus(2,1)=Ybus(1,2);
+Ybus(1,3)=-1/Z13;
+Ybus(3,1)=Ybus(1,3);
+Ybus(1,4)=-1/Z14;
+Ybus(4,1)=Ybus(1,4);
+Ybus(2,2)=1/Z12+1/Z32+1/Z42;
+Ybus(2,3)=-1/Z32;
+Ybus(3,2)=Ybus(2,3);
+Ybus(2,4)=-1/Z42;
+Ybus(4,2)=Ybus(2,4);
+Ybus(3,3)=1/Z13+1/Z43+1/Z32;
+Ybus(3,4)=-1/Z43;
+Ybus(4,3)=Ybus(3,4);
+Ybus(4,4)=1/Z14+1/Z43+1/Z42;
+Z=inv(Ybus);
+Zt34=Z(3,3)+Z(4,4)-2*Z(3,4);
+V=[V1;V2;V3;V4];
+I12=(V1-V2)/Z12;
+I13=(V1-V3)/Z13;
+I14=(V1-V4)/Z14;
+I23=(V2-V3)/Z32;
+I24=(V2-V4)/Z42;
+I34=(V3-V4)/Z43;
+Zaa=-Za;
+Zden=Zt34-Zaa;
+L1234=Zaa/Z12*((Z(1,3)-Z(1,4))-(Z(2,3)-Z(2,4)))/Zden;
+L1334=Zaa/Z13*((Z(1,3)-Z(1,4))-(Z(3,3)-Z(3,4)))/Zden;
+L1434=Zaa/Z14*((Z(1,3)-Z(1,4))-(Z(4,3)-Z(4,4)))/Zden;
+L2334=Zaa/Z32*((Z(2,3)-Z(2,4))-(Z(3,3)-Z(3,4)))/Zden;
+L2434=Zaa/Z42*((Z(2,3)-Z(2,4))-(Z(4,3)-Z(4,4)))/Zden;
+I112=I12+L1234*I34;
+I113=I13+L1334*I34;
+I114=I14+L1434*I34;
+I223=I23+L2334*I34;
+I224=I24+L2434*I34;
+Iinj=Ybus*V;
+S1=V(1)*conj(Iinj(1));
+S2=V(2)*conj(Iinj(2));
+S3=V(3)*conj(Iinj(3));
+S4=V(4)*conj(Iinj(4));
+L3234=Zaa/Z43*((Z(3,3)-Z(3,4))-(Z(2,3)-Z(2,4)))/Zden;
+K323=(Z(3,3)-Z(2,3))/Z43;
+K321=(Z(3,1)-Z(2,1))/Z43;
+K341=(Z(3,1)-Z(4,1))/Z43;
+K343=(Z(3,3)-Z(4,3))/Z43;
+K323d=K323+L3234*K343;
+K321d=K321+L3234*K341;
+delP32=K323d*(-1.6760/2)+K321d*(1.670/2);
+mprintf("Change in power flow is %.4f",delP32);
+
|