Formulation and calculation of Y- bus matrix of a given system using MATLAB software.

 Experiment: Formulation and calculation of Y- bus matrix of a given system using MATLAB software.

Apparatus:
                        MATLAB Software
Theory:

The Y-bus matrix is a matrix representation of the admittance values of a power system. It is used in power flow analysis to solve for voltage magnitudes and phase angles at each bus in the system. MATLAB software provides a powerful tool to create and calculate the Y-bus matrix of a given power system.

The Y-bus matrix is a square matrix whose size is equal to the number of buses in the system. The diagonal elements of the matrix represent the self-admittance of each bus, while the off-diagonal elements represent the mutual admittance between buses.

The formulation of the Y-bus matrix involves the following steps:

  1. Calculate the admittance value for each transmission line, transformer, and shunt capacitor in the system.

  2. Determine the direction of each transmission line, which is usually defined by the direction of the current flowing into the bus with the lower bus number.

  3. Calculate the off-diagonal elements of the Y-bus matrix, which represent the mutual admittance between buses. The off-diagonal elements are calculated using the formula:

    Y_ij = -(1/Z_ij) * exp(-j*theta_ij)

    where Z_ij is the impedance of the transmission line between buses i and j, and theta_ij is the phase angle difference between the voltage at bus i and j.

  4. Calculate the diagonal elements of the Y-bus matrix, which represent the self-admittance of each bus. The diagonal elements are calculated using the formula:

    Y_ii = sum(Y_ij) + Y_s

    where Y_ij is the mutual admittance between buses i and j, and Y_s is the admittance of any shunt capacitors connected to bus i.

Once the Y-bus matrix is formulated, MATLAB software can be used to calculate the voltage magnitudes and phase angles at each bus using the power flow equations. This allows engineers to analyze and optimize the performance of the power system.


Sample Numerical:







Calculations:






Algorithm:

1. Clear all variables in the workspace using `clear all`.
2. Prompt the user to enter the impedance values for lines 12, 13, and 23 using `z12=input('enter impedance for line12=');`, `z13=input('enter impedance for line13=');`, and `z23=input('enter impedance for line23=');`.
3. Calculate the admittance values for each line by taking the reciprocal of their respective impedances using `y12=1/z12;`, `y23=1/z23;`, and `y13=1/z13;`.
4. Calculate the shunt admittances between buses by assigning the values of `y12`, `y23`, and `y13` to `y21`, `y32`, and `y31`, respectively.
5. Calculate the diagonal and off-diagonal elements of the Y Bus matrix as follows:

   - `y11=y12+y13;`
   - `y22=y12+y23;`
   - `y33=y13+y23;`
   - `-y12`, `-y13`, and `-y23` are assigned to the appropriate off-diagonal elements.
   
6. Form the Y Bus matrix by assigning the calculated values to `ybus=[y11 -y12 -y13; -y21 y22 -y23; -y31 -y32 y33]`.
7. Display the resulting Y Bus matrix using `ybus`.

That's the algorithm for the given code.

Flowchart:

 START
 |
 |__Prompt user to enter impedance for line12
 |
 |__Read the value of z12
 |
 |__Prompt user to enter impedance for line13
 |
 |__Read the value of z13
 |
 |__Prompt user to enter impedance for line23
 |
 |__Read the value of z23
 |
 |__Calculate y12=1/z12
 |
 |__Calculate y23=1/z23
 |
 |__Calculate y13=1/z13
 |
 |__Calculate y21=y12
 |
 |__Calculate y32=y23
 |
 |__Calculate y31=y13
 |
 |__Calculate y11=y12+y13
 |
 |__Calculate y22=y12+y23
 |
 |__Calculate y33=y13+y23
 |
 |__Create the Y-bus matrix
 |   |
 |   |__Store y11 in row 1, column 1
 |   |
 |   |__Store -y12 in row 1, column 2
 |   |
 |   |__Store -y13 in row 1, column 3
 |   |
 |   |__Store -y21 in row 2, column 1
 |   |
 |   |__Store y22 in row 2, column 2
 |   |
 |   |__Store -y23 in row 2, column 3
 |   |
 |   |__Store -y31 in row 3, column 1
 |   |
 |   |__Store -y32 in row 3, column 2
 |   |
 |   |__Store y33 in row 3, column 3
 |   |
 |   |__Display the Y-bus matrix
 |
 END

PROGRAM:

%formation of Y Bus Matrix%

clear all,

z12=input('enter impedance for line12=');

z13=input('enter impedance for line13=');

z23=input('enter impedance for line23=');

y12=1/z12;

y23=1/z23;

y13=1/z13;

y21=y12;

y32=y23;

y31=y13;

y11=y12+y13;

y22=y12+y23;

y33=y13+y23;

ybus=[y11 -y12 -y13; -y21 y22 -y23; -y31 -y32 y33]

INPUT:

enter impedance for line12=0.25+1i

enter impedance for line13=0.2+0.8i

enter impedance for line23=0.2+0.8i

RESULT:

ybus =

   0.5294 - 2.1176i  -0.2353 + 0.9412i  -0.2941 + 1.1765i

  -0.2353 + 0.9412i   0.5294 - 2.1176i  -0.2941 + 1.1765i

  -0.2941 + 1.1765i  -0.2941 + 1.1765i   0.5882 - 2.3529i


Conclusion: Thus, we have Studied the calculation of Y- bus matrix of a given system using MATLAB software.


Comments

Popular posts from this blog

Measurement of ABCD parameters of a long transmission line with magnitude and angle.

Measurement of ABCD parameters of a medium transmission line with magnitude and angle.

Performance study of the effect of VAR compensation using capacitor bank on the transmission line.