Software Oriented

Formation of Bus Admittance Matrix (Y-Bus) for Transmission Systems

Aim

To determine the admittance matrix (Y-bus) of different transmission systems using analytical methods.
  1. To form the Y-bus matrix for small-scale transmission networks (3-bus systems).
  2. To form the Y-bus matrix for large-scale transmission networks (10-bus systems).
  3. To analyze the effect of line charging (shunt admittances) on the Y-bus matrix for long transmission lines.
  4. To determine the Y-bus for systems with ideal transformers using turns ratio.
  5. To verify analytical results using MATLAB simulations.

Apparatus & Software

Sl. No.Apparatus / SoftwareTechnical SpecificationQuantities
1MATLABR2023 or compatible1

Theory

In power system analysis, the bus admittance matrixbus admittance matrixA square matrix connecting nodal currents to nodal voltages in power system networks. Its diagonal elements are the sum of admittances connected to a bus, while off-diagonals are the negative of admittances between buses. (Ybus) is essential for load flow studies, short circuit analysis, and stability studies. It offers a clear and compact way to represent the network through nodal analysis. The Ybus connects bus current injections to bus voltages as follows:
[I]=[Ybus][V][I] = [Y_{bus}][V]
The Ybus matrix is typically sparse and symmetric. Once created, it can be reused for various calculations such as power flow or fault analysis without rebuilding the entire network equations.
Derivation of Ybus for a 3-Bus System (Short Transmission Line)
Consider a 3-bus power system with buses 1, 2, and 3 interconnected by transmission lines of admittances y12, y23, y31. Applying KCL at each bus:
I1=I12+I13I_1 = I_{12} + I_{13}
I1=(V1V2)y12+(V1V3)y13I_1 = (V_1 - V_2)y_{12} + (V_1 - V_3)y_{13}
I2=I21+I23I_2 = I_{21} + I_{23}
I2=(V2V1)y21+(V2V3)y23I_2 = (V_2 - V_1)y_{21} + (V_2 - V_3)y_{23}
I3=I31+I32I_3 = I_{31} + I_{32}
I3=(V3V1)y31+(V3V2)y32I_3 = (V_3 - V_1)y_{31} + (V_3 - V_2)y_{32}
Simplifying, we get:
I1=V1(y12+y13)y12V2y13V3I_1 = V_1(y_{12} + y_{13}) - y_{12}V_2 - y_{13}V_3
I2=y21V1+V2(y21+y23)y23V3I_2 = -y_{21}V_1 + V_2(y_{21} + y_{23}) - y_{23}V_3
I3=y31V1y32V2+V3(y31+y32)I_3 = -y_{31}V_1 - y_{32}V_2 + V_3(y_{31} + y_{32})
In matrix form:
[I1I2I3]=[y12+y13y12y13y21y21+y23y23y31y32y31+y32][V1V2V3]\begin{bmatrix} I_1 \\ I_2 \\ I_3 \end{bmatrix} = \begin{bmatrix} y_{12}+y_{13} & -y_{12} & -y_{13} \\ -y_{21} & y_{21}+y_{23} & -y_{23} \\ -y_{31} & -y_{32} & y_{31}+y_{32} \end{bmatrix} \begin{bmatrix} V_1 \\ V_2 \\ V_3 \end{bmatrix}
Thus, the bus admittance matrix for the 3-bus system is:
[Ybus]=[Y11Y12Y13Y21Y22Y23Y31Y32Y33][Y_{bus}] = \begin{bmatrix} Y_{11} & Y_{12} & Y_{13} \\ Y_{21} & Y_{22} & Y_{23} \\ Y_{31} & Y_{32} & Y_{33} \end{bmatrix}
where:
Y11=y12+y13,Y12=Y21=y12Y_{11} = y_{12} + y_{13},\quad Y_{12} = Y_{21} = -y_{12}
Y22=y21+y23,Y23=Y32=y23Y_{22} = y_{21} + y_{23},\quad Y_{23} = Y_{32} = -y_{23}
Y33=y31+y32,Y31=Y13=y13Y_{33} = y_{31} + y_{32},\quad Y_{31} = Y_{13} = -y_{13}
Derivation of Ybus for a 3-Bus System (Long Transmission Line)
Let the currents injected at buses 1, 2, and 3 be I1, I2, and I3 respectively. Including self/shunt admittances y10, y20, y30 at buses 1, 2, and 3:
I1=I10+I12+I13I_1 = I_{10} + I_{12} + I_{13}
I1=V1y10+(V1V2)y12+(V1V3)y13I_1 = V_1 y_{10} + (V_1 - V_2)y_{12} + (V_1 - V_3)y_{13}
I2=I20+I12+I23I_2 = I_{20} + I_{12} + I_{23}
I2=V2y20+(V2V1)y12+(V2V3)y23I_2 = V_2 y_{20} + (V_2 - V_1)y_{12} + (V_2 - V_3)y_{23}
I3=I30+I13+I23I_3 = I_{30} + I_{13} + I_{23}
I3=V3y30+(V3V1)y13+(V3V2)y23I_3 = V_3 y_{30} + (V_3 - V_1)y_{13} + (V_3 - V_2)y_{23}
Simplifying, we get:
I1=V1(y10+y12+y13)y12V2y13V3I_1 = V_1(y_{10} + y_{12} + y_{13}) - y_{12}V_2 - y_{13}V_3
I2=y12V1+V2(y20+y12+y23)y23V3I_2 = -y_{12}V_1 + V_2(y_{20} + y_{12} + y_{23}) - y_{23}V_3
I3=y13V1y23V2+V3(y30+y13+y23)I_3 = -y_{13}V_1 - y_{23}V_2 + V_3(y_{30} + y_{13} + y_{23})
In matrix form:
[I1I2I3]=[y10+y12+y13y12y13y12y20+y12+y23y23y13y23y30+y13+y23][V1V2V3]\begin{bmatrix} I_1 \\ I_2 \\ I_3 \end{bmatrix} = \begin{bmatrix} y_{10}+y_{12}+y_{13} & -y_{12} & -y_{13} \\ -y_{12} & y_{20}+y_{12}+y_{23} & -y_{23} \\ -y_{13} & -y_{23} & y_{30}+y_{13}+y_{23} \end{bmatrix} \begin{bmatrix} V_1 \\ V_2 \\ V_3 \end{bmatrix}
Thus, the bus admittance matrix is:
[Ybus]=[Y11Y12Y13Y21Y22Y23Y31Y32Y33][Y_{bus}] = \begin{bmatrix} Y_{11} & Y_{12} & Y_{13} \\ Y_{21} & Y_{22} & Y_{23} \\ Y_{31} & Y_{32} & Y_{33} \end{bmatrix}
where:
Y12=Y21=y12,Y23=Y32=y23,Y31=Y13=y13Y_{12} = Y_{21} = -y_{12},\quad Y_{23} = Y_{32} = -y_{23},\quad Y_{31} = Y_{13} = -y_{13}
Y11=y10+y12+y13,Y22=y20+y12+y23,Y33=y30+y13+y23Y_{11} = y_{10}+y_{12}+y_{13},\quad Y_{22} = y_{20}+y_{12}+y_{23},\quad Y_{33} = y_{30}+y_{13}+y_{23}

