diff options
Diffstat (limited to '671')
317 files changed, 5271 insertions, 0 deletions
diff --git a/671/CH1/EX1.1/1_1.sce b/671/CH1/EX1.1/1_1.sce new file mode 100755 index 000000000..b74b62d28 --- /dev/null +++ b/671/CH1/EX1.1/1_1.sce @@ -0,0 +1,25 @@ +disp("v1=A cos(w t+p)")
+disp("i1=B cos(w1 t+p1)")
+disp("i2=C sin(w2 t+p2)")
+disp("All values in degrees")
+w=input("w=")
+p=input("p=")
+w1=input("w1=")
+p1=input("p1=")
+w2=input("w2=")
+p2=input("p2=")
+
+if(w==w1)
+ lag1=p-p1;
+ disp(lag1, "i1 lags v1 by ")
+else
+ disp("Lag undefined for i1")
+end
+
+
+if(w==w2)
+ lag2=p-p2+90;
+ disp(lag2, "i2 lags v1 by ")
+else
+ disp("Lag undefined for i2")
+end
\ No newline at end of file diff --git a/671/CH1/EX1.10/1_10.sce b/671/CH1/EX1.10/1_10.sce new file mode 100755 index 000000000..07e6b3f40 --- /dev/null +++ b/671/CH1/EX1.10/1_10.sce @@ -0,0 +1,10 @@ +v1=6
+i2=2
+i3=4
+
+v2=2*i2
+v3=2*i3
+
+v4=-v1+4*i2+v3-v2 //KVL
+i4=v4/3
+disp(i4)
\ No newline at end of file diff --git a/671/CH1/EX1.11/1_11.sce b/671/CH1/EX1.11/1_11.sce new file mode 100755 index 000000000..ea9a3cf38 --- /dev/null +++ b/671/CH1/EX1.11/1_11.sce @@ -0,0 +1,12 @@ +i1=4-1 // KCL at node 1
+disp(i1,"i1=")
+
+v1=i1*1
+v12=1*1
+v2=v1-v12
+i2=v2/1
+
+i3=1-i2 //KCL at node 2
+
+Vs=v2-1*i3 //KVL
+disp(Vs,"Vs=")
\ No newline at end of file diff --git a/671/CH1/EX1.12/1_12.sce b/671/CH1/EX1.12/1_12.sce new file mode 100755 index 000000000..dc5335808 --- /dev/null +++ b/671/CH1/EX1.12/1_12.sce @@ -0,0 +1,13 @@ +i34=10-8 //KCL at node 4
+v34=5*i34
+v23=40-10 //KVL
+vx=v23
+disp(vx,"vx=")
+ix=4-8 //KCL at node 1
+disp(ix,"ix=")
+i23=ix+10 //KCL at node 2
+R2=vx/i23
+disp(R2,"R2=")
+v14=40+6*ix //KVL
+R1=v14/8
+disp(R1,"R1=")
\ No newline at end of file diff --git a/671/CH1/EX1.13/1_13.sce b/671/CH1/EX1.13/1_13.sce new file mode 100755 index 000000000..bf45efe44 --- /dev/null +++ b/671/CH1/EX1.13/1_13.sce @@ -0,0 +1,6 @@ +vs=0.01 // *cos(1000*t)
+
+vpi=vs
+i0=-vpi/1000
+vo=i0*1000;
+printf("v0 = %f *cos(1000*t)",vo)
\ No newline at end of file diff --git a/671/CH1/EX1.15/1_15.sce b/671/CH1/EX1.15/1_15.sce new file mode 100755 index 000000000..22a65b563 --- /dev/null +++ b/671/CH1/EX1.15/1_15.sce @@ -0,0 +1,11 @@ +t=0.1
+R=800
+i=50*exp(-10*t)/1000
+v=50*cos(25*t)
+v_i=10*t^(2.5)
+
+P1=i*i*R
+P2=v*v/R
+P3=v_i
+
+disp(P3,P2,P1)
\ No newline at end of file diff --git a/671/CH1/EX1.2/1_2.sce b/671/CH1/EX1.2/1_2.sce new file mode 100755 index 000000000..606d3307d --- /dev/null +++ b/671/CH1/EX1.2/1_2.sce @@ -0,0 +1,16 @@ +// X cos(w t+p)+Y sin(w t+q)
+
+X=50
+Y=-30
+w=120
+p=-45
+p=p/180*%pi;
+q=160
+q=q/180*%pi;
+
+//Part1
+
+A=X*cos(p)+ Y*sin(q);
+B=-X*sin(p)+ Y*cos(q);
+
+disp(B,"B=",A,"A=")
diff --git a/671/CH1/EX1.3/1_3.sce b/671/CH1/EX1.3/1_3.sce new file mode 100755 index 000000000..a49afbe80 --- /dev/null +++ b/671/CH1/EX1.3/1_3.sce @@ -0,0 +1,11 @@ +G1=input("G1=")
+G2=input("G2=")
+G3=input("G3=")
+Is1=input("Is1=")
+Is2=input("Is2=")
+
+A=[G1+G3,-G3;-G3,G2+G3];
+I=[Is1;Is2];
+V=inv(A)*I;
+
+disp(V)
\ No newline at end of file diff --git a/671/CH1/EX1.5/1_5.sce b/671/CH1/EX1.5/1_5.sce new file mode 100755 index 000000000..4e6810e00 --- /dev/null +++ b/671/CH1/EX1.5/1_5.sce @@ -0,0 +1,13 @@ +
+
+R1=input("R1=")
+R2=input("R2=")
+R3=input("R3=")
+Vs1=input("Vs1=")
+Vs2=input("Vs2=")
+
+R=[R1+R3,-R3;-R3,R2+R3];
+V=[Vs1;-Vs2];
+I=inv(R)*V;
+
+disp(I)
\ No newline at end of file diff --git a/671/CH1/EX1.7/1_7.sce b/671/CH1/EX1.7/1_7.sce new file mode 100755 index 000000000..eb60016c5 --- /dev/null +++ b/671/CH1/EX1.7/1_7.sce @@ -0,0 +1,23 @@ +R1=1
+R2=6
+R3=12
+R4=4
+I4=3/4
+V6=6
+
+V4=3/4*4
+I12=3/12
+IR=3/4+I12
+
+R=-12*I12+V6 //KVL
+disp(R,"R(Ohm)=")
+
+I6=V6/6
+I1=I6+IR
+
+Vs=1*I1+V6 //KVL
+disp(Vs, "Vs(V)=")
+
+disp(Vs*I1,"Power(W)=")
+
+
diff --git a/671/CH1/EX1.9/1_9.sce b/671/CH1/EX1.9/1_9.sce new file mode 100755 index 000000000..459dc2615 --- /dev/null +++ b/671/CH1/EX1.9/1_9.sce @@ -0,0 +1,11 @@ +i1=4
+v3=3
+v4=8
+
+i3=v3/3
+i4=v4/4
+
+i2=(i1-i3-i4)/2 //KCL
+v2=2*i2
+
+disp(v2,"v2=")
\ No newline at end of file diff --git a/671/CH1/EX1.A.1/1_A_1.sce b/671/CH1/EX1.A.1/1_A_1.sce new file mode 100755 index 000000000..22a65b563 --- /dev/null +++ b/671/CH1/EX1.A.1/1_A_1.sce @@ -0,0 +1,11 @@ +t=0.1
+R=800
+i=50*exp(-10*t)/1000
+v=50*cos(25*t)
+v_i=10*t^(2.5)
+
+P1=i*i*R
+P2=v*v/R
+P3=v_i
+
+disp(P3,P2,P1)
\ No newline at end of file diff --git a/671/CH1/EX1.A.2/1_A_2.sce b/671/CH1/EX1.A.2/1_A_2.sce new file mode 100755 index 000000000..f523b8b2f --- /dev/null +++ b/671/CH1/EX1.A.2/1_A_2.sce @@ -0,0 +1,6 @@ +v2=5
+i2=v2/1000
+v1=-i2/5
+vs=v1
+
+disp(vs)
\ No newline at end of file diff --git a/671/CH1/EX1.A.3/1_A_3.sce b/671/CH1/EX1.A.3/1_A_3.sce new file mode 100755 index 000000000..a2ed3cd2d --- /dev/null +++ b/671/CH1/EX1.A.3/1_A_3.sce @@ -0,0 +1,39 @@ +L=20/1000 + +///////////////////////////// +disp("Part1") +function i = i(t) + i = 8*exp(-100*t); +endfunction + +t=10/1000 +v= L*(derivative(i,t)) +disp(v,"V=") + +/////////////////////////////Part2 +disp("Part2") +t=0.1 + +function v=v(t) + v=6*exp(-12*t) +endfunction + +i0=8 + +i2=1/L*intg(0,t,v)+i0 +disp(i2) + +////////////////////////////Part3 +disp("Part3") +function i3 = i3(t) + i3 = 10-10*exp(-50*t); +endfunction + +t=40/1000 +v3=L*(derivative(i3,t)) +P40=v3*i3(t) +disp(P40) + +t=50/1000 +P50=1/2*L*(i3(50)^2) +disp(P50)
\ No newline at end of file diff --git a/671/CH1/EX1.A.4/1_A_4.sce b/671/CH1/EX1.A.4/1_A_4.sce new file mode 100755 index 000000000..06b30374b --- /dev/null +++ b/671/CH1/EX1.A.4/1_A_4.sce @@ -0,0 +1,9 @@ +function i = i(t) + i = 9*sin(%pi*t)/1000; +endfunction + +t=200/1000 +CV=intg(0,t,i) +Wc=300E-6 +C=(CV^2)/(2*Wc) +disp(C)
\ No newline at end of file diff --git a/671/CH1/EX1.A.5/1_A_5.sce b/671/CH1/EX1.A.5/1_A_5.sce new file mode 100755 index 000000000..c99451ab7 --- /dev/null +++ b/671/CH1/EX1.A.5/1_A_5.sce @@ -0,0 +1,10 @@ +L=25E-3
+
+T=5/1000
+I=1/L*integrate('25*cos(500*t)','t',0,T)
+P=25*cos(500*T)*I
+
+t1=%pi/2/500 /////power absorbed zero
+t2=%pi/500 /////energy stored zero
+
+disp(I,P,t1,t2)
\ No newline at end of file diff --git a/671/CH1/EX1.A.6/1_A_6.sce b/671/CH1/EX1.A.6/1_A_6.sce new file mode 100755 index 000000000..7230237e1 --- /dev/null +++ b/671/CH1/EX1.A.6/1_A_6.sce @@ -0,0 +1,14 @@ +e0=8.85E-12
+er=1
+A=%pi*(1/200)^2
+d=150/1000000
+C=er*e0*A/d
+
+E=1/1000
+v=sqrt(2*E/C)
+disp(v)
+
+E=2/1000000
+v=100
+er=2*E/(v^2)/C
+disp(er)
\ No newline at end of file diff --git a/671/CH1/EX1.A.7/1_A_7.sce b/671/CH1/EX1.A.7/1_A_7.sce new file mode 100755 index 000000000..d087697e6 --- /dev/null +++ b/671/CH1/EX1.A.7/1_A_7.sce @@ -0,0 +1,7 @@ +t=10/1000
+v3=8*exp(-50*t)
+p3=v3*(-3.6)
+P=[230/1000*4.8; (-3.2)*1.45;p3]
+
+disp("Power absorbed are respectively")
+disp(P)
\ No newline at end of file diff --git a/671/CH1/EX1.A.9/1_A_9.sce b/671/CH1/EX1.A.9/1_A_9.sce new file mode 100755 index 000000000..cb0aeed89 --- /dev/null +++ b/671/CH1/EX1.A.9/1_A_9.sce @@ -0,0 +1,20 @@ +Im=250/1000
+w=100
+r=4
+L=50/1000
+t=25/1000
+
+i=Im*sin(w*t)
+Vr=i*r
+Vl=Im*L*w*cos(w*t)
+
+Pr=i*i*r
+Pl=Vl*i
+wl=1/2*L*i*i
+wl_min=0 //min current =0
+wl_max=1/2*L*Im*Im //Im is the max current
+
+disp("All values in Joules")
+disp(wl_max,wl_min,wl,Pl,Pr)
+
+
diff --git a/671/CH10/EX10.1/10_1.sce b/671/CH10/EX10.1/10_1.sce new file mode 100755 index 000000000..c109fed3f --- /dev/null +++ b/671/CH10/EX10.1/10_1.sce @@ -0,0 +1,18 @@ +P=6
+S=36
+coilside=2
+N=8
+A=2
+d=0.25
+l=0.18
+Ia=10
+avgflux=0.8
+n=1200
+
+Z=S*coilside*N
+flux=%pi*d/P*l*avgflux
+Ea=flux*n*Z/60*P/A
+Pm=Ea*Ia
+disp(Pm)
+T=Pm/2/%pi/n*60
+disp(T)
diff --git a/671/CH10/EX10.10/10_10.sce b/671/CH10/EX10.10/10_10.sce new file mode 100755 index 000000000..dd80e3404 --- /dev/null +++ b/671/CH10/EX10.10/10_10.sce @@ -0,0 +1,22 @@ +V=300
+Ea=V
+n1=1200
+n2=1100
+Kaphi=Ea/2/%pi/n1*60
+
+T=350
+Ia=T/Kaphi
+disp(Ia)
+Ea=V*n2/n1
+Pm=Ea*Ia
+disp(Pm)
+
+Ra=(V-Ea)/Ia
+disp(Ra)
+
+disp(T)
+Ea=600-Ia*Ra
+n=Ea*60/Kaphi/2/%pi
+Pm=Ea*Ia
+disp(Pm)
+disp(n)
diff --git a/671/CH10/EX10.11/10_11.sce b/671/CH10/EX10.11/10_11.sce new file mode 100755 index 000000000..5d7e126f3 --- /dev/null +++ b/671/CH10/EX10.11/10_11.sce @@ -0,0 +1,20 @@ +V=300
+Ea=V
+n1=1200
+n2=1100
+Kaphi=Ea/2/%pi/n1*60
+
+T=350
+Ia=T/Kaphi
+Ea=V*n2/n1
+
+Ra=(V-Ea)/Ia
+
+
+Kaphi=Kaphi/2
+n=Ea/Kaphi*60/2/%pi
+Pm=Ea*Ia
+T=Kaphi*Ia
+disp(T)
+disp(Pm)
+disp(n)
diff --git a/671/CH10/EX10.12/10_12.sce b/671/CH10/EX10.12/10_12.sce new file mode 100755 index 000000000..02c6f7808 --- /dev/null +++ b/671/CH10/EX10.12/10_12.sce @@ -0,0 +1,15 @@ +V=600
+Ia=40
+R=0.5
+Ea=V-Ia*R
+n=500
+Ka=Ea/Ia/2/%pi/n*60
+T=Ka*Ia*Ia
+
+n2=450
+T=T*n2*n2/n/n
+Ia=sqrt(T/Ka)
+Ea=Ka*Ia*2*%pi*n2/60
+Rtotal=(V-Ea)/Ia
+Rext=Rtotal-R
+disp(Rext)
diff --git a/671/CH10/EX10.13/10_13.sce b/671/CH10/EX10.13/10_13.sce new file mode 100755 index 000000000..106e568e2 --- /dev/null +++ b/671/CH10/EX10.13/10_13.sce @@ -0,0 +1,9 @@ +V=220
+Ra=1
+Rse=0.4
+Ia1=20
+Ia2=sqrt(Ia1*Ia1*0.7*0.7*0.7)
+Ea1=V-Ia1*(Ra+Rse)
+Ea2=Ia2*0.7*Ea1/Ia1
+Rext=(V-Ea2)/Ia2-Ra-Rse
+disp(Rext)
diff --git a/671/CH10/EX10.14/10_14.sce b/671/CH10/EX10.14/10_14.sce new file mode 100755 index 000000000..4776a951a --- /dev/null +++ b/671/CH10/EX10.14/10_14.sce @@ -0,0 +1,11 @@ +V=250
+Ia=25
+n=1000
+KaNfNse=V/Ia*60/2/%pi/n
+T=KaNfNse*Ia*Ia
+Ia=sqrt(V*2/KaNfNse/sqrt(KaNfNse*2*%pi*n/60*2*%pi*n/60/T/2))
+w=sqrt(KaNfNse*2*%pi*n/60*2*%pi*n/60/T/2)*Ia
+n=w*60/2/%pi
+
+disp(n)
+disp(Ia)
diff --git a/671/CH10/EX10.15/10_15.sce b/671/CH10/EX10.15/10_15.sce new file mode 100755 index 000000000..62ec46ab5 --- /dev/null +++ b/671/CH10/EX10.15/10_15.sce @@ -0,0 +1,24 @@ +V=230
+Rf=120
+Ra=0.15
+If=V/Rf
+Psh=V*V/Rf
+
+I=14.5
+Pin=I*V
+Ia=I-If
+Pk=Pin-Ia*Ia*Ra
+
+I=215
+Ia=I-If
+Pl=Ia*Ia*Ra+Pk
+Pin=V*I
+effi=(Pin-Pl)/Pin
+disp(effi)
+
+Ia=sqrt(Pk/Ra)
+Il=Ia+If
+Pl=2*Pk
+Pin=V*Il
+effi=(Pin-Pl)/Pin
+disp(effi)
diff --git a/671/CH10/EX10.16/10_16.sce b/671/CH10/EX10.16/10_16.sce new file mode 100755 index 000000000..c9935b46a --- /dev/null +++ b/671/CH10/EX10.16/10_16.sce @@ -0,0 +1,21 @@ +V=250
+Rf=125
+Ra=0.2
+If=V/Rf
+I=16
+Ia0=I-If
+Pk=V*Ia0-Ia0*Ia0*Ra+V*If
+
+I=152
+Ia=I-If
+Pl=Ia*Ia*Ra+Pk
+Pin=V*I
+effi=(Pin-Pl)/Pin
+disp(effi)
+
+Il=152
+Ia=Il+If
+Pl=Ia*Ia*Ra+Pk
+Pout=V*Il
+effi=Pout/(Pout+Pl)
+disp(effi)
diff --git a/671/CH10/EX10.17/10_17.sce b/671/CH10/EX10.17/10_17.sce new file mode 100755 index 000000000..864dd1e9e --- /dev/null +++ b/671/CH10/EX10.17/10_17.sce @@ -0,0 +1,13 @@ +V=250
+n=800
+Ra=0.15
+Rse=0.1
+R=Ra+Rse
+
+Ia1=120
+Ea1=V-Ia1*R
+
+Ia2=60
+Ea2=V-Ia2*R
+n2=Ea2/Ea1*n/0.7
+disp(n2)
diff --git a/671/CH10/EX10.18/10_18.sce b/671/CH10/EX10.18/10_18.sce new file mode 100755 index 000000000..fd005b957 --- /dev/null +++ b/671/CH10/EX10.18/10_18.sce @@ -0,0 +1,9 @@ +R=1.2
+V=220
+Ea35=V-35*R
+n35=(475+400)/2
+
+V=200
+E0=V-35*(R+2)
+n=n35*E0/Ea35
+disp(n)
diff --git a/671/CH10/EX10.19/10_19.sce b/671/CH10/EX10.19/10_19.sce new file mode 100755 index 000000000..22b908d08 --- /dev/null +++ b/671/CH10/EX10.19/10_19.sce @@ -0,0 +1,18 @@ +V=250
+Ia=200
+Ra=0.22
+
+Ea=V-Ia*Ra
+Pm=Ea*Ia
+Prl=600
+Pmout=Pm-Prl
+n=1250
+wm=2*%pi*n/60
+Tl=Pmout/wm
+disp(Tl)
+
+Rf=125
+Psh=V*V/Rf
+Pein=V*Ia+Psh
+effi=Pmout/Pein
+disp(effi)
diff --git a/671/CH10/EX10.2/10_2.sce b/671/CH10/EX10.2/10_2.sce new file mode 100755 index 000000000..598d36290 --- /dev/null +++ b/671/CH10/EX10.2/10_2.sce @@ -0,0 +1,23 @@ +P=4
+A=4
+ra=0.145
+l=0.21
+Z=2*33*11
+K=Z*P/2/%pi/A
+disp(K)
+
+Ap=2*%pi*ra/P*0.7*l
+Barc=0.8
+flux=Ap*Barc
+n=1200
+Ea=K*flux*2*%pi*n/60
+disp(Ea)
+
+Ia=240
+Ic=Ia/A
+disp(Ic)
+
+T=K*flux*Ia
+disp(T)
+Pg=Ea*Ia
+disp(Pg)
diff --git a/671/CH10/EX10.20/10_20.sce b/671/CH10/EX10.20/10_20.sce new file mode 100755 index 000000000..bc3b06885 --- /dev/null +++ b/671/CH10/EX10.20/10_20.sce @@ -0,0 +1,20 @@ +P=25000
+n=1600
+V=250
+If=1.5
+Rf=V/If
+disp(Rf)
+
+Ra=0.1
+V=220
+Ia=P/V
+Ea=V-Ia*Ra
+If=0.875
+disp(If)
+Rf=V/If
+disp(Rf)
+
+Pdev=Ea*Ia
+disp(Pdev)
+Tdev=Pdev/2/%pi/n*60
+disp(Tdev)
diff --git a/671/CH10/EX10.21/10_21.sce b/671/CH10/EX10.21/10_21.sce new file mode 100755 index 000000000..51965132b --- /dev/null +++ b/671/CH10/EX10.21/10_21.sce @@ -0,0 +1,16 @@ +
+V=230
+Ea=210
+Ia=40
+Ra=(V-Ea)/Ia
+disp(Ra)
+
+Pdev=Ea*Ia
+n=1200
+wm=2*%pi*n/60
+Tdev=Pdev/wm
+disp(Pdev)
+disp(Tdev)
+
+n=n*V/Ea
+disp(n)
diff --git a/671/CH10/EX10.22/10_22.sce b/671/CH10/EX10.22/10_22.sce new file mode 100755 index 000000000..47f399386 --- /dev/null +++ b/671/CH10/EX10.22/10_22.sce @@ -0,0 +1,17 @@ +V=400
+Ia=50
+n=500
+Ra=0.5
+Ea=V-Ia*Ra
+Tdev=Ea*Ia/2/%pi/n*60
+
+Iastart=75
+Rs=V/Iastart-Ra
+disp(Rs)
+Tstart=Tdev*(Iastart/Ia)^2
+disp(Tstart)
+
+n2=200
+Ea200=Ea*n2/n
+Rs=(V-Ea200)/Iastart-Ra
+disp(Rs)
diff --git a/671/CH10/EX10.23/10_23.sce b/671/CH10/EX10.23/10_23.sce new file mode 100755 index 000000000..b008cf848 --- /dev/null +++ b/671/CH10/EX10.23/10_23.sce @@ -0,0 +1,6 @@ +n1=1200
+Rfcrit=260/4
+n2=1600
+Vfactor=n2/n2
+Vnl=395
+disp(Vnl)
diff --git a/671/CH10/EX10.24/10_24.sce b/671/CH10/EX10.24/10_24.sce new file mode 100755 index 000000000..095b0df97 --- /dev/null +++ b/671/CH10/EX10.24/10_24.sce @@ -0,0 +1,7 @@ +
+Ia=500
+Ra=0.05
+Vb=2
+Va=Ia*Ra+Vb
+Vt=330
+disp(Vt)
diff --git a/671/CH10/EX10.25/10_25.sce b/671/CH10/EX10.25/10_25.sce new file mode 100755 index 000000000..eb3bb7b5b --- /dev/null +++ b/671/CH10/EX10.25/10_25.sce @@ -0,0 +1,11 @@ +V=240
+Ea=V
+n=800
+I=16
+Ke=V/n/I
+K=I/n
+
+n=sqrt(V*2/Ke/K/sqrt(2))
+disp(n)
+Ia=sqrt(2)*K*n
+disp(Ia)
diff --git a/671/CH10/EX10.26/10_26.sce b/671/CH10/EX10.26/10_26.sce new file mode 100755 index 000000000..4aa24ca6d --- /dev/null +++ b/671/CH10/EX10.26/10_26.sce @@ -0,0 +1,22 @@ +V=600
+Pout=60000
+effi=0.85
+Pin=Pout/effi
+Il=Pin/V
+Rf=100
+If=V/Rf
+Ia=Il-If
+Ra=0.16
+Ea=V-Ia*Ra
+
+n=900
+n0=n*V/Ea
+sr=n0/n-1
+disp(n0)
+disp(sr)
+
+TL=Pin-Pout
+Pcu=Ia*Ia*Ra
+Psh=If*If*Rf
+Prl=TL-Pcu-Psh
+disp(Prl)
diff --git a/671/CH10/EX10.3/10_3.sce b/671/CH10/EX10.3/10_3.sce new file mode 100755 index 000000000..e44d8e547 --- /dev/null +++ b/671/CH10/EX10.3/10_3.sce @@ -0,0 +1,9 @@ +P=5000
+Vt=215
+n=1000
+Ra=0.4
+Ia=P/Vt
+Eag=Vt+Ra*Ia
+Eam=Vt-Ra*Ia
+newn=Eam/Eag*n/1.1
+disp(newn)
diff --git a/671/CH10/EX10.4/10_4.sce b/671/CH10/EX10.4/10_4.sce new file mode 100755 index 000000000..eeac8f001 --- /dev/null +++ b/671/CH10/EX10.4/10_4.sce @@ -0,0 +1,11 @@ +P=200000
+V=400
+n=600
+Z=864
+Pl=8000
+
+Ia=P/V
+Ra=Pl/Ia/Ia
+Ea=V-Ia*Ra
+flux=Ea*60/n/Z
+disp(flux)
diff --git a/671/CH10/EX10.5/10_5.sce b/671/CH10/EX10.5/10_5.sce new file mode 100755 index 000000000..0c5bd6cc6 --- /dev/null +++ b/671/CH10/EX10.5/10_5.sce @@ -0,0 +1,18 @@ +N=1800
+///////from figure
+Voc=250
+If=4.1
+Rf=Voc/If
+disp(If)
+disp(Rf)
+
+Rfcrit=150/2
+disp(Rfcrit)
+
+V3=120
+Ncrit=N*V3/150
+disp(Ncrit)
+
+Rf220=220/3.2
+Rext=Rf220-Rf
+disp(Rext)
diff --git a/671/CH10/EX10.6/10_6.sce b/671/CH10/EX10.6/10_6.sce new file mode 100755 index 000000000..31db64a43 --- /dev/null +++ b/671/CH10/EX10.6/10_6.sce @@ -0,0 +1,23 @@ +P=4
+V=230
+Z=888
+Ra=0.8
+flux=5.4E-3
+A=2
+
+Il=2
+If=0.6
+Ia=Il-If
+Ea=V-Ia*Ra
+n0=Ea*60/flux/Z/P*A
+disp(n0)
+
+T=29.6
+Ia=T*2*%pi/flux/Z/P*A
+Il=Ia+If
+disp(Il)
+Ea=V-Ra*Ia
+n=Ea*60/flux/Z/P*A
+disp(n)
+sr=(1-n/n0)*100
+disp(sr)
diff --git a/671/CH10/EX10.7/10_7.sce b/671/CH10/EX10.7/10_7.sce new file mode 100755 index 000000000..3560dc25c --- /dev/null +++ b/671/CH10/EX10.7/10_7.sce @@ -0,0 +1,18 @@ +n1=1000
+V=230
+Ia=75
+Ra=0.1
+Ea1=V-Ia*Ra
+Rf=275
+If=V/Rf
+Ke=Ea1/If/n1
+
+n2=1200
+Ia=125
+Ea2=V-Ia*Ra
+If2=Ea2/Ke/n2
+Rf2=V/If2
+Rfext=Rf2-Rf
+disp(Rfext)
+
+
diff --git a/671/CH10/EX10.8/10_8.sce b/671/CH10/EX10.8/10_8.sce new file mode 100755 index 000000000..e4760a2d2 --- /dev/null +++ b/671/CH10/EX10.8/10_8.sce @@ -0,0 +1,18 @@ +V=115
+Ia1=25
+Ra=0.3
+
+n1=1450
+Ea1=V-Ia1*Ra
+Ke=Ea1/n1
+
+n2=1200
+Ea2=Ke*n2
+Ia2=3/4*Ia1
+Raext=(V-Ea2)/Ia2-Ra
+disp(Raext)
+effia=Ea2/V*100 ///calculation mistake in the book at this point
+disp(effia)
+V=Ea2+Ia2*Ra
+effia=Ea2/V*100
+disp(effia)
diff --git a/671/CH10/EX10.9/10_9.sce b/671/CH10/EX10.9/10_9.sce new file mode 100755 index 000000000..ee9f2d927 --- /dev/null +++ b/671/CH10/EX10.9/10_9.sce @@ -0,0 +1,25 @@ +/////solving quadratic
+Ra=0.5
+P=8000
+V=230
+Ea=V
+n=1200
+Ke=V/n
+
+p=poly([P*Ra,-V,1],"w","coeff")
+w=roots(p)
+
+Ea=w(1) ///rejecting small value
+n=Ea/Ke
+disp(n)
+T=P/2/%pi/n*60
+disp(T)
+Ia=(V-Ea)/Ra
+disp(Ia)
+Kt=T/Ia
+
+
+p=poly([-Kt*V/Ra,Kt*Ke/Ra,0.6E-4],"w","coeff")
+w=roots(p)
+n=w(2)
+disp(n)
diff --git a/671/CH11/EX11.1/11_1.sce b/671/CH11/EX11.1/11_1.sce new file mode 100755 index 000000000..7d78578e2 --- /dev/null +++ b/671/CH11/EX11.1/11_1.sce @@ -0,0 +1,16 @@ +P=1000000
+Vrated=6600
+If=60
+Xs_unsat=4700/sqrt(3)/98
+disp(Xs_unsat)
+Xs_adj=Vrated/sqrt(3)/143
+disp(Xs_adj)
+
+Ia=P/sqrt(3)/Vrated
+pf=0.8
+theta=-acos(pf)
+Ia=Ia*(exp(%i*theta))
+Ef=norm(Vrated+%i*Xs_adj*Ia*sqrt(3))
+disp(Ef)
+VR=Ef/Vrated-1
+disp(VR)
diff --git a/671/CH11/EX11.10/11_10.sce b/671/CH11/EX11.10/11_10.sce new file mode 100755 index 000000000..d24cd2451 --- /dev/null +++ b/671/CH11/EX11.10/11_10.sce @@ -0,0 +1,28 @@ +P=10000
+V=400
+pf=0.8
+Xs=16
+theta=acos(pf)
+Ia=P/sqrt(3)/V*exp(-%i*theta)
+Vt=V/sqrt(3)
+Ef=Vt+%i*Xs*Ia
+disp(norm(Ef))
+disp(atan(imag(Ef)/real(Ef))*180/%pi)
+
+Ef2=1.2*norm(Ef)
+Pe=P*pf
+delta=asin(norm(Pe/3*Xs/Ef2/Vt))
+Ef2=Ef2*exp(%i*delta)
+Ia=(Ef2-Vt)/%i/Xs //calculation mistake in the book at this point
+disp(norm(Ia))
+pf=real(Ia)/norm(Ia)
+disp(pf)
+disp(acos(pf)*180/%pi)
+
+delta=%pi/2
+Pemax=norm(3*Ef*Vt/Xs*sin(delta))
+disp(Pemax)
+Ef=norm(Ef)*%i
+Ia=(Ef-Vt)/%i/Xs
+disp(norm(Ia))
+disp(real(Ia)/norm(Ia))
diff --git a/671/CH11/EX11.11/11_11.sce b/671/CH11/EX11.11/11_11.sce new file mode 100755 index 000000000..6f654b37a --- /dev/null +++ b/671/CH11/EX11.11/11_11.sce @@ -0,0 +1,40 @@ +f=50
+MechLoad=(8+0.5)*1000
+Pein=MechLoad
+Vt=231
+Ef=750/sqrt(3)
+Xs=16
+delta=asin(Pein/3*Xs/Ef/Vt)
+Ef=Ef*exp(-%i*delta)
+Ia=(Vt-Ef)/%i/Xs
+ns=120*50/4
+ws=ns/60*2*%pi
+Tdev=Pein/ws
+Tshaft=8000/ws
+disp(norm(Ia))
+disp(real(Ia)/norm(Ia))
+disp(acos(real(Ia)/norm(Ia))*180/%pi)
+disp(Tdev)
+disp(Tshaft)
+
+Ef=600/sqrt(3)
+delta=0
+Ia=(Vt-Ef)/%i/Xs
+kVAR=sqrt(3)*400*norm(Ia)
+disp(norm(Ia))
+disp(real(Ia)/norm(Ia))
+disp(kVAR)
+C=norm(Ia)/Vt/2/%pi/f
+
+Ef=300/sqrt(3)
+Ia=(Vt-Ef)/%i/Xs
+kVAR=sqrt(3)*400*norm(Ia)
+disp(norm(Ia))
+disp(real(Ia)/norm(Ia))
+disp(kVAR)
+L=Vt/norm(Ia)/2/%pi/f
+
+kVAR=6000
+Ia=kVAR/sqrt(3)/400*%i
+Ef=Vt-%i*Xs*Ia
+disp(Ef*sqrt(3))
diff --git a/671/CH11/EX11.12/11_12.sce b/671/CH11/EX11.12/11_12.sce new file mode 100755 index 000000000..6f3ad869e --- /dev/null +++ b/671/CH11/EX11.12/11_12.sce @@ -0,0 +1,12 @@ +P=1000000
+V=6600
+Xs=25
+pf=0.8
+theta=acos(pf)
+Ia=P/sqrt(3)/V*exp(-%i*theta)
+Vt=V/sqrt(3)
+Ef=Vt+%i*Xs*Ia
+delta=asin(norm(Xs*Ia*cos(theta)/Ef))
+Vt=norm(Ia)*Xs*sin(%pi-asin(pf)-delta)/sin(delta)
+Vl=Vt*sqrt(3)
+disp(Vl)
diff --git a/671/CH11/EX11.13/11_13.sce b/671/CH11/EX11.13/11_13.sce new file mode 100755 index 000000000..17382d5c3 --- /dev/null +++ b/671/CH11/EX11.13/11_13.sce @@ -0,0 +1,17 @@ +
+
+Xs=8
+Ia=40
+V=600
+Vt=V/sqrt(3)
+Ef=V
+
+delta=acos((1-(Xs*Ia/V)^2+(Vt/V)^2)/2/Vt*V)
+theta=-atan((cos(delta)-Vt/V)/sin(delta))
+pf=cos(theta)
+Pout=sqrt(3)*V*pf*Ia
+disp(Pout)
+
+theta=-theta
+Pin=Pout
+disp(Pout)
diff --git a/671/CH11/EX11.14/11_14.sce b/671/CH11/EX11.14/11_14.sce new file mode 100755 index 000000000..5bb262604 --- /dev/null +++ b/671/CH11/EX11.14/11_14.sce @@ -0,0 +1,20 @@ +
+V=400
+Vt=V/sqrt(3)
+Ia=50
+pf=1
+theta=0
+Xs=1.3
+
+Ef=Vt-%i*Xs*Ia
+delta=atan(imag(Ef)/real(Ef))
+disp(delta*180/%pi)
+
+Pelec=sqrt(3)*V*pf*Ia
+Pmech=Pelec
+pf=0.8
+theta=acos(0.8)
+Ia=Pelec/sqrt(3)/V/pf*exp(%i*theta)
+Ef2=Vt-%i*Xs*Ia
+If=0.9*norm(Ef2)/norm(Ef)
+disp(If)
diff --git a/671/CH11/EX11.15/11_15.sce b/671/CH11/EX11.15/11_15.sce new file mode 100755 index 000000000..5815c81b9 --- /dev/null +++ b/671/CH11/EX11.15/11_15.sce @@ -0,0 +1,33 @@ +Xspu=0.8
+P=1000000
+V=3000
+Xs=Xspu*V*V/P
+
+Vt=V/sqrt(3)
+Pm=750000
+Pe=Pm
+pf=0.85
+theta=acos(pf)
+Ia=Pm/0.8/sqrt(3)/V*exp(-%i*theta)
+
+Ef=Vt-%i*Xs*Ia
+Efline=sqrt(3)*norm(Ef)
+disp(Efline)
+
+delta=%pi/2
+Pmax=3*Vt*norm(Ef)/Xs
+disp(Pmax)
+ns=120*50/12
+ws=ns*2*%pi/60
+Tmax=Pmax/ws //////calculation mistake in the book at this point
+disp(Tmax)
+
+delta=90
+Efmin=Pm/3*Xs/Vt
+Efmin_line=sqrt(3)*Efmin
+disp(Efmin_line)
+
+Ia=(Vt+%i*Efmin)/%i/Xs
+disp(norm(Ia))
+pf=real(Ia)/norm(Ia)
+disp(pf)
diff --git a/671/CH11/EX11.2/11_2.sce b/671/CH11/EX11.2/11_2.sce new file mode 100755 index 000000000..9f66dadfd --- /dev/null +++ b/671/CH11/EX11.2/11_2.sce @@ -0,0 +1,22 @@ +P=45000
+V=440
+pf=0.8
+Ia=P/sqrt(3)/V*exp(%i*acos(pf))
+Vt=V/sqrt(3)
+Rs=0.2
+Xs=1.8
+Ef=norm(Vt-Ia*(Rs+%i*Xs))
+If=Ef/85
+Pein=pf*P
+Rf=35
+Fl=If*If*Rf
+Pin=Pein+Fl
+Pcu=norm(3*Ia*Ia*Rs)
+Pshaft=Pein-Pcu
+Prl=1500
+Pshaft_net=Pshaft-Prl
+effi=Pshaft_net/Pin
+
+disp(Pshaft_net)
+disp(If)
+disp(effi)
diff --git a/671/CH11/EX11.3/11_3.sce b/671/CH11/EX11.3/11_3.sce new file mode 100755 index 000000000..b6679f1e7 --- /dev/null +++ b/671/CH11/EX11.3/11_3.sce @@ -0,0 +1,27 @@ +V=12500
+Xs=8
+
+Vt=V/sqrt(3)
+Ef=Vt
+
+Ef=Vt*1.2
+Ia=(Ef-Vt)/Xs
+theta=%pi/2
+pf=0
+Pe=0
+Qe=-sqrt(3)*V*Ia
+disp(Ia)
+disp(Pe)
+disp(Qe)
+disp(pf)
+
+Ef=Vt*0.8
+Ia=(Vt-Ef)/Xs
+theta=-%pi/2
+pf=0
+Pe=0
+Qe=sqrt(3)*V*Ia
+disp(Ia)
+disp(Pe)
+disp(Qe)
+disp(pf)
diff --git a/671/CH11/EX11.4/11_4.sce b/671/CH11/EX11.4/11_4.sce new file mode 100755 index 000000000..455bd0ac7 --- /dev/null +++ b/671/CH11/EX11.4/11_4.sce @@ -0,0 +1,14 @@ +Pe=10000000
+V=12500
+Xs=8
+Vt=V/sqrt(3)
+Ef=Vt*1.2
+
+delta=asin(Pe/3/Vt/Ef*Xs)
+Ia=(Ef*exp(%i*delta)-Vt)/%i/Xs
+pf=real(Ia)/norm(Ia)
+Qe=-sqrt(3)*V*imag(Ia)
+
+disp(norm(Ia))
+disp(pf)
+disp(Qe)
diff --git a/671/CH11/EX11.5/11_5.sce b/671/CH11/EX11.5/11_5.sce new file mode 100755 index 000000000..6345cc8aa --- /dev/null +++ b/671/CH11/EX11.5/11_5.sce @@ -0,0 +1,17 @@ +
+Pein=1000000
+pf=0.9
+Xs=3.24
+theta=acos(pf)
+V=3300
+Ia=Pein/sqrt(3)/pf/V*exp(%i*theta)
+Vt=V/sqrt(3)
+Ef=norm(Vt-%i*Ia*Xs)
+Pemax=3*Vt*Ef/Xs
+Ia=(Vt+Ef*%i)/%i/Xs
+Qe=-sqrt(3)*V*imag(Ia)
+
+disp(Pemax)
+disp(norm(Ia))
+disp(real(Ia)/norm(Ia))
+disp(Qe)
diff --git a/671/CH11/EX11.6/11_6.sce b/671/CH11/EX11.6/11_6.sce new file mode 100755 index 000000000..b94f95571 --- /dev/null +++ b/671/CH11/EX11.6/11_6.sce @@ -0,0 +1,20 @@ +Pe=20000
+Pm=20000
+V=400
+pf=0.8
+Xs=4.5
+Ia=Pm/sqrt(3)/V/pf*exp(%i*acos(pf))
+Vt=V/sqrt(3)
+Ef=Vt-%i*Ia*Xs ///calculation mistake in the book at this step
+Efline=norm(Ef)*sqrt(3)
+disp(Efline)
+disp(atan(imag(Ef)/real(Ef)))
+
+delta=-%pi/2
+Efmin=Pe/3*Xs/Vt*sin(-delta)
+Efminline=Efmin*sqrt(3)
+disp(Efminline)
+disp(delta/%pi*180)
+Ia=(Vt+%i*Efmin)/%i/Xs
+disp(norm(Ia))
+disp(real(Ia)/norm(Ia))
diff --git a/671/CH11/EX11.7/11_7.sce b/671/CH11/EX11.7/11_7.sce new file mode 100755 index 000000000..99f9f027d --- /dev/null +++ b/671/CH11/EX11.7/11_7.sce @@ -0,0 +1,13 @@ +f=50
+ns=100
+P=110000
+pf=0.8
+
+p=120*f/ns
+disp(p)
+kVA=P/pf/1000
+disp(kVA)
+kW=P/0.971/1000
+disp(kW)
+Tpm=kW*1000*60/2/%pi/ns
+disp(Tpm)
diff --git a/671/CH11/EX11.8/11_8.sce b/671/CH11/EX11.8/11_8.sce new file mode 100755 index 000000000..f3ca3bf28 --- /dev/null +++ b/671/CH11/EX11.8/11_8.sce @@ -0,0 +1,15 @@ +P=12E6
+Q=6E6
+V=22000
+Xs=8
+S=P+%i*Q
+theta=atan(Q/P)
+disp(theta/%pi*180)
+
+Ia=norm(S)/sqrt(3)/V
+Ef=V/sqrt(3)+%i*Xs*Ia*exp(-%i*theta)
+delta=atan(imag(Ef)/real(Ef))
+disp(delta/%pi*180)
+
+emf=norm(Ef)*sqrt(3)
+disp(emf)
diff --git a/671/CH11/EX11.9/11_9.sce b/671/CH11/EX11.9/11_9.sce new file mode 100755 index 000000000..bfe8211e1 --- /dev/null +++ b/671/CH11/EX11.9/11_9.sce @@ -0,0 +1,31 @@ +Isc=60
+If=50
+
+Voc=15300
+Isc=60
+Xs_unsat=Voc/sqrt(3)/Isc
+disp(Xs_unsat)
+
+V=11000
+Isc=67.5
+Xs_sat=V/sqrt(3)/Isc
+disp(Xs_sat)
+
+pf=0.85
+theta=acos(pf)
+Ia=50*exp(-%i*theta)
+Vt=11000
+Vl=Vt/sqrt(3)
+Ef=Vl+%i*Xs_sat*Ia
+Efline=norm(Ef)*sqrt(3)
+disp(Efline)
+
+Voc=Efline
+VR=Voc/Vt-1
+disp(VR)
+If=57.5
+disp(If)
+
+
+
+
diff --git a/671/CH12/EX12.1/12_1.sce b/671/CH12/EX12.1/12_1.sce new file mode 100755 index 000000000..ba5ce3feb --- /dev/null +++ b/671/CH12/EX12.1/12_1.sce @@ -0,0 +1,12 @@ +V=400
+I=80
+pf=0.75
+Pin=sqrt(3)*V*I*pf
+Pshaft=Pin*0.85
+disp(Pshaft)
+ns=1000
+s=0.04
+n=(1-s)*ns
+w=2*%pi*n/60
+Tshaft=Pshaft/w
+disp(Tshaft)
diff --git a/671/CH12/EX12.10/12_10.sce b/671/CH12/EX12.10/12_10.sce new file mode 100755 index 000000000..3ba2f9fd4 --- /dev/null +++ b/671/CH12/EX12.10/12_10.sce @@ -0,0 +1,13 @@ +
+R2=0.5
+X2=5
+Tm_by_Tfl=3.5
+
+Ts_by_Tfl=R2*Tm_by_Tfl*2*X2/(R2^2+X2^2)
+disp(Ts_by_Tfl)
+
+Ts_by_Tfl2=Ts_by_Tfl/3
+disp(Ts_by_Tfl2)
+
+Ts_by_Tfl3=0.7*0.7*Ts_by_Tfl //calculation mistake in the book at this point
+disp(Ts_by_Tfl3)
diff --git a/671/CH12/EX12.11/12_11.sce b/671/CH12/EX12.11/12_11.sce new file mode 100755 index 000000000..9943b84be --- /dev/null +++ b/671/CH12/EX12.11/12_11.sce @@ -0,0 +1,5 @@ +
+s1=1-960/1000
+s2=1-800/1000
+R2ext=4/3*s2*0.25/s1-0.25
+disp(R2ext)
diff --git a/671/CH12/EX12.12/12_12.sce b/671/CH12/EX12.12/12_12.sce new file mode 100755 index 000000000..d0e6a50a9 --- /dev/null +++ b/671/CH12/EX12.12/12_12.sce @@ -0,0 +1,14 @@ +
+smaxT=1-860/1000
+R2=0.25
+X2=R2/smaxT
+Tmax=180
+k=Tmax*X2
+
+s=0.045
+T=2*100.6/((R2/s)^2+X2^2)*R2/s //some mistake in the book at this point. (What is V1/a)
+T=105
+disp(T)
+
+R2ext=X2-R2
+disp(R2ext)
diff --git a/671/CH12/EX12.13/12_13.sce b/671/CH12/EX12.13/12_13.sce new file mode 100755 index 000000000..dd50a6094 --- /dev/null +++ b/671/CH12/EX12.13/12_13.sce @@ -0,0 +1,17 @@ +V=400
+Poutmech=5000
+Prl=285
+Pm=Poutmech+Prl
+s=1-1445/1500
+s2=1-900/1500
+
+
+
+p=poly([0,-(1-s)*V*V/Pm/s,1/s/s+1/s2/s2],"R2","coeff")
+r=roots(p)
+R2=r(1)
+X2=R2/s2
+
+ws=2*%pi*1500/60
+Tmax=3/ws*V*V/3*0.5/X2
+disp(Tmax)
diff --git a/671/CH12/EX12.14/12_14.sce b/671/CH12/EX12.14/12_14.sce new file mode 100755 index 000000000..e8327b261 --- /dev/null +++ b/671/CH12/EX12.14/12_14.sce @@ -0,0 +1,11 @@ +Pmout=20000
+Pwfl=1500
+Pm=Pmout+Pwfl
+disp(Pm)
+ns=1500
+n=1440
+s=1-n/ns
+Pg=Pm/(1-s)
+disp(Pg)
+Pcu=s*Pg
+disp(Pcu)
diff --git a/671/CH12/EX12.15/12_15.sce b/671/CH12/EX12.15/12_15.sce new file mode 100755 index 000000000..e87691d2c --- /dev/null +++ b/671/CH12/EX12.15/12_15.sce @@ -0,0 +1,41 @@ +V1=400
+R1=2.28*3/2
+R1ac=1.1*3.42
+
+Y0=3.5/sqrt(3)/V1
+Gi=(445/3)/V1/V1
+Bm=sqrt(Y0^2-Gi^2)
+Ri=1/Gi
+Xm=1/Bm
+
+V2=200
+Z=V2/16.7*sqrt(3)
+R=2220/16.7/16.7
+X=sqrt(Z*Z-R*R)
+R2=R-R1ac
+
+n=935
+ns=1000
+s=1-n/ns
+Z=R1ac+R2/s+%i*X
+I2=V1/Z
+Ii=V1/Ri-%i*V1/Xm
+I1=I2+Ii
+Iline=norm(I1)*sqrt(3)
+pf=real(I1)/norm(I1)
+ws=2*%pi*ns/60
+T=norm(3*I2*I2*R2/s/ws)
+disp(T)
+disp(Iline)
+
+Pm=norm(3*I2*I2*R2*(1-s)/s)
+Pin=sqrt(3)*V1*Iline*pf
+effi=Pm/Pin
+disp(effi)
+
+V=400
+s=1
+Z=R1ac+R2/s+%i*X
+I2=V/sqrt(3)/Z ////calculation mistake in the book at this step
+Ts=norm(3*I2*I2*R2/ws)
+disp(Ts)
diff --git a/671/CH12/EX12.16/12_16.sce b/671/CH12/EX12.16/12_16.sce new file mode 100755 index 000000000..db1528a69 --- /dev/null +++ b/671/CH12/EX12.16/12_16.sce @@ -0,0 +1,12 @@ +V=400
+Pmout=5000
+Prl=285
+Pm=Pmout+Prl
+
+s=1-1445/1500
+smaxT=1-900/1500
+R2=(1/s-1)*V*V/Pm/(1/s^2+1/smaxT^2)
+X2=R2/smaxT
+ws=2*%pi*1500/60
+Tmax=V*V/ws/2/X2
+disp(Tmax)
diff --git a/671/CH12/EX12.17/12_17.sce b/671/CH12/EX12.17/12_17.sce new file mode 100755 index 000000000..fff19d4bf --- /dev/null +++ b/671/CH12/EX12.17/12_17.sce @@ -0,0 +1,31 @@ +V=440
+I=25
+pf=0.85
+Pin=sqrt(3)*V*I*pf
+ns=1500
+Pcore=750
+Pcus=950
+Pcur=450
+Pwfl=250
+
+Pg=Pin-Pcore-Pcus
+disp(Pg)
+
+Pm=Pg-Pcur
+disp(Pm)
+
+Pmout=Pm-Pwfl
+disp(Pmout)
+
+effi=Pmout/Pin
+disp(effi)
+
+s=Pcur/Pg
+n=(1-s)*ns
+disp(n)
+
+w=2*%pi*n/60
+Tdev=Pm/w
+disp(Tdev)
+Tnet=Pmout/w
+disp(Tnet)
diff --git a/671/CH12/EX12.2/12_2.sce b/671/CH12/EX12.2/12_2.sce new file mode 100755 index 000000000..c63cdbc10 --- /dev/null +++ b/671/CH12/EX12.2/12_2.sce @@ -0,0 +1,17 @@ +f=50
+f2=120/60
+s=f2/f
+ns=1500
+n=(1-s)*ns
+w=2*%pi*n/60
+
+T=100
+Pshaft=T*w
+disp(Pshaft)
+Pm=(T+7)*w
+Pcur=Pm*s/(1-s)
+disp(Pcur)
+Pin=Pm+Pcur+700
+disp(Pin)
+effi=Pshaft/Pin
+disp(effi)
diff --git a/671/CH12/EX12.3/12_3.sce b/671/CH12/EX12.3/12_3.sce new file mode 100755 index 000000000..d44bdaa4b --- /dev/null +++ b/671/CH12/EX12.3/12_3.sce @@ -0,0 +1,11 @@ +
+ns=120*50/20
+sfl=1-292.5/ns
+
+R2=0.12
+X2=1.12
+smaxT=R2/X2
+disp(smaxT)
+
+Tmax_by_Tfl=0.5/X2/(R2/sfl/((R2/sfl)^2+X2^2))
+disp(Tmax_by_Tfl)
diff --git a/671/CH12/EX12.5/12_5.sce b/671/CH12/EX12.5/12_5.sce new file mode 100755 index 000000000..48048106a --- /dev/null +++ b/671/CH12/EX12.5/12_5.sce @@ -0,0 +1,21 @@ +
+ns=750
+R2=0.5
+X2=5
+smaxT=R2/X2
+n=(1-smaxT)*ns
+disp(n)
+
+k=R2/X2
+Tmax_by_Tstart=(1+k*k)/2/k
+disp(Tmax_by_Tstart)
+
+p=poly([1,-4,1],"k","coeff")
+w=roots(p)
+R2=w*5
+R2ext=R2-0.5
+
+R2total=18.66
+smaxT=R2total/X2
+R2ext=R2ext(2)
+disp(R2ext)
diff --git a/671/CH12/EX12.6/12_6.sce b/671/CH12/EX12.6/12_6.sce new file mode 100755 index 000000000..85e50c843 --- /dev/null +++ b/671/CH12/EX12.6/12_6.sce @@ -0,0 +1,22 @@ +
+Tmax=200
+Tstart=80
+
+p=poly([1,-2*Tmax/Tstart,1],"smaxT","coeff")
+smaxT=roots(p)
+smaxT=smaxT(2)
+disp(smaxT)
+
+
+p=poly([1,-4,1],"w","coeff")
+w=roots(p)
+sfl=smaxT/w(1)
+disp(sfl)
+
+ratio=sqrt(((smaxT/sfl)^2+1)/(smaxT^2+1))
+disp(ratio)
+
+p=poly([1,-((smaxT/sfl)^2+1)*sfl,smaxT^2],"k","coeff")
+k=roots(p)
+k=k(2)
+disp(k)
diff --git a/671/CH12/EX12.7/12_7.sce b/671/CH12/EX12.7/12_7.sce new file mode 100755 index 000000000..42375bfe4 --- /dev/null +++ b/671/CH12/EX12.7/12_7.sce @@ -0,0 +1,20 @@ +V=440
+ns=1000
+ws=2*%pi*ns/60
+n=975
+s=1-n/ns
+Z=1.06+0.576/s+%i*(1.68+0.75)
+I2=V/sqrt(3)/Z
+Im=-%i*V/sqrt(3)/44.2
+I1=Im+I2
+pf=real(I1)/norm(I1)
+Pin=sqrt(3)*V*norm(I1)*pf
+Pout=norm(3*I2*I2*0.576*(1/s-1))-415
+effi=Pout/Pin
+Tnet=Pout/ws/(1-s)
+
+disp(Tnet)
+disp(Pin)
+disp(norm(I1))
+disp(pf)
+disp(effi)
diff --git a/671/CH12/EX12.8/12_8.sce b/671/CH12/EX12.8/12_8.sce new file mode 100755 index 000000000..e6773c5ad --- /dev/null +++ b/671/CH12/EX12.8/12_8.sce @@ -0,0 +1,54 @@ +V=400
+P0=1210
+I0=8.7
+Ri=(V/sqrt(3))^2/P0*3
+disp(Ri)
+pf=P0/sqrt(3)/V/I0
+theta0=acos(pf)
+Xm=Ri/tan(theta0)
+disp(Xm)
+
+P1=6050
+V1=200
+I1=47.8
+R=P1/3/I1/I1
+R1=0.42
+disp(R1)
+R2=R-R1
+disp(R2)
+Z=V1/sqrt(3)/I1
+X=sqrt(Z*Z-R*R)
+disp(X)
+
+ns=750
+n=710
+ws=ns*2*%pi/60
+s=1-n/ns
+Z=R1+R2/s+%i*X
+I2=V/sqrt(3)/Z
+I0=I0*exp(-%i*theta0)
+I1=I0+I2
+disp(norm(I1))
+pf=real(I1)/norm(I1)
+disp(pf)
+T=norm(3*I2*I2*R2/s/ws)
+disp(T)
+Pout=T*ws*(1-s)
+Pin=sqrt(3)*V*norm(I1)*pf
+effi=Pout/Pin
+disp(effi)
+
+s=1
+Z=R+%i*X
+I2=V/sqrt(3)/Z
+I1=I0+I2
+disp(norm(I1))
+Tstart=norm(3*I2*I2*R2/s/ws)
+disp(Tstart)
+
+smaxT=R2/sqrt(R1^2+X^2)
+Z=R1+R2/smaxT+%i*X
+I2=V/sqrt(3)/norm(Z)
+Tmax=3*I2*I2*R2/smaxT/ws
+disp(Tmax)
+disp(smaxT)
diff --git a/671/CH12/EX12.9/12_9.sce b/671/CH12/EX12.9/12_9.sce new file mode 100755 index 000000000..4c61c7f31 --- /dev/null +++ b/671/CH12/EX12.9/12_9.sce @@ -0,0 +1,4 @@ +Is_by_Ifl=5
+sfl=0.04
+Ts_by_Tfl=Is_by_Ifl^2*sfl
+disp("pu",Ts_by_Tfl)
diff --git a/671/CH14/EX14.1/14_1.sce b/671/CH14/EX14.1/14_1.sce new file mode 100755 index 000000000..384f386dd --- /dev/null +++ b/671/CH14/EX14.1/14_1.sce @@ -0,0 +1,6 @@ +Rv1=60/1000*10000
+Rv2=120/1000*10000
+Rx=(Rv2-Rv1)*(1/(27.5/30*2-1)-1)
+I=27.5/1000/600*(Rx+600)/Rx
+Vact=Rx*I
+disp(Vact)
diff --git a/671/CH14/EX14.10/14_10.sce b/671/CH14/EX14.10/14_10.sce new file mode 100755 index 000000000..4fc7d6417 --- /dev/null +++ b/671/CH14/EX14.10/14_10.sce @@ -0,0 +1,6 @@ +f=100E3
+w=2*%pi*f
+C=400E-12
+
+L=1/C/w/w
+disp(L)
diff --git a/671/CH14/EX14.11/14_11.sce b/671/CH14/EX14.11/14_11.sce new file mode 100755 index 000000000..7164354da --- /dev/null +++ b/671/CH14/EX14.11/14_11.sce @@ -0,0 +1,11 @@ +
+Resolution=1/10^4
+disp(Resolution)
+
+disp("14.760")
+
+R_1V=1*Resolution
+disp("0.5434") ///since any digits upto 4th decimal can be shown
+
+R_10V=10*Resolution
+disp("00.543") ///since only three decimal digits can be shown
diff --git a/671/CH14/EX14.12/14_12.sce b/671/CH14/EX14.12/14_12.sce new file mode 100755 index 000000000..5758a9c5d --- /dev/null +++ b/671/CH14/EX14.12/14_12.sce @@ -0,0 +1,7 @@ +
+Vp=10
+Vref=5
+R=100000
+C=0.22E-6
+T=Vp*R*C/Vref
+disp(T)
diff --git a/671/CH14/EX14.13/14_13.sce b/671/CH14/EX14.13/14_13.sce new file mode 100755 index 000000000..5565fb275 --- /dev/null +++ b/671/CH14/EX14.13/14_13.sce @@ -0,0 +1,11 @@ +
+V=3.217
+bits=4
+base=5
+a=0
+
+for i=1:bits
+ a=floor(V/base*(2^i))
+ disp(a);
+ V=V-a*base/(2^i)
+end
diff --git a/671/CH14/EX14.14/14_14.sce b/671/CH14/EX14.14/14_14.sce new file mode 100755 index 000000000..175514b7f --- /dev/null +++ b/671/CH14/EX14.14/14_14.sce @@ -0,0 +1,11 @@ +
+reading=5
+x=0.005/100*reading //0.005% of reading
+err=x+1E-6 //final digit
+disp("seconds",err)
+
+reading=500
+x=0.005/100*reading //0.005% of reading
+err=x+1 //final digit
+disp("seconds",err)
+
diff --git a/671/CH14/EX14.15/14_15.sce b/671/CH14/EX14.15/14_15.sce new file mode 100755 index 000000000..d233ecf6b --- /dev/null +++ b/671/CH14/EX14.15/14_15.sce @@ -0,0 +1,15 @@ +V=5.9
+Rx=0
+Rm=2000
+R1=49000
+Ifsd=100E-6
+Vam=Rm*Ifsd
+I=(V-Vam)/R1
+Ish=I-Ifsd
+R2=Vam/Ish
+disp(R2)
+
+I=0.6*I
+Req=V/I
+Rx=Req-R1-Rm*R2/(R2+Rm)
+disp(Rx)
diff --git a/671/CH14/EX14.17/14_17.sce b/671/CH14/EX14.17/14_17.sce new file mode 100755 index 000000000..8b15501e9 --- /dev/null +++ b/671/CH14/EX14.17/14_17.sce @@ -0,0 +1,16 @@ +f=50
+w=2*%pi*f
+
+Z2=1000
+Z3=16800
+
+C=0.38E-6
+Xc=1/%i/w/C
+Z4=833+Xc
+
+Z1=Z2*Z3/Z4
+Rx=real(Z1)
+Lx=imag(Z1)/w
+
+disp(Rx)
+disp(Lx)
diff --git a/671/CH14/EX14.18/14_18.sce b/671/CH14/EX14.18/14_18.sce new file mode 100755 index 000000000..19287d171 --- /dev/null +++ b/671/CH14/EX14.18/14_18.sce @@ -0,0 +1,6 @@ +f=50
+w=2*%pi*f
+T=1/f
+
+Iav=1/(T/2)*integrate('sin(w*t)','t',0,T/2)
+disp(Iav)
diff --git a/671/CH14/EX14.2/14_2.sce b/671/CH14/EX14.2/14_2.sce new file mode 100755 index 000000000..18de8d17b --- /dev/null +++ b/671/CH14/EX14.2/14_2.sce @@ -0,0 +1,8 @@ +
+Ifsd=25/1000
+Ix=4.975
+Rx=Ifsd*5/Ix
+disp(Rx)
+
+Rx=20/Ifsd-5
+disp(Rx)
diff --git a/671/CH14/EX14.3/14_3.sce b/671/CH14/EX14.3/14_3.sce new file mode 100755 index 000000000..8d1235044 --- /dev/null +++ b/671/CH14/EX14.3/14_3.sce @@ -0,0 +1,5 @@ +
+R1=40/0.025-5
+R2=60/0.025-5-R1
+disp(R1)
+disp(R2)
diff --git a/671/CH14/EX14.4/14_4.sce b/671/CH14/EX14.4/14_4.sce new file mode 100755 index 000000000..3bcfb1fab --- /dev/null +++ b/671/CH14/EX14.4/14_4.sce @@ -0,0 +1,8 @@ +
+W1=500
+W2=-200
+P=W1+W2
+phi=atan((W1-W2)/(W1+W2))
+pf=cos(phi)
+disp(pf)
+disp(P)
diff --git a/671/CH14/EX14.5/14_5.sce b/671/CH14/EX14.5/14_5.sce new file mode 100755 index 000000000..c360a1e9d --- /dev/null +++ b/671/CH14/EX14.5/14_5.sce @@ -0,0 +1,14 @@ +
+E=4
+R1=800
+R2=80
+R3=1605
+R4=160
+Rg=80
+s=8
+
+Eth=E*(R2/(R2+R4)-R1/(R1+R3))
+Rth=R1*R3/(R1+R3)+R2*R4/(R2+R4)
+Ig=Eth/(Rth+Rg)
+D=s*Ig*1000000
+disp(D)
diff --git a/671/CH14/EX14.6/14_6.sce b/671/CH14/EX14.6/14_6.sce new file mode 100755 index 000000000..1ad223f9b --- /dev/null +++ b/671/CH14/EX14.6/14_6.sce @@ -0,0 +1,25 @@ +function Zeq=parallel(Z1,Z2)
+ Zeq=Z1*Z2/(Z1+Z2)
+endfunction
+
+f=1000
+w=2*%pi*f
+
+///AB
+R=2000
+C=0.045E-6
+Xc=1/%i/w/C
+Z1=parallel(R,Xc)
+
+////BC
+R=1000
+C=0.45E-6
+Xc=1/%i/w/C
+Z2=R+Xc
+
+////AD
+C=0.4E-6
+Z3=1/%i/w/C
+
+Z4=Z2*Z3/Z1
+disp(Z4)
diff --git a/671/CH14/EX14.7/14_7.sce b/671/CH14/EX14.7/14_7.sce new file mode 100755 index 000000000..bccf8463a --- /dev/null +++ b/671/CH14/EX14.7/14_7.sce @@ -0,0 +1,6 @@ +
+ksine=1.11
+ksqr=1
+
+err=(ksine-ksqr)/ksqr*100
+disp("percent",err)
diff --git a/671/CH14/EX14.8/14_8.sce b/671/CH14/EX14.8/14_8.sce new file mode 100755 index 000000000..b6114e0c5 --- /dev/null +++ b/671/CH14/EX14.8/14_8.sce @@ -0,0 +1,17 @@ +
+f=50E6
+w=2*%pi*f
+theta=5*%pi/180
+
+
+C=1E-12
+R=1/theta/w/C
+disp(R)
+
+C=10E-12
+R=1/theta/w/C
+disp(R)
+
+C=100E-12
+R=1/theta/w/C
+disp(R)
diff --git a/671/CH14/EX14.9/14_9.sce b/671/CH14/EX14.9/14_9.sce new file mode 100755 index 000000000..391cdf572 --- /dev/null +++ b/671/CH14/EX14.9/14_9.sce @@ -0,0 +1,12 @@ +
+f=8E6
+w=2*%pi*f
+C=150E-12
+R=5
+
+Q1=1/w/C/R
+
+Rins=0.1
+Q2=1/w/C/(R+Rins)
+err=(Q1-Q2)/Q1*100
+disp(err)
diff --git a/671/CH15/EX15.1/15_1.sce b/671/CH15/EX15.1/15_1.sce new file mode 100755 index 000000000..ea1b9dcd5 --- /dev/null +++ b/671/CH15/EX15.1/15_1.sce @@ -0,0 +1,6 @@ +V1=250
+V2=480
+Vol2_by_Vol1=V1/V2
+
+sav=(1-Vol2_by_Vol1)*100
+disp(sav)
diff --git a/671/CH15/EX15.2/15_2.sce b/671/CH15/EX15.2/15_2.sce new file mode 100755 index 000000000..878268983 --- /dev/null +++ b/671/CH15/EX15.2/15_2.sce @@ -0,0 +1,16 @@ +P=5E6
+pf=0.85
+V=33000
+l=50000
+rho=3E-8
+Pt=P*pf
+Pl=Pt*0.1
+I=P/V
+A1=2*I*I*rho*l/Pl
+Vol1=2*l*A1
+disp(Vol1)
+
+Il=P/sqrt(3)/V
+A2=3*Il*Il*rho*l/Pl
+Vol2=3*l*A2
+disp(Vol2)
diff --git a/671/CH15/EX15.3/15_3.sce b/671/CH15/EX15.3/15_3.sce new file mode 100755 index 000000000..1fa60395d --- /dev/null +++ b/671/CH15/EX15.3/15_3.sce @@ -0,0 +1,16 @@ +f=50
+w=2*%pi*f
+I=0.8
+V=220
+P=75
+phi=acos(P/V/I)
+
+phi_new=acos(0.9)
+Ic=I*cos(phi)*(tan(phi)-tan(phi_new))
+C=Ic/V/w
+disp(C)
+
+phi_new=acos(1)
+Ic=I*cos(phi)*(tan(phi)-tan(phi_new))
+C=Ic/V/w
+disp(C)
diff --git a/671/CH15/EX15.4/15_4.sce b/671/CH15/EX15.4/15_4.sce new file mode 100755 index 000000000..5b99aef50 --- /dev/null +++ b/671/CH15/EX15.4/15_4.sce @@ -0,0 +1,5 @@ +Cond_cost=100
+charge=60
+phi2=asin(0.1*Cond_cost/charge)
+pf=cos(phi2)
+disp(pf)
diff --git a/671/CH15/EX15.5/15_5.sce b/671/CH15/EX15.5/15_5.sce new file mode 100755 index 000000000..46ddaf2c6 --- /dev/null +++ b/671/CH15/EX15.5/15_5.sce @@ -0,0 +1,11 @@ +
+Oc=400000
+pf1=0.8
+phi1=acos(pf1)
+ab=Oc/cos(phi1)*sin(phi1)
+pf2=0.25
+phi3=acos(pf2)
+pf2=0.484
+
+gammaa=(ab-pf2*Oc)/(pf2*cos(phi3)+sin(phi3))
+disp(gammaa)
diff --git a/671/CH15/EX15.6/15_6.sce b/671/CH15/EX15.6/15_6.sce new file mode 100755 index 000000000..b99f3ebfc --- /dev/null +++ b/671/CH15/EX15.6/15_6.sce @@ -0,0 +1,20 @@ +f=50
+w=2*%pi*f
+P=2E6
+V=11000
+pf=0.8
+phi=acos(pf)
+Xl=10
+IR=P/sqrt(3)/V/pf
+Vr=V/sqrt(3)
+Vs=Vr+IR*Xl*sin(phi)
+Vsll=Vs*sqrt(3)
+disp(Vsll)
+VR=Vsll/V-1
+disp(VR)
+
+pf=1
+disp(pf)
+Qc=P*tan(phi)
+C=Qc/V/V/w
+disp(C)
diff --git a/671/CH15/EX15.7/15_7.sce b/671/CH15/EX15.7/15_7.sce new file mode 100755 index 000000000..e80ca36c9 --- /dev/null +++ b/671/CH15/EX15.7/15_7.sce @@ -0,0 +1,32 @@ +f=50
+w=2*%pi*f
+V=33000
+Vr=V/sqrt(3)
+P=24E6/3
+pf=0.8
+phi=acos(pf)
+Ia=P/Vr/pf
+Rl=4
+Xl=20
+Vs=Vr+Ia*(Xl*sin(phi)+Rl*cos(phi))
+Vsll=sqrt(3)*Vs
+VR=Vsll/V-1
+disp(Vsll)
+Ia=Ia*exp(-%i*phi)
+disp(norm(Ia))
+
+phi1=atan(-Rl/Xl)
+pf=cos(phi1)
+Ia1=P/Vr/pf
+Ia1=Ia1*exp(-%i*phi1) ////calculation mistake in the book at this step
+
+Ic=Ia1-Ia
+C=norm(Ic/w/Vr)
+disp(C)
+
+LL1=norm(Ia*Ia*Rl)
+effi1=P/(P+LL1)
+LL2=norm(Ia1*Ia1*Rl)
+effi2=P/(P+LL2)
+disp(effi1)
+disp(effi2)
diff --git a/671/CH2/EX2.1/2_1.sce b/671/CH2/EX2.1/2_1.sce new file mode 100755 index 000000000..03bbb4202 --- /dev/null +++ b/671/CH2/EX2.1/2_1.sce @@ -0,0 +1,20 @@ +function s=series(r1,r2)
+ s=r1+r2
+endfunction
+
+function p=parallel(r1,r2)
+ p=r1*r2/(r1+r2)
+endfunction
+
+r1=series(12,8)
+r2=parallel(20,r1)
+r3=series(r2,50)
+r4=parallel(30,r3)
+r5=series(10,r4)
+r6=series(r5,20)
+Req_ab=parallel(r5,40)
+disp(Req_ab)
+
+r7=40+20+10 //series
+Req_bc=parallel(r4,r7)
+disp(Req_bc)
\ No newline at end of file diff --git a/671/CH2/EX2.10/2_10.sce b/671/CH2/EX2.10/2_10.sce new file mode 100755 index 000000000..db054fd7e --- /dev/null +++ b/671/CH2/EX2.10/2_10.sce @@ -0,0 +1,9 @@ +//converting 9v voltage source to current source
+I=9/0.45
+I=I-7
+
+//KCLs
+A=[1/0.45+1/10,-1/10 ; 0.2-1/10,1/10-0.2]
+V=inv(A)*[-18;5]
+
+disp(V(2))
\ No newline at end of file diff --git a/671/CH2/EX2.11/2_11.sce b/671/CH2/EX2.11/2_11.sce new file mode 100755 index 000000000..d4937c918 --- /dev/null +++ b/671/CH2/EX2.11/2_11.sce @@ -0,0 +1,15 @@ +//converting voltage source to current source
+
+I=240/3
+
+//KCLs
+
+A=[1/3+1/6,-1/6;-1/6,1/6+1/12+1/30]
+V=inv(A)*[70;5]
+Vx=V(1)
+Vy=V(2)-60
+
+V6=V(2)-V(1)
+P6=V6*V6/6
+
+disp(P6)
\ No newline at end of file diff --git a/671/CH2/EX2.13/2_13.sce b/671/CH2/EX2.13/2_13.sce new file mode 100755 index 000000000..06335a3bf --- /dev/null +++ b/671/CH2/EX2.13/2_13.sce @@ -0,0 +1,6 @@ +// KVLs
+
+A=[24,-6,-8;-6,20,-5;-8,-5,25]
+I=inv(A)*[16;0;0]
+I5=I(2)-I(3)
+disp(I5)
\ No newline at end of file diff --git a/671/CH2/EX2.14/2_14.sce b/671/CH2/EX2.14/2_14.sce new file mode 100755 index 000000000..b946a5c08 --- /dev/null +++ b/671/CH2/EX2.14/2_14.sce @@ -0,0 +1,9 @@ +//convert practical current source to voltage source
+V=10*5
+
+//KVLs
+A=[35,-20;-20,50]
+I=inv(A)*[50;-100]
+
+v=20*(I(1)-I(2))
+disp(v)
\ No newline at end of file diff --git a/671/CH2/EX2.15/2_15.sce b/671/CH2/EX2.15/2_15.sce new file mode 100755 index 000000000..d822bf55c --- /dev/null +++ b/671/CH2/EX2.15/2_15.sce @@ -0,0 +1,8 @@ +i1=0.37 + +//KVL for loop 2 +i2=(-100+20*i1)/50 + +//KVL for loop 1 +R=(50+20*(i2-i1))/i1 +disp(R)
\ No newline at end of file diff --git a/671/CH2/EX2.16/2_16.sce b/671/CH2/EX2.16/2_16.sce new file mode 100755 index 000000000..71064d322 --- /dev/null +++ b/671/CH2/EX2.16/2_16.sce @@ -0,0 +1,7 @@ +//Converting current sources to voltage sources
+// O=[i1;i2;vx]
+
+A=[10,-3,4;-3,7,0;3,-3,-1]
+O=inv(A)*[16;-6;0]
+
+disp(O)
\ No newline at end of file diff --git a/671/CH2/EX2.17/2_17.sce b/671/CH2/EX2.17/2_17.sce new file mode 100755 index 000000000..fdb722ba3 --- /dev/null +++ b/671/CH2/EX2.17/2_17.sce @@ -0,0 +1,16 @@ +//convert current sources to voltage
+
+A=[95,-15;-15,135]
+I=inv(A)*[20;-70]
+
+i3=I(1)-I(2)
+
+I60=0.5-I(1)
+V60=I60*60
+P1= 0.5*V60 //O.5 A source
+
+I80=1+I(2)
+V80=I80*80
+P2=1*V80
+
+disp(P2,P1)
\ No newline at end of file diff --git a/671/CH2/EX2.18/2_18.sce b/671/CH2/EX2.18/2_18.sce new file mode 100755 index 000000000..fbd7b4653 --- /dev/null +++ b/671/CH2/EX2.18/2_18.sce @@ -0,0 +1,6 @@ +//Nodal Equations
+
+A=[0.6,-0.5;2,-1.6]
+V=inv(A)*[4;0]
+V12=V(1)-V(2)
+disp(V12)
\ No newline at end of file diff --git a/671/CH2/EX2.19/2_19.sce b/671/CH2/EX2.19/2_19.sce new file mode 100755 index 000000000..d57dd9fcc --- /dev/null +++ b/671/CH2/EX2.19/2_19.sce @@ -0,0 +1,7 @@ +//convert dependent current source to dependent voltage source
+
+//Mesh Equations
+A=[14,-2,0;-2,18,3;2,-2,-1]
+O=inv(A)*[100;0;0]
+
+disp(O(3))
\ No newline at end of file diff --git a/671/CH2/EX2.2/2_2.sce b/671/CH2/EX2.2/2_2.sce new file mode 100755 index 000000000..b2ba5f34a --- /dev/null +++ b/671/CH2/EX2.2/2_2.sce @@ -0,0 +1,2 @@ +I=(14-4)/(8+5+5+7) //KVL
+disp(I)
\ No newline at end of file diff --git a/671/CH2/EX2.20/2_20.sce b/671/CH2/EX2.20/2_20.sce new file mode 100755 index 000000000..9438d2d3c --- /dev/null +++ b/671/CH2/EX2.20/2_20.sce @@ -0,0 +1,19 @@ +///////////////////Part 1
+
+//Nodal Method
+v1=(8/5+16/10)/(1/5+1/2+1/10)
+disp(v1)
+i5=(8-v1)/5000
+disp(i5)
+
+
+//////////////////Part2
+
+//Mesh Method
+
+A=[7,-2;-2,12]
+I=inv(A)*[8;-16]/1000
+disp(I)
+
+v1=2*1000*(I(1)-I(2))
+disp(v1)
\ No newline at end of file diff --git a/671/CH2/EX2.21/2_21.sce b/671/CH2/EX2.21/2_21.sce new file mode 100755 index 000000000..6c85a0c25 --- /dev/null +++ b/671/CH2/EX2.21/2_21.sce @@ -0,0 +1,21 @@ +function p=parallel(r1,r2)
+ p=r1*r2/(r1+r2)
+endfunction
+
+//deactivate voltage source
+
+i11=4*6/8
+i21=4*2/8
+v11=i11*2
+v21=1*1
+
+//deactivate current source
+Req=parallel(2,7)
+
+v22=8*Req/(2+Req)
+v12=v22*(2/(2+5))
+
+v1=v11+v12
+v2=v21+v22
+
+disp(v2,v1)
\ No newline at end of file diff --git a/671/CH2/EX2.22/2_22.sce b/671/CH2/EX2.22/2_22.sce new file mode 100755 index 000000000..1137cf227 --- /dev/null +++ b/671/CH2/EX2.22/2_22.sce @@ -0,0 +1,13 @@ +function p=parallel(r1,r2)
+ p=r1*r2/(r1+r2)
+endfunction
+
+//Thevenin Equivalent
+I=(32-8)/30
+Voc=32-20*I
+Ro=parallel(20,10)
+disp(Ro,Voc)
+
+//Norton Equivalent
+Isc=32/20+8/10
+disp(Ro,Isc)
\ No newline at end of file diff --git a/671/CH2/EX2.23/2_23.sce b/671/CH2/EX2.23/2_23.sce new file mode 100755 index 000000000..53ac9dd82 --- /dev/null +++ b/671/CH2/EX2.23/2_23.sce @@ -0,0 +1,14 @@ +//convert current source to voltage source
+V=3.5*20
+
+//KVL
+I=100/(10+20+V)
+Voc=100-10*I
+
+//Finding Isc
+I=100/10
+Isc=(1+3.5)*I
+
+Ro=Voc/Isc
+
+disp(Ro,Voc)
\ No newline at end of file diff --git a/671/CH2/EX2.24/2_24.sce b/671/CH2/EX2.24/2_24.sce new file mode 100755 index 000000000..8fd5d8f86 --- /dev/null +++ b/671/CH2/EX2.24/2_24.sce @@ -0,0 +1,17 @@ +V=32 +I=1 +R1=20 +R2=8 +R3=2 +Voc1=V/(R1+R2+R3)*(R2+R3) ///a,b open +Isc1=V/R1 ///a,b short + +Voc2=I*R2/(R1+R2+R3)*R1 +Isc2=I*R2/(R2+R3) + +////by superposition +Voc=Voc1+Voc2 +Isc=Isc1+Isc2 + +disp(Voc) +disp(Isc) diff --git a/671/CH2/EX2.25/2_25.sce b/671/CH2/EX2.25/2_25.sce new file mode 100755 index 000000000..45a48b71c --- /dev/null +++ b/671/CH2/EX2.25/2_25.sce @@ -0,0 +1,16 @@ +function [Ra,Rb,Rc]=delta_to_star(Rab,Rbc,Rca)
+ X=Rab+Rbc+Rca
+ Ra=Rab*Rca/X
+ Rb=Rab*Rbc/X
+ Rc=Rca*Rbc/X
+endfunction
+
+function p=parallel(r1,r2)
+ p=r1*r2/(r1+r2)
+endfunction
+
+[R1,R2,R3]=delta_to_star(4,12,8)
+Req=10+4+parallel(R1+15,R2+16)
+
+I=12/Req
+disp(I)
\ No newline at end of file diff --git a/671/CH2/EX2.26/2_26.sce b/671/CH2/EX2.26/2_26.sce new file mode 100755 index 000000000..83bd9f74d --- /dev/null +++ b/671/CH2/EX2.26/2_26.sce @@ -0,0 +1,12 @@ +//convert current source to voltage source
+
+V1=4*2
+V2=2*2
+
+//Mesh Analysis
+
+A=[7,-3;-15,19]
+I=inv(A)*[6;-14]
+
+Vx=3*(I(1)-I(2))
+disp(Vx)
\ No newline at end of file diff --git a/671/CH2/EX2.27/2_27.sce b/671/CH2/EX2.27/2_27.sce new file mode 100755 index 000000000..d500dc577 --- /dev/null +++ b/671/CH2/EX2.27/2_27.sce @@ -0,0 +1,11 @@ +//Short Circuit AB and convert Curr Source to V source
+
+V=9*5
+Isc=(45-9)/6
+
+function p=parallel(r1,r2)
+ p=r1*r2/(r1+r2)
+endfunction
+
+Ro=parallel(5+1,3)
+disp(Ro,Isc)
\ No newline at end of file diff --git a/671/CH2/EX2.28/2_28.sce b/671/CH2/EX2.28/2_28.sce new file mode 100755 index 000000000..833b7b84a --- /dev/null +++ b/671/CH2/EX2.28/2_28.sce @@ -0,0 +1,12 @@ +//Mesh Analysis
+
+A=[4,-2;998,24.5]
+I=inv(A)*[1/1000;0]
+
+disp(I)
+
+P1=I(2)^2*2.5*1000
+P2=1/1000*I(1)
+P3=-10^6*I(1)*I(2)
+P=[P1,P2,P3]
+disp(P)
\ No newline at end of file diff --git a/671/CH2/EX2.29/2_29.sce b/671/CH2/EX2.29/2_29.sce new file mode 100755 index 000000000..723a5725c --- /dev/null +++ b/671/CH2/EX2.29/2_29.sce @@ -0,0 +1,16 @@ +function p=parallel(r1,r2)
+ p=r1*r2/(r1+r2)
+endfunction
+
+//as seen from ab
+Vth1=30*60/(30+60)
+Rth1=parallel(30,60)
+
+//as seen from cd
+Vth2=80*40/(40+60)
+Rth2=parallel(40,60)
+
+Vnet=60+Vth1-Vth2
+Rnet=Rth1+Rth2
+
+disp(Rnet,Vnet)
\ No newline at end of file diff --git a/671/CH2/EX2.3/2_3.sce b/671/CH2/EX2.3/2_3.sce new file mode 100755 index 000000000..098843cd6 --- /dev/null +++ b/671/CH2/EX2.3/2_3.sce @@ -0,0 +1,21 @@ +r1=100
+v=3/4
+
+r2=r1*v/(1-v)
+
+
+function p=parallel(r1,r2)
+ p=r1*r2/(r1+r2)
+endfunction
+
+//////Part1
+R2_eq=parallel(r2,10000)
+k=R2_eq/(R2_eq+r1)
+change1=(3/4-k)/(3/4)*100
+disp(change1)
+//////Part2
+
+R2_eq=parallel(r2,1000)
+k=R2_eq/(R2_eq+r1)
+change2=(3/4-k)/(3/4)*100
+disp(change2)
\ No newline at end of file diff --git a/671/CH2/EX2.30/2_30.sce b/671/CH2/EX2.30/2_30.sce new file mode 100755 index 000000000..40580acc5 --- /dev/null +++ b/671/CH2/EX2.30/2_30.sce @@ -0,0 +1,14 @@ +function p=parallel(r1,r2)
+ p=r1*r2/(r1+r2)
+endfunction
+
+R=parallel(60,120)
+
+//Mesh Analysis
+
+A=[6,-4;-4,12]
+I=inv(A)*[2.4;-3.6]
+I3=I(1)-I(2)
+
+I60=I3*120/(120+60)
+disp(I60)
\ No newline at end of file diff --git a/671/CH2/EX2.31/2_31.sce b/671/CH2/EX2.31/2_31.sce new file mode 100755 index 000000000..23662836e --- /dev/null +++ b/671/CH2/EX2.31/2_31.sce @@ -0,0 +1,5 @@ +//Nodal Equation
+
+Vn=198/10.5
+I60=Vn/60
+disp(I60)
\ No newline at end of file diff --git a/671/CH2/EX2.32/2_32.sce b/671/CH2/EX2.32/2_32.sce new file mode 100755 index 000000000..ebb08ac82 --- /dev/null +++ b/671/CH2/EX2.32/2_32.sce @@ -0,0 +1,16 @@ +V8=2*8
+
+//KVL
+I1=(30-16)/10
+
+//KCL at left node
+I2=2-I1
+
+//KVL middle mesh
+I4=(10*I1-2*I2)/4
+Vx=4*I4
+
+//right node
+Ix=I4-I2
+
+disp(Vx)
\ No newline at end of file diff --git a/671/CH2/EX2.33/2_33.sce b/671/CH2/EX2.33/2_33.sce new file mode 100755 index 000000000..98182eeed --- /dev/null +++ b/671/CH2/EX2.33/2_33.sce @@ -0,0 +1,18 @@ +////////////////////////////////investigate the if then else construct
+
+
+
+I=5
+
+//KVL
+R=(-12.5+15)/I-0.02-0.035
+disp(R)
+
+P=poly([-25,12.5,0.035],"I","coeff")
+Z=roots(P)
+Ib=Z(2)
+disp(Ib)
+
+I=(13-12.5)/0.035
+R=(15-13)/I-0.02
+disp(R)
diff --git a/671/CH2/EX2.35/2_35.sce b/671/CH2/EX2.35/2_35.sce new file mode 100755 index 000000000..a09f6901e --- /dev/null +++ b/671/CH2/EX2.35/2_35.sce @@ -0,0 +1,10 @@ +R=12*12/4-25
+disp(R)
+
+I=sqrt(1.6/1000/10000)
+R=12/I-10000-15000
+disp(R)
+
+I=0
+V=12
+disp(V)
\ No newline at end of file diff --git a/671/CH2/EX2.36/2_36.sce b/671/CH2/EX2.36/2_36.sce new file mode 100755 index 000000000..fdc428548 --- /dev/null +++ b/671/CH2/EX2.36/2_36.sce @@ -0,0 +1,7 @@ +function p=parallel(r1,r2)
+ p=r1*r2/(r1+r2)
+endfunction
+
+Req=1+parallel(parallel(1,1),1)
+
+disp(Req)
\ No newline at end of file diff --git a/671/CH2/EX2.37/2_37.sce b/671/CH2/EX2.37/2_37.sce new file mode 100755 index 000000000..28544b071 --- /dev/null +++ b/671/CH2/EX2.37/2_37.sce @@ -0,0 +1,8 @@ +function p=parallel(r1,r2)
+ p=r1*r2/(r1+r2)
+endfunction
+
+R1=parallel(parallel(40,60),80+40)
+
+Req=20+parallel(10+R1,30)
+disp(Req)
\ No newline at end of file diff --git a/671/CH2/EX2.38/2_38.sce b/671/CH2/EX2.38/2_38.sce new file mode 100755 index 000000000..f12221376 --- /dev/null +++ b/671/CH2/EX2.38/2_38.sce @@ -0,0 +1,13 @@ +function p=parallel(r1,r2)
+ p=r1*r2/(r1+r2)
+endfunction
+
+R1=parallel(5,40)+15
+Req=parallel(R1,15)+10
+i=6/(1000*Req)
+
+ix=i*R1/(R1+15)
+disp(ix)
+
+P=i*i*10000 //////wrongly done in the book as ix*ix*10000
+disp(P)
\ No newline at end of file diff --git a/671/CH2/EX2.39/2_39.sce b/671/CH2/EX2.39/2_39.sce new file mode 100755 index 000000000..dfcf4a112 --- /dev/null +++ b/671/CH2/EX2.39/2_39.sce @@ -0,0 +1,12 @@ +function p=parallel(r1,r2)
+ p=r1*r2/(r1+r2)
+endfunction
+
+R1=parallel(1,3)
+
+//convert current source to voltage
+V=20/1000*2000
+I=(40-8)/(2+0.75)
+
+Pr=8*I
+disp(Pr)
\ No newline at end of file diff --git a/671/CH2/EX2.4/2_4.sce b/671/CH2/EX2.4/2_4.sce new file mode 100755 index 000000000..9217f5ab2 --- /dev/null +++ b/671/CH2/EX2.4/2_4.sce @@ -0,0 +1,15 @@ +function p=parallel(r1,r2)
+ p=r1*r2/(r1+r2)
+endfunction
+
+
+v=150
+
+Req=1000*parallel(parallel(10,5),4)
+i1=v/(2000+0.2*1000+Req)
+v1=i1*0.2*1000
+VReq=Req*i1
+i2=VReq/4000
+
+disp(v1)
+disp(i2)
diff --git a/671/CH2/EX2.40/2_40.sce b/671/CH2/EX2.40/2_40.sce new file mode 100755 index 000000000..babd7f068 --- /dev/null +++ b/671/CH2/EX2.40/2_40.sce @@ -0,0 +1,25 @@ +function p=parallel(r1,r2)
+ p=r1*r2/(r1+r2)
+endfunction
+
+I1=12/1000
+Ix=I1*30/(30+60)
+disp(Ix)
+
+I2=20/1000
+V2=I2*(10+5)
+R1=10+parallel(30,60)
+I1=V2/R1
+Ix=I1*30/(30+60)
+disp(Ix) //Wrongly printed in the book as 10
+
+Ix=6/1000
+I1=(30+60)/30*Ix
+V2=I1*R1
+I2=V2/15
+disp(I2)
+
+Is=45
+I1=45*(10+5)/(10+5+R1)
+Ix=I1*30/(30+60)
+disp(Ix) ///Answer is wrong in the book
\ No newline at end of file diff --git a/671/CH2/EX2.5/2_5.sce b/671/CH2/EX2.5/2_5.sce new file mode 100755 index 000000000..91c2413fc --- /dev/null +++ b/671/CH2/EX2.5/2_5.sce @@ -0,0 +1,15 @@ +function [Rab,Rbc,Rca]=star_to_delta(Ra,Rb,Rc)
+ X=Ra*Rb+Rb*Rc+Rc*Ra
+ Rab=X/Rc
+ Rbc=X/Ra
+ Rca=X/Rb
+endfunction
+
+function p=parallel(r1,r2)
+ p=r1*r2/(r1+r2)
+endfunction
+
+[Rx,Ry,Rz]=star_to_delta(8,4,2)
+
+Req_ad=parallel(parallel(4,Rx)+parallel(12,Rz),parallel(3,Ry))
+disp(Req_ad)
\ No newline at end of file diff --git a/671/CH2/EX2.6/2_6.sce b/671/CH2/EX2.6/2_6.sce new file mode 100755 index 000000000..8d28a3906 --- /dev/null +++ b/671/CH2/EX2.6/2_6.sce @@ -0,0 +1,8 @@ +//Converting Voltage source with series resistance to current source
+I=1/(1/4)
+
+//KCL at nodes 1,2,3 using conductances
+A=[11,-3,-4;-3,6,-2;-4,-2,11]
+V=inv(A)*[5;-7;6]
+
+disp(V)
\ No newline at end of file diff --git a/671/CH2/EX2.7/2_7.sce b/671/CH2/EX2.7/2_7.sce new file mode 100755 index 000000000..17ea12878 --- /dev/null +++ b/671/CH2/EX2.7/2_7.sce @@ -0,0 +1,12 @@ +function p=parallel(r1,r2)
+ p=r1*r2/(r1+r2)
+endfunction
+
+Req=parallel(15,30)
+
+//KCL at nodes 1 and 2
+A=[3,-1;-3,5]
+V=inv(A)*[80;-360]
+
+disp(V(1))
+
diff --git a/671/CH2/EX2.8/2_8.sce b/671/CH2/EX2.8/2_8.sce new file mode 100755 index 000000000..0a05d4239 --- /dev/null +++ b/671/CH2/EX2.8/2_8.sce @@ -0,0 +1,10 @@ +//Converting practical voltage source to current source
+I=12/6
+
+//KCLs
+A=[0.7,-0.5;-0.5,0.767]
+V=inv(A)*[7;2]
+disp(V)
+
+I12=(V(1)-V(2))/2
+disp(I12)
\ No newline at end of file diff --git a/671/CH2/EX2.9/2_9.sce b/671/CH2/EX2.9/2_9.sce new file mode 100755 index 000000000..29df50817 --- /dev/null +++ b/671/CH2/EX2.9/2_9.sce @@ -0,0 +1,11 @@ +//KCLs
+
+A=[2,-1;-4,19]
+V=inv(A)*[10;25]
+
+Pc=1*V(1)
+Iv=(5-V(2))/2 + (5-V(1))/5
+Pv=5*Iv
+
+disp(V)
+disp(Pv,Pc)
\ No newline at end of file diff --git a/671/CH3/EX3.1/3_1.sce b/671/CH3/EX3.1/3_1.sce new file mode 100755 index 000000000..a3843c726 --- /dev/null +++ b/671/CH3/EX3.1/3_1.sce @@ -0,0 +1,9 @@ +function C=seriesC(C1,C2)
+ C=C1*C2/(C1+C2)
+endfunction
+
+Ceq1=10+seriesC(10,10)
+Ceq2=Ceq1
+
+Ceq=seriesC(seriesC(Ceq1,Ceq2),10)
+disp(Ceq)
\ No newline at end of file diff --git a/671/CH3/EX3.11/3_11b.sce b/671/CH3/EX3.11/3_11b.sce new file mode 100755 index 000000000..d62736528 --- /dev/null +++ b/671/CH3/EX3.11/3_11b.sce @@ -0,0 +1,12 @@ +L=2
+
+VL_0minus=0 //steady state
+disp(VL_0minus)
+
+i_0minus=1
+i_0plus=i_0minus
+VL_0plus=12-4*i_0plus
+disp(VL_0plus)
+
+di_by_dt_0plus=VL_0plus/L
+disp(di_by_dt_0plus)
diff --git a/671/CH3/EX3.12/3_12.sce b/671/CH3/EX3.12/3_12.sce new file mode 100755 index 000000000..b11cd88ff --- /dev/null +++ b/671/CH3/EX3.12/3_12.sce @@ -0,0 +1,6 @@ +Vc_0m=100
+Vc_0p=Vc_0m
+T=(400+100)*2E-6
+i_0p=100/500
+P_0p=i_0p^2*400
+disp(P_0p)
\ No newline at end of file diff --git a/671/CH3/EX3.13/3_13.sce b/671/CH3/EX3.13/3_13.sce new file mode 100755 index 000000000..609040e84 --- /dev/null +++ b/671/CH3/EX3.13/3_13.sce @@ -0,0 +1,15 @@ +Vc_0m=10
+Vc_0p=Vc_0m
+disp(Vc_0p)
+
+//KVL
+i1_0p=(10-Vc_0p)/20
+i2_0p=Vc_0p/20
+
+//KCL
+iC_0p=i1_0p-i2_0p
+disp(iC_0p)
+iC_inf=0 //capacitor is open circuit
+disp(iC_inf)
+VC_inf=10*20/(20+20)
+disp(VC_inf)
\ No newline at end of file diff --git a/671/CH3/EX3.16/3_16.sce b/671/CH3/EX3.16/3_16.sce new file mode 100755 index 000000000..0bef764dd --- /dev/null +++ b/671/CH3/EX3.16/3_16.sce @@ -0,0 +1,12 @@ +L=0.25
+R=250
+V=10
+T=L/R
+
+t=0.5E-3
+i=V/R*(1-exp(-t/T))
+disp(i)
+
+t=2E-3
+i=V/R*((exp((1E-3-t)/T)-exp(-t/T)))
+disp(i)
\ No newline at end of file diff --git a/671/CH3/EX3.18/3_18.sce b/671/CH3/EX3.18/3_18.sce new file mode 100755 index 000000000..bf8fdfbec --- /dev/null +++ b/671/CH3/EX3.18/3_18.sce @@ -0,0 +1,13 @@ +R=5000
+C=1.0E-6
+Ie=1/1000
+Vcf=Ie*R
+T=R*C
+
+t=10/1000
+Vc10=Vcf*(1-exp(-t/T))
+disp(Vc10)
+
+t=20/1000
+Vc20=Vcf*(1-exp(-t/T))-Vc10
+disp(Vc20)
\ No newline at end of file diff --git a/671/CH3/EX3.2/3_2.sce b/671/CH3/EX3.2/3_2.sce new file mode 100755 index 000000000..dd88f252d --- /dev/null +++ b/671/CH3/EX3.2/3_2.sce @@ -0,0 +1,7 @@ +function p=parallel(r1,r2)
+ p=r1*r2/(r1+r2)
+endfunction
+
+Leq=1+parallel(2,2)+parallel(parallel(3,3),3)
+
+disp(Leq)
\ No newline at end of file diff --git a/671/CH3/EX3.21/3_21.sce b/671/CH3/EX3.21/3_21.sce new file mode 100755 index 000000000..f54e2c485 --- /dev/null +++ b/671/CH3/EX3.21/3_21.sce @@ -0,0 +1,13 @@ +//Replace curr source by voltage source
+Ics=1/1000
+R=100*1000
+V=Ics*R
+
+Vc_0m=25/(25+100)*V
+disp(Vc_0m)
+
+Vc_0p=Vc_0m
+disp(Vc_0p)
+
+Vc_inf=(V-10)*25/(100+25)
+disp(Vc_inf)
\ No newline at end of file diff --git a/671/CH3/EX3.22/3_22.sce b/671/CH3/EX3.22/3_22.sce new file mode 100755 index 000000000..a30cd9822 --- /dev/null +++ b/671/CH3/EX3.22/3_22.sce @@ -0,0 +1,12 @@ +L=20/1000
+VR2_0p=10
+VR2_inf=0
+VR2_1=5
+
+t=1/1000
+T=-t/log((VR2_1-VR2_inf)/(VR2_0p-VR2_inf))
+
+R2=L/T
+R1=1/(2/VR2_0p-1/R2)
+
+disp(R2,R1)
\ No newline at end of file diff --git a/671/CH3/EX3.24/3_24.sce b/671/CH3/EX3.24/3_24.sce new file mode 100755 index 000000000..7fc87c007 --- /dev/null +++ b/671/CH3/EX3.24/3_24.sce @@ -0,0 +1,14 @@ +C=1/4 +Vc_0m=12/(12+6)*12 +Vc_0p=8 +disp(Vc_0p) +t=0 +V_0p=6*cos(t) + +//at t=0+ +Vth=12/(12+6)*6 +Rth=6*12/(6+12) +ic_0p=(Vth-8)/Rth +disp(ic_0p) +d_by_dt_Vc_0p=ic_0p/C +disp(d_by_dt_Vc_0p)
\ No newline at end of file diff --git a/671/CH3/EX3.26/3_26.sce b/671/CH3/EX3.26/3_26.sce new file mode 100755 index 000000000..632d4ef64 --- /dev/null +++ b/671/CH3/EX3.26/3_26.sce @@ -0,0 +1,9 @@ +//at t=0-
+iL=4
+v=0
+disp(v,iL)
+
+//at t=0+
+iL=4
+v=-4*20
+disp(v,iL)
\ No newline at end of file diff --git a/671/CH3/EX3.27/3_27.sce b/671/CH3/EX3.27/3_27.sce new file mode 100755 index 000000000..63925557b --- /dev/null +++ b/671/CH3/EX3.27/3_27.sce @@ -0,0 +1,28 @@ +function p=parallel(r1,r2)
+ p=r1*r2/(r1+r2)
+endfunction
+
+L=25/1000
+
+//at t=0-
+R1=parallel(150,75)
+iL_0m=30/2
+disp(iL_0m)
+
+R2=parallel(150,50)
+ix_0m=R2/(R2+75)*30
+disp(ix_0m)
+
+
+//at t=0+
+iL_0p=iL_0m
+
+T=L/(75+50)
+iL_inf=0
+
+//at t=0.2ms
+t=0.2E-3
+
+iL=iL_inf+(iL_0p-iL_inf)*exp(-t/T)
+ix=-iL
+disp(ix,iL)
\ No newline at end of file diff --git a/671/CH3/EX3.29/3_29.sce b/671/CH3/EX3.29/3_29.sce new file mode 100755 index 000000000..638fac046 --- /dev/null +++ b/671/CH3/EX3.29/3_29.sce @@ -0,0 +1,17 @@ +R=250
+C=25E-3
+
+//at t=0-
+v_0m=200*0.2
+
+//at t=0+
+v_0p=v_0m
+
+T=R*C
+v_inf=0
+
+//at t=0.2ms
+t=0.2E-3
+
+t=T*log((v_0p-v_inf)/(20-v_inf))
+disp(t)
\ No newline at end of file diff --git a/671/CH3/EX3.3/3_3.sce b/671/CH3/EX3.3/3_3.sce new file mode 100755 index 000000000..810c2f2e6 --- /dev/null +++ b/671/CH3/EX3.3/3_3.sce @@ -0,0 +1,21 @@ +function C=seriesC(C1,C2)
+ C=C1*C2/(C1+C2)
+endfunction
+
+V=100
+
+Cp=1+2
+Ceq=seriesC(Cp,6)
+q=Ceq*V
+
+q1=q*(1/(1+2))
+q2=q-q1
+
+disp(q2,q1,q)
+
+E6=q*q/2/6/1000
+E1=q1*q1/2/1/1000
+E2=q2*q2/2/2/1000
+Enet=E1+E2+E6
+
+disp(Enet,E6,E2,E1)
\ No newline at end of file diff --git a/671/CH3/EX3.32/3_32.sce b/671/CH3/EX3.32/3_32.sce new file mode 100755 index 000000000..c1b871e42 --- /dev/null +++ b/671/CH3/EX3.32/3_32.sce @@ -0,0 +1,14 @@ +L=0.2
+R=50+30
+
+iL_0m=100/50
+iL_0p=iL_0m
+iL_inf=0
+T=L/R
+
+t=10/1000
+iL_10=iL_0p*exp(-t/T)
+disp(iL_10)
+
+t1=-T*log(0.5*iL_0p/(iL_0p))
+disp(t1)
\ No newline at end of file diff --git a/671/CH3/EX3.33/3_33.sce b/671/CH3/EX3.33/3_33.sce new file mode 100755 index 000000000..6d2c36143 --- /dev/null +++ b/671/CH3/EX3.33/3_33.sce @@ -0,0 +1,24 @@ +R=5
+L=2
+V=10
+T=L/R
+
+iL_m=V/R
+disp(iL_m)
+iL_0p=iL_m
+iL_inf=2+V/R
+
+//function I=iL(t)
+// I=iL_inf+(iL_0p-iL_inf)*exp(-t/T)
+//endfunction
+
+//disp(iL(0.5))
+//disp(iL(1.5))
+
+t=0.5
+I=iL_inf+(iL_0p-iL_inf)*exp(-t/T)
+disp(I)
+
+t=1.5
+I=iL_inf+(iL_0p-iL_inf)*exp(-t/T)
+disp(I)
\ No newline at end of file diff --git a/671/CH3/EX3.36/3_36.sce b/671/CH3/EX3.36/3_36.sce new file mode 100755 index 000000000..d623c8512 --- /dev/null +++ b/671/CH3/EX3.36/3_36.sce @@ -0,0 +1,17 @@ +L=4/1000
+R=1000
+V=9
+
+iL_0m=V/(2*R)
+iL_0p=iL_0m
+iL_inf=0
+isw_inf=V/R
+T=L/R
+
+t=5E-6
+
+iL_5=iL_0p*exp(-t/T)
+disp(iL_5)
+
+isw_5=isw_inf*(1-exp(-t/T))
+disp(isw_5)
\ No newline at end of file diff --git a/671/CH3/EX3.37.38/3_37_38.sce b/671/CH3/EX3.37.38/3_37_38.sce new file mode 100755 index 000000000..5fa2f9d3d --- /dev/null +++ b/671/CH3/EX3.37.38/3_37_38.sce @@ -0,0 +1,34 @@ +R=20
+L=2
+C=1/25
+
+//at t=0-
+iR=-4
+iL=4
+iC=0
+vR=-R*4
+vC=-vR
+vL=0
+
+disp(iR,iL,iC,vR,vL,vC)
+
+//at t=0+
+iL=iL
+vC=vC
+iR=5-4 //KCL at node 1
+vR=R*iR
+iC=4+iR //KCL at node 2
+vL=vC+vR //KVL inner mesh
+
+disp(iR,iL,iC,vR,vL,vC)
+
+
+//at t=0+ derivatives are
+DiL=vL/L
+DvC=iC/C
+DiR=-DiL //Differentiating KCL at node 1
+DiC=DiR //Differentiating KCL at node 2
+DvR=R*DiR
+DvL=DvR+DvC //Differentiating KVL inner mesh
+
+disp(DiR,DiL,DiC,DvR,DvL,DvC)
\ No newline at end of file diff --git a/671/CH3/EX3.4/3_4.sce b/671/CH3/EX3.4/3_4.sce new file mode 100755 index 000000000..8e36e0d7d --- /dev/null +++ b/671/CH3/EX3.4/3_4.sce @@ -0,0 +1,2 @@ +L=poly([3,-4,1],"L","coeff")
+disp(roots(L))
diff --git a/671/CH3/EX3.5/3_5.sce b/671/CH3/EX3.5/3_5.sce new file mode 100755 index 000000000..6192aa309 --- /dev/null +++ b/671/CH3/EX3.5/3_5.sce @@ -0,0 +1,7 @@ +function C=seriesC(C1,C2)
+ C=C1*C2/(C1+C2)
+endfunction
+
+Ceq=1+seriesC(6,3)
+
+disp(Ceq)
\ No newline at end of file diff --git a/671/CH3/EX3.6/3_6.sce b/671/CH3/EX3.6/3_6.sce new file mode 100755 index 000000000..3b2271c0a --- /dev/null +++ b/671/CH3/EX3.6/3_6.sce @@ -0,0 +1,10 @@ +function p=parallel(r1,r2)
+ p=r1*r2/(r1+r2)
+endfunction
+
+Lbc=parallel(1/10,1/20)
+Leq=1/50+Lbc
+disp(Leq)
+
+Vbc=Lbc*150
+disp(Vbc)
\ No newline at end of file diff --git a/671/CH3/EX3.7/3_7.sce b/671/CH3/EX3.7/3_7.sce new file mode 100755 index 000000000..7b1be3ebc --- /dev/null +++ b/671/CH3/EX3.7/3_7.sce @@ -0,0 +1,15 @@ +function C=seriesC(C1,C2)
+ C=C1*C2/(C1+C2)
+endfunction
+
+Ceq=seriesC(seriesC(10,20),40)
+disp(Ceq)
+
+q=Ceq*280
+disp(q)
+
+V1=q/10
+V2=q/20
+V3=q/40
+
+disp(V3,V2,V1)
\ No newline at end of file diff --git a/671/CH3/EX3.8/3_8.sce b/671/CH3/EX3.8/3_8.sce new file mode 100755 index 000000000..965e88ea0 --- /dev/null +++ b/671/CH3/EX3.8/3_8.sce @@ -0,0 +1,6 @@ +Ceq=10+20+40
+Q=200*[10,20,40]
+
+disp(Q)
+Qnet=Q(1)+Q(2)+Q(3)
+disp(Qnet)
\ No newline at end of file diff --git a/671/CH3/EX3.9/3_9.sce b/671/CH3/EX3.9/3_9.sce new file mode 100755 index 000000000..53ac6fe54 --- /dev/null +++ b/671/CH3/EX3.9/3_9.sce @@ -0,0 +1,15 @@ +//deactivate all independent sources
+
+function p=parallel(r1,r2)
+ p=r1*r2/(r1+r2)
+endfunction
+
+L=2
+Req=parallel(6,12)+4
+T1=L/Req
+disp(T1)
+
+C=1/2
+Req=2+parallel(6,12)+2
+T2=Req*C
+disp(T2)
diff --git a/671/CH4/EX4.1/4_1.sce b/671/CH4/EX4.1/4_1.sce new file mode 100755 index 000000000..f71274753 --- /dev/null +++ b/671/CH4/EX4.1/4_1.sce @@ -0,0 +1,5 @@ +Iav=1/(2*%pi)*integrate('20*sin(wt)','wt',%pi/3,%pi)
+disp(Iav)
+
+Irms=sqrt(1/(2*%pi)*integrate('(20*sin(wt))^2','wt',%pi/3,%pi))
+disp(Irms)
\ No newline at end of file diff --git a/671/CH4/EX4.10/4_10.sce b/671/CH4/EX4.10/4_10.sce new file mode 100755 index 000000000..96cbc72c1 --- /dev/null +++ b/671/CH4/EX4.10/4_10.sce @@ -0,0 +1,10 @@ +function Zeq=parallel(Z1,Z2)
+ Zeq=Z1*Z2/(Z1+Z2)
+endfunction
+
+Zeq=parallel(5,3-imult(6))
+I=complex(10,0)
+V=Zeq*I
+pf=cos(atan(imag(V)/real(V)))
+P=norm(V)*norm(I)*pf
+disp(pf,P)
\ No newline at end of file diff --git a/671/CH4/EX4.11/4_11.sce b/671/CH4/EX4.11/4_11.sce new file mode 100755 index 000000000..75ab8020f --- /dev/null +++ b/671/CH4/EX4.11/4_11.sce @@ -0,0 +1,26 @@ +P1=8000
+pf1=0.8
+V1=430
+
+I1=P1/V1/pf1
+Pr1=P1-I1^2*1
+Q1=P1*tan(acos(pf1))
+Qr1=Q1-I1^2*1.2
+Sr1=sqrt(Pr1^2+Qr1^2)
+
+Vl=Sr1/I1
+Pl=15000
+Ql=Pl*tan(acos(0.8))
+Pr2=Pl-Pr1
+Qr2=Ql-Qr1
+Sr2=sqrt(Pr2^2+Qr2^2)
+
+I2=Sr2/Vl
+P2=Pr2+I2^2*0.7
+Q2=Qr2+I2^2*0.9
+
+pf=cos(atan(Q2/P2))
+S2=sqrt(P2^2+Q2^2)
+V2=S2/I2
+
+disp(V2,pf,P2,Q2,Q1,Vl)
diff --git a/671/CH4/EX4.12/4_12.sce b/671/CH4/EX4.12/4_12.sce new file mode 100755 index 000000000..e49706f62 --- /dev/null +++ b/671/CH4/EX4.12/4_12.sce @@ -0,0 +1,16 @@ +V=231
+f=50
+w=2*%pi*f
+Sl=10
+pf=0.8
+Pl=Sl*pf
+Ql=Sl*sin(acos(pf))
+Qc=Ql-tan(acos(0.95))*Pl
+
+C=Qc*1000/V^2/w
+
+Is1=10*1000/V
+Il=Is1
+Is2=norm(Pl+%i*(Ql-Qc))*1000/V
+
+disp(Is2,Is1,C,Qc)
\ No newline at end of file diff --git a/671/CH4/EX4.13/4_13.sce b/671/CH4/EX4.13/4_13.sce new file mode 100755 index 000000000..aa3ada8a1 --- /dev/null +++ b/671/CH4/EX4.13/4_13.sce @@ -0,0 +1,23 @@ +function [x,y]=polar_to_cart(r,theta)
+ theta=theta/180*%pi
+ x=r*cos(theta)
+ y=r*sin(theta)
+endfunction
+
+//converting v source to curr source
+V=15
+R=5
+I1=V/R
+
+
+[Ix,Iy]=polar_to_cart(2,-30)
+I2=complex(Ix,Iy)
+
+//nodal analysis
+A=[0.7-0.1*%i,-0.5;-0.5,0.5+0.5*%i]
+V=inv(A)*[I1;I2]
+
+[rv1,thetav1]=polar(V(1))
+[rv2,thetav2]=polar(V(2))
+
+disp(real(thetav2*180/%pi),rv2,real(thetav1*180/%pi),rv1)
\ No newline at end of file diff --git a/671/CH4/EX4.14/4_14.sce b/671/CH4/EX4.14/4_14.sce new file mode 100755 index 000000000..17a118d27 --- /dev/null +++ b/671/CH4/EX4.14/4_14.sce @@ -0,0 +1,17 @@ +w=600
+R=10
+L=10E-3
+C=0.5E-3
+Xl=w*L*%i
+Xc=1/(w*C*%i) //Xc value in the book is wrong
+V1=40
+V2=complex(0,-30)
+
+//mesh analysis
+A=[R+Xl,-R;-R,R+Xc]
+I=inv(A)*[V1;V2]
+
+Ir=I(1)-I(2)
+Vr=R*Ir
+
+disp(Vr) //Final answer is different
\ No newline at end of file diff --git a/671/CH4/EX4.15/4_15.sce b/671/CH4/EX4.15/4_15.sce new file mode 100755 index 000000000..4e9f75505 --- /dev/null +++ b/671/CH4/EX4.15/4_15.sce @@ -0,0 +1,18 @@ +Z1=complex(2,-1)
+Z2=complex(0,-5)
+Z3=complex(2,1)
+I1=1
+I2=complex(0,-2)
+
+//deactivate curr source 2
+V11=I1*(Z2+Z3)/(Z1+Z2+Z3)*Z1
+V21=I1*Z1/(Z1+Z2+Z3)*Z3
+
+//deactivate curr source 1
+V12=I2*Z3*Z1/(Z1+Z2+Z3)
+V22=I2*(Z1+Z2)/(Z1+Z2+Z3)*Z3
+
+V1=V11+V12
+V2=V21+V22
+
+disp(V2,V1)
\ No newline at end of file diff --git a/671/CH4/EX4.16/4_16.sce b/671/CH4/EX4.16/4_16.sce new file mode 100755 index 000000000..34ffcf90a --- /dev/null +++ b/671/CH4/EX4.16/4_16.sce @@ -0,0 +1,28 @@ +function [Ra,Rb,Rc]=delta_to_star(Rab,Rbc,Rca)
+ X=Rab+Rbc+Rca
+ Ra=Rab*Rca/X
+ Rb=Rab*Rbc/X
+ Rc=Rca*Rbc/X
+endfunction
+
+function Zeq=parallel(Z1,Z2)
+ Zeq=Z1*Z2/(Z1+Z2)
+endfunction
+
+V=20
+w=2
+R=1
+C=1/2
+Xc=1/(w*C*%i)
+Zab=-%i
+Zbc=2
+Zca=2
+
+[Za,Zb,Zc]=delta_to_star(Zab,Zbc,Zca)
+Zth=Za+parallel(R+Zb,Xc+Zc)
+
+Vdc=V*(Zc+Xc)/(R+Zb+Zc+Xc)
+disp(Zth,Vdc)
+
+Isc=Vdc/Zth
+disp(Zth,Isc)
\ No newline at end of file diff --git a/671/CH4/EX4.17/4_17.sce b/671/CH4/EX4.17/4_17.sce new file mode 100755 index 000000000..a804a6cae --- /dev/null +++ b/671/CH4/EX4.17/4_17.sce @@ -0,0 +1,18 @@ +function Zeq=parallel(Z1,Z2)
+ Zeq=Z1*Z2/(Z1+Z2)
+endfunction
+
+V=20
+Z1=complex(5,10)
+Z2=complex(3,-4)
+
+Vth=V*Z2/(Z1+Z2)
+Zth=parallel(Z1,Z2)
+
+//by maximum power transfer theorem
+Zl=conj(Zth)
+P=norm(Vth/(Zth+Zl))^2*real(Zl)
+disp(P,Zl)
+
+Rl=sqrt(real(Zth)^2+(4+imag(Zth))^2)
+disp(Rl)
\ No newline at end of file diff --git a/671/CH4/EX4.18/4_18.sce b/671/CH4/EX4.18/4_18.sce new file mode 100755 index 000000000..f3bf09f6b --- /dev/null +++ b/671/CH4/EX4.18/4_18.sce @@ -0,0 +1,34 @@ +function [x,y]=polar_to_cart(r,theta)
+ theta=theta/180*%pi
+ x=r*cos(theta)
+ y=r*sin(theta)
+endfunction
+
+R1=1
+R2=6
+L=2
+C=1/3
+
+[Vx,Vy]=polar_to_cart(4,30)
+[Ix,Iy]=polar_to_cart(0.8,-10)
+
+//deactivate current source
+V=complex(Vx,Vy)
+w=3
+Xl=w*L*%i
+Xc=1/(w*C*%i)
+
+Il1=V/(R1+R2+Xl+Xc)
+Pav1=norm(Il1)^2*R1
+
+//deactivate voltage source
+I=complex(Ix,Iy)
+w=5
+Xl=w*L*%i
+Xc=1/(w*C*%i)
+
+Il2=I*(R2+Xl)/(R2+Xl+R1+Xc)
+Pav2=norm(Il2)^2*R1
+
+Pav=Pav1+Pav2
+disp(Pav)
\ No newline at end of file diff --git a/671/CH4/EX4.2/4_2.sce b/671/CH4/EX4.2/4_2.sce new file mode 100755 index 000000000..94f742740 --- /dev/null +++ b/671/CH4/EX4.2/4_2.sce @@ -0,0 +1,4 @@ +Iav_by_Im=1/%pi*integrate('sin(wt)','wt',0,%pi)
+disp(Iav_by_Im)
+
+//final answer is wrong in the book
\ No newline at end of file diff --git a/671/CH4/EX4.21/4_21.sce b/671/CH4/EX4.21/4_21.sce new file mode 100755 index 000000000..7b34071e6 --- /dev/null +++ b/671/CH4/EX4.21/4_21.sce @@ -0,0 +1,19 @@ +I=35
+VR=25
+Vrl=40
+VRrl=50
+Vc=45
+C=50E-6
+Xc=Vc/I
+w=1/(Xc*C)
+
+theta=acos((VR^2+VRrl^2-Vrl^2)/(2*VR*VRrl))
+x=VRrl*cos(theta)-25
+y=VRrl*sin(theta)
+
+r=x/I
+L=y/(I*w)
+Vappl=sqrt((VR+x)^2+y^2)
+R=VR/I
+
+disp(L,r,R)
\ No newline at end of file diff --git a/671/CH4/EX4.22/4_22.sce b/671/CH4/EX4.22/4_22.sce new file mode 100755 index 000000000..efd1b0701 --- /dev/null +++ b/671/CH4/EX4.22/4_22.sce @@ -0,0 +1,13 @@ +V=12
+w=1000
+R=4
+L=5E-3
+C=400E-6
+Xl=w*L*%i
+Xc=1/(w*C*%i)
+
+//mesh analysis
+A=[R+Xl,-Xl;2-Xl,Xl+Xc]
+I=inv(A)*[12;0]
+
+disp(I(1)) //answer is wrong in the book
\ No newline at end of file diff --git a/671/CH4/EX4.23/4_23.sce b/671/CH4/EX4.23/4_23.sce new file mode 100755 index 000000000..a9796fbe4 --- /dev/null +++ b/671/CH4/EX4.23/4_23.sce @@ -0,0 +1,23 @@ +function [x,y]=polar_to_cart(r,theta)
+ theta=theta/180*%pi
+ x=r*cos(theta)
+ y=r*sin(theta)
+endfunction
+
+[I1x,I1y]=polar_to_cart(2,10)
+[I2x,I2y]=polar_to_cart(3,120)
+
+I1=complex(I1x,I1y)
+I2=complex(I2x,I2y)
+w=4
+R=2
+L=3
+C=1/4
+Xl=w*L*%i
+Xc=1/(w*C*%i)
+
+//deactivate source 2
+i1=(R+Xl)/(R+Xl+Xc)*I1
+i2=1/(R+Xl+Xc)*I2
+i=i1+i2
+disp(i) //answer is wrong in the book
\ No newline at end of file diff --git a/671/CH4/EX4.24/4_24.sce b/671/CH4/EX4.24/4_24.sce new file mode 100755 index 000000000..d4b04e5e6 --- /dev/null +++ b/671/CH4/EX4.24/4_24.sce @@ -0,0 +1,22 @@ +V=230
+w=2*%pi*50
+R=8
+L=0.1
+C=160E-6
+
+Xl=w*L*%i
+disp(Xl)
+
+Xc=1/(w*C*%i)
+disp(Xc)
+
+Z=norm(R+Xl+Xc)
+disp(Z)
+I=V/Z
+disp(I)
+pf=cos(atan(norm(Xl+Xc)/R))
+disp(pf)
+
+Vcoil=I*norm(R+Xl)
+Vc=norm(I*Xc)
+disp(Vc,Vcoil)
\ No newline at end of file diff --git a/671/CH4/EX4.25/4_25.sce b/671/CH4/EX4.25/4_25.sce new file mode 100755 index 000000000..da954c3c9 --- /dev/null +++ b/671/CH4/EX4.25/4_25.sce @@ -0,0 +1,17 @@ +function Zeq=parallel(Z1,Z2)
+ Zeq=Z1*Z2/(Z1+Z2)
+endfunction
+
+V=100
+Z1=complex(0,-5)
+Z2=complex(5,0)
+Z3=complex(0,5)
+I=[0,0,0]
+
+Z=Z1+parallel(Z2,Z3)
+I(1)=V/Z
+
+I(2)=Z3/(Z2+Z3)*I(1)
+I(3)=Z2/(Z2+Z3)*I(1)
+
+disp(I)
\ No newline at end of file diff --git a/671/CH4/EX4.26/4_26.sce b/671/CH4/EX4.26/4_26.sce new file mode 100755 index 000000000..7c1766861 --- /dev/null +++ b/671/CH4/EX4.26/4_26.sce @@ -0,0 +1,21 @@ +function Zeq=parallel(Z1,Z2)
+ Zeq=Z1*Z2/(Z1+Z2)
+endfunction
+
+//converting curr source to v source
+I=0.4
+R1=15
+V=I*R1
+w=400
+
+R2=5
+R3=80
+L=25E-3
+Xl=w*L*%i
+
+Zeq=R1+R2+parallel(R3,Xl)
+I=V/Zeq
+Il=I*R3/(R3+Xl)
+Ix=I*Xl/(R3+Xl)
+
+disp(Il,Ix)
\ No newline at end of file diff --git a/671/CH4/EX4.27/4_27.sce b/671/CH4/EX4.27/4_27.sce new file mode 100755 index 000000000..ac237de14 --- /dev/null +++ b/671/CH4/EX4.27/4_27.sce @@ -0,0 +1,11 @@ +V=4
+w=2
+
+R=4
+L=2
+Xl=w*L*%i
+
+Il=V/(Xl+R)
+Xc=-V/imag(Il)
+C=1/(w*Xc)
+disp(C)
\ No newline at end of file diff --git a/671/CH4/EX4.28/4_28.sce b/671/CH4/EX4.28/4_28.sce new file mode 100755 index 000000000..7faf4c7a3 --- /dev/null +++ b/671/CH4/EX4.28/4_28.sce @@ -0,0 +1,21 @@ +function [x,y]=polar_to_cart(r,theta)
+ theta=theta/180*%pi
+ x=r*cos(theta)
+ y=r*sin(theta)
+endfunction
+
+I=4
+w=500
+[Ir,Ic]=polar_to_cart(3,40)
+Ix=complex(Ir,Ic)
+C=1E-3
+L=10E-3
+Xl=w*L*%i
+Xc=1/(w*C*%i)
+
+Il=I-Ix
+Ic=Ix
+Vc=Ic*Xc
+Vl=Il*Xl
+Vx=Vl-Vc
+disp(Vx) //answer wrong in the book
\ No newline at end of file diff --git a/671/CH4/EX4.29/4_29.sce b/671/CH4/EX4.29/4_29.sce new file mode 100755 index 000000000..fd0999d18 --- /dev/null +++ b/671/CH4/EX4.29/4_29.sce @@ -0,0 +1,10 @@ +w=10
+R=2
+L=0.3
+Ir=10*(cos(%pi/4)+%i*sin(%pi/4))
+Vr=Ir*R
+Vc=20*(cos(%pi/4)-%i*sin(%pi/4))
+V=Vr+Vc
+Ic=Ir
+C=Ic/(w*Vc*%i)
+disp(real(C)) ///////Wrong in book
\ No newline at end of file diff --git a/671/CH4/EX4.30/4_30.sce b/671/CH4/EX4.30/4_30.sce new file mode 100755 index 000000000..41d8707d4 --- /dev/null +++ b/671/CH4/EX4.30/4_30.sce @@ -0,0 +1,11 @@ +R=2000
+C=5E-6
+w=1000
+
+Xc=1/(w*C*%i)
+Y=1/R+1/Xc
+Z=1/Y
+Req=real(Z)
+Ceq=-1/(imag(Z)*w)
+
+disp(Ceq*1E6,Req) //////Answer wrong in the book
\ No newline at end of file diff --git a/671/CH4/EX4.31/4_31.sce b/671/CH4/EX4.31/4_31.sce new file mode 100755 index 000000000..1a46d1ee5 --- /dev/null +++ b/671/CH4/EX4.31/4_31.sce @@ -0,0 +1,15 @@ +I=10*(cos(%pi/180*37)-%i*sin(%pi/180*37))
+V=6
+C=250E-6
+w=1000
+Xc=1/(w*C*%i)
+
+Ic=V/Xc
+disp(Ic)
+
+Ix=imag(I-Ic)
+X=abs(V/Ix)
+Ir=real(I-Ic)
+R=V/Ir
+
+disp(R,X)
\ No newline at end of file diff --git a/671/CH4/EX4.32/4_32.sce b/671/CH4/EX4.32/4_32.sce new file mode 100755 index 000000000..168a418ad --- /dev/null +++ b/671/CH4/EX4.32/4_32.sce @@ -0,0 +1,31 @@ +V1=30+10*%i
+V2=30
+w=1000
+L=1
+C1=1E-6
+C2=1E-6
+R1=1000
+R2=1000
+
+Xl=%i*w*L
+Xc1=%i/(w*C1)
+Xc2=%i/(w*C2)
+
+////////mesh equations
+
+A=[1,%i; %i,1-2*%i]
+I=inv(A)*[10*%i;30]
+
+Ic1=I(1)-I(2)
+
+disp(Ic1)
+
+
+
+
+
+
+
+
+
+
diff --git a/671/CH4/EX4.33/4_33.sce b/671/CH4/EX4.33/4_33.sce new file mode 100755 index 000000000..e2bfdd4ce --- /dev/null +++ b/671/CH4/EX4.33/4_33.sce @@ -0,0 +1,17 @@ +function [x,y]=polar_to_cart(r,theta)
+ theta=theta/180*%pi
+ x=r*cos(theta)
+ y=r*sin(theta)
+endfunction
+
+[Ir,Ic]=polar_to_cart(3,30)
+I=complex(Ir,Ic)
+Zc=-5*%i
+Zrl=10+5*%i
+
+Ic=Zrl/(Zc+Zrl)*I
+Vth=Ic*Zc
+Zth=parallel(Zc,Zrl)
+In=Vth/Zth
+
+disp(Rth,In,Vth)
\ No newline at end of file diff --git a/671/CH4/EX4.34/4_34.sce b/671/CH4/EX4.34/4_34.sce new file mode 100755 index 000000000..9c81b7546 --- /dev/null +++ b/671/CH4/EX4.34/4_34.sce @@ -0,0 +1,26 @@ +function [x,y]=polar_to_cart(r,theta)
+ theta=theta/180*%pi
+ x=r*cos(theta)
+ y=r*sin(theta)
+endfunction
+
+[Ir,Ic]=polar_to_cart(2,10)
+I1=complex(Ir,Ic)
+[Ir,Ic]=polar_to_cart(3,90+30)
+I2=complex(Ir,Ic)
+
+w=4
+R=2
+L=0.5
+C=1/4
+Xl=w*L*%i
+Xc=1/(w*C*%i)
+
+//deactivate voltage source
+i1=I1*(R+Xl)/(R+Xl+Xc)
+
+//deactivate curr source
+i2=I2/(R+Xl+Xc)
+
+i=i1+i2
+disp(i)
\ No newline at end of file diff --git a/671/CH4/EX4.35/4_35.sce b/671/CH4/EX4.35/4_35.sce new file mode 100755 index 000000000..85f6c53b2 --- /dev/null +++ b/671/CH4/EX4.35/4_35.sce @@ -0,0 +1,27 @@ +function Zeq=parallel(Z1,Z2)
+ Zeq=Z1*Z2/(Z1+Z2)
+endfunction
+
+I=10
+w=2000
+R=200
+L=0.125
+
+Xl=w*L*%i
+
+Zeq=parallel(R,Xl)
+V=I*Zeq
+Il=V/Xl
+Ir=V/R
+
+t=1/1000
+I1=sqrt(2)*real(I*exp(%i*w*t))
+Il1=sqrt(2)*real(Il*exp(%i*w*t))
+Ir1=sqrt(2)*real(Ir*exp(%i*w*t))
+V1=sqrt(2)*real(V*exp(%i*w*t))
+
+Ps=-V1*I1
+Pr=-V1*Ir1
+Pl=-V1*Il1
+
+disp(Pl,Pr,Ps)
\ No newline at end of file diff --git a/671/CH4/EX4.36/4_36.sce b/671/CH4/EX4.36/4_36.sce new file mode 100755 index 000000000..79fc6fb1b --- /dev/null +++ b/671/CH4/EX4.36/4_36.sce @@ -0,0 +1,20 @@ +function [x,y]=polar_to_cart(r,theta)
+ theta=theta/180*%pi
+ x=r*cos(theta)
+ y=r*sin(theta)
+endfunction
+
+[Vr,Vc]=polar_to_cart(120,45)
+V=complex(Vr,Vc)
+
+[Zr,Zc]=polar_to_cart(16.3,24.5)
+Z=complex(Zr,Zc)
+
+w=50
+
+I=V/Z
+P=V*conj(I)
+Pavg=real(P)
+pf=real((V/I)/norm(V/I))
+
+disp(pf,Pavg)
\ No newline at end of file diff --git a/671/CH4/EX4.37/4_37.sce b/671/CH4/EX4.37/4_37.sce new file mode 100755 index 000000000..dcf69a414 --- /dev/null +++ b/671/CH4/EX4.37/4_37.sce @@ -0,0 +1,23 @@ +function Zeq=parallel(Z1,Z2)
+ Zeq=Z1*Z2/(Z1+Z2)
+endfunction
+
+function [x,y]=polar_to_cart(r,theta)
+ theta=theta/180*%pi
+ x=r*cos(theta)
+ y=r*sin(theta)
+endfunction
+
+[Ir,Ic]=polar_to_cart(20,60)
+I=complex(Ir,Ic)
+
+w=5000
+R=3000
+L=1
+C=0.25E-6
+Xl=w*L*%i
+Xc=1/(w*C*%i)
+
+Z=parallel(R+Xl,Xc)
+V=I*Z
+disp(V)
\ No newline at end of file diff --git a/671/CH4/EX4.38/4_38.sce b/671/CH4/EX4.38/4_38.sce new file mode 100755 index 000000000..efb046cce --- /dev/null +++ b/671/CH4/EX4.38/4_38.sce @@ -0,0 +1,22 @@ +function Zeq=parallel(Z1,Z2)
+ Zeq=Z1*Z2/(Z1+Z2)
+endfunction
+
+V=5
+w=5
+R=2
+L1=0.8
+L2=1
+C=1/5
+Xl1=w*L1*%i
+Xl2=w*L2*%i
+Xc=1/(w*C*%i)
+
+Vth=R/(R+Xl2)*V
+Zth=Xc+parallel(Xl2,R)
+disp(Zth,Vth)
+
+I=Vth/(Zth+Xl1)
+Vl=I*Xl1
+S=Vl*conj(I)/2
+disp(S)
\ No newline at end of file diff --git a/671/CH4/EX4.39/4_39.sce b/671/CH4/EX4.39/4_39.sce new file mode 100755 index 000000000..872b2b604 --- /dev/null +++ b/671/CH4/EX4.39/4_39.sce @@ -0,0 +1,8 @@ +Pm=600
+Vm=sqrt(3*Pm)
+f=15.36E6
+w=2*%pi*f
+t=20.3E-3
+theta=%pi/2-modulo(w*t,2*%pi)
+
+disp(theta*180/%pi)
\ No newline at end of file diff --git a/671/CH4/EX4.4/4_4.sce b/671/CH4/EX4.4/4_4.sce new file mode 100755 index 000000000..a278b7aaa --- /dev/null +++ b/671/CH4/EX4.4/4_4.sce @@ -0,0 +1,21 @@ +/////////////////////part a
+L=0.05
+R=20
+w=1.2E3
+Xl=w*L
+V=complex(100,200)
+I=complex(5,0)
+
+Xc=-imult(R+imult(Xl)-V/I)
+C=1/w/Xc
+
+disp(C)
+
+/////////////////////part b
+w=200
+V=complex(100,0)
+Xl=w*L
+Xc=-imult(R+imult(Xl)-V/I)
+C=1/w/Xc
+
+disp(C)
\ No newline at end of file diff --git a/671/CH4/EX4.40/4_40.sce b/671/CH4/EX4.40/4_40.sce new file mode 100755 index 000000000..3333f6e04 --- /dev/null +++ b/671/CH4/EX4.40/4_40.sce @@ -0,0 +1,19 @@ +V=240
+w=100*%pi
+R=6
+
+Vr=120
+I=Vr/R
+
+t=(205/I)^2 ////t=r^2+Xl^2
+r=((240/I)^2-t-R*R)/2/R ///this part solved wrong in the book
+Xl=sqrt(t-r*r)
+Z=sqrt(t)
+disp(r)
+disp(Xl)
+disp(Z)
+
+Pl_choke=I*I*r
+disp(Pl_choke)
+pf=Pl_choke/205/20
+disp(pf)
diff --git a/671/CH4/EX4.41/4_41.sce b/671/CH4/EX4.41/4_41.sce new file mode 100755 index 000000000..89f2471a1 --- /dev/null +++ b/671/CH4/EX4.41/4_41.sce @@ -0,0 +1,12 @@ +w=2 +L=1 +C=0.5 +Xl=w*L*%i +Xc=1/(w*C*%i) + +V=1 +I=V/(1+%i) +Y=I/V +R=1/real(Y) + +disp(R,Y)
\ No newline at end of file diff --git a/671/CH4/EX4.42/4_42.sce b/671/CH4/EX4.42/4_42.sce new file mode 100755 index 000000000..6a0371b54 --- /dev/null +++ b/671/CH4/EX4.42/4_42.sce @@ -0,0 +1,14 @@ +w=400
+R=5
+L=25E-3
+C=1.25E-3
+Xl=w*L*%i
+Xc=1/(w*C*%i)
+
+Z=R+Xl+Xc
+Y=1/Z
+C=-imag(Y)/w
+Yn=real(Y)
+Rn=1/Y
+
+disp(C)
\ No newline at end of file diff --git a/671/CH4/EX4.43/4_43.sce b/671/CH4/EX4.43/4_43.sce new file mode 100755 index 000000000..118d5d264 --- /dev/null +++ b/671/CH4/EX4.43/4_43.sce @@ -0,0 +1,16 @@ +function Zeq=parallel(Z1,Z2)
+ Zeq=Z1*Z2/(Z1+Z2)
+endfunction
+
+w=800
+R1=10
+R2=20
+L=0.05
+C=0.25E-3
+Xl=w*L*%i
+Xc=1/(w*C*%i)
+
+Zeq1=R2+parallel(Xc,R1+Xl)
+Zeq2=parallel(parallel(R1,R2)+Xc,Xl)
+
+disp(Zeq2,Zeq1)
\ No newline at end of file diff --git a/671/CH4/EX4.44/4_44.sce b/671/CH4/EX4.44/4_44.sce new file mode 100755 index 000000000..c0b8a08b1 --- /dev/null +++ b/671/CH4/EX4.44/4_44.sce @@ -0,0 +1,14 @@ +pf=0.707
+theta=acos(pf)
+P=200
+Q=tan(theta)*P
+pf2=0.85
+theta_n=acos(pf2)
+Qn=Q*tan(theta_n)
+Qc=Q-Qn
+
+w=314
+V=2000
+C=Qc/(V*V*w)
+
+disp(C)
\ No newline at end of file diff --git a/671/CH4/EX4.45/4_45.sce b/671/CH4/EX4.45/4_45.sce new file mode 100755 index 000000000..588e661cb --- /dev/null +++ b/671/CH4/EX4.45/4_45.sce @@ -0,0 +1,23 @@ +I=20
+w=2000
+R=200
+L=0.25
+Xl=w*L*%i
+
+Ir=I*Xl/(Xl+R)
+Il=I-Ir
+Vl=Xl*Il
+
+t=1E-3
+ir=sqrt(2)*real(Ir*exp(%i*w*t))
+il=sqrt(2)*real(Il*exp(%i*w*t))
+vl=sqrt(2)*real(Vl*exp(%i*w*t))
+is=sqrt(2)*real(I*exp(%i*w*t))
+vs=vl
+
+Pr=ir*ir*R
+Pl=vl*il
+Ps=is*ir*R
+Pr=ir*vl
+
+disp(Ps,Pl,Pr)
\ No newline at end of file diff --git a/671/CH4/EX4.46/4_46.sce b/671/CH4/EX4.46/4_46.sce new file mode 100755 index 000000000..5d1528458 --- /dev/null +++ b/671/CH4/EX4.46/4_46.sce @@ -0,0 +1,23 @@ +Vl=1
+w=2
+R=1
+r=1/2
+L=0.5
+C=1
+Xl=w*L*%i
+Xc=1/(w*C*%i)
+
+Il=Vl/Xl
+VR=Il*R
+Vs=Vl+VR
+
+Vr=Vs
+Ir=Vr/r
+Ic=Vs/Xc
+Is=Ir+Ic+Il
+
+PR=-VR*VR/R
+Pr=-Vr*Vr/r
+Ps=Vs*conj(Is)
+
+disp(real(Ps),Pr,PR)
\ No newline at end of file diff --git a/671/CH4/EX4.47/4_47.sce b/671/CH4/EX4.47/4_47.sce new file mode 100755 index 000000000..b765ddb30 --- /dev/null +++ b/671/CH4/EX4.47/4_47.sce @@ -0,0 +1,18 @@ +V=10*%i
+w=1000
+R=2
+L=2E-3
+C=500E-6
+Xl=w*L*%i
+Xc=1/(w*C*%i)
+
+Zeq=Xl+Xc+parallel(R,Xl)
+disp(Zeq)
+
+I=V/Z
+Ir=I*Xl/(R+Xl)
+Il2=I-Ir
+Vl=I*Xl
+Vc=I*Xc
+
+disp(I,Ir,Il2,Vl,Vc)
\ No newline at end of file diff --git a/671/CH4/EX4.48/4_48.sce b/671/CH4/EX4.48/4_48.sce new file mode 100755 index 000000000..1c85dc228 --- /dev/null +++ b/671/CH4/EX4.48/4_48.sce @@ -0,0 +1,29 @@ +function [x,y]=polar_to_cart(r,theta)
+ theta=theta/180*%pi
+ x=r*cos(theta)
+ y=r*sin(theta)
+endfunction
+
+[Vr,Vc]=polar_to_cart(100,120)
+V1=complex(Vr,Vc)
+
+I=10
+w=5000
+R=10000
+L=2.4E-3
+C=0.05E-3
+
+
+[Vr,Vc]=polar_to_cart(96,60)
+Vl=complex(Vr,Vc)
+
+Xl=w*L*%i
+Xc=1/(w*C*%i)
+
+Il=Vl/Xl
+Ic=I-Il
+V2=(R+Xc)*Ic+V1
+V3=V2-Vl
+V1=Ic*Xc
+
+disp(V1,V2,V3)
\ No newline at end of file diff --git a/671/CH4/EX4.49/4_49.sce b/671/CH4/EX4.49/4_49.sce new file mode 100755 index 000000000..a636875ef --- /dev/null +++ b/671/CH4/EX4.49/4_49.sce @@ -0,0 +1,12 @@ +function Zeq=parallel(Z1,Z2)
+ Zeq=Z1*Z2/(Z1+Z2)
+endfunction
+
+////////////short AB
+Vab=0
+Isc=50/4
+
+////////////for Zn
+Zn=parallel(4,8*%i)
+
+disp(Isc,Zn)
\ No newline at end of file diff --git a/671/CH4/EX4.5/4_5.sce b/671/CH4/EX4.5/4_5.sce new file mode 100755 index 000000000..364807b14 --- /dev/null +++ b/671/CH4/EX4.5/4_5.sce @@ -0,0 +1,19 @@ +L=0.0255
+R1=6
+V=240
+f=50
+w=2*%pi*f
+Va=sqrt(V^2/10)
+Vb=3*Va
+Xl=w*L
+Theta1=atan(Xl/R1)
+Theta2=%pi/2-Theta1 //Va and Vb are in quadrature
+
+I=Vb/sqrt(R1^2+Xl^2)
+
+R=(Va/I)/sqrt(1+tan(Theta2)^2)
+disp(R)
+
+Xc=R*tan(Theta2)
+C=1/w/Xc
+disp(C)
\ No newline at end of file diff --git a/671/CH4/EX4.50/4_50.sce b/671/CH4/EX4.50/4_50.sce new file mode 100755 index 000000000..20125fddc --- /dev/null +++ b/671/CH4/EX4.50/4_50.sce @@ -0,0 +1,17 @@ +function Zeq=parallel(Z1,Z2)
+ Zeq=Z1*Z2/(Z1+Z2)
+endfunction
+
+V=12*%i
+
+Vth=4-12*%i/(4-12*%i+6+9*%i)*V
+Zth=parallel(4-12*%i,6+9*%i)
+
+I=Vth/(Zth+6+12*%i)
+S=V*conj(I)
+disp(S)
+
+Zl=conj(Zth)
+I=Vth/(Zth+Zl)
+S=V*conj(I)
+disp(Zth,S)
\ No newline at end of file diff --git a/671/CH4/EX4.51/4_51.sce b/671/CH4/EX4.51/4_51.sce new file mode 100755 index 000000000..13a0e0399 --- /dev/null +++ b/671/CH4/EX4.51/4_51.sce @@ -0,0 +1,14 @@ +function Zeq=parallel(Z1,Z2)
+ Zeq=Z1*Z2/(Z1+Z2)
+endfunction
+
+I=5
+
+Zth=parallel(40,30*%i)
+Zl=conj(Zth)
+Vth=Zth*I
+Z=Zth+Zl
+Il=Vth/Z
+Pmax=abs(Il*Il*real(Zl))
+
+disp(Zth,Pmax)
\ No newline at end of file diff --git a/671/CH4/EX4.52/4_52.sce b/671/CH4/EX4.52/4_52.sce new file mode 100755 index 000000000..0214dc317 --- /dev/null +++ b/671/CH4/EX4.52/4_52.sce @@ -0,0 +1,11 @@ +V=4*sqrt(2)
+w=2
+R=4
+L=2
+Xl=w*L*%i
+
+Il=V/(R+Xl)
+Ic=-imag(Il)*%i
+C=Ic/(V*%i*w)
+
+disp(C)
\ No newline at end of file diff --git a/671/CH4/EX4.6/4_6.sce b/671/CH4/EX4.6/4_6.sce new file mode 100755 index 000000000..d9cb01554 --- /dev/null +++ b/671/CH4/EX4.6/4_6.sce @@ -0,0 +1,11 @@ +Z1=complex(10,15)
+Z2=complex(6,-8)
+
+I=complex(15,0)
+I1=I*Z2/(Z1+Z2)
+I2=I*Z1/(Z1+Z2)
+phase=[atan(imag(I1)/real(I1));atan(imag(I2)/real(I2))]
+disp(phase*180/%pi)
+
+V=I1*Z1
+disp(180/%pi*atan(imag(V)/real(V)))
\ No newline at end of file diff --git a/671/CH4/EX4.7/4_7.sce b/671/CH4/EX4.7/4_7.sce new file mode 100755 index 000000000..bbd220593 --- /dev/null +++ b/671/CH4/EX4.7/4_7.sce @@ -0,0 +1,33 @@ +function [r,theta]=cart_to_polar(z)
+ x=real(z)
+ y=imag(z)
+ r=norm(z)
+ theta=atan(y/x)
+endfunction
+
+function Zeq=parallel(Z1,Z2)
+ Zeq=Z1*Z2/(Z1+Z2)
+endfunction
+
+w=400
+R=10
+L=25E-3
+C=250E-6
+Xl=w*L*%i
+Xc=1/(w*C*%i)
+
+////////////part a
+Zin1=R+Xc
+[r1,theta1]=cart_to_polar(Zin1)
+disp(theta1*180/%pi,r1)
+
+////////////part b
+//Zin2=10+parallel(Xc,Xl) ///impedence is infinite...thus an error
+//[r2,theta2]=cart_to_polar(Zin2)
+disp(90," inf")
+
+
+////////////part c
+Zin3=R+parallel(Xc,Xl+10)
+[r3,theta3]=cart_to_polar(Zin3)
+disp(theta3*180/%pi,r3)
\ No newline at end of file diff --git a/671/CH4/EX4.8/4_8.sce b/671/CH4/EX4.8/4_8.sce new file mode 100755 index 000000000..db1a96dca --- /dev/null +++ b/671/CH4/EX4.8/4_8.sce @@ -0,0 +1,41 @@ +function [r,theta]=cart_to_polar(z)
+ x=real(z)
+ y=imag(z)
+ r=norm(z)
+ theta=atan(y/x)
+endfunction
+
+function [x,y]=polar_to_cart(zpolar)
+ r=real(zpolar)
+ theta=imag(zpolar)/180*%pi
+ x=r*cos(theta)
+ y=r*sin(theta)
+endfunction
+
+function Zeq=parallel(Z1,Z2)
+ Zeq=Z1*Z2/(Z1+Z2)
+endfunction
+
+R=200
+L=0.5
+C=50E-6
+w=200
+
+Xl=w*L*%i
+Xc=1/(w*C*%i)
+
+////////////////////////////part a
+Ir=complex(0.02*cos(30*%pi/180),0.02*sin(30*%pi/180))
+V=Ir*R
+Il=V/Xl
+Ic=V/Xc
+I=Ir+Il+Ic
+disp(I)
+
+////////////////////////////part b
+[Ix,Iy]=polar_to_cart(complex(2,-40))
+I=complex(Ix,Iy)
+Zin=parallel(parallel(R,Xc),Xl)
+V=Zin*I
+Ir=V/R
+disp(V,Ir)
\ No newline at end of file diff --git a/671/CH4/EX4.9/4_9.sce b/671/CH4/EX4.9/4_9.sce new file mode 100755 index 000000000..d50787223 --- /dev/null +++ b/671/CH4/EX4.9/4_9.sce @@ -0,0 +1,3 @@ +p=poly([0,2,0,-8],"w","coeff")
+w=roots(p)
+disp(w(1))
\ No newline at end of file diff --git a/671/CH5/EX5.1/5_1.sce b/671/CH5/EX5.1/5_1.sce new file mode 100755 index 000000000..10d77884f --- /dev/null +++ b/671/CH5/EX5.1/5_1.sce @@ -0,0 +1,17 @@ +Q0=200 + +//a +R=1 +C=2E-6 +L=C/(Q0/R)^2 +disp(L) + +L=2E-15 +C=1.2E-9 +R=Q0*sqrt(L/C) +disp(R) + +R=118500 +L=120E-12 +C=L*(Q0/R)^2 +disp(C)
\ No newline at end of file diff --git a/671/CH5/EX5.10/5_10.sce b/671/CH5/EX5.10/5_10.sce new file mode 100755 index 000000000..95cc73c00 --- /dev/null +++ b/671/CH5/EX5.10/5_10.sce @@ -0,0 +1,11 @@ +C=2.5E-6
+R=8
+wb=400
+
+L=R/wb
+w0=1/sqrt(L*C)
+Q0=w0*L/R
+w1=w0-wb/2
+w2=w0+wb/2
+
+disp(w2,w1,Q0,w0,L)
\ No newline at end of file diff --git a/671/CH5/EX5.11/5_11.sce b/671/CH5/EX5.11/5_11.sce new file mode 100755 index 000000000..2092a404f --- /dev/null +++ b/671/CH5/EX5.11/5_11.sce @@ -0,0 +1,15 @@ +w=1E6
+wb=1000
+V=0.05
+I=5E-3
+
+R=V/I
+Q0=w0/wb
+L=R*Q0/w0
+C=1/(w0*w0*L)
+Vl=w0*L*I
+Vc=Vl
+w1=w0-wb/2
+w2=w0+wb/2
+
+disp(w2,w1,Vc,Vl,C,L,Q0,R)
\ No newline at end of file diff --git a/671/CH5/EX5.12/5_12.sce b/671/CH5/EX5.12/5_12.sce new file mode 100755 index 000000000..0af93e583 --- /dev/null +++ b/671/CH5/EX5.12/5_12.sce @@ -0,0 +1,14 @@ +R=1E6
+L=1
+C=1E-6
+I=10E-6
+
+w0=1/sqrt(L*C)
+V=I*R
+
+wb=1/(R*C)
+Q0=w0/wb
+w1=w0-wb/2
+w2=w0+wb/2
+
+disp(w2,w1,V,Q0,w0)
\ No newline at end of file diff --git a/671/CH5/EX5.13/5_13.sce b/671/CH5/EX5.13/5_13.sce new file mode 100755 index 000000000..dfe16ada2 --- /dev/null +++ b/671/CH5/EX5.13/5_13.sce @@ -0,0 +1,16 @@ +f0=1E6
+Cmax=500E-12
+C=450E-12
+w0=2*%pi*f
+
+L=1/(w0*w0*Cmax)
+
+w=1/sqrt(L*C)
+f=w/(2*%pi)
+wb=2*2*%pi*(f-f0)
+r=wb*L
+Q0=2*%pi*f*L/r
+
+disp(Q0,L,r)
+
+////////calculation mistakes in book
\ No newline at end of file diff --git a/671/CH5/EX5.14/5_14.sce b/671/CH5/EX5.14/5_14.sce new file mode 100755 index 000000000..b2cfb3ff3 --- /dev/null +++ b/671/CH5/EX5.14/5_14.sce @@ -0,0 +1,13 @@ +R=10E3
+L=50E-3
+C=100E-6
+
+w0=1/sqrt(L*C)
+Q0=w0*R*C
+alpha=w0/2/Q0
+zeta=alpha/w0
+wd=w0*sqrt(1-zeta^2)
+
+disp(wd,zeta,alpha,Q0,w0)
+
+//////////calculation mistakes in the book
\ No newline at end of file diff --git a/671/CH5/EX5.15/5_15.sce b/671/CH5/EX5.15/5_15.sce new file mode 100755 index 000000000..f2c57cefa --- /dev/null +++ b/671/CH5/EX5.15/5_15.sce @@ -0,0 +1,11 @@ +w0=1000
+wd=997
+Yin=1.2E-3
+
+zeta=sqrt(1-(wd/w0)^2)
+alpha=zeta*w0
+R=1/Yin
+C=1/(2*alpha*R)
+L=1/(w0*w0*C)
+
+disp(C,L,R)
\ No newline at end of file diff --git a/671/CH5/EX5.17/5_17.sce b/671/CH5/EX5.17/5_17.sce new file mode 100755 index 000000000..07789cf64 --- /dev/null +++ b/671/CH5/EX5.17/5_17.sce @@ -0,0 +1,19 @@ +I=1
+w=400
+R=500
+L=1/40
+C=250E-6
+Xl=w*L*%i
+Xc=1/(w*C*%i)
+
+w0=1/sqrt(L*C)
+////////at resonance
+Ir=I
+V=R*I
+Il=V/Xl
+Ic=V/Xc
+Icir=abs(Il)
+Ic+Il=0
+Icl=Ic+Il
+
+disp(Icl,Ic,Il,Ir)
\ No newline at end of file diff --git a/671/CH5/EX5.18/5_18.sce b/671/CH5/EX5.18/5_18.sce new file mode 100755 index 000000000..30d01fd7d --- /dev/null +++ b/671/CH5/EX5.18/5_18.sce @@ -0,0 +1,15 @@ +V=100
+R=10
+L=2E-3
+C=200E-6
+
+w0=1/sqrt(L*C)
+Xl=w0*L*%i
+Xc=1/(w0*C*%i)
+I=V/R
+
+Vl=I*Xl
+Vc=I*Xc
+Vlc=Vl+Vc
+
+disp(Vlc,Vc,Vl,I,w0)
\ No newline at end of file diff --git a/671/CH5/EX5.19/5_19.sce b/671/CH5/EX5.19/5_19.sce new file mode 100755 index 000000000..353b507c9 --- /dev/null +++ b/671/CH5/EX5.19/5_19.sce @@ -0,0 +1,17 @@ +R=1
+L=10E-6
+C=10E-12
+V=10
+
+
+w0=1/sqrt(L*C)
+Xl=w0*L*%i
+Xc=1/(w0*C*%i)
+
+Q0=w0*L/R
+Z=R*Q0*Q0
+Iin=V/Z
+
+Ic=V/Xc
+
+disp(Ic,Iin,Z,Q0,w0)
\ No newline at end of file diff --git a/671/CH5/EX5.2/5_2.sce b/671/CH5/EX5.2/5_2.sce new file mode 100755 index 000000000..1c6dc8a45 --- /dev/null +++ b/671/CH5/EX5.2/5_2.sce @@ -0,0 +1,8 @@ +R=1000
+C=49E-6
+L=13E-3
+
+w0=1/sqrt(L*C)
+Q0=w0*R*C
+
+disp(Q0,w0)
\ No newline at end of file diff --git a/671/CH5/EX5.20/5_20.sce b/671/CH5/EX5.20/5_20.sce new file mode 100755 index 000000000..2faf08f79 --- /dev/null +++ b/671/CH5/EX5.20/5_20.sce @@ -0,0 +1,24 @@ +V=200
+R=2
+L=0.02
+
+f=25
+w0=2*%pi*f
+C=1/(w0*w0*L)
+I=V/2
+Vc=1/(C*w0)
+disp(I,Vc)
+
+f=50
+w0=2*%pi*f
+C=1/(w0*w0*L)
+I=V/2
+Vc=1/(C*w0)
+disp(I,Vc)
+
+f=100
+w0=2*%pi*f
+C=1/(w0*w0*L)
+I=V/2
+Vc=1/(C*w0)
+disp(I,Vc)
\ No newline at end of file diff --git a/671/CH5/EX5.21/5_21.sce b/671/CH5/EX5.21/5_21.sce new file mode 100755 index 000000000..558df96ef --- /dev/null +++ b/671/CH5/EX5.21/5_21.sce @@ -0,0 +1,10 @@ +R=10
+L=0.1
+C=150E-6
+
+w=sqrt((1+R*R*C/L)/(L*C))
+f=w/(2*%pi)
+
+disp(f)
+Req=R/(1-w*w*L*C+(w*R*C)^2)
+disp(Req)
\ No newline at end of file diff --git a/671/CH5/EX5.22/5_22.sce b/671/CH5/EX5.22/5_22.sce new file mode 100755 index 000000000..4b5c4f612 --- /dev/null +++ b/671/CH5/EX5.22/5_22.sce @@ -0,0 +1,13 @@ +R=35
+Q0=50
+f1=540E3
+f2=1610E3
+w1=2*%pi*f1
+w2=2*%pi*f2
+
+
+L=1/(w1*(Q0/R))
+Cmax=(Q0/R)^2*L
+Cmin=1/(L*w2^2)
+
+disp(Cmin*1000000,Cmax*1000000,L*1000000)
\ No newline at end of file diff --git a/671/CH5/EX5.28/5_28.sce b/671/CH5/EX5.28/5_28.sce new file mode 100755 index 000000000..ae10eb3db --- /dev/null +++ b/671/CH5/EX5.28/5_28.sce @@ -0,0 +1,34 @@ +function [x,y]=polar_to_cart(r,theta)
+ theta=theta/180*%pi
+ x=r*cos(theta)
+ y=r*sin(theta)
+endfunction
+
+[Vr,Vc]=polar_to_cart(4,30)
+V=complex(Vr,Vc)
+
+[Ir,Ic]=polar_to_cart(0.8,-10)
+I=complex(Ir,Ic)
+
+wv=3
+wi=5
+R1=1
+L=2
+R6=6
+C=1/3
+
+//////////deactivating curr source
+Xl=wv*L*%i
+Xc=1/(wv*C*%i)
+Il1=V/(R1+R6+Xl+Xc)
+Pav1=norm(Il1)^2*R1
+
+//////////deactivating voltage source
+Xl=wi*L*%i
+Xc=1/(wi*C*%i)
+Il2=I*(R6+Xl)/(R6+Xl+R1+Xc)
+Pav2=norm(Il2)^2*R1
+
+Pav=Pav1+Pav2
+
+disp(Pav)
\ No newline at end of file diff --git a/671/CH5/EX5.29/5_29.sce b/671/CH5/EX5.29/5_29.sce new file mode 100755 index 000000000..41a2c4cd6 --- /dev/null +++ b/671/CH5/EX5.29/5_29.sce @@ -0,0 +1,14 @@ +L=10E-6
+R=1
+C=10E-9
+V=10
+
+Zmax=L/R/C
+I=V/Zmax
+w0=1/sqrt(L*C)
+w=0.9*w0
+
+Y=R*C/L+%i*(w*C-1/w/L)
+I=norm(Y)*V
+
+disp(I)
\ No newline at end of file diff --git a/671/CH5/EX5.3/5_3.sce b/671/CH5/EX5.3/5_3.sce new file mode 100755 index 000000000..f6ae6d5f7 --- /dev/null +++ b/671/CH5/EX5.3/5_3.sce @@ -0,0 +1,12 @@ +R=5
+C=0.08E-6
+L=5E-3
+
+w0=1/sqrt(L*C)
+f0=w0/2/%pi
+Q0=w0*L/R
+bandwidth=w0/Q0
+wb=bandwidth
+w=[w0-1/2*wb,w0+1/2*wb]
+
+disp(w(2),w(1))
\ No newline at end of file diff --git a/671/CH5/EX5.4/5_4.sce b/671/CH5/EX5.4/5_4.sce new file mode 100755 index 000000000..85b418fd5 --- /dev/null +++ b/671/CH5/EX5.4/5_4.sce @@ -0,0 +1,14 @@ +L=40E-6
+R=4.02
+f0=800E3
+
+w0=2*%pi*f0
+C=1/(w0*w0*L)
+Q0=w0*L/R
+fb=f0/Q0
+
+Xl=w0*L*%i
+Xc=1/(w0*C*%i)
+Zin=R+Xl+Xc
+
+disp(Zin,fb,C)
\ No newline at end of file diff --git a/671/CH5/EX5.5/5_5.sce b/671/CH5/EX5.5/5_5.sce new file mode 100755 index 000000000..789546e59 --- /dev/null +++ b/671/CH5/EX5.5/5_5.sce @@ -0,0 +1,11 @@ +G=5E-6
+L=2E-3
+I=2E-3
+w=5000
+
+C=1/(w*w*L)
+Vmax=I/G
+Il=1
+I=Il*w*L*G
+
+disp(I,Vmax,C)
\ No newline at end of file diff --git a/671/CH5/EX5.6/5_6.sce b/671/CH5/EX5.6/5_6.sce new file mode 100755 index 000000000..8bb05df3f --- /dev/null +++ b/671/CH5/EX5.6/5_6.sce @@ -0,0 +1,6 @@ +w0=1000
+w2=1050
+wb=2*(w2-w0)
+
+Q0=w0/wb
+disp(Q0)
\ No newline at end of file diff --git a/671/CH5/EX5.7/5_7.sce b/671/CH5/EX5.7/5_7.sce new file mode 100755 index 000000000..1d4a9d901 --- /dev/null +++ b/671/CH5/EX5.7/5_7.sce @@ -0,0 +1,9 @@ +w0=200E3
+wb=5E3
+L=2.5E-3
+Q=65
+
+Q0=w0/wb
+r=w0*L/Q
+
+disp(r)
\ No newline at end of file diff --git a/671/CH5/EX5.8/5_8.sce b/671/CH5/EX5.8/5_8.sce new file mode 100755 index 000000000..8e1d376ba --- /dev/null +++ b/671/CH5/EX5.8/5_8.sce @@ -0,0 +1,12 @@ +C=12E-9
+L=4E-3
+R=5
+
+w0=1/sqrt(L*C)
+
+Vc=1.5
+I=w0*C*Vc
+Zi=R
+Vi=R*I
+
+disp(Vi,w0)
\ No newline at end of file diff --git a/671/CH5/EX5.9/5_9.sce b/671/CH5/EX5.9/5_9.sce new file mode 100755 index 000000000..92dfe0d11 --- /dev/null +++ b/671/CH5/EX5.9/5_9.sce @@ -0,0 +1,9 @@ +w0=2.5E6
+Zin=60E3
+Q0=80
+
+R=60E3
+C=Q0/(w0*R)
+L=1/(C*w0*w0)
+
+disp(C,L,R)
\ No newline at end of file diff --git a/671/CH6/EX6.1/6_1.sce b/671/CH6/EX6.1/6_1.sce new file mode 100755 index 000000000..570dd087e --- /dev/null +++ b/671/CH6/EX6.1/6_1.sce @@ -0,0 +1,19 @@ +function [x,y]=polar_to_cart(r,theta)
+ theta=theta/180*%pi
+ x=r*cos(theta)
+ y=r*sin(theta)
+endfunction
+
+omega=exp(%i*120/180*%pi)
+Va=200
+Vb=200/omega
+Vc=200*omega
+
+[Zr,Zc]=polar_to_cart(100,60)
+Z=complex(Zr,Zc)
+
+Ia=Va/Z
+Ib=Vb/Z
+Ic=Vc/Z
+
+disp(Va,Vb,Vc,Ia,Ib,Ic)
\ No newline at end of file diff --git a/671/CH6/EX6.10/6_10.sce b/671/CH6/EX6.10/6_10.sce new file mode 100755 index 000000000..a7d9f8fc3 --- /dev/null +++ b/671/CH6/EX6.10/6_10.sce @@ -0,0 +1,17 @@ +omega=exp(%i*120/180*%pi)
+
+Zp=17.32+%i*10
+Vab=400
+Iab=Vab/Zp
+Ica=Iab/omega
+IAa=Iab-Ica
+IBb=IAa/omega
+ICc=IAa*omega
+disp(ICc,IBb,IAa)
+
+Pab=(norm(Iab)^2)*real(Zp)
+Ptotal=3*Pab
+disp(Ptotal)
+
+Itotal=IAa+IBb+ICc
+disp(Itotal)
\ No newline at end of file diff --git a/671/CH6/EX6.11/6_11.sce b/671/CH6/EX6.11/6_11.sce new file mode 100755 index 000000000..aed956b22 --- /dev/null +++ b/671/CH6/EX6.11/6_11.sce @@ -0,0 +1,22 @@ +omega=exp(%i*120/180*%pi)
+
+function [x,y]=polar_to_cart(r,theta)
+ theta=theta/180*%pi
+ x=r*cos(theta)
+ y=r*sin(theta)
+endfunction
+
+[Zr,Zc]=polar_to_cart(5,60)
+Z=complex(Zr,Zc)
+
+[Vr,Vc]=polar_to_cart(25,30)
+Van=complex(Vr,Vc)
+
+Ian=Van/Z
+Ibn=Ian/omega
+Icn=Ian*omega
+
+Vcn=Van*omega
+Vac=Van-Vcn
+
+disp(Ibn,Icn,Vac)
\ No newline at end of file diff --git a/671/CH6/EX6.12/6_12.sce b/671/CH6/EX6.12/6_12.sce new file mode 100755 index 000000000..6316ff84b --- /dev/null +++ b/671/CH6/EX6.12/6_12.sce @@ -0,0 +1,17 @@ +V=400
+w=2*50*%pi
+P=25000
+pf1=0.7
+theta1=acos(pf1)
+Il1=P/(sqrt(3)*V*pf1)*exp(-%i*theta1)
+Ip1=Il1/sqrt(3)
+
+
+pf2=0.85
+theta2=acos(pf2)
+Il2=P/(sqrt(3)*V*pf2)*exp(-%i*theta2)
+Ip2=Il2/sqrt(3)
+
+Ic=Ip2-Ip1 ////calculation mistake in the book at this step
+C=real(Ic/(V*w*%i))
+disp(C)
\ No newline at end of file diff --git a/671/CH6/EX6.13/6_13.sce b/671/CH6/EX6.13/6_13.sce new file mode 100755 index 000000000..ffae9f0a3 --- /dev/null +++ b/671/CH6/EX6.13/6_13.sce @@ -0,0 +1,16 @@ +omega=exp(%i*120/180*%pi)
+Vrn=400/sqrt(3)
+Vyn=Vrn/omega
+Vbn=Vrn*omega
+
+P1=4000
+P2=8000
+P3=12000
+
+Ir=conj(P1/Vrn)
+Iy=conj(P2/Vyn)
+Ib=conj(P3/Vbn)
+
+In=Ir+Iy+Ib
+
+disp(norm(Ir),norm(Iy),norm(Ib),norm(In))
\ No newline at end of file diff --git a/671/CH6/EX6.14/6_14.sce b/671/CH6/EX6.14/6_14.sce new file mode 100755 index 000000000..849120426 --- /dev/null +++ b/671/CH6/EX6.14/6_14.sce @@ -0,0 +1,26 @@ +function [x,y]=polar_to_cart(r,theta)
+ theta=theta/180*%pi
+ x=r*cos(theta)
+ y=r*sin(theta)
+endfunction
+
+
+Vbc=-400*%i
+Rl=1
+
+[Sr,Sc]=polar_to_cart(10000,acos(0.8))
+S=complex(Sr,Sc)
+
+
+Vl=Vbc
+Il=norm(S/(sqrt(3)*Vl)) ////////calculation mistake in book here
+P=3*Il*Il*Rl
+disp(P)
+
+Van=norm(Vbc/sqrt(3))
+
+Ia=Il*exp(-%i*acos(0.8))
+omega=exp(%i*120/180*%pi)
+Ib=Ia/omega
+
+disp(Van,Ia,Ib)
\ No newline at end of file diff --git a/671/CH6/EX6.15/6_15.sce b/671/CH6/EX6.15/6_15.sce new file mode 100755 index 000000000..7d8c949a9 --- /dev/null +++ b/671/CH6/EX6.15/6_15.sce @@ -0,0 +1,24 @@ +function [x,y]=polar_to_cart(r,theta)
+ theta=theta/180*%pi
+ x=r*cos(theta)
+ y=r*sin(theta)
+endfunction
+
+[Vr,Vc]=polar_to_cart(231,60)
+Van=complex(Vr,Vc)
+
+Sp=(2.5-%i*1.2)*1000
+
+omega=exp(%i*120/180*%pi)
+Vbn=Van/omega
+Vcn=Van*omega
+
+Vbc=Vbn-Vcn
+
+Ibc=conj(Sp/Vbc)
+Ica=Ibc*omega
+Iab=Ibc/omega
+
+IaA=Ica-Iab
+
+disp(IaA)
\ No newline at end of file diff --git a/671/CH6/EX6.16/6_16.sce b/671/CH6/EX6.16/6_16.sce new file mode 100755 index 000000000..3ae5d40f8 --- /dev/null +++ b/671/CH6/EX6.16/6_16.sce @@ -0,0 +1,17 @@ +omega=exp(%i*120/180*%pi)
+Vab=400
+Vca=400*omega
+Vbc=400/omega
+
+//Mesh Method
+A=[80+100*%i,100*%i;100*%i,50*%i]
+I=inv(A)*[-Vca;Vbc]
+Ia=I(1)
+Ib=I(2)
+
+Ic=-(Ia+Ib)
+Van=80*Ia
+Vbn=-50*%i*Ib
+Vcn=100*%i*Ic
+
+disp(Ia,Ib,Ic,Van,Vbn,Vcn)
\ No newline at end of file diff --git a/671/CH6/EX6.17/6_17.sce b/671/CH6/EX6.17/6_17.sce new file mode 100755 index 000000000..28b3b8ed2 --- /dev/null +++ b/671/CH6/EX6.17/6_17.sce @@ -0,0 +1,14 @@ +omega=exp(%i*120/180*%pi)
+Vab=400
+Vca=400*omega
+Vbc=400/omega
+
+Iab=Vab/(100*%i)
+Ibc=Vbc/(-50*%i)
+Ica=Vca/80
+
+Ia=Iab-Ica ///calaculation mistake in the book here
+Ib=Ibc-Iab
+Ic=Ica-Ibc
+
+disp(Ia,Ib,Ic)
\ No newline at end of file diff --git a/671/CH6/EX6.18/6_18.sce b/671/CH6/EX6.18/6_18.sce new file mode 100755 index 000000000..2dd922d5d --- /dev/null +++ b/671/CH6/EX6.18/6_18.sce @@ -0,0 +1,11 @@ +V=400
+P=900
+pf=0.8
+
+Pph=P/3
+Vph=V/sqrt(3)
+Iph=Pph/Vph/pf
+Zph=Vph/Iph
+theta=acos(pf)
+Zph=Zph*exp(-%i*theta)
+disp(Zph)
\ No newline at end of file diff --git a/671/CH6/EX6.19/6_19.sce b/671/CH6/EX6.19/6_19.sce new file mode 100755 index 000000000..710ebeca4 --- /dev/null +++ b/671/CH6/EX6.19/6_19.sce @@ -0,0 +1,8 @@ +V=400
+Z=complex(40,30)
+
+Iph=V/Z
+Il=sqrt(3)*norm(Iph)
+Ptotal=sqrt(3)*Il*V*cos(atan(imag(Z)/real(Z)))
+
+disp(Iph,Il,Ptotal)
\ No newline at end of file diff --git a/671/CH6/EX6.2/6_2.sce b/671/CH6/EX6.2/6_2.sce new file mode 100755 index 000000000..b5e9722e1 --- /dev/null +++ b/671/CH6/EX6.2/6_2.sce @@ -0,0 +1,12 @@ +Vl=400
+Vph=Vl
+pf=0.8
+
+Pph=1500/3
+Iph=Pph/Vph/pf
+Il=sqrt(3)*Iph
+theta=acos(0.8)
+Iph=Iph*exp(%i*theta)
+Zph=Vph/Iph
+
+disp(Iph,Il,Zph)
\ No newline at end of file diff --git a/671/CH6/EX6.20/6_20.sce b/671/CH6/EX6.20/6_20.sce new file mode 100755 index 000000000..71b4ece44 --- /dev/null +++ b/671/CH6/EX6.20/6_20.sce @@ -0,0 +1,29 @@ +Ig1=15000/sqrt(3)/800/0.8
+PG1=15000
+QG1=15000*tan(acos(0.8))
+SG1=PG1+%i*QG1
+
+Pll=3*Ig1*Ig1*1.2
+Qll=3*Ig1*Ig1*1.8
+Sll=Pll+%i*Qll
+SlG1=SG1-Sll
+Vl=SlG1/sqrt(3)/Ig1
+
+
+Pl=30000
+Ql=30000*tan(acos(0.8))
+PlG2=Pl-real(SlG1)
+QlG2=Ql-imag(SlG1)
+SlG2=PlG2+%i*QlG2
+
+IG2=SlG2/sqrt(3)/Vl
+
+Pll2=3*IG2*IG2*0.8
+Qll2=3*IG2*IG2*1.2
+
+PG2=PlG2+Pll2
+QG2=QlG2+Qll2
+SG2=PG2+%i*QG2
+VG2=SG2/sqrt(3)/IG2
+
+disp(norm(SG2),norm(VG2))
\ No newline at end of file diff --git a/671/CH6/EX6.21/6_21.sce b/671/CH6/EX6.21/6_21.sce new file mode 100755 index 000000000..c51cf9718 --- /dev/null +++ b/671/CH6/EX6.21/6_21.sce @@ -0,0 +1,20 @@ +omega=exp(%i*120/180*%pi)
+w=2*50*%pi
+Vry=415
+Vyb=Vry/omega
+Vbr=Vry*omega
+
+C=40E-6
+Zry=100
+Zyb=complex(20,60)
+Zbr=1/(%i*w*C)
+
+I1=Vry/Zry
+I2=Vyb/Zyb
+I3=Vbr/Zbr
+
+Ir=I1-I3
+Iy=I2-I1
+Ib=I3-I2
+
+disp(norm(Ir),norm(Iy),norm(Ib))
\ No newline at end of file diff --git a/671/CH6/EX6.3/6_3.sce b/671/CH6/EX6.3/6_3.sce new file mode 100755 index 000000000..385757a50 --- /dev/null +++ b/671/CH6/EX6.3/6_3.sce @@ -0,0 +1,11 @@ +Vl=400
+pf=0.8
+
+Pph=1200/3
+Vph=Vl/sqrt(3)
+Iph=Pph/Vph/pf
+Il=Iph
+theta=acos(0.8)
+Zph=Vph/Iph*exp(%i*theta)
+
+disp(Il,Iph,Zph)
\ No newline at end of file diff --git a/671/CH6/EX6.4/6_4.sce b/671/CH6/EX6.4/6_4.sce new file mode 100755 index 000000000..bd6561a0f --- /dev/null +++ b/671/CH6/EX6.4/6_4.sce @@ -0,0 +1,19 @@ +function [x,y]=polar_to_cart(r,theta)
+ theta=theta/180*%pi
+ x=r*cos(theta)
+ y=r*sin(theta)
+endfunction
+
+Vl=400
+Vp=Vl/sqrt(3)
+disp(Vp)
+
+[Ir,Ic]=polar_to_cart(50,-30)
+Il=complex(Ir,Ic)
+Ip=Il
+Zy=Vp/Il
+disp(Zy)
+
+P=sqrt(3)*Vl*Il*cos(30/180*%pi)
+Q=sqrt(3)*Vl*Il*sin(30/180*%pi)
+disp(P,Q)
\ No newline at end of file diff --git a/671/CH6/EX6.5/6_5.sce b/671/CH6/EX6.5/6_5.sce new file mode 100755 index 000000000..f4ef090ee --- /dev/null +++ b/671/CH6/EX6.5/6_5.sce @@ -0,0 +1,14 @@ +Vl=400
+Z=16+%i*12
+
+Vp=Vl
+Ip=Vp/Z
+pf=cos(atan(imag(Z)/real(Z)))
+Il=Ip*sqrt(3)
+
+P=sqrt(3)*Vl*Il*pf
+Q=sqrt(3)*Vl*Il*sin(acos(pf))
+
+S=P+%i*Q
+
+disp(Ip,Il,pf,P,Q,S)
\ No newline at end of file diff --git a/671/CH6/EX6.6/6_6.sce b/671/CH6/EX6.6/6_6.sce new file mode 100755 index 000000000..253079ec0 --- /dev/null +++ b/671/CH6/EX6.6/6_6.sce @@ -0,0 +1,20 @@ +Vl=400
+Zload=60+%i*15
+
+Vs=Vl/sqrt(3)
+Z=0.3+%i*1+Zload
+
+Il=Vs/Z
+Vload=Il*Zload*sqrt(3)
+Pload=3*Il*Il*real(Zload)
+Qload=3*Il*Il*imag(Zload)
+Sload=Pload+%i*Qload
+
+////////////ll=lineloss
+Pll=3*Il*Il*real(Z-Zload)
+Qll=3*Il*Il*imag(Z-Zload)
+Sll=Pll+%i*Qll
+
+Ssource=Sload+Sll
+
+disp(Il,Vload,Sload,Sll,Ssource)
\ No newline at end of file diff --git a/671/CH6/EX6.7/6_7.sce b/671/CH6/EX6.7/6_7.sce new file mode 100755 index 000000000..e132a39d9 --- /dev/null +++ b/671/CH6/EX6.7/6_7.sce @@ -0,0 +1,29 @@ +Ig1=200000/sqrt(3)/11000/0.75
+PG1=200000
+QG1=200000*tan(acos(0.75))
+SG1=PG1+%i*QG1
+
+Pll=3*Ig1*Ig1*1
+Qll=3*Ig1*Ig1*2.2
+Sll=Pll+%i*Qll
+SlG1=SG1-Sll
+Vl=SlG1/sqrt(3)/Ig1
+
+
+Pl=400000
+Ql=400000*tan(acos(0.8))
+PlG2=Pl-real(SlG1)
+QlG2=Ql-imag(SlG1)
+SlG2=PlG2+%i*QlG2
+
+IG2=SlG2/sqrt(3)/Vl
+
+Pll2=3*IG2*IG2*0.6
+Qll2=3*IG2*IG2*1.2
+
+PG2=PlG2+Pll2
+QG2=QlG2+Qll2
+SG2=PG2+%i*QG2
+VG2=SG2/sqrt(3)/IG2
+
+disp(norm(SG2),norm(VG2))
\ No newline at end of file diff --git a/671/CH6/EX6.9/6_9.sce b/671/CH6/EX6.9/6_9.sce new file mode 100755 index 000000000..72d87f1ed --- /dev/null +++ b/671/CH6/EX6.9/6_9.sce @@ -0,0 +1,24 @@ +function [x,y]=polar_to_cart(r,theta)
+ theta=theta/180*%pi
+ x=r*cos(theta)
+ y=r*sin(theta)
+endfunction
+
+Vl=400
+[Ir,Ic]=polar_to_cart(20,-30)
+Iab=complex(Ir,Ic)
+
+omega=exp(%i*120/180*%pi)
+Ibc=Iab/omega
+Ica=Iab*omega
+
+IAa=Iab-Ica
+Pab=Vl*norm(Iab)*cos(30/180*%pi)
+Ptotal=3*Pab
+
+Zp=Vl/Iab
+Rp=real(Zp)
+
+disp(IAa)
+disp(Ptotal)
+disp(Rp)
\ No newline at end of file diff --git a/671/CH7/EX7.1/7_1.sce b/671/CH7/EX7.1/7_1.sce new file mode 100755 index 000000000..b5ee96116 --- /dev/null +++ b/671/CH7/EX7.1/7_1.sce @@ -0,0 +1,12 @@ +uo=(4*%pi)*1E-7 + +i1=5 +i2=2.5 +r=0.4 +H=i1/(2*%pi*r) + +F=uo*H*i2 /////////attractive +ur=8000 +Firon=ur*F + +disp(H,F,Firon)
\ No newline at end of file diff --git a/671/CH7/EX7.10/7_10.sce b/671/CH7/EX7.10/7_10.sce new file mode 100755 index 000000000..be6a66286 --- /dev/null +++ b/671/CH7/EX7.10/7_10.sce @@ -0,0 +1,16 @@ +Ac=12/10000
+Fmin=160*9.81
+B=sqrt(Fmin*2*uo/Ac)
+
+H=2800
+L=75/100
+F=H*L
+Lg=0.1/1000
+A=24/10000
+Rg=Lg/(uo*A)
+fluxg=B*A
+Fg=fluxg*Rg
+
+Ftotal=F+Fg
+imin=Ftotal/1000
+disp(imin)
\ No newline at end of file diff --git a/671/CH7/EX7.11/7_11.sce b/671/CH7/EX7.11/7_11.sce new file mode 100755 index 000000000..02ab52406 --- /dev/null +++ b/671/CH7/EX7.11/7_11.sce @@ -0,0 +1,12 @@ +Wm1=1/2*(1200-750)*0.012
+disp(Wm1)
+
+flux_g=0.012/750*1200
+Wm2=1/2*(flux_g-0.012)*1200
+disp(Wm2)
+
+Ra=1200/0.012
+Rb=1200/flux_g
+Fo=-1/2*(0.012^2)*0.75*10^6
+Fc=-1/2*(flux_g^2)*0.75*10^6
+disp(Fc,Fo)
\ No newline at end of file diff --git a/671/CH7/EX7.12/7_12.sce b/671/CH7/EX7.12/7_12.sce new file mode 100755 index 000000000..2b9d67976 --- /dev/null +++ b/671/CH7/EX7.12/7_12.sce @@ -0,0 +1,10 @@ +V1=10
+
+//Mesh Method
+A=[1+10*%i,-80*%i;80*%i,-500-800*%i]
+I=inv(A)*[V1;0]
+
+V2=500*I(2)
+
+disp(V1,V2,I)
+
diff --git a/671/CH7/EX7.14/7_14.sce b/671/CH7/EX7.14/7_14.sce new file mode 100755 index 000000000..7f4d6cb49 --- /dev/null +++ b/671/CH7/EX7.14/7_14.sce @@ -0,0 +1,14 @@ +uo=(4*%pi)*1E-7
+ur=1600
+
+lc=160/100
+lg=0.8/1000
+A=5/10000
+N=1200
+
+Rc=lc/(uo*ur*A)
+Rg=lg/(uo*A)
+R=Rc+Rg
+
+L=N*N/R
+disp(L)
\ No newline at end of file diff --git a/671/CH7/EX7.15/7_15.sce b/671/CH7/EX7.15/7_15.sce new file mode 100755 index 000000000..4a84ce28f --- /dev/null +++ b/671/CH7/EX7.15/7_15.sce @@ -0,0 +1,24 @@ +N=100
+l1=0.15
+l2=0.3
+l3=0.45
+A=0.001
+
+ur1=1447
+ur2=5969
+ur3=47750
+
+flux=0.6E-3
+
+B=flux/A
+
+H1=B/(uo*ur1)
+H2=B/(uo*ur2)
+H3=B/(uo*ur3)
+disp(H1,H2,H3)
+
+F=H1*l1+H2*l2+H3*l3
+disp(F)
+
+I=F/N
+disp(I)
\ No newline at end of file diff --git a/671/CH7/EX7.16/7_16.sce b/671/CH7/EX7.16/7_16.sce new file mode 100755 index 000000000..633449c76 --- /dev/null +++ b/671/CH7/EX7.16/7_16.sce @@ -0,0 +1,14 @@ +Pl1=1500
+f1=50
+Pl2=3000
+f2=75
+
+Y=[1,f1;1,f2]
+X=inv(Y)*[Pl1/f1;Pl2/f2]
+
+Ph1=X(1)*f1
+Pe1=X(2)*f1*f1
+Ph2=X(1)*f2
+Pe2=X(2)*f2*f2
+
+disp(Ph1,Pe1,Ph2,Pe2)
\ No newline at end of file diff --git a/671/CH7/EX7.17/7_17.sce b/671/CH7/EX7.17/7_17.sce new file mode 100755 index 000000000..e48dafc01 --- /dev/null +++ b/671/CH7/EX7.17/7_17.sce @@ -0,0 +1,22 @@ +uo=(4*%pi)*1E-7
+F=750*1
+disp(F)
+
+dm=(16+20)/200
+lc=dm*%pi
+Hc=F/lc
+disp(Hc)
+
+flux=1.25/1000
+Ac=(20-16)*2.5/10000
+Bc=flux/Ac
+disp(Bc)
+
+R=F/flux
+disp(R)
+
+u=Bc/Hc
+disp(u)
+
+ur=u/uo
+disp(ur) //calculation mistake in the book here
\ No newline at end of file diff --git a/671/CH7/EX7.18/7_18.sce b/671/CH7/EX7.18/7_18.sce new file mode 100755 index 000000000..aa59d086a --- /dev/null +++ b/671/CH7/EX7.18/7_18.sce @@ -0,0 +1,13 @@ +fluxc=1.5E-3
+Ac=12/10000
+Bc=fluxc/Ac
+Hc=1250
+lc=0.3
+F=Hc*lc
+
+Fa=200*1
+Fb=600*0.75
+
+Fc=F-Fb+Fa
+Nc=Fc/0.5
+disp(Nc) ////clockwise5
\ No newline at end of file diff --git a/671/CH7/EX7.19/7_19.sce b/671/CH7/EX7.19/7_19.sce new file mode 100755 index 000000000..a3f3015c3 --- /dev/null +++ b/671/CH7/EX7.19/7_19.sce @@ -0,0 +1,23 @@ +uo=(4*%pi)*1E-7
+ur=2000
+V=200
+f=50
+N=1600
+Ac=5/10000
+
+flux_max=V/(4.44*f*N)
+Bmax=flux_max/Ac
+disp(Bmax)
+
+Rc=20/100/(uo*ur*Ac)
+Rg=0.5/1000/(uo*Ac)
+R=Rc+Rg
+
+imax=flux_max*R/N
+disp(imax)
+
+Wfmax=1/2*R*(flux_max^2)
+disp(Wfmax)
+
+percent=Rg/R*100
+disp(percent)
\ No newline at end of file diff --git a/671/CH7/EX7.2/7_2.sce b/671/CH7/EX7.2/7_2.sce new file mode 100755 index 000000000..a85b0b9dc --- /dev/null +++ b/671/CH7/EX7.2/7_2.sce @@ -0,0 +1,8 @@ +l=0.15
+i1=50
+
+H1=i1/(2*%pi*(0.1+l))
+i2=-H1*(2*%pi*0.1)
+
+
+disp(i2)
\ No newline at end of file diff --git a/671/CH7/EX7.3/7_3.sce b/671/CH7/EX7.3/7_3.sce new file mode 100755 index 000000000..9b8ab686f --- /dev/null +++ b/671/CH7/EX7.3/7_3.sce @@ -0,0 +1,6 @@ +Ha=4/(2*%pi*0.2)
+Hb=Ha
+H=sqrt(Ha^2+Hb^2)
+theta=(%pi+atan(-Hb/Ha))*180/%pi
+
+disp(H,theta)
\ No newline at end of file diff --git a/671/CH7/EX7.4/7_4.sce b/671/CH7/EX7.4/7_4.sce new file mode 100755 index 000000000..434dc4972 --- /dev/null +++ b/671/CH7/EX7.4/7_4.sce @@ -0,0 +1,19 @@ +uo=(4*%pi)*1E-7
+
+Bg=1.2
+N=400
+ur=4000
+
+lc=(2*(20-4+16-4)-0.2)/100
+Ac=4/100*4/100
+Rc=lc/(ur*uo*Ac)
+
+lg=0.2/100
+Rg=lg/(uo*Ac)
+
+R=Rc+Rg
+
+flux=Bg*Ac
+i=flux*R/N
+
+disp(i)
\ No newline at end of file diff --git a/671/CH7/EX7.5/7_5.sce b/671/CH7/EX7.5/7_5.sce new file mode 100755 index 000000000..dd8bb1dac --- /dev/null +++ b/671/CH7/EX7.5/7_5.sce @@ -0,0 +1,22 @@ +function Zeq=parallel(Z1,Z2)
+ Zeq=Z1*Z2/(Z1+Z2)
+endfunction
+
+uo=(4*%pi)*1E-7
+fluxg1=0.8E-3
+
+lg1=0.02/100
+lg2=0.02/100
+lg3=0.025/100
+Ag1=2/100*1/100
+Ag2=1/100*1/100
+Ag3=1/100*1/100
+
+Rg1=lg1/(uo*Ag1)
+Rg2=lg2/(uo*Ag2)
+Rg3=lg3/(uo*Ag3)
+Req=Rg1+parallel(Rg2,Rg3)
+
+MMF=fluxg1*Req
+
+disp(MMF)
\ No newline at end of file diff --git a/671/CH7/EX7.6/7_6.sce b/671/CH7/EX7.6/7_6.sce new file mode 100755 index 000000000..fbbb146b5 --- /dev/null +++ b/671/CH7/EX7.6/7_6.sce @@ -0,0 +1,24 @@ +uo=(4*%pi)*1E-7
+ur=4000
+fluxc=0.01
+N=500
+
+Ll=(2*(20+4)+25+4)/100
+Lc=(25+4)/100
+Lr=Ll-0.02/100
+Lg=0.02/100
+A=4/100*4/100
+
+Rl=Ll/(ur*uo*A)
+Rc=Lc/(ur*uo*A)
+Rr=Lr/(ur*uo*A)
+Rg=Lg/(uo*A)
+
+Fab=fluxc*Rc
+fluxr=Fab/(Rr+Rg)
+fluxl=fluxc+fluxr
+
+F=fluxl*Rl+Fab
+I=F/N
+
+disp(I)
\ No newline at end of file diff --git a/671/CH7/EX7.7/7_7.sce b/671/CH7/EX7.7/7_7.sce new file mode 100755 index 000000000..a29bf8e6d --- /dev/null +++ b/671/CH7/EX7.7/7_7.sce @@ -0,0 +1,32 @@ +uo=(4*%pi)*1E-7
+
+l1=50/100
+l2=20/100
+l3=50/100
+lbc=0.025/100
+
+A1=25E-4
+A2=12.5E-4
+A3=25E-4
+
+fluxg=0.75E-3
+
+B=fluxg/A1
+Fbc=B/uo*lbc
+
+Hcd=200
+Hab=Hcd
+Fabcd=Hab*l1
+Fad=Fbc+Fabcd
+Had=Fab/l2
+Bad=1.04
+fluxad=Bad*A2
+
+fluxdea=fluxad+fluxg
+Bdea=fluxdea/A3
+Hdea=500
+Fdea=Hdea*l3
+
+F=Fdea+Fad
+
+disp(F)
\ No newline at end of file diff --git a/671/CH7/EX7.8/7_8.sce b/671/CH7/EX7.8/7_8.sce new file mode 100755 index 000000000..cdf2e76c3 --- /dev/null +++ b/671/CH7/EX7.8/7_8.sce @@ -0,0 +1,30 @@ +uo=(4*%pi)*1E-7
+ur=3000
+Ac=10/100*10/1000
+Bc=1.4
+Hc=Bc/(uo*ur)
+lc=150/100
+Ftotal=Hc*lc
+
+N2=800
+I2=2
+F2=N2*I2
+F1=Ftotal-F2
+
+N1=400
+I1=F1/N1 ////out of terminal a
+disp(I1)
+
+
+Bc=1.4
+fluxc=Bc*Ac
+Rc=lc/(Ac*uo*ur)
+Wf=1/2*Rc*fluxc*fluxc
+disp(Wf)
+
+
+
+L1=N1*N1/Rc
+L2=N2*N2/Rc
+M=sqrt(L1*L2)
+disp(M)
\ No newline at end of file diff --git a/671/CH7/EX7.9/7_9.sce b/671/CH7/EX7.9/7_9.sce new file mode 100755 index 000000000..0f60336c1 --- /dev/null +++ b/671/CH7/EX7.9/7_9.sce @@ -0,0 +1,28 @@ +uo=(4*%pi)*1E-7
+ur=6000
+A=5/2*2/10000
+Lr=(%pi*(20+25)/2-0.1)/100
+Lg=0.1/100
+Rr=Lr/(uo*ur*A)
+Rg=Lg/(uo*A)
+Rtotal=Rr+Rg
+
+F=2*500
+flux=F/Rtotal
+Bg=flux/A
+disp(Bg)
+
+L=flux*500/2
+disp(L)
+
+Wfr=1/2*Rr*flux*flux
+Wfg=1/2*Rg*flux*flux
+disp(Wfg,Wfr)
+
+imax=2
+flux_max=flux
+E=4.44*314/(2*%pi)*500*flux_max
+flux_max2=100/(sqrt(2)*4.44*314/(2*%pi)*500)
+Fmax2=flux_max2*Rtotal
+imax2=Fmax2/500
+disp(imax2)
\ No newline at end of file diff --git a/671/CH8/EX8.1/8_1.sce b/671/CH8/EX8.1/8_1.sce new file mode 100755 index 000000000..8ddfe758c --- /dev/null +++ b/671/CH8/EX8.1/8_1.sce @@ -0,0 +1,16 @@ +V1=3300
+f=50
+N1=100
+N2=300
+Z=100+35*%i
+flux_max=V1/(sqrt(2)*%pi*f*N1)
+V2=V1*N2/N1
+I2=V2/Z
+I1=N2/N1*I2
+S=V1*conj(I1)
+Z1=Z*(N1/N2)^2
+
+disp(flux_max)
+disp(I1,I2)
+disp(real(S),imag(S))
+disp(Z1)
\ No newline at end of file diff --git a/671/CH8/EX8.10/8_10.sce b/671/CH8/EX8.10/8_10.sce new file mode 100755 index 000000000..41b640a25 --- /dev/null +++ b/671/CH8/EX8.10/8_10.sce @@ -0,0 +1,25 @@ +P=50E3
+a=2200/110
+
+/////OC Parameters
+Poc=400
+Ioc=10
+Voc=110
+
+Y0=Ioc/Voc
+Gi=Poc/Voc/Voc
+disp(Gi)
+Bm=sqrt(Y0*Y0-Gi*Gi)
+disp(Bm)
+
+///////////Referred to HV side
+GiHV=Gi/a/a
+disp(GiHV)
+BmHV=Bm/a/a
+disp(BmHV)
+
+//////////Per unit
+GiPU=Gi*P/Voc/Voc
+BmPU=Bm*P/Voc/Voc
+disp(GiPU)
+disp(BmPU)
diff --git a/671/CH8/EX8.11/8_11.sce b/671/CH8/EX8.11/8_11.sce new file mode 100755 index 000000000..641831991 --- /dev/null +++ b/671/CH8/EX8.11/8_11.sce @@ -0,0 +1,40 @@ +P=25000
+V1=2200
+V2=220
+a=V1/V2
+f=50
+r1=2
+r2=0.025
+x1=7
+x2=0.07
+Xm=16000
+
+Im=V2/Xm
+disp("pf=0, 90 degree lag Po=0", Im)
+
+R=r1+a*a*r2
+X=x1+a*a*x2
+Z=sqrt(R*R+X*X)
+Ifl=P/V1
+Vsc=Z*Ifl
+Vsc_percent=Vsc/V1*100
+disp(Vsc,Vsc_percent)
+Im=Vsc/Xm
+Im_percent=Im/Ifl*100
+disp(Im,Im_percent)
+
+Sc_pf=cos(atan(X/R))
+disp(Sc_pf)
+
+////////////Per unit
+ZBpu=1000*2.2*2.2/25
+r1pu=r1/193.6
+r2pu=a*a*r2/193.6
+x1pu=x1/193.6
+x2pu=a*a*x2/193.6
+
+Rpu=r1pu+r2pu
+Xpu=x1pu+x2pu
+
+Xmpu=Xm/193.6
+disp(Rpu,Xpu,Xmpu)
diff --git a/671/CH8/EX8.12/8_12.sce b/671/CH8/EX8.12/8_12.sce new file mode 100755 index 000000000..3090785ef --- /dev/null +++ b/671/CH8/EX8.12/8_12.sce @@ -0,0 +1,28 @@ +P=10000
+v1=2300
+v2=230
+a=v1/v2
+f=50
+r1=3.96
+r2=0.0396
+x1=15.8
+x2=0.158
+
+R=r1+a*a*r2
+X=x1+a*a*x2
+V2=v2*a
+I=P/V2
+theta=acos(0.80)
+V1=V2+I*(R*cos(theta)+X*sin(theta))
+disp(V1)
+VR=(V1-V2)/V2
+disp(VR)
+
+pf=X/sqrt(R*R+X*X)
+theta2=acos(pf)
+Il=I*(cos(theta)-%i*sin(theta))
+Ic=real(Il*tan(theta2))-imag(Il)
+Rating_Cap=V2*Ic
+disp(Rating_Cap)
+V1=V2
+disp(V1)
diff --git a/671/CH8/EX8.13/8_13.sce b/671/CH8/EX8.13/8_13.sce new file mode 100755 index 000000000..25e4915c2 --- /dev/null +++ b/671/CH8/EX8.13/8_13.sce @@ -0,0 +1,29 @@ +P=100000
+N1=400
+N2=100
+a=N1/N2
+r1=0.3
+r2=0.015
+x1=1.1
+x2=0.055
+V1=2400
+
+R=r1+a*a*r2
+disp(R)
+X=x1+a*a*x2
+disp(X)
+
+I1=P/V1
+pf=0.8
+theta=acos(pf)
+Vd=I1*(R*cos(theta)+X*sin(theta))
+VR=Vd/V1*100
+V2=(V1-Vd)/a
+disp(VR,V2)
+Vd=I1*(R*cos(theta)-X*sin(theta))
+VR=Vd/V1*100
+V2=(V1-Vd)/a
+disp(VR,V2)
+
+pf=cos(atan(R/X)) /////wrong in the book
+disp("leading",pf)
diff --git a/671/CH8/EX8.14/8_14.sce b/671/CH8/EX8.14/8_14.sce new file mode 100755 index 000000000..d8dbf19db --- /dev/null +++ b/671/CH8/EX8.14/8_14.sce @@ -0,0 +1,40 @@ +P=10000
+v1=2300
+v2=230
+a=v1/v2
+f=50
+r1=3.96
+r2=0.0396
+x1=15.8
+x2=0.158
+
+R=r1+a*a*r2
+X=x1+a*a*x2
+V2=v2*a
+I=P/V2
+pf=0.8
+theta=acos(pf)
+V1=V2+I*(R*cos(theta)+X*sin(theta))
+Pi=75*V1*V1/V2/V2
+Pc=I*I*R
+Pl=Pi+Pc
+P0=P*pf
+effi=P0/(P0+Pl)*100
+disp(effi)
+
+V1=V2
+Pi=75
+pf2=X/sqrt(R*R+X*X)
+I=P0/V1/pf2
+Pc=I*I*R
+Pl=Pi+Pc
+P0=P*pf
+effi=P0/(P0+Pl)*100
+disp(effi)
+
+I=sqrt(Pi/R)
+Load=V2*I
+P0=Load*pf
+Pl=2*Pi
+effi_max=P0/(P0+Pl)*100
+disp(effi_max)
diff --git a/671/CH8/EX8.15/8_15.sce b/671/CH8/EX8.15/8_15.sce new file mode 100755 index 000000000..a7bc6ca0d --- /dev/null +++ b/671/CH8/EX8.15/8_15.sce @@ -0,0 +1,62 @@ +P=15E3
+a=3000/250
+
+/////OC Parameters
+Poc=105
+Ioc=0.62
+Voc=250
+
+/////SC Parameters
+Psc=360
+Isc=5.2
+Vsc=157
+
+
+Y0=Ioc/Voc
+Gi=Poc/Voc/Voc
+Bm=sqrt(Y0*Y0-Gi*Gi)
+
+Z=Vsc/Isc
+R=Psc/Isc/Isc
+X=sqrt(Z*Z-R*R)
+
+///////////Referred to HV side
+GiHV=Gi/a/a
+disp(GiHV)
+BmHV=Bm/a/a
+disp(BmHV)
+disp(R)
+disp(X)
+
+//////////Per unit
+ZB=3.12/5.2
+GiPU=Gi*ZB
+BmPU=Y0*ZB
+RPU=R/ZB/1000
+XPU=X/ZB/1000
+disp(GiPU)
+disp(BmPU)
+disp(RPU)
+disp(XPU)
+
+
+pf=0.8
+theta=acos(pf)
+V2=250*a
+I=P/V2
+Vd=I*(R*cos(theta)-X*sin(theta))
+VR=-Vd/V2*100
+disp(VR)
+Pi=105
+Pc=I*I*R
+Pl=Pi+Pc
+P0=P*pf
+effi=P0/(Pl+P0)*100
+
+pf2=cos(atan(R/X))
+disp("leading", pf2)
+
+
+IPU=sqrt(Pi/P/RPU)
+effi_max=IPU
+disp(effi_max)
diff --git a/671/CH8/EX8.16/8_16.sce b/671/CH8/EX8.16/8_16.sce new file mode 100755 index 000000000..d18e0fd19 --- /dev/null +++ b/671/CH8/EX8.16/8_16.sce @@ -0,0 +1,20 @@ +v1=2500
+v2=250
+P=25000
+Pc=130
+Pcfl=320
+pf=0.8
+
+V2=2750
+
+P0=P*pf
+Pl=Pcfl+Pc
+effi=P0/(P0+Pl)*100
+disp(effi)
+
+I2=P/v2
+I1=I2+P/v1
+kVA=I1*v1/1000
+P0=kVA*pf*1000
+effi=P0/(P0+Pl)*100
+disp(effi)
diff --git a/671/CH8/EX8.17/8_17.sce b/671/CH8/EX8.17/8_17.sce new file mode 100755 index 000000000..0919b7f9d --- /dev/null +++ b/671/CH8/EX8.17/8_17.sce @@ -0,0 +1,14 @@ +a=10
+Load=120000
+V=400
+
+I=Load/V/sqrt(3)
+Vll=a*V/sqrt(3)
+Ill=sqrt(3)*I/a
+all=Vll/V
+disp(Vll,Ill,all)
+
+Vll=a*V*sqrt(3)
+Ill=I/a/sqrt(3)
+all=Vll/V
+disp(Vll,Ill,all)
diff --git a/671/CH8/EX8.18/8_18.sce b/671/CH8/EX8.18/8_18.sce new file mode 100755 index 000000000..5e8e27aba --- /dev/null +++ b/671/CH8/EX8.18/8_18.sce @@ -0,0 +1,18 @@ +f=50
+N1=500
+
+Pin=60
+Io=0.4
+Vin=220
+r=0.8
+
+Pci=Io*Io*r
+Pi=Pin-Pci
+disp(Pi)
+theta=acos(Pin/Vin/Io)
+Im=Io*sin(theta)
+Xm=Vin/Im
+disp(Xm)
+Iio=Io*cos(theta)
+Ri=Vin/Iio
+disp(Ri)
diff --git a/671/CH8/EX8.19/8_19.sce b/671/CH8/EX8.19/8_19.sce new file mode 100755 index 000000000..94afd024b --- /dev/null +++ b/671/CH8/EX8.19/8_19.sce @@ -0,0 +1,38 @@ +P=15E3
+v1=2200
+v2=220
+a=v1/v2
+
+/////OC Parameters
+Poc=185
+Ioc=2.72
+Voc=220
+
+/////SC Parameters
+Psc=197
+Isc=6.3
+Vsc=112
+
+Pi=Poc
+disp(Pi)
+
+IHVfl=P/v1
+Pcfl=IHVfl*IHVfl/Isc/Isc*Psc
+disp(Pcfl)
+
+pf=0.85
+Po=P*pf
+Pl=Pi+Pcfl
+effi=Po/(Po+Pl)*100
+disp(effi)
+
+Z=Vsc/Isc
+R=Psc/Isc/Isc
+X=sqrt(Z*Z-R*R)
+pf=0.8
+theta=acos(pf)
+Vd1=IHVfl*(R*cos(theta)+X*sin(theta))
+Vd2=IHVfl*(R*cos(theta)-X*sin(theta))
+VR1=Vd1/v1*100
+VR2=Vd2/v1*100
+disp(VR1, VR2)
diff --git a/671/CH8/EX8.2/8_2.sce b/671/CH8/EX8.2/8_2.sce new file mode 100755 index 000000000..183e9a44d --- /dev/null +++ b/671/CH8/EX8.2/8_2.sce @@ -0,0 +1,21 @@ +a=2400/240
+
+R=0.2+a*a*2/1000
+X=0.6+a*a*6/1000
+disp(R,X)
+
+Rlv=1/a/a*R
+Xlv=1/a/a*X
+disp(Rlv,Xlv)
+
+I2=150*1000/2400
+Z=R+%i*X
+V=I2*Z
+pcnt=norm(V)/2400*100
+disp(V,pcnt)
+
+Im=2400/1600
+Ii=2400/10000
+Io=Ii-%i*Im
+pf=cos(atan(imag(Io)/real(Io)))
+disp(Io,pf)
\ No newline at end of file diff --git a/671/CH8/EX8.20/8_20.sce b/671/CH8/EX8.20/8_20.sce new file mode 100755 index 000000000..147e4c143 --- /dev/null +++ b/671/CH8/EX8.20/8_20.sce @@ -0,0 +1,21 @@ +P=50000
+lr=0.9
+
+P0=P*1*0.9
+effi=0.974
+Pl=(1-effi)/effi*P0
+Pi=Pl/2
+Pcfl=Pi/lr/lr
+
+pf=0.8
+P0=P*pf
+Pl=Pi+Pcfl
+effi=P0/(P0+Pl)*100
+disp(effi)
+
+P0=P/2*lr
+Pl=Pi+Pcfl/2/2
+effi=P0/(P0+Pl)*100
+disp(effi)
+
+/////////calculation mistakes in the book
diff --git a/671/CH8/EX8.21/8_21.sce b/671/CH8/EX8.21/8_21.sce new file mode 100755 index 000000000..e5f2fb0b7 --- /dev/null +++ b/671/CH8/EX8.21/8_21.sce @@ -0,0 +1,13 @@ +P=500E3
+effi=0.95
+
+A=[1,1;1,0.6*0.6]
+Pa=inv(A)*[P*(1-effi)/effi;P*0.6*(1-effi)/effi]
+Pi=Pa(1)
+disp(Pi)
+Pc=Pa(2)
+disp(Pc)
+
+Pl=Pi+0.75*0.75*Pc
+effi=P*0.75/(P*0.75+Pl)
+disp(effi)
diff --git a/671/CH8/EX8.22/8_22.sce b/671/CH8/EX8.22/8_22.sce new file mode 100755 index 000000000..3aabaf878 --- /dev/null +++ b/671/CH8/EX8.22/8_22.sce @@ -0,0 +1,14 @@ +v1=2200
+v2=220
+f=50
+emfperturn=12
+
+N1=floor(v1/emfperturn)
+N2=floor(v2/emfperturn)
+disp(N1)
+disp(N2)
+
+fluxmax=emfperturn/4.44/f
+Bmax=1.5
+Ac=fluxmax/Bmax
+disp(Ac)
diff --git a/671/CH8/EX8.23/8_23.sce b/671/CH8/EX8.23/8_23.sce new file mode 100755 index 000000000..87547d2c0 --- /dev/null +++ b/671/CH8/EX8.23/8_23.sce @@ -0,0 +1,24 @@ +v1=3300
+v2=600
+f=50
+Ac=25/10000
+l=1.2
+
+Bmax=1.2
+fluxmax1=Bmax*Ac
+N1=v1/4.44/f/fluxmax1
+N2=v2/4.44/f/fluxmax1
+disp(N1,N2)
+
+I2=20
+pf=0.8
+I1=N2/N1*I2
+I1=I1*(pf-%i*sin(acos(0.8)))
+disp(I1)
+
+Hmax=250
+ATmax=Hmax*l
+immax=ATmax/N1/sqrt(2)
+Ii=0
+I1=-%i*immax+I1
+disp("lagging", real(I1)/norm(I1), norm(I1))
diff --git a/671/CH8/EX8.24/8_24.sce b/671/CH8/EX8.24/8_24.sce new file mode 100755 index 000000000..8bcc0c9ea --- /dev/null +++ b/671/CH8/EX8.24/8_24.sce @@ -0,0 +1,11 @@ +P=50000
+v1=2400
+v2=240
+f=50
+a=v1/v2
+Pd=375
+pf=0.4
+
+I0=Pd/v1/pf
+I0_prime=I0*a
+disp(I0_prime,pf)
diff --git a/671/CH8/EX8.25/8_25.sce b/671/CH8/EX8.25/8_25.sce new file mode 100755 index 000000000..e40e6119e --- /dev/null +++ b/671/CH8/EX8.25/8_25.sce @@ -0,0 +1,10 @@ +v1=220
+v2=110
+z1=0.32+%i*0.85
+z2=0.11+%i*0.27
+a=v1/v2
+
+z=z1+a*a*z2
+IHV=v1/norm(z)
+ILV=IHV*a
+disp(IHV,ILV)
diff --git a/671/CH8/EX8.26/8_26.sce b/671/CH8/EX8.26/8_26.sce new file mode 100755 index 000000000..d3ceb2a7e --- /dev/null +++ b/671/CH8/EX8.26/8_26.sce @@ -0,0 +1,32 @@ +P=1000000
+v1=11000
+v2=230
+f=50
+Vsc=310
+Psc=5210
+
+Isc=P/v1
+Z=Vsc/Isc
+R=Psc/Isc/Isc
+X=sqrt(Z*Z-R*R)
+
+pf=1
+theta=acos(pf)
+Vd=Isc*(R*cos(theta)+X*sin(theta))
+VR=Vd/v1*100
+V1=v1+Vd
+disp(VR,V1)
+
+pf=0.8
+theta=acos(pf)
+Vd=Isc*(R*cos(theta)+X*sin(theta))
+VR=Vd/v1*100
+V1=v1+Vd
+disp(VR,V1)
+
+pf=0.8
+theta=acos(pf)
+Vd=Isc*(R*cos(theta)-X*sin(theta)) //calculation mistake in the book at this point
+VR=Vd/v1*100
+V1=v1+Vd
+disp(VR,V1)
diff --git a/671/CH8/EX8.27/8_27.sce b/671/CH8/EX8.27/8_27.sce new file mode 100755 index 000000000..dc6161c75 --- /dev/null +++ b/671/CH8/EX8.27/8_27.sce @@ -0,0 +1,25 @@ +P=10000
+v1=2200
+v2=220
+r1=4
+r2=0.04
+x1=5
+x2=0.05
+a=v1/v2
+R=r1+a*a*r2
+X=x1+a*a*x2
+I1=P/v1
+pf=0.8
+V2=v2*a
+theta=acos(pf)
+Vd=I1*(R*cos(theta)+X*sin(theta))
+VR=Vd/v1*100
+V1=v1+Vd
+disp(VR,V1)
+
+pf=cos(atan(X/R))
+disp("leading",pf)
+
+Pr=P*pf
+Q=-P*sin(acos(pf))
+disp(Q,Pr)
diff --git a/671/CH8/EX8.28/8_28.sce b/671/CH8/EX8.28/8_28.sce new file mode 100755 index 000000000..01c8f91e2 --- /dev/null +++ b/671/CH8/EX8.28/8_28.sce @@ -0,0 +1,25 @@ +P=20000
+v1=200
+v2=400
+f=50
+V1=600
+V2=200
+
+a=V1/V2
+disp(a)
+
+I1=P/v2
+VA=V1*I1
+disp(VA)
+
+disp(I1)
+I2=30000/V2
+Is=I2-I1
+disp(I2)
+disp(Is)
+
+VAtrans=v2*I1
+VAcond=30000-VAtrans
+disp(VAtrans)
+disp(VAcond)
+
diff --git a/671/CH8/EX8.29/8_29.sce b/671/CH8/EX8.29/8_29.sce new file mode 100755 index 000000000..086952265 --- /dev/null +++ b/671/CH8/EX8.29/8_29.sce @@ -0,0 +1,17 @@ +P=100000
+v1=11000
+v2=400
+
+Vl=400
+Vp=Vl/sqrt(3)
+
+a=ceil(v1/Vp)
+disp(a)
+
+Il=P/sqrt(3)/Vl
+Ip=Il
+disp(Il,Ip)
+
+Il=P/sqrt(3)/v1
+Ip=Il/sqrt(3)
+disp(Il,Ip)
diff --git a/671/CH8/EX8.3/8_3.sce b/671/CH8/EX8.3/8_3.sce new file mode 100755 index 000000000..93802f8a9 --- /dev/null +++ b/671/CH8/EX8.3/8_3.sce @@ -0,0 +1,19 @@ +P=200E3 +V1=11000 +V2=415 +f=50 +N2=80 + +N1=V1/V2*N2 +a=N1/N2 +disp(a) + +I2=P/V2 +disp(I2) +I1=I2/a +disp(I1) + +Z2=V2*V2/P +disp(Z2) +Z21=Z2*a*a +disp(Z21) diff --git a/671/CH8/EX8.4/8_4.sce b/671/CH8/EX8.4/8_4.sce new file mode 100755 index 000000000..979d53302 --- /dev/null +++ b/671/CH8/EX8.4/8_4.sce @@ -0,0 +1,25 @@ +V1=200
+f=50
+N1=150
+Ac=10*5/10000
+
+
+Flux_max=V1/(sqrt(2)*%pi*f*N1)
+Bmax=Flux_max/Ac
+Hmax=250
+l=2*(25+10)+2*(20+10)
+l=l/100
+AT_max=Hmax*l
+Im_max=AT_max/150
+Im_rms=Im_max/sqrt(2)
+disp(Im_rms)
+
+Fe_loss=23000
+
+Cv = 2*(25+2*10)*10*5 + 2*20*10*5
+Cv=Cv/1000000
+Cl=Fe_loss*Cv
+disp(Cl)
+
+Ii=150/V1
+disp(Ii)
diff --git a/671/CH8/EX8.5/8_5.sce b/671/CH8/EX8.5/8_5.sce new file mode 100755 index 000000000..7df0ae10f --- /dev/null +++ b/671/CH8/EX8.5/8_5.sce @@ -0,0 +1,18 @@ +function [x,y]=polar_to_cart(r,theta)
+ theta=theta/180*%pi
+ x=r*cos(theta)
+ y=r*sin(theta)
+endfunction
+
+[Zr,Zc]=polar_to_cart(5,30)
+Z2=complex(Zr,Zc)
+
+V=200
+N2=75
+N1=100
+
+I2=V/Z2
+I1=N2/N1*I2
+
+disp(norm(I1))
+disp(" lagging" , real(I1)/norm(I1))
diff --git a/671/CH8/EX8.6/8_6.sce b/671/CH8/EX8.6/8_6.sce new file mode 100755 index 000000000..15c1d6123 --- /dev/null +++ b/671/CH8/EX8.6/8_6.sce @@ -0,0 +1,14 @@ +R=60
+V=6
+Rs=2400
+
+a=sqrt(Rs/R)
+disp(a)
+
+Pl_max=1/2*(R*R)/(Rs+Rs)
+I1=V/2/Rs
+
+Il=I1*a
+disp(Il)
+Vl=V/2/a
+disp(Vl)
diff --git a/671/CH8/EX8.7/8_7.sce b/671/CH8/EX8.7/8_7.sce new file mode 100755 index 000000000..2b44d1c0d --- /dev/null +++ b/671/CH8/EX8.7/8_7.sce @@ -0,0 +1,19 @@ +f=50
+a=1100/220
+Rhv=0.125
+Xhv=0.625
+Rlv=0.005
+Xlv=0.025
+
+Zhv=Rhv+%i*Xhv
+Zlv=Rlv+%i*Xlv
+
+Z1=Zhv+a*a*Zlv
+disp(Z1)
+Z2=Z1/a/a
+disp(Z2)
+
+Zpu1=Z1*0.05/1.1/1.1
+disp(Zpu1)
+Zpu2=Z2*0.05/0.22/0.22
+disp(Zpu2)
diff --git a/671/CH8/EX8.8/8_8.sce b/671/CH8/EX8.8/8_8.sce new file mode 100755 index 000000000..7e05fe177 --- /dev/null +++ b/671/CH8/EX8.8/8_8.sce @@ -0,0 +1,26 @@ +P=600E3
+a=2400/600
+r1=0.05
+r2=0.004
+x1=0.025
+x2=0.016
+R1=1667
+Xm=417
+
+/////As seen from the LV side
+
+Zlv=r2+%i*x2+1/a/a*(r1+%i*x1)
+disp(Zlv)
+
+RiLV=R1/a/a
+disp(RiLV)
+XmLV=Xm/a/a
+disp(XmLV)
+
+
+Zpu=Zlv*0.6/0.6/0.6
+disp(Zpu)
+Ri=RiLV*0.6/0.6/0.6
+disp(Ri)
+Xm=XmLV*0.6/0.6/0.6
+disp(Xm)
diff --git a/671/CH8/EX8.9/8_9.sce b/671/CH8/EX8.9/8_9.sce new file mode 100755 index 000000000..de3559235 --- /dev/null +++ b/671/CH8/EX8.9/8_9.sce @@ -0,0 +1,48 @@ +P=50E3
+a=2200/220
+
+/////OC Parameters
+Poc=405
+Ioc=5
+Voc=220
+
+/////SC Parameters
+Psc=805
+Isc=20.2
+Vsc=95
+
+
+Y0=Ioc/Voc
+Gi=Poc/Voc/Voc
+Bm=sqrt(Y0*Y0-Gi*Gi)
+
+Z=Vsc/Isc
+R=Psc/Isc/Isc
+X=sqrt(Z*Z-R*R)
+
+///////////Referred to HV side
+GiHV=Gi/a/a
+disp(GiHV)
+BmHV=Bm/a/a
+disp(BmHV)
+disp(R)
+disp(X)
+
+////////////Referred to LV side
+disp(Gi)
+disp(Bm)
+RLV=R/a/a
+disp(RLV)
+XLV=X/a/a
+disp(XLV)
+
+
+//////////Per unit
+GiPU=GiHV/0.0103
+BmPU=BmHV/0.0103
+RPU=R/96.8
+XPU=X/96.8
+disp(GiPU)
+disp(BmPU)
+disp(RPU)
+disp(XPU)
diff --git a/671/CH9/EX9.1/9_1.sce b/671/CH9/EX9.1/9_1.sce new file mode 100755 index 000000000..1384f3236 --- /dev/null +++ b/671/CH9/EX9.1/9_1.sce @@ -0,0 +1,32 @@ +f=50
+flux=0.016
+S=36
+P=6
+N=10
+
+
+m=S/P
+gammaa=%pi/m
+Kb=sin(m*gammaa/2)/m/sin(gammaa/2)
+Nph=S*N*2/2
+Ep=4.44*Kb*f*Nph*flux
+kVA=Ep*N/1000
+disp(kVA)
+
+m=S/2/P
+gammaa=%pi/2/m
+Kb=sin(m*gammaa/2)/m/sin(gammaa/2)
+Nph=S*N*2/2/2
+Ep=4.44*Kb*f*Nph*flux
+Eline=Ep*sqrt(2)
+kVA=Ep*N*2/1000
+disp(kVA)
+
+m=S/3/P
+gammaa=%pi/3/m
+Kb=sin(m*gammaa/2)/m/sin(gammaa/2)
+Nph=S*N*2/2/3
+Ep=4.44*Kb*f*Nph*flux
+Eline=Ep*sqrt(3)
+kVA=Ep*N*3/1000
+disp(kVA)
diff --git a/671/CH9/EX9.10/9_10.sce b/671/CH9/EX9.10/9_10.sce new file mode 100755 index 000000000..11f43153d --- /dev/null +++ b/671/CH9/EX9.10/9_10.sce @@ -0,0 +1,13 @@ +f=50
+ns=1000
+P=120*f/ns
+disp(P)
+s=(ns-940)/ns
+disp(s*100)
+nrr=ns-940
+disp(nrr)
+nrs=1000
+disp(nrs)
+s=2*s
+n=1000*(1-s)
+disp(n)
diff --git a/671/CH9/EX9.11/9_11.sce b/671/CH9/EX9.11/9_11.sce new file mode 100755 index 000000000..d8f91323f --- /dev/null +++ b/671/CH9/EX9.11/9_11.sce @@ -0,0 +1,5 @@ +ns=1000
+s=(ns-940)/ns
+news=2*s
+n=1000*(1-news)
+disp(n)
diff --git a/671/CH9/EX9.12/9_12.sce b/671/CH9/EX9.12/9_12.sce new file mode 100755 index 000000000..46365f8ae --- /dev/null +++ b/671/CH9/EX9.12/9_12.sce @@ -0,0 +1,8 @@ +P=8
+f1=60
+f2=50
+If1=5
+If2=f1/f2*If1
+disp(If2)
+nA2=120*f2/P
+disp(nA2)
diff --git a/671/CH9/EX9.13/9_13.sce b/671/CH9/EX9.13/9_13.sce new file mode 100755 index 000000000..e98c8d576 --- /dev/null +++ b/671/CH9/EX9.13/9_13.sce @@ -0,0 +1,7 @@ +f1=60
+f2=50
+P1=12
+P2=f2/f1*P1
+disp(P2)
+nset=120*f1/P1
+disp(nset)
diff --git a/671/CH9/EX9.14/9_14.sce b/671/CH9/EX9.14/9_14.sce new file mode 100755 index 000000000..793b54420 --- /dev/null +++ b/671/CH9/EX9.14/9_14.sce @@ -0,0 +1,6 @@ +m=6
+gammaa=%pi/m
+Kb=sin(m*gammaa/2)/m/sin(gammaa/2)
+
+m=4
+Kb=sin(m*gammaa/2)/m/sin(gammaa/2)
diff --git a/671/CH9/EX9.15/9_15.sce b/671/CH9/EX9.15/9_15.sce new file mode 100755 index 000000000..a3acdf3b8 --- /dev/null +++ b/671/CH9/EX9.15/9_15.sce @@ -0,0 +1,16 @@ +
+f=50
+n=965
+P=floor(120*f/n)
+disp(P)
+
+s=(1000-965)/1000
+disp(s)
+f2=s*f
+disp(f2)
+
+nsr=1000-965
+disp(nsr)
+nrr=120*f2/P
+nsrf=1000-965-nrr
+disp(nsrf)
diff --git a/671/CH9/EX9.16/9_16.sce b/671/CH9/EX9.16/9_16.sce new file mode 100755 index 000000000..1966fa190 --- /dev/null +++ b/671/CH9/EX9.16/9_16.sce @@ -0,0 +1,15 @@ +f=50
+P=4
+a=2
+
+ns=120*f/P
+n=1440
+s=1-n/ns
+disp(s)
+f2=s*f
+disp(f2)
+E1p=400
+E2f=400/a
+E2f2=E2f*f2/f
+E2l=sqrt(3)*E2f2
+disp(E2l)
diff --git a/671/CH9/EX9.2/9_2.sce b/671/CH9/EX9.2/9_2.sce new file mode 100755 index 000000000..0e3e62fc1 --- /dev/null +++ b/671/CH9/EX9.2/9_2.sce @@ -0,0 +1,12 @@ +S=54
+P=6
+m=S/3/P
+gammaa=%pi/3/m
+
+Kb1=sin(m*gammaa/2)/m/sin(gammaa/2)
+Kb3=sin(m*gammaa/2*3)/m/sin(gammaa/2*3)
+Kb5=sin(m*gammaa/2*5)/m/sin(gammaa/2*5)
+
+disp(Kb1)
+disp(Kb3)
+disp(Kb5)
diff --git a/671/CH9/EX9.3/9_3.sce b/671/CH9/EX9.3/9_3.sce new file mode 100755 index 000000000..237e4a220 --- /dev/null +++ b/671/CH9/EX9.3/9_3.sce @@ -0,0 +1,20 @@ +f=50
+n=500
+m=5
+N=12
+flux=0.025
+
+P=120*f/n
+S=m*3*P
+Nph=S*N*2/2/3
+gammaa=%pi/3/m
+Kb=sin(m*gammaa/2)/m/sin(gammaa/2)
+polepitch=S/N
+coilpitch=13
+spa=(polepitch-coilpitch)*gammaa
+Kp=cos(spa/2)
+
+Ep=4.44*Kb*Kp*f*Nph*flux
+disp(Ep)
+Eline=sqrt(3)*Ep
+disp(Eline)
diff --git a/671/CH9/EX9.4/9_4.sce b/671/CH9/EX9.4/9_4.sce new file mode 100755 index 000000000..9c462eaec --- /dev/null +++ b/671/CH9/EX9.4/9_4.sce @@ -0,0 +1,6 @@ +f=50
+P=6
+ns=120*f/P
+disp(ns)
+wm=2*%pi/60*ns
+disp(wm)
diff --git a/671/CH9/EX9.5/9_5.sce b/671/CH9/EX9.5/9_5.sce new file mode 100755 index 000000000..24de70fd0 --- /dev/null +++ b/671/CH9/EX9.5/9_5.sce @@ -0,0 +1,10 @@ +F2=850
+F1=400
+lambda=123.6/180*%pi
+ppp=1.408/1000
+
+theta=%pi-lambda
+Fr=sqrt(F1*F1+F2*F2-2*F1*F2*cos(theta))
+
+fluxr=2/%pi*ppp*Fr
+disp(fluxr)
diff --git a/671/CH9/EX9.6/9_6.sce b/671/CH9/EX9.6/9_6.sce new file mode 100755 index 000000000..67952c6cb --- /dev/null +++ b/671/CH9/EX9.6/9_6.sce @@ -0,0 +1,9 @@ +
+P=6
+N=1000
+
+f=P*N/120
+ns=120*f/4
+s=0.04
+n=(1-s)*ns
+disp(n)
diff --git a/671/CH9/EX9.7/9_7.sce b/671/CH9/EX9.7/9_7.sce new file mode 100755 index 000000000..2ef96efd6 --- /dev/null +++ b/671/CH9/EX9.7/9_7.sce @@ -0,0 +1,17 @@ +
+P=4
+f=50
+
+
+ns=120*f/P
+n1=-1500
+s1=(ns-n1)/ns
+f2=s1*f
+SRV=s1*80
+disp(f2,SRV)
+
+n2=1000
+s2=(ns-n2)/ns
+f2=s2*f
+SRV=s2*80
+disp(f2,SRV)
diff --git a/671/CH9/EX9.8/9_8.sce b/671/CH9/EX9.8/9_8.sce new file mode 100755 index 000000000..b1fed8da4 --- /dev/null +++ b/671/CH9/EX9.8/9_8.sce @@ -0,0 +1,17 @@ +
+betaa=acos(0)*2/5
+coilpitch=%pi-betaa
+disp(coilpitch/%pi*180)
+
+P=6
+S=72
+m=S/P
+gammaa=%pi/m
+cpis=150/180*%pi
+betaa=%pi-cpis
+Kp1=cos(betaa/2)
+Kp3=cos(5*betaa/2)
+Kp13=cos(13*betaa/2)
+disp(Kp1)
+disp(Kp3)
+disp(Kp13)
diff --git a/671/CH9/EX9.9/9_9.sce b/671/CH9/EX9.9/9_9.sce new file mode 100755 index 000000000..c1afd007b --- /dev/null +++ b/671/CH9/EX9.9/9_9.sce @@ -0,0 +1,19 @@ +
+P=2
+f=50
+S=42
+m=S/3/P
+gammaa=%pi/3/m
+Kb=sin(m*gammaa/2)/m/sin(gammaa/2)
+coilpitch=17
+polepitch=S/2
+spa=(polepitch-coilpitch)*gammaa
+Kp=cos(spa/2)
+
+N=S*2
+Nc=N/2
+Coilsperphase=Nc/3
+Nph=Coilsperphase/2
+Eline=2300
+flux=Eline/sqrt(3)/4.44/Kb/Kp/f/Nph
+disp(flux)
|