Home > matpower4.0 > idx_brch.m

idx_brch

PURPOSE ^

IDX_BRCH Defines constants for named column indices to branch matrix.

SYNOPSIS ^

function [F_BUS, T_BUS, BR_R, BR_X, BR_B, RATE_A, RATE_B,RATE_C, TAP, SHIFT, BR_STATUS, PF, QF, PT, QT, MU_SF, MU_ST,ANGMIN, ANGMAX, MU_ANGMIN, MU_ANGMAX] = idx_brch

DESCRIPTION ^

IDX_BRCH   Defines constants for named column indices to branch matrix.
   Example:

   [F_BUS, T_BUS, BR_R, BR_X, BR_B, RATE_A, RATE_B, RATE_C, ...
   TAP, SHIFT, BR_STATUS, PF, QF, PT, QT, MU_SF, MU_ST, ...
   ANGMIN, ANGMAX, MU_ANGMIN, MU_ANGMAX] = idx_brch;

   Some examples of usage, after defining the constants using the line above,
   are:

    branch(4, BR_STATUS) = 0;              % take branch 4 out of service
    Ploss = branch(:, PF) + branch(:, PT); % compute real power loss vector
 
   The index, name and meaning of each column of the branch matrix is given
   below:

   columns 1-11 must be included in input matrix (in case file)
    1  F_BUS       f, from bus number
    2  T_BUS       t, to bus number
    3  BR_R        r, resistance (p.u.)
    4  BR_X        x, reactance (p.u.)
    5  BR_B        b, total line charging susceptance (p.u.)
    6  RATE_A      rateA, MVA rating A (long term rating)
    7  RATE_B      rateB, MVA rating B (short term rating)
    8  RATE_C      rateC, MVA rating C (emergency rating)
    9  TAP         ratio, transformer off nominal turns ratio
    10 SHIFT       angle, transformer phase shift angle (degrees)
    11 BR_STATUS   initial branch status, 1 - in service, 0 - out of service
    12 ANGMIN      minimum angle difference, angle(Vf) - angle(Vt) (degrees)
    13 ANGMAX      maximum angle difference, angle(Vf) - angle(Vt) (degrees)

   columns 14-17 are added to matrix after power flow or OPF solution
   they are typically not present in the input matrix
    14 PF          real power injected at "from" bus end (MW)
    15 QF          reactive power injected at "from" bus end (MVAr)
    16 PT          real power injected at "to" bus end (MW)
    17 QT          reactive power injected at "to" bus end (MVAr)

   columns 18-21 are added to matrix after OPF solution
   they are typically not present in the input matrix
                   (assume OPF objective function has units, u)
    18 MU_SF       Kuhn-Tucker multiplier on MVA limit at "from" bus (u/MVA)
    19 MU_ST       Kuhn-Tucker multiplier on MVA limit at "to" bus (u/MVA)
    20 MU_ANGMIN   Kuhn-Tucker multiplier lower angle difference limit (u/degree)
    21 MU_ANGMAX   Kuhn-Tucker multiplier upper angle difference limit (u/degree)

   See also DEFINE_CONSTANTS.

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:

SOURCE CODE ^