Pre-Lab / Circuit Diagram

Circuit Diagram — 3-Bus Power System (Short Transmission)
Figure 1: 3-Bus Power System (Short Transmission Line)

Figure 1: 3-Bus Power System (Short Transmission Line)

Circuit Diagram — 3-Bus Power System (Long Transmission)
Figure 2: 3-Bus Power System (Long Transmission Line with Shunt Admittances)

Figure 2: 3-Bus Power System (Long Transmission Line with Shunt Admittances)

Procedure

  1. Define the number of buses (nbus) and line data (From Bus, To Bus, R, X, and B if applicable).
  2. Initialize the Ybus matrix as a zero matrix of size nbus × nbus.
  3. For each transmission line, compute the series admittance Y = 1 / (R + jX).
  4. For short lines: update off-diagonal elements Yij = Yji = −Y and diagonal elements Yii, Yjj += Y.
  5. For long lines: additionally add jB/2 to each of the two diagonal elements Yii and Yjj.
  6. For systems with ideal transformers: use the turns ratio formulation to populate the 2×2 Ybus.
  7. For junction-based networks: apply KCL at the junction node, solve for Vt, and express bus currents in terms of bus voltages to obtain Ybus.
  8. Display the computed Ybus matrix in rectangular (complex) form.
  9. Convert Ybus elements to polar form (magnitude and angle in degrees) for verification.
  10. Verify computed results against hand-calculated values.
