Bus Admittance Matrix 1
implement bus admittance matrix using matlab, java and python
|
Functions | |
S (j, i) | |
Display results | disp ('Complex Power(S):') |
disp (S) | |
disp ('Line Losses(SL):') | |
disp (SL) | |
disp ('Real Power(P):') | |
disp (P) | |
disp ('Reactive Power(Q):') | |
disp (Q) | |
disp ('Real Line Losses(SLR):') | |
disp (SLR) | |
disp ('Reactive Line Losses(SLI):') | |
disp (SLI) | |
Variables | |
function [P, Q] | |
Complex power | SL = zeros(n, n) |
Line losses Calculate complex power for | i |
No losses on the diagonal else | continue |
end end Calculate load flow equations | P = real(S) |
Q = imag(S) | |
SLR = real(SL) | |
SLI = imag(SL) | |
disp | ( | 'Line Losses(SL):' | ) |
disp | ( | 'Reactive Line Losses(SLI):' | ) |
disp | ( | 'Reactive Power(Q):' | ) |
disp | ( | 'Real Line Losses(SLR):' | ) |
disp | ( | 'Real Power(P):' | ) |
disp | ( | P | ) |
disp | ( | Q | ) |
disp | ( | S | ) |
disp | ( | SL | ) |
disp | ( | SLI | ) |
disp | ( | SLR | ) |
S | ( | j | , |
i | |||
) |
No losses on the diagonal else continue |
if i |
end end Calculate load flow equations P = real(S) |
Q = imag(S) |
SLI = imag(SL) |
SLR = real(SL) |