0001 function [F_BUS, T_BUS, BR_R, BR_X, BR_B, RATE_A, RATE_B, ...
0002     RATE_C, TAP, SHIFT, BR_STATUS, PF, QF, PT, QT, MU_SF, MU_ST, ...
0003     ANGMIN, ANGMAX, MU_ANGMIN, MU_ANGMAX] = idx_brch
0004 %IDX_BRCH   Defines constants for named column indices to branch matrix.
0005 %   Example:
0006 %
0007 %   [F_BUS, T_BUS, BR_R, BR_X, BR_B, RATE_A, RATE_B, RATE_C, ...
0008 %   TAP, SHIFT, BR_STATUS, PF, QF, PT, QT, MU_SF, MU_ST, ...
0009 %   ANGMIN, ANGMAX, MU_ANGMIN, MU_ANGMAX] = idx_brch;
0010 %
0011 %   Some examples of usage, after defining the constants using the line above,
0012 %   are:
0013 %
0014 %    branch(4, BR_STATUS) = 0;              % take branch 4 out of service
0015 %    Ploss = branch(:, PF) + branch(:, PT); % compute real power loss vector
0016 %
0017 %   The index, name and meaning of each column of the branch matrix is given
0018 %   below:
0019 %
0020 %   columns 1-11 must be included in input matrix (in case file)
0021 %    1  F_BUS       f, from bus number
0022 %    2  T_BUS       t, to bus number
0023 %    3  BR_R        r, resistance (p.u.)
0024 %    4  BR_X        x, reactance (p.u.)
0025 %    5  BR_B        b, total line charging susceptance (p.u.)
0026 %    6  RATE_A      rateA, MVA rating A (long term rating)
0027 %    7  RATE_B      rateB, MVA rating B (short term rating)
0028 %    8  RATE_C      rateC, MVA rating C (emergency rating)
0029 %    9  TAP         ratio, transformer off nominal turns ratio
0030 %    10 SHIFT       angle, transformer phase shift angle (degrees)
0031 %    11 BR_STATUS   initial branch status, 1 - in service, 0 - out of service
0032 %    12 ANGMIN      minimum angle difference, angle(Vf) - angle(Vt) (degrees)
0033 %    13 ANGMAX      maximum angle difference, angle(Vf) - angle(Vt) (degrees)
0034 %
0035 %   columns 14-17 are added to matrix after power flow or OPF solution
0036 %   they are typically not present in the input matrix
0037 %    14 PF          real power injected at "from" bus end (MW)
0038 %    15 QF          reactive power injected at "from" bus end (MVAr)
0039 %    16 PT          real power injected at "to" bus end (MW)
0040 %    17 QT          reactive power injected at "to" bus end (MVAr)
0041 %
0042 %   columns 18-21 are added to matrix after OPF solution
0043 %   they are typically not present in the input matrix
0044 %                   (assume OPF objective function has units, u)
0045 %    18 MU_SF       Kuhn-Tucker multiplier on MVA limit at "from" bus (u/MVA)
0046 %    19 MU_ST       Kuhn-Tucker multiplier on MVA limit at "to" bus (u/MVA)
0047 %    20 MU_ANGMIN   Kuhn-Tucker multiplier lower angle difference limit (u/degree)
0048 %    21 MU_ANGMAX   Kuhn-Tucker multiplier upper angle difference limit (u/degree)
0049 %
0050 %   See also DEFINE_CONSTANTS.
0051 
0052 %   MATPOWER
0053 %   $Id: idx_brch.m,v 1.12 2010/04/26 19:45:25 ray Exp $
0054 %   by Ray Zimmerman, PSERC Cornell
0055 %   Copyright (c) 1996-2010 by Power System Engineering Research Center (PSERC)
0056 %
0057 %   This file is part of MATPOWER.
0058 %   See http://www.pserc.cornell.edu/matpower/ for more info.
0059 %
0060 %   MATPOWER is free software: you can redistribute it and/or modify
0061 %   it under the terms of the GNU General Public License as published
0062 %   by the Free Software Foundation, either version 3 of the License,
0063 %   or (at your option) any later version.
0064 %
0065 %   MATPOWER is distributed in the hope that it will be useful,
0066 %   but WITHOUT ANY WARRANTY; without even the implied warranty of
0067 %   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
0068 %   GNU General Public License for more details.
0069 %
0070 %   You should have received a copy of the GNU General Public License
0071 %   along with MATPOWER. If not, see <http://www.gnu.org/licenses/>.
0072 %
0073 %   Additional permission under GNU GPL version 3 section 7
0074 %
0075 %   If you modify MATPOWER, or any covered work, to interface with
0076 %   other modules (such as MATLAB code and MEX-files) available in a
0077 %   MATLAB(R) or comparable environment containing parts covered
0078 %   under other licensing terms, the licensors of MATPOWER grant
0079 %   you additional permission to convey the resulting work.
0080 
0081 %% define the indices
0082 F_BUS       = 1;    %% f, from bus number
0083 T_BUS       = 2;    %% t, to bus number
0084 BR_R        = 3;    %% r, resistance (p.u.)
0085 BR_X        = 4;    %% x, reactance (p.u.)
0086 BR_B        = 5;    %% b, total line charging susceptance (p.u.)
0087 RATE_A      = 6;    %% rateA, MVA rating A (long term rating)
0088 RATE_B      = 7;    %% rateB, MVA rating B (short term rating)
0089 RATE_C      = 8;    %% rateC, MVA rating C (emergency rating)
0090 TAP         = 9;    %% ratio, transformer off nominal turns ratio
0091 SHIFT       = 10;   %% angle, transformer phase shift angle (degrees)
0092 BR_STATUS   = 11;   %% initial branch status, 1 - in service, 0 - out of service
0093 ANGMIN      = 12;   %% minimum angle difference, angle(Vf) - angle(Vt) (degrees)
0094 ANGMAX      = 13;   %% maximum angle difference, angle(Vf) - angle(Vt) (degrees)
0095 
0096 %% included in power flow solution, not necessarily in input
0097 PF          = 14;   %% real power injected at "from" bus end (MW)       (not in PTI format)
0098 QF          = 15;   %% reactive power injected at "from" bus end (MVAr) (not in PTI format)
0099 PT          = 16;   %% real power injected at "to" bus end (MW)         (not in PTI format)
0100 QT          = 17;   %% reactive power injected at "to" bus end (MVAr)   (not in PTI format)
0101 
0102 %% included in opf solution, not necessarily in input
0103 %% assume objective function has units, u
0104 MU_SF       = 18;   %% Kuhn-Tucker multiplier on MVA limit at "from" bus (u/MVA)
0105 MU_ST       = 19;   %% Kuhn-Tucker multiplier on MVA limit at "to" bus (u/MVA)
0106 MU_ANGMIN   = 20;   %% Kuhn-Tucker multiplier lower angle difference limit (u/degree)
0107 MU_ANGMAX   = 21;   %% Kuhn-Tucker multiplier upper angle difference limit (u/degree)

Generated on Mon 26-Jan-2015 14:56:45 by m2html © 2005