The following four problems are solved in this experiment:
  1. Q1: 3-bus system with given line impedances and line-charging susceptances (long transmission line model).
  2. Q2: 3-bus system with generators as ideal voltage sources, all series and shunt impedances Z = j1 \Omega, using junction nodal analysis.
  3. Q3: 10-bus power system with 11 lines, no shunt admittances, using the direct inspection method.
  4. Q4: 2-bus system with a transmission line of admittance Y and ideal transformers of turns ratios 1:t1 and t2:1 at the two ends.

Simulation / Execution

MATLAB was used to compute and verify the Y-bus matrix for all four problems. The code for each problem initializes line data, iterates over each transmission line to build the Ybus matrix, and displays the result in both rectangular and polar forms.
MATLAB Code — Q1 (3-Bus, Long Transmission with Line Charging)
Figure 3: MATLAB code used for Q1

Figure 3: MATLAB code used for Q1

MATLAB Code — Q2 (3-Bus, Junction Network)
Figure 5: MATLAB code used for Q2

Figure 5: MATLAB code used for Q2

MATLAB Code — Q3 (10-Bus System)
Figure 7: MATLAB code used for Q3

Figure 7: MATLAB code used for Q3

MATLAB Code — Q4 (2-Bus with Ideal Transformers)
Figure 10: MATLAB code used for Q4

Figure 10: MATLAB code used for Q4

Observations

Q1 — Computed Ybus (3-Bus, Long Transmission Line)
Figure 4: Computed Ybus for Q1

Figure 4: Computed Ybus for Q1

Q2 — Computed Ybus (3-Bus, Junction Network)
Figure 6: Computed Ybus for Q2

Figure 6: Computed Ybus for Q2

Q3 — Computed Ybus (10-Bus System)
Figure 8: Computed Ybus for Q3

Figure 8: Computed Ybus for Q3

Figure 9: Computed Ybus for Q3 Polar Form

Figure 9: Computed Ybus for Q3 Polar Form

Q4 — Computed Ybus (2-Bus System with Ideal Transformers)
Figure 11: Computed Ybus for Q4

Figure 11: Computed Ybus for Q4

Calculations

Solved Problems
Q1. Given a 3-bus system with the following line impedances (in per unit): Z12 = 0.1 + j0.3, Z23 = 0.2 + j0.4, Z13 = 0.1 + j0.2, and total line-charging susceptances: B12 = 1.0, B23 = 1.6, B13 = 0.0. Find the bus admittance matrix Ybus.
Given Data:
Z12=0.1+j0.3,Z23=0.2+j0.4,Z13=0.1+j0.2Z_{12} = 0.1 + j0.3,\quad Z_{23} = 0.2 + j0.4,\quad Z_{13} = 0.1 + j0.2
B12=1.0,B23=1.6,B13=0.0B_{12} = 1.0,\quad B_{23} = 1.6,\quad B_{13} = 0.0
Y12=1Z12,Y23=1Z23,Y13=1Z13Y_{12} = \frac{1}{Z_{12}},\quad Y_{23} = \frac{1}{Z_{23}},\quad Y_{13} = \frac{1}{Z_{13}}
The diagonal elements of the Ybus are obtained as:
Yii=YijY_{ii} = \sum Y_{ij}
The off-diagonal elements are given by:
Yij=1Zij,ijY_{ij} = -\frac{1}{Z_{ij}},\quad i \neq j
Ybus=[Y11Y12Y13Y21Y22Y23Y31Y32Y33]\therefore Y_{bus} = \begin{bmatrix} Y_{11} & Y_{12} & Y_{13} \\ Y_{21} & Y_{22} & Y_{23} \\ Y_{31} & Y_{32} & Y_{33} \end{bmatrix}
Q2. If a 3-bus network is shown, consider generators as ideal voltage sources. If rows 1, 2 and 3 of the Ybus matrix correspond to bus 1, 2 and 3 respectively, then determine the Ybus of the network.
3-Bus network with generators as ideal voltage sources (Q2)

