Documentos de Académico
Documentos de Profesional
Documentos de Cultura
Y Bus MATLAB
Y Bus MATLAB
File Exchange
Answ ers
New sgroup
Link Exchange
Blogs
Trendy
Cody
Contest
MathWorks.com
Y-bus
by arvind singh 06 Oct 2010 admittance matrix
ybus_final.m %P r o g r a mt of o r mA d m i t t a n c eB u sF o r m a t i o nw i t hT r a n s f o r m e rT a ps e t t i n g . . c l c c l e a ra l l n b r a n c h = i n p u t ( ' e n t e rt o t a ln o .o fl i n e si nn e t w o r k ' ) ; d i s p ( ' e n t e rl i n ed a t a ' ) f o rp = 1 : 1 : n b r a n c h f b = i n p u t ( ' f r o mb u sn o .: ' ) ; t b = i n p u t ( ' t ob u sn o .: ' ) ; r = i n p u t ( ' r e s i s t a n c eo fl i n e= ' ) ; x = i n p u t ( ' r e a c t a n c eo fl i n e= ' ) ; B = i n p u t ( ' l i n ec h a r g i n ga d m i t t a n c e " b / 2 " = ' ) ; T = i n p u t ( ' t a p = ' ) ; z=r+i * x ; %Zm a t r i x . . . y=1 . / z ; %T og e ti n v e r s eo fe a c he l e m e n t . . . L d a t a ( p , : ) = [ f bt brxBTy ] ; e n d f b=L d a t a ( : , 1 ) ; %F r o mb u sn u m b e r . . . t b=L d a t a ( : , 2 ) ; %T ob u sn u m b e r . . . r=L d a t a ( : , 3 ) ; %R e s i s t a n c e ,R . . . x=L d a t a ( : , 4 ) ; %R e a c t a n c e ,X . . . b=L d a t a ( : , 5 ) ; %G r o u n dA d m i t t a n c e ,B / 2 . . . a=L d a t a ( : , 6 ) ; %T a ps e t t i n gv a l u e . . y=L d a t a ( : , 7 ) ; b=i * b ; %M a k eBi m a g i n a r y . . . n b u s=m a x ( m a x ( f b ) , m a x ( t b ) ) ; %n o .o fb u s e s . . . Y=z e r o s ( n b u s , n b u s ) ; %I n i t i a l i s eY B u s . . . %F o r m a t i o no ft h eO f fD i a g o n a lE l e m e n t s . . . f o rk = 1 : n b r a n c h Y ( f b ( k ) , t b ( k ) )=Y ( f b ( k ) , t b ( k ) ) y ( k ) ; Y ( t b ( k ) , f b ( k ) )=Y ( f b ( k ) , t b ( k ) ) ; e n d %F o r m a t i o no fD i a g o n a lE l e m e n t s . . . . f o rm= 1 : n b u s f o rn= 1 : n b r a n c h i ff b ( n )= =m Y ( m , m )=Y ( m , m )+y ( n )+b ( n ) ; e l s e i ft b ( n )= =m Y ( m , m )=Y ( m , m )+y ( n )+b ( n ) ; e n d e n d e n d Y %B u sA d m i t t a n c eM a t r i x . .
Contact us
Trademarks Support
Webinars
www.mathworks.in/matlabcentral/fileexchange/28954-y-bus/content/ybus_final.m
1/2
2/16/14
www.mathworks.in/matlabcentral/fileexchange/28954-y-bus/content/ybus_final.m
2/2