You are on page 1of 14

disp('Core Desgin')

disp('-----------')

S = input ('Please Enter transformer power rating (KVA)');

VHv = input('Please Enter Voltage of high voltage side (kV):');

VLv = input('Please Enter Voltage of Low voltage side (V):');

Connection = input('Please Enter The Connection type : for Dy press 1 - for Dd press 2 - for Yy press 3 -
for Yd press 4');

if Connection == 1

VHv = 1 * VHv;

VLv = 1 * VLv ;

elseif Connection == 2

VLv = VLv / sqrt(3) ;

elseif Connection == 3

VHv = sqrt(3) * VHv ;

elseif Connection == 4

VHv = sqrt(3) * VHv ;

VLv = VLv / sqrt(3) ;

else

disp('Wrong Value , please Choose 1 for Dy , 2 for Dd , 3 for Yy or 4 for Yd')

end

if S <= 200

Kw = 10 /(30+VHv);

% Kw : Window Factor Depends on Transformer rating

elseif S <= 50

Kw = 8 /(30+VHv);

elseif S <= 1000

Kw = 12 /(30+VHv);

else

Kw = 10 /(30+VHv);
% As the voltage rating of the transformer increases, quantity of insulation in the window increases,
area of copper reduces.

% Thus the window space factor reduces as the voltage increases.

% A value for Kw can be calculated by the precedent empirical formula.

End

F = input('Please Enter Frequancy (Hz)');

Trans = input('Please Enter If it Power Or Distribution Transformer : for Power press 1 - for Distribution
press 2');

if Trans == 1

Bm = 1.35;

% Bm = Flux density Of Limb (Tesla)

disp('Assume Hot rolled - Bm =1.35 T')

Pi = 2.6;

% Pi = Power Loss of specific Limb (W/Kg)

HL = 900;

% HL = magnetic field strength Of Limb (AT/m)

Bm_Y = Bm * 0.8;

% Bm_Y = Flux density Of Yoke (Tesla)

Pi_Y = 1.3;

HY = 400;

% HY = magnetic field strength of Yoke (AT/m)

elseif Trans == 2

Bm = 1.25;

disp('Assume Hot rolled - Bm =1.25 T')

Bm_Y = Bm * 0.8;

Pi = 2.1;

Pi_Y = 1.2;

HL = 450 ;

HY = 200 ;
else

Bm =input('Please Enter The Flux density of Limb (Tesla):');

Bm_Y = Bm * 0.8;

Pi =input('Please Enter The Power Loss of specific Limb (W/Kg) :');

Pi_Y =input('Please Enter The Power Loss of specific Yoke (W/Kg) :');

HY =input('Please Enter The HY = magnetic field strength of Yoke (AT/m) :');

HL =input('Please Enter The HL = magnetic field strength Of Limb (AT/m) :');

end

Type = input('Please Enter If it core or shell type : for core press 1 for shell press 2');

if Type == 1

K=0.55;

% K = voltage per turn constant

elseif Type == 2

K=1.3;

Else

disp('Wrong Value , please Choose 1 for core or 2 for shell')

end

Et = K * sqrt (S);

% Et = volt per turn

Ai=(Et/(4.44*F*Bm));

% Ai = Area of iron (meter^2) - Net Core Area (meter^2)

Density = input('Please Enter The Current densty (A/mm^2):');

s = S / (10^3); %becouse we have two law , one with KVA & another with VA

Aw = s / (3.33*F*Bm*Kw*Ai*Density);

% Aw = windows Area (meter^2)

Ww = sqrt(Aw/3);

% Ww = Width of Window (meter)

Hw = Aw / Ww;

% Hw = Hight of Window (meter)


disp('Please Choose The Stepped :-')

Stepped = input('For squre core press 1 - For Cruciform core press 2 - For 3-Stepped core press 3 - For 4-
Stepped core press 4');

if Stepped == 1

Kc = 0.45;

% Kc = core area factor

d = sqrt(Ai / Kc);

% d = diameter of Circumscribing Circle (meter)

a = d / sqrt(2);

% a = Total Side of Square (meter)

elseif Stepped == 2

Kc = 0.56;

d = sqrt(Ai / Kc);

a = 0.85 * d;

elseif Stepped == 3

Kc = 0.6;

d = sqrt(Ai / Kc);

a = 0.9 * d;

elseif Stepped == 4

Kc = 0.62;

d = sqrt(Ai / Kc);

a = 0.93 * d;

else

disp('Wrong Value Entered')

end

hY = 1.2 * a;

% hY = hight of Yoke (meter)

D = Ww + d;

% D= Distance between core centers (meter)


W = 2*D + a;

% W= width of transformer (meter)

H = Hw + 2*hY;

% H = Hight of transformer (meter)

msg1 = ['the value of Ww = Width of Window (meter) is :' num2str(Ww)];

disp (msg1)

msg2 = ['the value of Hw = Hight of Window (meter) is :' num2str(Hw)];

disp (msg2)

msg3 = ['the value of hY = hight of Yoke (meter) is :' num2str(hY)];

disp (msg3)

msg4 = ['the value of D= Distance between core centers (meter) is :' num2str(D)];

disp (msg4)

msg5 = ['the value of W= width of transformer (meter) is :' num2str(W)];

disp (msg5)

msg6 = ['the value of H = Hight of transformer (meter) is :' num2str(H)];

disp (msg6)

disp(' ')

disp(' ')

disp('Winding Design')

disp('--------------')

VphL = VLv / sqrt(3);

% VphL = phase voltage of Low side (V)

TL =ceil(VphL / Et) ;

% TL = No. of turns at low voltage side (turns)

TH =ceil((VHv * 10^3) / Et) ;

% TH = No. of turns at high voltage side (turns)

TH= ceil(TH/10)*10;

tap0 =input('Please Enter The Max. OFF-load tap changer percentage (%) :');

tap =ceil((tap0 / 100) * TH) ;


% tap = Extra Winding For tap changer (turns)

msg7 = ['the value of TL = No. of turns at low voltage side (turns) is :' num2str(TL)];

disp (msg7)

msg8 = ['the value of TH = No. of turns at high voltage side (turns) is :' num2str(TH)];

disp (msg8)

msg9 = ['the value of Extra Winding For tap changer (turns) is :' num2str(ceil(tap/10)*10)];

disp (msg9)

I_L = S*1000 / (3* VphL);

% I_L = Current of low vottage side (Amp)

A_L = I_L / Density;

% A_L = Cross Sectional Area of low voltage side (mm^2)

I_H = S*1000 / (3*1000* VHv);

% I_L = Current of high vottage side (Amp)

A_H = I_H / Density;

% A_H = Cross Sectional Area of High voltage side (mm^2)

if A_L < 10

disp('For Low side use Cylindrical Conductor')

else

disp('For Low side use Rectangular (Sheets) Conductor')

end

disp('For Low side use Helical Winding')

msg10 = ['the value of A_L = Cross Sectional Area of low voltage side (mm^2) is :' num2str(A_L)];

disp (msg10)

if A_H < 10

disp('For High side use Cylindrical Conductor')

else

disp('For High side use Rectangular (Sheets) Conductor')

end

disp('For High side use Cross-Over Winding')


msg11 = ['the value of A_H = Cross Sectional Area of High voltage side (mm^2) is :' num2str(A_H)];

disp (msg11)

disp('--------------------------------------------------------')

disp(' Former Desgin ')

disp(' {Low Voltage side} ')

d_tot = ((d*1000) + 20 + (2*(2+sqrt(A_L))))/10;

% d_tot = Total distance of LOW voltage side Former(cm)

Lc_L = (TL *(2+sqrt(A_L))) /10;

% Lc_L = Total Height Of LOW voltage side Former(cm)

% Check

if Lc_L < (Hw*100)

disp('The Design is OK')

msg12 = ['the value of d_tot = Total distance of LOW voltage side Former(cm) is :' num2str(d_tot)];

disp (msg12)

msg13 = ['the value of Lc_L = Total Height Of LOW voltage side Former(cm) is :' num2str(Lc_L)];

disp (msg13)

else

disp('The Design is Wrong _ Re-Design')

end

disp(' {HIGH Voltage side} ')

d_c = sqrt((4 * A_H)/pi);

% d_c = High Voltage Side Conductor diameter(mm)

d_act = d_c + 2;

% d_act = Autual High Voltage Side Conductor diameter (with Instulation) (mm)

disp(' 100 turn Formers Design ')

Lc_H = (d_act) + 2;

% Lc_H = Total Hight Of High voltage side of one Former(cm)

duct = 5;

% duct = a (cm)
dH_in = d_tot + (2*duct);

% dH_in = Internal Distance of High Voltage Side (cm)

dH_out = dH_in + 2 + 2*(d_act);

% dH_out = Outer Distance of High Voltage Side (cm)

msgx = ['the value of dH_out = Outer Distance of High Voltage Side (cm) is :' num2str(dH_out)];

disp (msgx)

msg14 = ['the value of Lc_H = Total Height Of High voltage side of one Former(cm) is :' num2str(Lc_H)];

disp (msg14)

disp(' Remain turn Formers Design ')

R_T = mod(TH,100);

% R_T = Remaining turns of High Voltage Formers Design

r = ceil(R_T/10);

L_R = ( r * (d_act/10)) +2 ;

% L_R = Total Hight Of Remaining turns of High Voltage Formers(cm)

msg15 = ['the value of L_R = Total Height Of Remaining turns of High Voltage Formers(cm) is :'
num2str(L_R)];

disp (msg15)

disp(' Tap changer turns Formers Design ')

L_Ch = ((ceil(tap/10)) * (d_act/10))+2 ;

% L_Ch = Total Height Of Tap changer turns of High Voltage Formers(cm)

msg16 = ['the value of L_Ch = Total Height Of Tap changer turns of High Voltage Formers(cm) is :'
num2str(L_Ch)];

disp (msg16)

disp('Total Lentgh Of H.V Former Design')

Lh_T = (fix(TH/100) * Lc_H) + L_R + L_Ch ;

% Lh_T = Total Lentgh Of H.V Former (cm)

msg17 = ['the value of Lh_T = Total Height Of H.V Former (cm) is :' num2str(Lh_T)];

disp (msg17)

disp('Assume Max. Allowable Clearence 2C = 8 cm')


C = 8;

% Check

if Lh_T+ C < Hw*100

disp('The Design is OK')

else

disp('The Design is Wrong _ Re-Design')

end

% Check

if D >= dH_out + C

disp('The Design is OK')

else

disp('The Design is Wrong _ Re-Design')

end

disp(' ')

disp(' ')

disp('Req,Xeq,Zeq Calculation')

disp('-----------------------')

disp(' Req ')

L_LV = pi * ((d*100) +2 + (d_tot)) / (2*100);

% L_LV = Length of mean turns of L.V (meter)

R_LV = 0.021 * (TL * L_LV) / A_L ;

% R_LV = Resistance of LOW Voltage (ohm)

L_HV = pi * ( (dH_in) + 2 + (dH_out)) / (2*100);

% L_HV = Length of mean turns of H.V (meter)

R_HV = 0.021 * ( TH * L_HV ) / A_H;

% R_HV = Resistance of HIGH Voltage (ohm)

Req_H = R_HV + ( R_LV * (TH/TL)^2 );

% Req_H = Equivlant Resistance Referred to High voltage (ohm)

Req_L = R_LV + ( R_HV * (TL/TH)^2 );


% Req_L = Equivlant Resistance Referred to Low voltage (ohm)

msg18 = ['the value of Req_L = Equivlant resistance Referred to Low voltage (ohm) is :' num2str(Req_L)];

disp (msg18)

msg19 = ['the value of Req_H = Equivlant resistance Referred to High voltage (ohm) is :'
num2str(Req_H)];

disp (msg19)

disp(' Xeq ')

L_C = ( Lh_T+Lc_L) / 200;

% L_C = Coil Length(meter)

L_M = (pi * ( (d*100) + 2 + (dH_out))/ 2)/100;

% L_M = Length Of Mean Turns Between H.V & L.V (meter)

b1 = ((sqrt (A_L)) + 2) /1000 ; %meter

b2 = (10 * d_act)/1000 ; %meter

duct = 0.06 ;

% chnage duct (meter) = (duct(cm) +1 cm)/100

Xeq_H = 2*pi*F*4*pi*(10^-7)* (TH^2)* (L_M /L_C )* ( duct + ((b1+b2)/3));

% Xeq_H = Equivlant Inductance Referred to High voltage (ohm)

msg20 = ['the value of Xeq_H = Equivlant Inductance Referred to High voltage (ohm) is :'
num2str(Xeq_H)];

disp (msg20)

disp(' Zeq ')

Zeq = sqrt ( (Xeq_H^2)+(Req_H^2));

% Zeq = Equivlant Impedance (ohm)

msg21 = ['the value of Zeq = Equivlant Impedance (ohm) is :' num2str(Zeq)];

disp (msg21)

% Check

Z_base = ((VHv*1000)/I_H);

Zp.u = (Zeq / Z_base) *100 ;

% Zp.u = Equivlant Impedance per unit


if Zp.u <= 10

disp(' Accepted , Zp.u <= 10% ')

else

disp('Not Accepted , Zp.u > 10% - Re-Design')

end

disp(' Ic ')

V_L = 3 * Ai * Hw ;

% V_L = Volume of Limb (m^3)

V_Y = 2 * 1.2 * Ai * W;

% V_Y = Volume of Yoke (m^3)

M_L = 7800 * V_L;

% M_L = Mass of Limb (Kg)

% 7800 == Density

M_Y = 7800 * V_Y;

% M_Y = Mass of Yoke (Kg)

Poi = (Pi * M_L) + (Pi_Y * M_Y);

% Poi = Power Loss

Rc = (3 * ((VHv*1000)^2))/Poi;

% Rc = Core Resistance (ohm)

Ic = (VHv*1000) / Rc ;

% Ic =Core Loss Current (Amp)

msg22 = ['the value of Rc = Core Resistance (ohm) is :' num2str(Rc)];

disp (msg22)

msg23 = ['the value of Ic =Core Loss Current (Amp) is :' num2str(Ic)];

disp (msg23)

disp(' Im ')

AT = (3* HL *Hw )+(2* HY * W)+((Bm/(4*pi*10^-7))*(0.5*10^-3));

% AT = AT OF Limb + AT OF Yoke + AT OF Air gap

Im = AT / ( 3 * 1.41421 *TH );
% Im = Magnitizting Current (Amp)

Xc = VHv *1000 / Im ;

msg24 = ['the value of Im = Magnitizting Current (Amp) is :' num2str(Im)];

disp (msg24)

msg25 = ['the value of Xc (ohm) is :' num2str(Xc)];

disp (msg25)

disp('Tank Design')

disp('-----------')

disp(' {Tank Dimensions} ')

if VHv <= 66

D_N = 12;

% D_N = (cm)

else

D_N =32;

end

X = (dH_out + ( 2 * D_N)) /100 ;

% X = Length Of Tank (meter)

Y = ((W*100) + dH_out + (2* D_N) - (a*100))/100;

% Y = Width Of Tank (meter)

Z = H + 0.5 ;

% Z = Higth of Tank (meter)

msg26 = ['the value of X = Length Of Tank (meter) is :' num2str(X)];

disp (msg26)

msg27 = ['the value of Y = Width Of Tank (meter) is :' num2str(Y)];

disp (msg27)

msg28 = ['the value of Z = Higth of Tank (meter) is :' num2str(Z)];

disp (msg28)

disp(' {Tank Shape} ')

St = (2*X*Z) + (2*Y*Z) + ((Y*X)/2);


% St = Tank dissipation Area ( meter^2 )

msg29 = ['the value of St = Tank dissipation Area ( meter^2 ) is :' num2str(St)];

disp (msg29)

Theta =input('Please Enter The Max. Allowable Temp. rise (Celsius degree):');

P_cu = 3 * (I_H^2) * Req_H ;

% P_cu = Cupper Loss Power at Full load (Watt)

Theta_Max = (Poi + P_cu) / (12.5 * St);

if Theta > Theta_Max

disp('The Cooling is Good , No Need For Tubes ')

else

disp('The Cooling is So Bad , Tubes are needed ')

end

if S <= 20

disp('Use Air Natural (AN) Cooling ')

elseif S <= 50

disp('Use Air Blast (AB) Cooling ')

elseif S <= 10000

disp('Use Oil Natural(ON) Cooling ')

elseif S <= 15000

disp('Use Oil Natural Air Forced (ONAF) Cooling ')

elseif S <= 25000

disp('Use Oil Forced Air Natural (OFAN) Cooling ')

elseif S <= 60000

disp('Use Oil Forced Air Forced (OFAF) Cooling ')

else

disp('Use Oil Forced Water Forced (OFWF) Cooling ')

end

disp('----------------------------------------------------------------------')

disp('The Code Is Finished')


disp('Sec 1')

You might also like