3-Bus network with generators as ideal voltage sources (Q2)

Assume Voltage at the junction as Vt. By Ohm's and Kirchhoff's relations:
V1Vt=i1Y1,V2Vt=i2Y2,V3Vt=i3Y3V_1 - V_t = \frac{i_1}{Y_1},\qquad V_2 - V_t = \frac{i_2}{Y_2},\qquad V_3 - V_t = \frac{i_3}{Y_3}
Equivalently,
i1=Y1(V1Vt),i2=Y2(V2Vt),i3=Y3(V3Vt)i_1 = Y_1(V_1 - V_t),\quad i_2 = Y_2(V_2 - V_t),\quad i_3 = Y_3(V_3 - V_t)
KCL at the junction Vt (including shunt current i0 = Y0Vt) gives:
i1+i2+i3+i0=0    Y1(V1Vt)+Y2(V2Vt)+Y3(V3Vt)+Y0Vt=0i_1 + i_2 + i_3 + i_0 = 0 \implies Y_1(V_1-V_t) + Y_2(V_2-V_t) + Y_3(V_3-V_t) + Y_0 V_t = 0
Collect terms to solve for Vt:
Y1V1+Y2V2+Y3V3(Y1+Y2+Y3+Y0)Vt=0Y_1 V_1 + Y_2 V_2 + Y_3 V_3 - (Y_1 + Y_2 + Y_3 + Y_0)V_t = 0
hence
Vt=Y1V1+Y2V2+Y3V3YΣ,where YΣY1+Y2+Y3+Y0V_t = \frac{Y_1 V_1 + Y_2 V_2 + Y_3 V_3}{Y_{\Sigma}},\quad \text{where } Y_{\Sigma} \equiv Y_1 + Y_2 + Y_3 + Y_0
Now substitute Vt into i1 = Y1(V1 − Vt):
i1=Y1V1Y1Y1V1+Y2V2+Y3V3YΣi_1 = Y_1 V_1 - Y_1 \frac{Y_1 V_1 + Y_2 V_2 + Y_3 V_3}{Y_{\Sigma}}
Rearranging to get coefficients of V1, V2, V3 and doing the same for i2, i3 yields the nodal form:
[i1i2i3]=1YΣ[Y1(YΣY1)Y1Y2Y1Y3Y2Y1Y2(YΣY2)Y2Y3Y3Y1Y3Y2Y3(YΣY3)][V1V2V3]\begin{bmatrix} i_1 \\ i_2 \\ i_3 \end{bmatrix} = \frac{1}{Y_{\Sigma}} \begin{bmatrix} Y_1(Y_{\Sigma}-Y_1) & -Y_1 Y_2 & -Y_1 Y_3 \\ -Y_2 Y_1 & Y_2(Y_{\Sigma}-Y_2) & -Y_2 Y_3 \\ -Y_3 Y_1 & -Y_3 Y_2 & Y_3(Y_{\Sigma}-Y_3) \end{bmatrix} \begin{bmatrix} V_1 \\ V_2 \\ V_3 \end{bmatrix}
So in compact form (for i \neq j):
Yij=YiYjYΣ,Yii=Yi(YΣYi)YΣY_{ij} = -\frac{Y_i Y_j}{Y_{\Sigma}},\qquad Y_{ii} = \frac{Y_i(Y_{\Sigma} - Y_i)}{Y_{\Sigma}}
Substituting numerical values: All series impedances and the shunt impedance are Z = j1 \Omega (given). Thus:
Y1=Y2=Y3=Y0=1j1=jY_1 = Y_2 = Y_3 = Y_0 = \frac{1}{j1} = -j
Hence:
YΣ=Y1+Y2+Y3+Y0=4(j)=4jY_{\Sigma} = Y_1 + Y_2 + Y_3 + Y_0 = 4(-j) = -4j
Compute diagonal and off-diagonal entries:
Yii=Yi(YΣYi)YΣ=(j)(4j(j))4j=34jY_{ii} = \frac{Y_i(Y_{\Sigma} - Y_i)}{Y_{\Sigma}} = \frac{(-j)(-4j-(-j))}{-4j} = -\frac{3}{4}j
Yij=YiYjYΣ=(j)(j)4j=14j(ij)Y_{ij} = -\frac{Y_i Y_j}{Y_{\Sigma}} = -\frac{(-j)(-j)}{-4j} = \frac{1}{4}j \quad (i \neq j)
Therefore the numeric bus-admittance matrix is:
[Ybus]=[34j14j14j14j34j14j14j14j34j][Y_{bus}] = \begin{bmatrix} -\frac{3}{4}j & \frac{1}{4}j & \frac{1}{4}j \\ \frac{1}{4}j & -\frac{3}{4}j & \frac{1}{4}j \\ \frac{1}{4}j & \frac{1}{4}j & -\frac{3}{4}j \end{bmatrix}
Q3. A 10-bus power system is modeled using per-unit values. All line data are given in pu on a common system base. There are no shunt admittances at any bus. Using the direct inspection method, form the bus admittance matrix Ybus for the network defined by the following series impedances:
LineFrom busTo busR (pu)X (pu)
1120.100.30
2130.050.25
3240.080.24
4250.060.18
5360.120.36
6470.090.27
7580.070.21
8690.110.33
97100.050.15
10890.080.24
119100.100.30
Yij=1Rij+jXij,Yii=ki1ZikY_{ij} = -\frac{1}{R_{ij} + jX_{ij}},\quad Y_{ii} = \sum_{k \neq i} \frac{1}{Z_{ik}}
Q4. Two buses i and j are connected with a Tx-line of admittance Y, at the two ends of which there are ideal transformers with turns ratio as shown. Bus admittance matrix for the system is:
Two-bus system with transmission line of admittance Y and ideal transformers (Q4)

