summaryrefslogtreecommitdiff
path: root/3871/CH6/EX6.18/Ex6_18.sce
blob: 5dac1f964d9ac692e20fe4a9852566e3f5ef9ab0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
//===========================================================================
//chapter 6 example 18

clc;
clear all;

//variable declraration
Ts	= 300;	//number of turns in secondary winding
Tp	= 1;	//number of turns in primary winding
Is	=5;	//current in A
Zs	=(1.5)+(%i*1)	//secondary impedance ‎Ω
MMF	= 100;
Pi	= 1.2;		//iron loss in watts
KN  = 300;         //turn ratio


//calculations
KT	=Ts/Tp;      //turn ratio
Es	= Is*Zs;     //secondary voltage in volts
Es1     = sqrt(((real(Es))^2)+((imag(Es))^2));
Im	=MMF/Tp;                 //magnetising current in A
E	= Pi/Es1;                 //energy compnent of exciting current on secondary side in A
Ie	= KT*E;                  //energy compnent of exciting current on primary side in A
I0	= Im+%i*Ie;              //exciting current on primary side in A
I01    =sqrt(((real(I0))^2)+((imag(I0))^2));
alpha	= atan(Ie/Im);
alpha1  = (alpha*180)/%pi;
theta	= atan(imag(Zs)/real(Zs));
theta1  = (theta*180)/%pi;
KC	= KT+((I01*sin(((theta1+alpha1)*%pi)/180))/Is);     //actual current ratio 
e	= ((KN-KC)/KC)*100;               //percentage ratio error in %
b	= (I01*cos((((theta1+alpha1)*%pi)/180)))/(KT*Is);         //phase angle in radians
b1  = b*(180/%pi);          


//result
mprintf("percentage ratio error =%3.2f   percentage ",e);
mprintf("\nphase angle = %3.2f °",b1);