.. _StaticGen: ================================================================================ StaticGen ================================================================================ Static generator group. Static generators include PV and Slack, which are used to impose algebraic equations. Static generators are used primarily for power flow. Static generators do not have the modeling details for stability simulation. Although some of them can stay for time-domain simulation, most of them should be substituted by dynamic generators, including synchronous generators and inverter-based resources upon TDS initialization. The substitution is done by setting the ``gen`` field of a dynamic generator to refer to the static generator. To replace one StaticGen by multiple dynamic generators, see the notes in :ref:`SynGen`. Generators connected to the same bus need to have their `gammap` and `gammaq`, respectively, summed up to be exactly 1.0. TDS initialization will ensure that the dynamic generators impose the same amount of power as the static generator. At the end of initialization, `StaticGen`'s that have been substituted will have their connectivity status ``u`` changed to ``0``. Common Parameters: u, name, Sn, Vn, p0, q0, ra, xs, subidx Common Variables: q, a, v Available models: PV_, Slack_ .. _PV: -------------------------------------------------------------------------------- PV -------------------------------------------------------------------------------- Static PV generator with reactive power limit checking and PV-to-PQ conversion. `pv2pq = 1` turns on the conversion. It starts from iteration `min_iter` or when the convergence error drops below `err_tol`. The PV-to-PQ conversion first ranks the reactive violations. A maximum number of `npv2pq` PVs above the upper limit, and a maximum of `npv2pq` PVs below the lower limit will be converted to PQ, which sets the reactive power to `pmax` or `pmin`. If `pv2pq` is `1` (enabled) and `npv2pq` is `0`, heuristics will be used to determine the number of PVs to be converted for each iteration. Parameters ---------- +---------+------------------+-----------------------------------------+---------+--------+------------+ | Name | Symbol | Description | Default | Unit | Properties | +=========+==================+=========================================+=========+========+============+ | idx | | unique device idx | | | | +---------+------------------+-----------------------------------------+---------+--------+------------+ | u | :math:`u` | connection status | 1 | *bool* | | +---------+------------------+-----------------------------------------+---------+--------+------------+ | name | | device name | | | | +---------+------------------+-----------------------------------------+---------+--------+------------+ | Sn | :math:`S_n` | Power rating | 100 | | non_zero | +---------+------------------+-----------------------------------------+---------+--------+------------+ | Vn | :math:`V_n` | AC voltage rating | 110 | | non_zero | +---------+------------------+-----------------------------------------+---------+--------+------------+ | subidx | | index for generators on the same bus | | | | +---------+------------------+-----------------------------------------+---------+--------+------------+ | bus | | idx of the installed bus | | | mandatory | +---------+------------------+-----------------------------------------+---------+--------+------------+ | busr | | bus idx for remote voltage control | | | | +---------+------------------+-----------------------------------------+---------+--------+------------+ | p0 | :math:`p_0` | active power set point in system base | 0 | *p.u.* | | +---------+------------------+-----------------------------------------+---------+--------+------------+ | q0 | :math:`q_0` | reactive power set point in system base | 0 | *p.u.* | | +---------+------------------+-----------------------------------------+---------+--------+------------+ | pmax | :math:`p_{max}` | maximum active power in system base | 999 | *p.u.* | | +---------+------------------+-----------------------------------------+---------+--------+------------+ | pmin | :math:`p_{min}` | minimum active power in system base | -1 | *p.u.* | | +---------+------------------+-----------------------------------------+---------+--------+------------+ | qmax | :math:`q_{max}` | maximim reactive power in system base | 999 | *p.u.* | | +---------+------------------+-----------------------------------------+---------+--------+------------+ | qmin | :math:`q_{min}` | minimum reactive power in system base | -999 | *p.u.* | | +---------+------------------+-----------------------------------------+---------+--------+------------+ | v0 | :math:`v_0` | voltage set point | 1 | | | +---------+------------------+-----------------------------------------+---------+--------+------------+ | vmax | :math:`v_{max}` | maximum voltage voltage | 1.400 | | | +---------+------------------+-----------------------------------------+---------+--------+------------+ | vmin | :math:`v_{min}` | minimum allowed voltage | 0.600 | | | +---------+------------------+-----------------------------------------+---------+--------+------------+ | ra | :math:`r_a` | armature resistance | 0 | | | +---------+------------------+-----------------------------------------+---------+--------+------------+ | xs | :math:`x_s` | armature reactance | 0.300 | | | +---------+------------------+-----------------------------------------+---------+--------+------------+ | wmod | :math:`w_{mod}` | Machine ctrl. mode [PSS/E] | 0 | *int* | | +---------+------------------+-----------------------------------------+---------+--------+------------+ | busv0 | :math:`V_{0bus}` | | 0 | | | +---------+------------------+-----------------------------------------+---------+--------+------------+ Variables --------- +------+-----------+----------+----------------------------------+--------+----------------+ | Name | Symbol | Type | Description | Unit | Properties | +======+===========+==========+==================================+========+================+ | q | :math:`q` | Algeb | actual reactive power generation | *p.u.* | v_str | +------+-----------+----------+----------------------------------+--------+----------------+ | a | :math:`a` | ExtAlgeb | | | | +------+-----------+----------+----------------------------------+--------+----------------+ | v | :math:`v` | ExtAlgeb | | | v_str,v_setter | +------+-----------+----------+----------------------------------+--------+----------------+ Initialization Equations ------------------------ +------+-----------+----------+-----------------------------------------------------+ | Name | Symbol | Type | Initial Value | +======+===========+==========+=====================================================+ | q | :math:`q` | Algeb | :math:`q_{0} u` | +------+-----------+----------+-----------------------------------------------------+ | a | :math:`a` | ExtAlgeb | | +------+-----------+----------+-----------------------------------------------------+ | v | :math:`v` | ExtAlgeb | :math:`busv_{0} \cdot \left(1 - u\right) + u v_{0}` | +------+-----------+----------+-----------------------------------------------------+ Algebraic Equations ----------------------------- +------+-----------+----------+-----------------------------------------------------------------------------------------------------------------------------------+ | Name | Symbol | Type | RHS of Equation "0 = g(x, y)" | +======+===========+==========+===================================================================================================================================+ | q | :math:`q` | Algeb | :math:`u \left(qlim_{zi} \left(- v + v_{0}\right) + qlim_{zl} \left(- q + qmin\right) + qlim_{zu} \left(- q + qmax\right)\right)` | +------+-----------+----------+-----------------------------------------------------------------------------------------------------------------------------------+ | a | :math:`a` | ExtAlgeb | :math:`- p u` | +------+-----------+----------+-----------------------------------------------------------------------------------------------------------------------------------+ | v | :math:`v` | ExtAlgeb | :math:`- q u` | +------+-----------+----------+-----------------------------------------------------------------------------------------------------------------------------------+ Services ---------- +------+-----------+---------------+--------------+ | Name | Symbol | Equation | Type | +======+===========+===============+==============+ | p | :math:`p` | :math:`p_{0}` | ConstService | +------+-----------+---------------+--------------+ Discretes ----------- +-------+--------------+---------------+------+ | Name | Symbol | Type | Info | +=======+==============+===============+======+ | qlim | :math:`qlim` | SortedLimiter | | +-------+--------------+---------------+------+ Config Fields in [PV] +----------------+------------------------+-------+----------------------------------------------------------+-----------------+ | Option | Symbol | Value | Info | Accepted values | +================+========================+=======+==========================================================+=================+ | allow_adjust | | 1 | allow adjusting upper or lower limits | (0, 1) | +----------------+------------------------+-------+----------------------------------------------------------+-----------------+ | adjust_lower | | 0 | adjust lower limit | (0, 1) | +----------------+------------------------+-------+----------------------------------------------------------+-----------------+ | adjust_upper | | 1 | adjust upper limit | (0, 1) | +----------------+------------------------+-------+----------------------------------------------------------+-----------------+ | pv2pq | :math:`z_{pv2pq}` | 0 | convert PV to PQ in PFlow at Q limits | (0, 1) | +----------------+------------------------+-------+----------------------------------------------------------+-----------------+ | npv2pq | :math:`n_{pv2pq}` | 0 | max. # of conversion each iteration, 0 - auto | >=0 | +----------------+------------------------+-------+----------------------------------------------------------+-----------------+ | min_iter | :math:`sw_{iter}` | 2 | iteration number starting from which to enable switching | int | +----------------+------------------------+-------+----------------------------------------------------------+-----------------+ | err_tol | :math:`\epsilon_{tol}` | 0.010 | iteration error below which to enable switching | float | +----------------+------------------------+-------+----------------------------------------------------------+-----------------+ | abs_violation | | 1 | use absolute (1) or relative (0) limit violation | (0, 1) | +----------------+------------------------+-------+----------------------------------------------------------+-----------------+ .. _Slack: -------------------------------------------------------------------------------- Slack -------------------------------------------------------------------------------- Slack generator. Parameters ---------- +---------+-----------------------+-----------------------------------------+---------+--------+------------+ | Name | Symbol | Description | Default | Unit | Properties | +=========+=======================+=========================================+=========+========+============+ | idx | | unique device idx | | | | +---------+-----------------------+-----------------------------------------+---------+--------+------------+ | u | :math:`u` | connection status | 1 | *bool* | | +---------+-----------------------+-----------------------------------------+---------+--------+------------+ | name | | device name | | | | +---------+-----------------------+-----------------------------------------+---------+--------+------------+ | Sn | :math:`S_n` | Power rating | 100 | | non_zero | +---------+-----------------------+-----------------------------------------+---------+--------+------------+ | Vn | :math:`V_n` | AC voltage rating | 110 | | non_zero | +---------+-----------------------+-----------------------------------------+---------+--------+------------+ | subidx | | index for generators on the same bus | | | | +---------+-----------------------+-----------------------------------------+---------+--------+------------+ | bus | | idx of the installed bus | | | mandatory | +---------+-----------------------+-----------------------------------------+---------+--------+------------+ | busr | | bus idx for remote voltage control | | | | +---------+-----------------------+-----------------------------------------+---------+--------+------------+ | p0 | :math:`p_0` | active power set point in system base | 0 | *p.u.* | | +---------+-----------------------+-----------------------------------------+---------+--------+------------+ | q0 | :math:`q_0` | reactive power set point in system base | 0 | *p.u.* | | +---------+-----------------------+-----------------------------------------+---------+--------+------------+ | pmax | :math:`p_{max}` | maximum active power in system base | 999 | *p.u.* | | +---------+-----------------------+-----------------------------------------+---------+--------+------------+ | pmin | :math:`p_{min}` | minimum active power in system base | -1 | *p.u.* | | +---------+-----------------------+-----------------------------------------+---------+--------+------------+ | qmax | :math:`q_{max}` | maximim reactive power in system base | 999 | *p.u.* | | +---------+-----------------------+-----------------------------------------+---------+--------+------------+ | qmin | :math:`q_{min}` | minimum reactive power in system base | -999 | *p.u.* | | +---------+-----------------------+-----------------------------------------+---------+--------+------------+ | v0 | :math:`v_0` | voltage set point | 1 | | | +---------+-----------------------+-----------------------------------------+---------+--------+------------+ | vmax | :math:`v_{max}` | maximum voltage voltage | 1.400 | | | +---------+-----------------------+-----------------------------------------+---------+--------+------------+ | vmin | :math:`v_{min}` | minimum allowed voltage | 0.600 | | | +---------+-----------------------+-----------------------------------------+---------+--------+------------+ | ra | :math:`r_a` | armature resistance | 0 | | | +---------+-----------------------+-----------------------------------------+---------+--------+------------+ | xs | :math:`x_s` | armature reactance | 0.300 | | | +---------+-----------------------+-----------------------------------------+---------+--------+------------+ | wmod | :math:`w_{mod}` | Machine ctrl. mode [PSS/E] | 0 | *int* | | +---------+-----------------------+-----------------------------------------+---------+--------+------------+ | a0 | :math:`\theta_0` | reference angle set point | 0 | | | +---------+-----------------------+-----------------------------------------+---------+--------+------------+ | busv0 | :math:`V_{0bus}` | | 0 | | | +---------+-----------------------+-----------------------------------------+---------+--------+------------+ | busa0 | :math:`\theta_{0bus}` | | 0 | | | +---------+-----------------------+-----------------------------------------+---------+--------+------------+ Variables --------- +------+-----------+----------+----------------------------------+--------+----------------+ | Name | Symbol | Type | Description | Unit | Properties | +======+===========+==========+==================================+========+================+ | q | :math:`q` | Algeb | actual reactive power generation | *p.u.* | v_str | +------+-----------+----------+----------------------------------+--------+----------------+ | p | :math:`p` | Algeb | actual active power generation | *p.u.* | v_str | +------+-----------+----------+----------------------------------+--------+----------------+ | a | :math:`a` | ExtAlgeb | | | v_str,v_setter | +------+-----------+----------+----------------------------------+--------+----------------+ | v | :math:`v` | ExtAlgeb | | | v_str,v_setter | +------+-----------+----------+----------------------------------+--------+----------------+ Initialization Equations ------------------------ +------+-----------+----------+-----------------------------------------------------+ | Name | Symbol | Type | Initial Value | +======+===========+==========+=====================================================+ | q | :math:`q` | Algeb | :math:`q_{0} u` | +------+-----------+----------+-----------------------------------------------------+ | p | :math:`p` | Algeb | :math:`p_{0} u` | +------+-----------+----------+-----------------------------------------------------+ | a | :math:`a` | ExtAlgeb | :math:`a_{0} u + busa_{0} \cdot \left(1 - u\right)` | +------+-----------+----------+-----------------------------------------------------+ | v | :math:`v` | ExtAlgeb | :math:`busv_{0} \cdot \left(1 - u\right) + u v_{0}` | +------+-----------+----------+-----------------------------------------------------+ Algebraic Equations ----------------------------- +------+-----------+----------+-----------------------------------------------------------------------------------------------------------------------------------+ | Name | Symbol | Type | RHS of Equation "0 = g(x, y)" | +======+===========+==========+===================================================================================================================================+ | q | :math:`q` | Algeb | :math:`u \left(qlim_{zi} \left(- v + v_{0}\right) + qlim_{zl} \left(- q + qmin\right) + qlim_{zu} \left(- q + qmax\right)\right)` | +------+-----------+----------+-----------------------------------------------------------------------------------------------------------------------------------+ | p | :math:`p` | Algeb | :math:`u \left(plim_{zi} \left(- a + a_{0}\right) + plim_{zl} \left(- p + pmin\right) + plim_{zu} \left(- p + pmax\right)\right)` | +------+-----------+----------+-----------------------------------------------------------------------------------------------------------------------------------+ | a | :math:`a` | ExtAlgeb | :math:`- p u` | +------+-----------+----------+-----------------------------------------------------------------------------------------------------------------------------------+ | v | :math:`v` | ExtAlgeb | :math:`- q u` | +------+-----------+----------+-----------------------------------------------------------------------------------------------------------------------------------+ Discretes ----------- +-------+--------------+---------------+------+ | Name | Symbol | Type | Info | +=======+==============+===============+======+ | qlim | :math:`qlim` | SortedLimiter | | +-------+--------------+---------------+------+ | plim | :math:`plim` | SortedLimiter | | +-------+--------------+---------------+------+ Config Fields in [Slack] +----------------+------------------------+-------+----------------------------------------------------------+-----------------+ | Option | Symbol | Value | Info | Accepted values | +================+========================+=======+==========================================================+=================+ | allow_adjust | | 1 | allow adjusting upper or lower limits | (0, 1) | +----------------+------------------------+-------+----------------------------------------------------------+-----------------+ | adjust_lower | | 0 | adjust lower limit | (0, 1) | +----------------+------------------------+-------+----------------------------------------------------------+-----------------+ | adjust_upper | | 1 | adjust upper limit | (0, 1) | +----------------+------------------------+-------+----------------------------------------------------------+-----------------+ | pv2pq | :math:`z_{pv2pq}` | 0 | convert PV to PQ in PFlow at Q limits | (0, 1) | +----------------+------------------------+-------+----------------------------------------------------------+-----------------+ | npv2pq | :math:`n_{pv2pq}` | 0 | max. # of conversion each iteration, 0 - auto | >=0 | +----------------+------------------------+-------+----------------------------------------------------------+-----------------+ | min_iter | :math:`sw_{iter}` | 2 | iteration number starting from which to enable switching | int | +----------------+------------------------+-------+----------------------------------------------------------+-----------------+ | err_tol | :math:`\epsilon_{tol}` | 0.010 | iteration error below which to enable switching | float | +----------------+------------------------+-------+----------------------------------------------------------+-----------------+ | abs_violation | | 1 | use absolute (1) or relative (0) limit violation | (0, 1) | +----------------+------------------------+-------+----------------------------------------------------------+-----------------+ | av2pv | :math:`z_{av2pv}` | 0 | convert Slack to PV in PFlow at P limits | (0, 1) | +----------------+------------------------+-------+----------------------------------------------------------+-----------------+