Two-bus system with transmission line of admittance Y and ideal transformers of turns ratio 1:ti and tj:1 (Q4)

The relation across the line with transformers is:
tiVitjVj=IijYt_i V_i - t_j V_j = \frac{I_{ij}}{Y}
Expressing the injected currents at the buses in terms of bus voltages:
Ii=ti2YVititjYVjI_i = t_i^2 Y V_i - t_i t_j Y V_j
Ij=titjYVitj2YVjI_j = t_i t_j Y V_i - t_j^2 Y V_j
In matrix form, the bus admittance matrix is:
[IiIj]=[ti2YtitjYtitjYtj2Y][ViVj]=[Ybus][ViVj]\begin{bmatrix} I_i \\ I_j \end{bmatrix} = \begin{bmatrix} t_i^2 Y & -t_i t_j Y \\ -t_i t_j Y & t_j^2 Y \end{bmatrix} \begin{bmatrix} V_i \\ V_j \end{bmatrix} = [Y_{bus}] \begin{bmatrix} V_i \\ V_j \end{bmatrix}

Results & Analysis

The Y-bus matrices were successfully computed using MATLAB for all four problems. The results are summarized below.
ProblemNetwork TypeBusesLinesKey Observation
Q13-Bus Long Transmission33Line charging (B/2) adds to diagonal elements; off-diagonals are negative series admittances.
Q23-Bus Junction Network33 + shuntSymmetric Ybus with equal diagonal (−0.75j) and off-diagonal (+0.25j) entries due to uniform impedances.
Q310-Bus Short Transmission1011Sparse symmetric 10×10 Ybus; zero entries where no direct line exists between buses.
Q42-Bus with Transformers21Ybus diagonal elements scale as ti² and tj²; off-diagonal elements scale as −ti·tj.
For Q1, including line charging susceptances (B/2 = 0.5, 0.8, 0.0) modified the diagonal elements of the Ybus compared to the short-line model, while the off-diagonal elements remained equal to the negative series admittances. For Q3, the 10×10 Ybus confirmed the sparse nature of admittance matrices in large power systems, with most off-diagonal entries being zero due to limited inter-bus connectivity. The transformer-coupled system in Q4 produced a 2×2 Ybus whose entries are entirely determined by the line admittance Y and the turns ratios t1 and t2.

