summaryrefslogtreecommitdiff
path: root/3793/CH10/EX10.6/exp_10_6.sce
blob: e0b2e8bf70d5d8f409fdc51c52cabaee6c09b7e1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
clear;
clc;
Sb=30;
vb=11;
sg=20;
p=10;
R=6.6;
//generator
X1=complex(0,.1);
X2=complex(0,.1);
X0=complex(0,.15);
x1=X1*(Sb/sg);
x2=X2*(Sb/sg);
x0=X0*(Sb/sg);
//transformer12
xt1=complex(0,.12);
xt2=complex(0,.12);
xt0=complex(0,.12);
//transmission line
vtr=22;
Ztr=vtr^2/Sb;
Z=complex(1,5);
Zpu=Z/Ztr;
//transformer34
Xt1=complex(0,.05);
Xt2=complex(0,.05);
Xt0=complex(0,.05);
xtt1=Xt1*(Sb/sg);
xtt2=Xt2*(Sb/sg);
xtt0=Xt0*(Sb/sg);
Vf3=1;
Rpu=((Vf3^2)*Sb)/p;
Rf=(R*Sb)/vtr^2;
Il=p/Sb;
Vf4=Vf3+(Il*xtt1);
Zfp=((x1+xt1+Zpu)*(Rpu+xtt1))/(x1+xt1++Zpu+Rpu+xtt1);
Zfn=Zfp;
zf0=Zpu+xt1;
Ia1=Vf3/complex(1.611,1.5); //from figure
Ia0=Ia1;
Ia=3*Ia1;
Va0=-zf0*Ia0;
Va1=Vf3-(Zfn*Ia1);
Va2=-(Zfn*Ia1);
Ibase=(Sb*1000)/(sqrt(3)*vtr);
If=Ibase*Ia;
mprintf("fault current is %f%f A \n",real(If),imag(If));
a=complex(-.5,.866);
A=[1 1 1;1 a^2 a;1 a a^2];
V1=[Va0;Va1;Va2];
V=A*V1;
Vab=V(1,1)-V(2,1);
Vbc=V(2,1)-V(3,1);
Vca=V(3,1)-V(1,1);
mprintf("Actual Line Voltages are Vab=%f+%f Kv   Vbc=%f%f Kv  Vca=%f+%f Kv",real(Vab),imag(Vab),real(Vbc),imag(Vbc),real(Vca),imag(Vca));