summaryrefslogtreecommitdiff
path: root/671/CH6/EX6.14/6_14.sce
blob: 8491204267aa545057e4640a7da0f30171f048fb (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
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)