Conclusion

In this experiment, we determined the bus admittance matrix (Ybus) for different transmission systems using analytical methods. We used the direct inspection method for multi-bus networks and systematic nodal analysis for networks with junctions and transformers. We applied MATLAB to compute and verify Ybus for various setups, including short transmission lines, long transmission lines with line charging, and systems with ideal transformers.
The Ybus matrix is crucial in power system analysis because it gives a clear representation of network admittances that connect bus currents and voltages. By comparing short and long transmission lines, we found that line charging adds extra shunt admittances, which affect the diagonal elements of Ybus. In contrast, short lines mainly impact the off-diagonal terms. This experiment shows the importance of accurately forming Ybus for reliable load flow, fault, and stability analysis in power systems.

Post-Lab / Viva Voce

  1. Q: What is the bus admittance matrix (Ybus) and why is it important in power system analysis?

    A: The bus admittance matrix (Ybus) is a square matrix that relates the bus current injections to the bus voltages in a power system through the relation [I] = [Ybus][V]. It is important because it provides a compact, systematic, and computationally efficient representation of the network topology and line admittances. Ybus is used extensively in load flow analysis, short circuit studies, and stability analysis. It is typically a sparse and symmetric matrix, which reduces storage requirements and computational effort in large systems.
  2. Q: How are the diagonal and off-diagonal elements of the Ybus matrix formed using the direct inspection method?

    A: Using the direct inspection method, the diagonal element Yii of the Ybus is the sum of all admittances connected to bus i, including both series line admittances and any shunt admittances at that bus. The off-diagonal element Yij (i ≠ j) is the negative of the total admittance directly connected between bus i and bus j. This method allows rapid construction of the Ybus without writing KCL equations explicitly.
  3. Q: How does line charging affect the Ybus matrix in long transmission line models compared to short transmission line models?

    A: In the short transmission line model, each line is represented only by its series impedance, so only off-diagonal elements and diagonal elements due to series admittances are affected. In the long transmission line model, line charging susceptances (B/2) are added as shunt admittances at each end of the line. This adds an extra jB/2 term to the diagonal elements Yii and Yjj for every line connected to those buses. The off-diagonal elements remain equal to the negative series admittances and are unaffected by line charging.
  4. Q: What is the significance of the sparsity of the Ybus matrix in large power systems?

    A: In a large power system, each bus is typically connected to only a few other buses, so most off-diagonal elements of the Ybus are zero. This sparsity is highly significant for computational efficiency: sparse matrix storage formats drastically reduce memory requirements, and sparse solvers (such as LU factorization with optimal ordering) reduce the computational time for solving the network equations. For a 10-bus system as in Q3, the Ybus contains many zero off-diagonal entries corresponding to pairs of buses with no direct connection.
  5. Q: How does the presence of ideal transformers with off-nominal turns ratios affect the Ybus matrix structure?

    A: When ideal transformers with turns ratios 1:ti and tj:1 are placed at the two ends of a transmission line, the resulting 2×2 Ybus is no longer symmetric in general if ti ≠ tj. The diagonal elements become ti²Y and tj²Y, and the off-diagonal elements become −ti·tj·Y. This asymmetry means the Ybus loses its standard symmetric property, which must be accounted for in load flow and fault analysis algorithms that typically assume a symmetric Ybus.
  6. Q: In Q2, why is the junction voltage Vt eliminated before forming the Ybus?

    A: The junction node Vt is an internal node that has no external current injection. In the Ybus formulation, only bus nodes (where generators or loads are connected) are retained. The internal junction node is eliminated by applying KCL at that node and expressing Vt in terms of the bus voltages V1, V2, and V3. This process, known as Kron reduction or node elimination, reduces the network to only the external bus nodes, yielding a 3×3 Ybus that directly relates the injected bus currents to the bus voltages.

References & Resources (Not Applicable)

This section is not required for this experiment.