diff --git a/dev/api/internal/index.html b/dev/api/internal/index.html index 44383bd8f..4db5ff0e4 100644 --- a/dev/api/internal/index.html +++ b/dev/api/internal/index.html @@ -1,10 +1,10 @@ -Internal API Reference · PowerSimulationsDynamics.jl

Internal

PowerSimulationsDynamics.generator_inner_varsType

Generator Inner Vars:

  • τe_var :: Electric torque
  • τm_var :: Mechanical torque
  • Vf_var :: Field voltage
  • V_pss_var :: Additional PSS voltage
  • VR_gen_var :: Real part of the terminal voltage
  • VI_gen_var :: Imaginary part of the terminal voltage
  • ψd_var :: Stator Flux (if defined) in the d-axis
  • ψq_var :: Stator Flux (if defined) in the q-axis
source
PowerSimulationsDynamics.inverter_inner_varsType

Inverter Inner Vars:

  • md_var :: Modulation signal on the d-component
  • mq_var :: Modulation signal on the q-component
  • Vdc_var :: DC voltage supplied by the DC source
  • Vr_filter_var :: Voltage seen in the capacitor of the filter in the R-component
  • Vi_filter_var :: Voltage seen in the capacitor of the filter in the I-component
  • θ_freq_estimator_var :: Angle estimated by the frequency estimator.
  • ω_freq_estimator_var :: Frequency estimated by the frequency estimator.
  • V_oc_var :: Control voltage reference in the d-axis supplied from the outer loop control to the inner loop (for Voltage Mode Control)
  • Id_oc_var :: Control current reference in the d-axis supplied from the outer loop control to the inner loop (for Current Mode Control)
  • Iq_oc_var :: Control current reference in the q-axis supplied from the outer loop control to the inner loop (for Current Mode Control)
  • Id_ic_var :: Control current reference in the d-axis supplied from the inner loop control to the converter (for Generic Models)
  • Iq_ic_var :: Control current reference in the q-axis supplied from the inner loop control to the converter (for Generic Models)
  • Ir_cnv_var :: Control current reference in the R-axis supplied from the converter to the filter (for Generic Models)
  • Ii_cnv_var :: Control current reference in the I-axis supplied from the converter to the filter (for Generic Models)
  • ω_oc_var :: Control frequency supplied from the outer loop control the inner loop
  • θ_oc_var :: Variation of the angle (PLL or VSM) of the inverter
  • Vr_inv_var :: Real terminal voltage on the inverter
  • Vi_inv_var :: Imaginary terminal voltage on the inverter
  • Vr_cnv_var :: Voltage supplied from the converter in the R-component
  • Vi_cnv_var :: Voltage supplied from the converter in the I-component
  • P_ES_var :: Power supplied from the Energy Source side
source
PowerSimulationsDynamics._field_currentMethod

Function to obtain the field current time series of a Dynamic Generator. It is dispatched via the machine type. By default, machine does not have support for field current

source
PowerSimulationsDynamics._field_voltageMethod

Function to obtain the field voltage time series of a Dynamic Generator with avrs that have the field voltage as a state. By default it is assumed that the models have that state.

source
PowerSimulationsDynamics._frequencyMethod

Function to obtain the frequency time series of a virtual inertia grid forming inverter out of the DAE Solution. It is dispatched via the OuterControl type.

source
PowerSimulationsDynamics._frequencyMethod

Function to obtain the frequency time series of a grid-following inverter with KauraPLL out of the DAE Solution. It is dispatched via the OuterControl and FrequencyEstimator type.

source
PowerSimulationsDynamics._frequencyMethod

Function to obtain the frequency time series of a grid-following inverter with ReducedOrderPLL out of the DAE Solution. It is dispatched via the OuterControl and FrequencyEstimator type.

source
PowerSimulationsDynamics.compute_field_currentMethod

Function to obtain the field current time series of a Dynamic Generator model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage. It is dispatched for device type to compute the specific current.

source
PowerSimulationsDynamics.compute_field_currentMethod

Function to obtain the field current time series of a Dynamic Inverter model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage. It must return nothing since field current does not exists in inverters.

source
PowerSimulationsDynamics.compute_field_voltageMethod

Function to obtain the field voltage time series of a Dynamic Generator model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage. It is dispatched for device type to compute the specific voltage.

source
PowerSimulationsDynamics.compute_field_voltageMethod

Function to obtain the field current time series of a Dynamic Inverter model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage. It must return nothing since field voltage does not exists in inverters.

source
PowerSimulationsDynamics.compute_mechanical_torqueMethod

Function to obtain the mechanical torque time series of a Dynamic Generator model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage. It is dispatched for device type to compute the specific torque.

source
PowerSimulationsDynamics.compute_mechanical_torqueMethod

Function to obtain the mechanical torque time series of a Dynamic Inverter model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage. It must return nothing since mechanical torque is not used in inverters.

source
PowerSimulationsDynamics.compute_output_currentMethod

Function to obtain the output current time series of a PeriodicVariableSource model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage. It is dispatched for device type to compute the specific current. computeoutputcurrent(::SimulationResults, ::PeriodicVariableSource, ::Vector{Float64}, ::Vector{Float64}, ::Nothing)

source
PowerSimulationsDynamics.compute_output_currentMethod

Function to obtain the output current time series of a Dynamic Generator model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage. It is dispatched for device type to compute the specific current.

source
PowerSimulationsDynamics.compute_output_currentMethod

Function to obtain the output current time series of a Dynamic Inverter model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage. It is dispatched for device type to compute the specific current.

source
PowerSimulationsDynamics.compute_pss_outputMethod

Function to obtain the pss output time series of a Dynamic Generator model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage. It is dispatched for device type to compute the specific output.

source
PowerSimulationsDynamics.configure_loggingMethod
configure_logging(;
+Internal API Reference · PowerSimulationsDynamics.jl

Internal

PowerSimulationsDynamics.generator_inner_varsType

Generator Inner Vars:

  • τe_var :: Electric torque
  • τm_var :: Mechanical torque
  • Vf_var :: Field voltage
  • V_pss_var :: Additional PSS voltage
  • VR_gen_var :: Real part of the terminal voltage
  • VI_gen_var :: Imaginary part of the terminal voltage
  • ψd_var :: Stator Flux (if defined) in the d-axis
  • ψq_var :: Stator Flux (if defined) in the q-axis
source
PowerSimulationsDynamics.inverter_inner_varsType

Inverter Inner Vars:

  • md_var :: Modulation signal on the d-component
  • mq_var :: Modulation signal on the q-component
  • Vdc_var :: DC voltage supplied by the DC source
  • Vr_filter_var :: Voltage seen in the capacitor of the filter in the R-component
  • Vi_filter_var :: Voltage seen in the capacitor of the filter in the I-component
  • θ_freq_estimator_var :: Angle estimated by the frequency estimator.
  • ω_freq_estimator_var :: Frequency estimated by the frequency estimator.
  • V_oc_var :: Control voltage reference in the d-axis supplied from the outer loop control to the inner loop (for Voltage Mode Control)
  • Id_oc_var :: Control current reference in the d-axis supplied from the outer loop control to the inner loop (for Current Mode Control)
  • Iq_oc_var :: Control current reference in the q-axis supplied from the outer loop control to the inner loop (for Current Mode Control)
  • Id_ic_var :: Control current reference in the d-axis supplied from the inner loop control to the converter (for Generic Models)
  • Iq_ic_var :: Control current reference in the q-axis supplied from the inner loop control to the converter (for Generic Models)
  • Ir_cnv_var :: Control current reference in the R-axis supplied from the converter to the filter (for Generic Models)
  • Ii_cnv_var :: Control current reference in the I-axis supplied from the converter to the filter (for Generic Models)
  • ω_oc_var :: Control frequency supplied from the outer loop control the inner loop
  • θ_oc_var :: Variation of the angle (PLL or VSM) of the inverter
  • Vr_inv_var :: Real terminal voltage on the inverter
  • Vi_inv_var :: Imaginary terminal voltage on the inverter
  • Vr_cnv_var :: Voltage supplied from the converter in the R-component
  • Vi_cnv_var :: Voltage supplied from the converter in the I-component
  • P_ES_var :: Power supplied from the Energy Source side
source
PowerSimulationsDynamics._field_currentMethod

Function to obtain the field current time series of a Dynamic Generator. It is dispatched via the machine type. By default, machine does not have support for field current

source
PowerSimulationsDynamics._field_voltageMethod

Function to obtain the field voltage time series of a Dynamic Generator with avrs that have the field voltage as a state. By default it is assumed that the models have that state.

source
PowerSimulationsDynamics._frequencyMethod

Function to obtain the frequency time series of a virtual inertia grid forming inverter out of the DAE Solution. It is dispatched via the OuterControl type.

source
PowerSimulationsDynamics._frequencyMethod

Function to obtain the frequency time series of a grid-following inverter with KauraPLL out of the DAE Solution. It is dispatched via the OuterControl and FrequencyEstimator type.

source
PowerSimulationsDynamics._frequencyMethod

Function to obtain the frequency time series of a grid-following inverter with ReducedOrderPLL out of the DAE Solution. It is dispatched via the OuterControl and FrequencyEstimator type.

source
PowerSimulationsDynamics.compute_field_currentMethod

Function to obtain the field current time series of a Dynamic Generator model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage. It is dispatched for device type to compute the specific current.

source
PowerSimulationsDynamics.compute_field_currentMethod

Function to obtain the field current time series of a Dynamic Inverter model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage. It must return nothing since field current does not exists in inverters.

source
PowerSimulationsDynamics.compute_field_voltageMethod

Function to obtain the field voltage time series of a Dynamic Generator model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage. It is dispatched for device type to compute the specific voltage.

source
PowerSimulationsDynamics.compute_field_voltageMethod

Function to obtain the field current time series of a Dynamic Inverter model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage. It must return nothing since field voltage does not exists in inverters.

source
PowerSimulationsDynamics.compute_mechanical_torqueMethod

Function to obtain the mechanical torque time series of a Dynamic Generator model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage. It is dispatched for device type to compute the specific torque.

source
PowerSimulationsDynamics.compute_mechanical_torqueMethod

Function to obtain the mechanical torque time series of a Dynamic Inverter model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage. It must return nothing since mechanical torque is not used in inverters.

source
PowerSimulationsDynamics.compute_output_currentMethod

Function to obtain the output current time series of a PeriodicVariableSource model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage. It is dispatched for device type to compute the specific current. computeoutputcurrent(::SimulationResults, ::PeriodicVariableSource, ::Vector{Float64}, ::Vector{Float64}, ::Nothing)

source
PowerSimulationsDynamics.compute_output_currentMethod

Function to obtain the output current time series of a Dynamic Generator model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage. It is dispatched for device type to compute the specific current.

source
PowerSimulationsDynamics.compute_output_currentMethod

Function to obtain the output current time series of a Dynamic Inverter model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage. It is dispatched for device type to compute the specific current.

source
PowerSimulationsDynamics.compute_pss_outputMethod

Function to obtain the pss output time series of a Dynamic Generator model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage. It is dispatched for device type to compute the specific output.

source
PowerSimulationsDynamics.configure_loggingMethod
configure_logging(;
     console_level = Logging.Error,
     file_level = Logging.Info,
     filename = "power-simulations.log",
 )

Creates console and file loggers.

Note: Log messages may not be written to the file until flush() or close() is called on the returned logger.

Arguments

  • console_level = Logging.Error: level for console messages
  • file_level = Logging.Info: level for file messages
  • filename::String = power-simulations.log: log file

Example

logger = configure_logging(console_level = Logging.Info)
 @info "log message"
-close(logger)
source
PowerSimulationsDynamics.device!Method

Model of 12-state Active Constant Power Load in Julia. Based on the paper Malicious Control of an Active Load in an Islanded Mixed-Source Microgrid by C. Roberts, U. Markovic, D. Arnold and D. Callaway.

source
PowerSimulationsDynamics.device!Method

Model of 3-state (SimplifiedSingleCageInductionMachine) induction motor in Julia. Based on the 3rd order model derived in Prabha Kundur's Book and the equations in "Analysis of Electric Machinery and Drive Systems" by Paul Krause, Oleg Wasynczuk and Scott Sudhoff.

source
PowerSimulationsDynamics.device!Method

Model of 5-state (SingleCageInductionMachine) induction motor in Julia. Refer to "Analysis of Electric Machinery and Drive Systems" by Paul Krause, Oleg Wasynczuk and Scott Sudhoff for the equations

source
PowerSimulationsDynamics.mdl_zip_load!Method

Model for ZIP Load model given by:

Pzip = Ppower + Pcurrent * (V / V0) + Pimpedance * (V / V0)^2 Qzip = Qpower + Qcurrent * (V / V0) + Qimpedance * (V / V0)^2

with V = sqrt(Vr^2 + Vi^2) and V0 the voltage magnitude from the power flow solution

The current taken for the load is computed as: Izip = (Pzip + j Qzip)^* / (Vr + j Vi)^* Izip = (Pzip - j Qzip) / (Vr - j Vi)

For constant impedance it is obtained: Izre = (1 / V0)^2 * (Vr * Pimpedance + Vi * Qimpedance) Izim = (1 / V0)^2 * (Vi * Pimpedance - Vr * Qimpedance)

For constant current it is obtained: Iire = (1 / V0) * ( (Vr * Pcurrent + Vi * Qcurrent) / V ) Iiim = (1 / V0) * ( (Vi * Pcurrent - Vr * Qcurrent) / V )

For constant power it is obtained: Ipre = (Vr * Ppower + Vi * Qpower) / V^2 Ipim = (Vi * Ppower - Vr * Qpower) / V^2

Model for Exponential Load model given by:

Pexp = P0 * (V / V0)^α Qexp = Q0 * (V / V0)^β

The current taken for the load is computed as: Iexp = (Pexp + j Qexp)^* / (Vr + j Vi)^* Iexp = (Pexp - j Qexp) / (Vr - j Vi)

It results: Irexp = Vr * P0 * (V^(α - 2) / V0^α) + Vi * Q0 * (V^(β - 2)/ V0^β) Iiim = Vi * P0 * (V^(α - 2) / V0^α) - Vr * Q0 * (V^(β - 2)/ V0^β)

source
+close(logger)
source
PowerSimulationsDynamics.device!Method

Model of 12-state Active Constant Power Load in Julia. Based on the paper Malicious Control of an Active Load in an Islanded Mixed-Source Microgrid by C. Roberts, U. Markovic, D. Arnold and D. Callaway.

source
PowerSimulationsDynamics.device!Method

Model of 3-state (SimplifiedSingleCageInductionMachine) induction motor in Julia. Based on the 3rd order model derived in Prabha Kundur's Book and the equations in "Analysis of Electric Machinery and Drive Systems" by Paul Krause, Oleg Wasynczuk and Scott Sudhoff.

source
PowerSimulationsDynamics.device!Method

Model of 5-state (SingleCageInductionMachine) induction motor in Julia. Refer to "Analysis of Electric Machinery and Drive Systems" by Paul Krause, Oleg Wasynczuk and Scott Sudhoff for the equations

source
PowerSimulationsDynamics.mdl_zip_load!Method

Model for ZIP Load model given by:

Pzip = Ppower + Pcurrent * (V / V0) + Pimpedance * (V / V0)^2 Qzip = Qpower + Qcurrent * (V / V0) + Qimpedance * (V / V0)^2

with V = sqrt(Vr^2 + Vi^2) and V0 the voltage magnitude from the power flow solution

The current taken for the load is computed as: Izip = (Pzip + j Qzip)^* / (Vr + j Vi)^* Izip = (Pzip - j Qzip) / (Vr - j Vi)

For constant impedance it is obtained: Izre = (1 / V0)^2 * (Vr * Pimpedance + Vi * Qimpedance) Izim = (1 / V0)^2 * (Vi * Pimpedance - Vr * Qimpedance)

For constant current it is obtained: Iire = (1 / V0) * ( (Vr * Pcurrent + Vi * Qcurrent) / V ) Iiim = (1 / V0) * ( (Vi * Pcurrent - Vr * Qcurrent) / V )

For constant power it is obtained: Ipre = (Vr * Ppower + Vi * Qpower) / V^2 Ipim = (Vi * Ppower - Vr * Qpower) / V^2

Model for Exponential Load model given by:

Pexp = P0 * (V / V0)^α Qexp = Q0 * (V / V0)^β

The current taken for the load is computed as: Iexp = (Pexp + j Qexp)^* / (Vr + j Vi)^* Iexp = (Pexp - j Qexp) / (Vr - j Vi)

It results: Irexp = Vr * P0 * (V^(α - 2) / V0^α) + Vi * Q0 * (V^(β - 2)/ V0^β) Iiim = Vi * P0 * (V^(α - 2) / V0^α) - Vr * Q0 * (V^(β - 2)/ V0^β)

source
diff --git a/dev/api/public/index.html b/dev/api/public/index.html index 0d5c50e8a..5141e9f94 100644 --- a/dev/api/public/index.html +++ b/dev/api/public/index.html @@ -4,116 +4,116 @@ branch_type::Type{<:PSY.ACBranch} branch_name::String multiplier::Float64 -end

A BranchImpedanceChange change the impedance of a branch by a user defined multiplier. Currently there is only support for static branches disconnection, PowerSystems.Line and PowerSystems.Transformer2W. Future releases will provide support for a Dynamic Line disconnection.

Arguments:

source
PowerSimulationsDynamics.BranchTripType
mutable struct BranchTrip <: Perturbation
+end

A BranchImpedanceChange change the impedance of a branch by a user defined multiplier. Currently there is only support for static branches disconnection, PowerSystems.Line and PowerSystems.Transformer2W. Future releases will provide support for a Dynamic Line disconnection.

Arguments:

  • time::Float64 : Defines when the Branch Impedance Change will happen. This time should be inside the time span considered in the Simulation
  • branch_tipe::Type{<:PowerSystems.ACBranch} : Type of branch modified
  • branch_name::String : User defined name for identifying the branch
  • multiplier::Float64 : User defined value for impedance multiplier.
source
PowerSimulationsDynamics.BranchTripType
mutable struct BranchTrip <: Perturbation
     time::Float64
     branch_type::Type{<:PowerSystems.ACBranch}
     branch_name::String
-end

A BranchTrip completely disconnects a branch from the system. Currently there is only support for static branches disconnection, PowerSystems.Line and PowerSystems.Transformer2W. Future releases will provide support for a Dynamic Line disconnection. Note: Islanding is currently not supported in PowerSimulationsDynamics.jl. If a BranchTrip isolates a generation unit, the system may diverge due to the isolated generator.

Arguments:

  • time::Float64 : Defines when the Branch Trip will happen. This time should be inside the time span considered in the Simulation
  • branch_tipe::Type{<:PowerSystems.ACBranch} : Type of branch disconnected
  • branch_name::String : User defined name for identifying the branch
source
PowerSimulationsDynamics.ControlReferenceChangeType
mutable struct ControlReferenceChange <: Perturbation
+end

A BranchTrip completely disconnects a branch from the system. Currently there is only support for static branches disconnection, PowerSystems.Line and PowerSystems.Transformer2W. Future releases will provide support for a Dynamic Line disconnection. Note: Islanding is currently not supported in PowerSimulationsDynamics.jl. If a BranchTrip isolates a generation unit, the system may diverge due to the isolated generator.

Arguments:

  • time::Float64 : Defines when the Branch Trip will happen. This time should be inside the time span considered in the Simulation
  • branch_tipe::Type{<:PowerSystems.ACBranch} : Type of branch disconnected
  • branch_name::String : User defined name for identifying the branch
source
PowerSimulationsDynamics.ControlReferenceChangeType
mutable struct ControlReferenceChange <: Perturbation
     time::Float64
     device::PowerSystems.DynamicInjection
     signal::Symbol
     ref_value::Float64
-end

A ControlReferenceChange allows to change the reference setpoint provided by a generator/inverter.

Arguments:

  • time::Float64 : Defines when the Control Reference Change will happen. This time should be inside the time span considered in the Simulation
  • device::Type{<:PowerSystems.DynamicInjection} : Dynamic device modified
  • signal::Symbol : determines which reference setpoint will be modified. The accepted signals are:
    • :P_ref: Modifies the active power reference setpoint.
    • :V_ref: Modifies the voltage magnitude reference setpoint (if used).
    • :Q_ref: Modifies the reactive power reference setpoint (if used).
    • :ω_ref: Modifies the frequency setpoint.
  • ref_value::Float64 : User defined value for setpoint reference.
source
PowerSimulationsDynamics.GeneratorTripType
mutable struct GeneratorTrip <: Perturbation
+end

A ControlReferenceChange allows to change the reference setpoint provided by a generator/inverter.

Arguments:

  • time::Float64 : Defines when the Control Reference Change will happen. This time should be inside the time span considered in the Simulation
  • device::Type{<:PowerSystems.DynamicInjection} : Dynamic device modified
  • signal::Symbol : determines which reference setpoint will be modified. The accepted signals are:
    • :P_ref: Modifies the active power reference setpoint.
    • :V_ref: Modifies the voltage magnitude reference setpoint (if used).
    • :Q_ref: Modifies the reactive power reference setpoint (if used).
    • :ω_ref: Modifies the frequency setpoint.
  • ref_value::Float64 : User defined value for setpoint reference.
source
PowerSimulationsDynamics.GeneratorTripType
mutable struct GeneratorTrip <: Perturbation
     time::Float64
     device::PowerSystems.DynamicInjection
-end

A GeneratorTrip allows to disconnect a Dynamic Generation unit from the system at a specified time.

Arguments:

  • time::Float64 : Defines when the Generator Trip will happen. This time should be inside the time span considered in the Simulation
  • device::Type{<:PowerSystems.DynamicInjection} : Device to be disconnected
source
PowerSimulationsDynamics.LoadChangeType
mutable struct LoadChange <: Perturbation
+end

A GeneratorTrip allows to disconnect a Dynamic Generation unit from the system at a specified time.

Arguments:

  • time::Float64 : Defines when the Generator Trip will happen. This time should be inside the time span considered in the Simulation
  • device::Type{<:PowerSystems.DynamicInjection} : Device to be disconnected
source
PowerSimulationsDynamics.LoadChangeType
mutable struct LoadChange <: Perturbation
     time::Float64
     device::PowerSystems.ElectricLoad
     signal::Symbol
     ref_value::Float64
-end

A LoadChange allows to change the active or reactive power setpoint from a load.

Arguments:

  • time::Float64 : Defines when the Load Change will happen. This time should be inside the time span considered in the Simulation
  • device::Type{<:PowerSystems.ElectricLoad} : Dynamic device modified
  • signal::Symbol : determines which reference setpoint will be modified. The accepted signals are:
    • :P_ref: Modifies the active power reference setpoint.
    • :Q_ref: Modifies the reactive power reference setpoint.
  • ref_value::Float64 : User defined value for setpoint reference.
source
PowerSimulationsDynamics.LoadTripType
mutable struct LoadTrip <: Perturbation
+end

A LoadChange allows to change the active or reactive power setpoint from a load.

Arguments:

  • time::Float64 : Defines when the Load Change will happen. This time should be inside the time span considered in the Simulation
  • device::Type{<:PowerSystems.ElectricLoad} : Dynamic device modified
  • signal::Symbol : determines which reference setpoint will be modified. The accepted signals are:
    • :P_ref: Modifies the active power reference setpoint.
    • :Q_ref: Modifies the reactive power reference setpoint.
  • ref_value::Float64 : User defined value for setpoint reference.
source
PowerSimulationsDynamics.LoadTripType
mutable struct LoadTrip <: Perturbation
     time::Float64
     device::PowerSystems.ElectricLoad
-end

A LoadTrip allows the user to disconnect a load from the system.

Arguments:

  • time::Float64 : Defines when the Generator Trip will happen. This time should be inside the time span considered in the Simulation
  • device::Type{<:PowerSystems.ElectricLoad} : Device to be disconnected
source
PowerSimulationsDynamics.MassMatrixModelMethod

Instantiate a MassMatrixModel for ODE inputs.

source
PowerSimulationsDynamics.MassMatrixModelMethod

Instantiate a MassMatrixModel for ForwardDiff calculations

source
PowerSimulationsDynamics.NetworkSwitchType
function NetworkSwitch(
+end

A LoadTrip allows the user to disconnect a load from the system.

Arguments:

  • time::Float64 : Defines when the Generator Trip will happen. This time should be inside the time span considered in the Simulation
  • device::Type{<:PowerSystems.ElectricLoad} : Device to be disconnected
source
PowerSimulationsDynamics.MassMatrixModelMethod

Instantiate a MassMatrixModel for ODE inputs.

source
PowerSimulationsDynamics.MassMatrixModelMethod

Instantiate a MassMatrixModel for ForwardDiff calculations

source
PowerSimulationsDynamics.NetworkSwitchType
function NetworkSwitch(
     time::Float64,
     ybus::SparseArrays.SparseMatrixCSC{Complex{Float64}, Int},
-)

Allows to modify directly the admittance matrix, Ybus, used in the Simulation. This allows the user to perform branch modifications, three phase faults (with impedance larger than zero) or branch trips, as long as the new Ybus provided captures that perturbation.

Arguments:

  • time::Float64 : Defines when the Network Switch will happen. This time should be inside the time span considered in the Simulation
  • ybus::SparseArrays.SparseMatrixCSC{Complex{Float64}, Int} : Complex admittance matrix
source
PowerSimulationsDynamics.PerturbStateType
function PerturbState(
+)

Allows to modify directly the admittance matrix, Ybus, used in the Simulation. This allows the user to perform branch modifications, three phase faults (with impedance larger than zero) or branch trips, as long as the new Ybus provided captures that perturbation.

Arguments:

  • time::Float64 : Defines when the Network Switch will happen. This time should be inside the time span considered in the Simulation
  • ybus::SparseArrays.SparseMatrixCSC{Complex{Float64}, Int} : Complex admittance matrix
source
PowerSimulationsDynamics.PerturbStateType
function PerturbState(
     time::Float64,
     index::Int,
     value::Float64,
-)

Allows the user to modify the state index by adding value. The user should modify dynamic states only, since algebraic state may require to do a reinitialization.

Arguments:

  • time::Float64 : Defines when the modification of the state will happen. This time should be inside the time span considered in the Simulation.
  • index::Int : Defines which state index you want to modify
  • value::Float64 : Defines how much the state will increase in value
source
PowerSimulationsDynamics.ResidualModelMethod

Instantiate an ResidualModel for ODE inputs.

source
PowerSimulationsDynamics.ResidualModelMethod

Instantiate an ResidualModel for ForwardDiff calculations

source
PowerSimulationsDynamics.SimulationMethod
function Simulation
+)

Allows the user to modify the state index by adding value. The user should modify dynamic states only, since algebraic state may require to do a reinitialization.

Arguments:

  • time::Float64 : Defines when the modification of the state will happen. This time should be inside the time span considered in the Simulation.
  • index::Int : Defines which state index you want to modify
  • value::Float64 : Defines how much the state will increase in value
source
PowerSimulationsDynamics.ResidualModelMethod

Instantiate an ResidualModel for ODE inputs.

source
PowerSimulationsDynamics.ResidualModelMethod

Instantiate an ResidualModel for ForwardDiff calculations

source
PowerSimulationsDynamics.SimulationMethod
function Simulation
     ::SimulationModel
     system::PowerSystems.System
     simulation_folder::String
     tspan::NTuple{2, Float64},
     perturbations::Vector{<:Perturbation} = Vector{Perturbation}();
     kwargs...,
-end

Builds the simulation object and conducts the indexing process. The original system is not modified and a copy its created and stored in the Simulation.

Arguments:

  • ::SimulationModel : Type of Simulation Model. ResidualModel or MassMatrixModel. See Models Section for more details
  • system::PowerSystems.System : System data
  • simulation_folder::String : Folder directory
  • tspan::NTuple{2, Float64} : Time span for simulation
  • perturbations::Vector{<:Perturbation} : Vector of Perturbations for the Simulation. Default: No Perturbations
  • initialize_simulation::Bool : Runs the initialization routine. If false, simulation runs based on the operation point stored in System
  • initial_conditions::Vector{Float64} : Allows the user to pass a vector with the initial condition values desired in the simulation. If initialize_simulation = true, these values are used as a first guess and overwritten.
  • frequency_reference : Default ReferenceBus. Determines which frequency model is used for the network. Currently there are two options available:
    • ConstantFrequency assumes that the network frequency is 1.0 per unit at all times.
    • ReferenceBus will use the frequency state of a Dynamic Generator (rotor speed) or Dynamic Inverter (virtual speed) connected to the Reference Bus (defined in the Power Flow data) as the network frequency. If multiple devices are connected to such bus, the device with larger base power will be used as a reference. If a Voltage Source is connected to the Reference Bus, then a ConstantFrequency model will be used.
  • system_to_file::Bool : Default false. Serializes the initialized system
  • console_level::Logging : Default Logging.Warn. Sets the level of logging output to the console. Can be set to Logging.Error, Logging.Warn, Logging.Info or Logging.Debug
  • file_level::Logging : Default Logging.Info. Sets the level of logging output to file. Can be set to Logging.Error, Logging.Warn, Logging.Info or Logging.Debug
  • disable_timer_outputs::Bool : Default false. Allows the user to display timer information about the construction and initilization of the Simulation.
source
PowerSimulationsDynamics.SourceBusVoltageChangeType
mutable struct SourceBusVoltageChange <: Perturbation
+end

Builds the simulation object and conducts the indexing process. The original system is not modified and a copy its created and stored in the Simulation.

Arguments:

  • ::SimulationModel : Type of Simulation Model. ResidualModel or MassMatrixModel. See Models Section for more details
  • system::PowerSystems.System : System data
  • simulation_folder::String : Folder directory
  • tspan::NTuple{2, Float64} : Time span for simulation
  • perturbations::Vector{<:Perturbation} : Vector of Perturbations for the Simulation. Default: No Perturbations
  • initialize_simulation::Bool : Runs the initialization routine. If false, simulation runs based on the operation point stored in System
  • initial_conditions::Vector{Float64} : Allows the user to pass a vector with the initial condition values desired in the simulation. If initialize_simulation = true, these values are used as a first guess and overwritten.
  • frequency_reference : Default ReferenceBus. Determines which frequency model is used for the network. Currently there are two options available:
    • ConstantFrequency assumes that the network frequency is 1.0 per unit at all times.
    • ReferenceBus will use the frequency state of a Dynamic Generator (rotor speed) or Dynamic Inverter (virtual speed) connected to the Reference Bus (defined in the Power Flow data) as the network frequency. If multiple devices are connected to such bus, the device with larger base power will be used as a reference. If a Voltage Source is connected to the Reference Bus, then a ConstantFrequency model will be used.
  • system_to_file::Bool : Default false. Serializes the initialized system
  • console_level::Logging : Default Logging.Warn. Sets the level of logging output to the console. Can be set to Logging.Error, Logging.Warn, Logging.Info or Logging.Debug
  • file_level::Logging : Default Logging.Info. Sets the level of logging output to file. Can be set to Logging.Error, Logging.Warn, Logging.Info or Logging.Debug
  • disable_timer_outputs::Bool : Default false. Allows the user to display timer information about the construction and initilization of the Simulation.
source
PowerSimulationsDynamics.SourceBusVoltageChangeType
mutable struct SourceBusVoltageChange <: Perturbation
     time::Float64
     device::PSY.Source
     signal::Symbol
     ref_value::Float64
-end

A SourceBusVoltageChange allows to change the reference setpoint provided by a voltage source.

Arguments:

  • time::Float64 : Defines when the Control Reference Change will happen. This time should be inside the time span considered in the Simulation
  • device::Type{<:PowerSystems.Source} : Device modified
  • signal::Symbol : determines which reference setpoint will be modified. The accepted signals are:
    • :V_ref Modifies the internal voltage magnitude reference setpoint.
    • :θ_ref Modifies the internal voltage angle reference setpoint.
  • ref_value::Float64 : User defined value for setpoint reference.
source
PowerSimulationsDynamics.Simulation!Method
function Simulation!
+end

A SourceBusVoltageChange allows to change the reference setpoint provided by a voltage source.

Arguments:

  • time::Float64 : Defines when the Control Reference Change will happen. This time should be inside the time span considered in the Simulation
  • device::Type{<:PowerSystems.Source} : Device modified
  • signal::Symbol : determines which reference setpoint will be modified. The accepted signals are:
    • :V_ref Modifies the internal voltage magnitude reference setpoint.
    • :θ_ref Modifies the internal voltage angle reference setpoint.
  • ref_value::Float64 : User defined value for setpoint reference.
source
PowerSimulationsDynamics.Simulation!Method
function Simulation!
     ::SimulationModel
     system::PowerSystems.System
     simulation_folder::String
     tspan::NTuple{2, Float64},
     perturbations::Vector{<:Perturbation} = Vector{Perturbation}();
     kwargs...,
-end

Builds the simulation object and conducts the indexing process. The initial conditions are stored in the system.

Arguments:

  • ::SimulationModel : Type of Simulation Model. ResidualModel or MassMatrixModel. See Models Section for more details
  • system::PowerSystems.System : System data
  • simulation_folder::String : Folder directory
  • tspan::NTuple{2, Float64} : Time span for simulation
  • perturbations::Vector{<:Perturbation} : Vector of Perturbations for the Simulation. Default: No Perturbations
  • initialize_simulation::Bool : Runs the initialization routine. If false, simulation runs based on the operation point stored in System
  • initial_conditions::Vector{Float64} : Allows the user to pass a vector with the initial condition values desired in the simulation. If initialize_simulation = true, these values are used as a first guess and overwritten.
  • frequency_reference : Default ReferenceBus. Determines which frequency model is used for the network. Currently there are two options available:
    • ConstantFrequency assumes that the network frequency is 1.0 per unit at all times.
    • ReferenceBus will use the frequency state of a Dynamic Generator (rotor speed) or Dynamic Inverter (virtual speed) connected to the Reference Bus (defined in the Power Flow data) as the network frequency. If multiple devices are connected to such bus, the device with larger base power will be used as a reference. If a Voltage Source is connected to the Reference Bus, then a ConstantFrequency model will be used.
  • system_to_file::Bool : Default false. Serializes the initialized system
  • console_level::Logging : Default Logging.Warn. Sets the level of logging output to the console. Can be set to Logging.Error, Logging.Warn, Logging.Info or Logging.Debug
  • file_level::Logging : Default Logging.Info. Sets the level of logging output to file. Can be set to Logging.Error, Logging.Warn, Logging.Info or Logging.Debug
  • disable_timer_outputs::Bool : Default false. Allows the user to display timer information about the construction and initilization of the Simulation.
source
PowerSimulationsDynamics.execute!Method
execute!(
+end

Builds the simulation object and conducts the indexing process. The initial conditions are stored in the system.

Arguments:

  • ::SimulationModel : Type of Simulation Model. ResidualModel or MassMatrixModel. See Models Section for more details
  • system::PowerSystems.System : System data
  • simulation_folder::String : Folder directory
  • tspan::NTuple{2, Float64} : Time span for simulation
  • perturbations::Vector{<:Perturbation} : Vector of Perturbations for the Simulation. Default: No Perturbations
  • initialize_simulation::Bool : Runs the initialization routine. If false, simulation runs based on the operation point stored in System
  • initial_conditions::Vector{Float64} : Allows the user to pass a vector with the initial condition values desired in the simulation. If initialize_simulation = true, these values are used as a first guess and overwritten.
  • frequency_reference : Default ReferenceBus. Determines which frequency model is used for the network. Currently there are two options available:
    • ConstantFrequency assumes that the network frequency is 1.0 per unit at all times.
    • ReferenceBus will use the frequency state of a Dynamic Generator (rotor speed) or Dynamic Inverter (virtual speed) connected to the Reference Bus (defined in the Power Flow data) as the network frequency. If multiple devices are connected to such bus, the device with larger base power will be used as a reference. If a Voltage Source is connected to the Reference Bus, then a ConstantFrequency model will be used.
  • system_to_file::Bool : Default false. Serializes the initialized system
  • console_level::Logging : Default Logging.Warn. Sets the level of logging output to the console. Can be set to Logging.Error, Logging.Warn, Logging.Info or Logging.Debug
  • file_level::Logging : Default Logging.Info. Sets the level of logging output to file. Can be set to Logging.Error, Logging.Warn, Logging.Info or Logging.Debug
  • disable_timer_outputs::Bool : Default false. Allows the user to display timer information about the construction and initilization of the Simulation.
source
PowerSimulationsDynamics.execute!Method
execute!(
     sim::Simulation,
     solver;
     kwargs...
-)

Solves the time-domain dynamic simulation model.

Arguments

  • sim::Simulation : Initialized simulation object
  • solver : Solver used for numerical integration. Must be passed correctly depending on the Type of Simulation Model
  • enable_progress_bar::Bool : Default: true. Enables progress bar for the integration routine.
  • Additional solver keyword arguments can be included. See Common Solver Options in the DifferentialEquations.jl documentation for more details.
source
PowerSimulationsDynamics.get_activepower_branch_flowMethod
get_activepower_branch_flow(
+)

Solves the time-domain dynamic simulation model.

Arguments

  • sim::Simulation : Initialized simulation object
  • solver : Solver used for numerical integration. Must be passed correctly depending on the Type of Simulation Model
  • enable_progress_bar::Bool : Default: true. Enables progress bar for the integration routine.
  • Additional solver keyword arguments can be included. See Common Solver Options in the DifferentialEquations.jl documentation for more details.
source
PowerSimulationsDynamics.get_activepower_branch_flowMethod
get_activepower_branch_flow(
         res::SimulationResults,
         name::String,
         location::Symbol,
-)

Function to obtain the active power flowing through the series element of a Branch. The user must specified is the power should be computed in the :from or to :bus, by specifying a symbol.

If :from is specified, the power is computed flowing outwards the :from bus. If :to is specified, the power is computed flowing into the :to bus.

Arguments

  • res::SimulationResults : Simulation Results object that contains the solution
  • name::String : Name to identify the specified line
  • location::Symbol : :from or :to to specify a bus
source
PowerSimulationsDynamics.get_activepower_seriesMethod
get_activepower_series(
+)

Function to obtain the active power flowing through the series element of a Branch. The user must specified is the power should be computed in the :from or to :bus, by specifying a symbol.

If :from is specified, the power is computed flowing outwards the :from bus. If :to is specified, the power is computed flowing into the :to bus.

Arguments

  • res::SimulationResults : Simulation Results object that contains the solution
  • name::String : Name to identify the specified line
  • location::Symbol : :from or :to to specify a bus
source
PowerSimulationsDynamics.get_activepower_seriesMethod
get_activepower_series(
         res::SimulationResults,
         name::String,
-)

Function to obtain the active power output time series of a Dynamic Injection series out of the DAE Solution.

Arguments

  • res::SimulationResults : Simulation Results object that contains the solution
  • name::String : Name to identify the specified device
source
PowerSimulationsDynamics.get_field_current_seriesMethod
get_field_current_series(
+)

Function to obtain the active power output time series of a Dynamic Injection series out of the DAE Solution.

Arguments

  • res::SimulationResults : Simulation Results object that contains the solution
  • name::String : Name to identify the specified device
source
PowerSimulationsDynamics.get_field_current_seriesMethod
get_field_current_series(
         res::SimulationResults,
         name::String,
-)

Function to obtain the field current time series of a Dynamic Generator out of the DAE Solution.

Arguments

  • res::SimulationResults : Simulation Results object that contains the solution
  • name::String : Name to identify the specified device
source
PowerSimulationsDynamics.get_field_voltage_seriesMethod
get_field_voltage_series(
+)

Function to obtain the field current time series of a Dynamic Generator out of the DAE Solution.

Arguments

  • res::SimulationResults : Simulation Results object that contains the solution
  • name::String : Name to identify the specified device
source
PowerSimulationsDynamics.get_field_voltage_seriesMethod
get_field_voltage_series(
         res::SimulationResults,
         name::String,
-)

Function to obtain the field voltage time series of a Dynamic Generator out of the DAE Solution.

Arguments

  • res::SimulationResults : Simulation Results object that contains the solution
  • name::String : Name to identify the specified device
source
PowerSimulationsDynamics.get_frequency_seriesMethod
get_frequency_series(
+)

Function to obtain the field voltage time series of a Dynamic Generator out of the DAE Solution.

Arguments

  • res::SimulationResults : Simulation Results object that contains the solution
  • name::String : Name to identify the specified device
source
PowerSimulationsDynamics.get_frequency_seriesMethod
get_frequency_series(
         res::SimulationResults,
         name::String,
-)

Function to obtain the frequency time series of a Dynamic Injection out of the DAE Solution.

Arguments

  • res::SimulationResults : Simulation Results object that contains the solution
  • name::String : Name to identify the specified device
source
PowerSimulationsDynamics.get_imaginary_current_branch_flowMethod
get_imaginary_current_branch_flow(
+)

Function to obtain the frequency time series of a Dynamic Injection out of the DAE Solution.

Arguments

  • res::SimulationResults : Simulation Results object that contains the solution
  • name::String : Name to identify the specified device
source
PowerSimulationsDynamics.get_imaginary_current_branch_flowMethod
get_imaginary_current_branch_flow(
         res::SimulationResults,
         name::String,
-)

Function to obtain the imaginary current flowing through the series element of a Branch

Arguments

  • res::SimulationResults : Simulation Results object that contains the solution
  • name::String : Name to identify the specified line
source
PowerSimulationsDynamics.get_imaginary_current_seriesMethod
get_imaginary_current_series(
+)

Function to obtain the imaginary current flowing through the series element of a Branch

Arguments

  • res::SimulationResults : Simulation Results object that contains the solution
  • name::String : Name to identify the specified line
source
PowerSimulationsDynamics.get_imaginary_current_seriesMethod
get_imaginary_current_series(
         res::SimulationResults,
         name::String,
-)

Function to obtain the imaginary current time series of a Dynamic Injection series out of the DAE Solution.

Arguments

  • res::SimulationResults : Simulation Results object that contains the solution
  • name::String : Name to identify the specified device
source
PowerSimulationsDynamics.get_jacobianMethod
function get_jacobian(
+)

Function to obtain the imaginary current time series of a Dynamic Injection series out of the DAE Solution.

Arguments

  • res::SimulationResults : Simulation Results object that contains the solution
  • name::String : Name to identify the specified device
source
PowerSimulationsDynamics.get_jacobianMethod
function get_jacobian(
 ::Type{T},
 system::PSY.System,
 sparse_retrieve_loop::Int = 3,
-) where {T <: SimulationModel}

Returns the jacobian function of the system model resulting from the system data.

Arguments:

  • ::SimulationModel : Type of Simulation Model. ResidualModel or MassMatrixModel. See Models Section for more details
  • system::PowerSystems.System : System data
  • sparse_retrieve_loop::Int : Number of loops for sparsity detection. If 0, builds the Jacobian with a DenseMatrix
source
PowerSimulationsDynamics.get_mechanical_torque_seriesMethod
get_mechanical_torque_series(
+) where {T <: SimulationModel}

Returns the jacobian function of the system model resulting from the system data.

Arguments:

  • ::SimulationModel : Type of Simulation Model. ResidualModel or MassMatrixModel. See Models Section for more details
  • system::PowerSystems.System : System data
  • sparse_retrieve_loop::Int : Number of loops for sparsity detection. If 0, builds the Jacobian with a DenseMatrix
source
PowerSimulationsDynamics.get_mechanical_torque_seriesMethod
get_mechanical_torque_series(
         res::SimulationResults,
         name::String,
-)

Function to obtain the mechanical torque time series of the mechanical torque out of the DAE Solution.

Arguments

  • res::SimulationResults : Simulation Results object that contains the solution
  • name::String : Name to identify the specified device
source
PowerSimulationsDynamics.get_pss_output_seriesMethod
get_pss_output_series(
+)

Function to obtain the mechanical torque time series of the mechanical torque out of the DAE Solution.

Arguments

  • res::SimulationResults : Simulation Results object that contains the solution
  • name::String : Name to identify the specified device
source
PowerSimulationsDynamics.get_pss_output_seriesMethod
get_pss_output_series(
         res::SimulationResults,
         name::String,
-)

Function to obtain the pss output time series of a Dynamic Generator out of the DAE Solution.

Arguments

  • res::SimulationResults : Simulation Results object that contains the solution
  • name::String : Name to identify the specified device
source
PowerSimulationsDynamics.get_reactivepower_branch_flowMethod
get_reactivepower_branch_flow(
+)

Function to obtain the pss output time series of a Dynamic Generator out of the DAE Solution.

Arguments

  • res::SimulationResults : Simulation Results object that contains the solution
  • name::String : Name to identify the specified device
source
PowerSimulationsDynamics.get_reactivepower_branch_flowMethod
get_reactivepower_branch_flow(
         res::SimulationResults,
         name::String,
         location::Symbol,
-)

Function to obtain the reactive power flowing through the series element of a Branch. The user must specified is the power should be computed in the :from or to :bus, by specifying a symbol.

If :from is specified, the power is computed flowing outwards the :from bus. If :to is specified, the power is computed flowing into the :to bus.

Arguments

  • res::SimulationResults : Simulation Results object that contains the solution
  • name::String : Name to identify the specified line
  • location::Symbol : :from or :to to specify a bus
source
PowerSimulationsDynamics.get_reactivepower_seriesMethod
get_reactivepower_series(
+)

Function to obtain the reactive power flowing through the series element of a Branch. The user must specified is the power should be computed in the :from or to :bus, by specifying a symbol.

If :from is specified, the power is computed flowing outwards the :from bus. If :to is specified, the power is computed flowing into the :to bus.

Arguments

  • res::SimulationResults : Simulation Results object that contains the solution
  • name::String : Name to identify the specified line
  • location::Symbol : :from or :to to specify a bus
source
PowerSimulationsDynamics.get_reactivepower_seriesMethod
get_reactivepower_series(
         res::SimulationResults,
         name::String,
-)

Function to obtain the reactive power output time series of a Dynamic Injection series out of the DAE Solution.

Arguments

  • res::SimulationResults : Simulation Results object that contains the solution
  • name::String : Name to identify the specified device
source
PowerSimulationsDynamics.get_real_current_branch_flowMethod
get_real_current_branch_flow(
+)

Function to obtain the reactive power output time series of a Dynamic Injection series out of the DAE Solution.

Arguments

  • res::SimulationResults : Simulation Results object that contains the solution
  • name::String : Name to identify the specified device
source
PowerSimulationsDynamics.get_real_current_branch_flowMethod
get_real_current_branch_flow(
         res::SimulationResults,
         name::String,
-)

Function to obtain the real current flowing through the series element of a Branch

Arguments

  • res::SimulationResults : Simulation Results object that contains the solution
  • name::String : Name to identify the specified line
source
PowerSimulationsDynamics.get_real_current_seriesMethod
get_real_current_series(
+)

Function to obtain the real current flowing through the series element of a Branch

Arguments

  • res::SimulationResults : Simulation Results object that contains the solution
  • name::String : Name to identify the specified line
source
PowerSimulationsDynamics.get_real_current_seriesMethod
get_real_current_series(
         res::SimulationResults,
         name::String,
-)

Function to obtain the real current time series of a Dynamic Injection series out of the DAE Solution.

Arguments

  • res::SimulationResults : Simulation Results object that contains the solution
  • name::String : Name to identify the specified device
source
PowerSimulationsDynamics.get_setpointsMethod
get_setpoints(sim::Simulation)

Function that returns the reference setpoints for all the dynamic devices.

Arguments

  • sim::Simulation : Simulation object that contains the initial condition and setpoints.
source
PowerSimulationsDynamics.get_source_imaginary_current_seriesFunction

Function to obtain output imaginary current for a source. It receives the simulation results, the Source name and an optional argument of the time step of the results.

source
PowerSimulationsDynamics.get_source_real_current_seriesFunction

Function to obtain output real current for a source. It receives the simulation results, the Source name and an optional argument of the time step of the results.

source
PowerSimulationsDynamics.get_state_seriesMethod
get_state_series(
+)

Function to obtain the real current time series of a Dynamic Injection series out of the DAE Solution.

Arguments

  • res::SimulationResults : Simulation Results object that contains the solution
  • name::String : Name to identify the specified device
source
PowerSimulationsDynamics.get_setpointsMethod
get_setpoints(sim::Simulation)

Function that returns the reference setpoints for all the dynamic devices.

Arguments

  • sim::Simulation : Simulation object that contains the initial condition and setpoints.
source
PowerSimulationsDynamics.get_source_imaginary_current_seriesFunction

Function to obtain output imaginary current for a source. It receives the simulation results, the Source name and an optional argument of the time step of the results.

source
PowerSimulationsDynamics.get_source_real_current_seriesFunction

Function to obtain output real current for a source. It receives the simulation results, the Source name and an optional argument of the time step of the results.

source
PowerSimulationsDynamics.get_state_seriesMethod
get_state_series(
     res::SimulationResults,
     ref::Tuple{String, Symbol};
     dt::Union{Nothing, Float64, Vector{Float64}} = nothing
 )
-end

Function to obtain series of states out of DAE Solution.

Arguments

  • res::SimulationResults : Simulation Results object that contains the solution
  • ref:Tuple{String, Symbol} : Tuple used to identify the dynamic device, via its name, as a String, and the associated state as a Symbol.
source
PowerSimulationsDynamics.get_voltage_angle_seriesMethod
get_voltage_angle_series(
+end

Function to obtain series of states out of DAE Solution.

Arguments

  • res::SimulationResults : Simulation Results object that contains the solution
  • ref:Tuple{String, Symbol} : Tuple used to identify the dynamic device, via its name, as a String, and the associated state as a Symbol.
source
PowerSimulationsDynamics.get_voltage_angle_seriesMethod
get_voltage_angle_series(
     res::SimulationResults,
     bus_number::Int
-)

Function to obtain the voltage angle series out of the DAE Solution.

Arguments

  • res::SimulationResults : Simulation Results object that contains the solution
  • bus_number::Int : Bus number identifier
source
PowerSimulationsDynamics.get_voltage_magnitude_seriesMethod
get_voltage_magnitude_series(
+)

Function to obtain the voltage angle series out of the DAE Solution.

Arguments

  • res::SimulationResults : Simulation Results object that contains the solution
  • bus_number::Int : Bus number identifier
source
PowerSimulationsDynamics.get_voltage_magnitude_seriesMethod
get_voltage_magnitude_series(
     res::SimulationResults,
     bus_number::Int
-)

Function to obtain the voltage magnitude series out of the DAE Solution.

Arguments:

  • res::SimulationResults : Simulation Results object that contains the solution
  • bus_number::Int : Bus number identifier
source
PowerSimulationsDynamics.read_initial_conditionsMethod

Returns a Dictionary with the resulting initial conditions of the simulation

source
PowerSimulationsDynamics.show_states_initial_valueMethod
show_states_initial_value(res::SimulationResults)

Function to print initial states.

Arguments

  • res::SimulationResults : Simulation Results object that contains the solution
source
PowerSimulationsDynamics.show_states_initial_valueMethod
show_states_initial_value(sim::Simulation)

Function to print initial states.

Arguments

  • sim::Simulation : Simulation object that contains the initial condition
source
PowerSimulationsDynamics.small_signal_analysisMethod
small_signal_analysis(
+)

Function to obtain the voltage magnitude series out of the DAE Solution.

Arguments:

  • res::SimulationResults : Simulation Results object that contains the solution
  • bus_number::Int : Bus number identifier
source
PowerSimulationsDynamics.read_initial_conditionsMethod

Returns a Dictionary with the resulting initial conditions of the simulation

source
PowerSimulationsDynamics.show_states_initial_valueMethod
show_states_initial_value(res::SimulationResults)

Function to print initial states.

Arguments

  • res::SimulationResults : Simulation Results object that contains the solution
source
PowerSimulationsDynamics.show_states_initial_valueMethod
show_states_initial_value(sim::Simulation)

Function to print initial states.

Arguments

  • sim::Simulation : Simulation object that contains the initial condition
source
PowerSimulationsDynamics.small_signal_analysisMethod
small_signal_analysis(
         sim::Simulation,
-)

Returns the Small Signal Output object that contains the eigenvalues and participation factors.

Arguments

  • sim::Simulation : Small Signal Output object that contains the eigenvalues and participation factors
source
PowerSimulationsDynamics.summary_eigenvaluesMethod
summary_eigenvalues(
+)

Returns the Small Signal Output object that contains the eigenvalues and participation factors.

Arguments

  • sim::Simulation : Small Signal Output object that contains the eigenvalues and participation factors
source
PowerSimulationsDynamics.summary_eigenvaluesMethod
summary_eigenvalues(
         sm::SmallSignalOutput,
-)

Function to obtain a summary of the eigenvalues of the Jacobian at the operating point. It returns a DataFrame with the most associated state for each eigenvalue, its real and imaginary part, damping and frequency.

Arguments

  • sm::SmallSignalOutput : Small Signal Output object that contains the eigenvalues and participation factors
source
PowerSimulationsDynamics.summary_participation_factorsMethod
summary_participation_factors(
+)

Function to obtain a summary of the eigenvalues of the Jacobian at the operating point. It returns a DataFrame with the most associated state for each eigenvalue, its real and imaginary part, damping and frequency.

Arguments

  • sm::SmallSignalOutput : Small Signal Output object that contains the eigenvalues and participation factors
source
PowerSimulationsDynamics.summary_participation_factorsMethod
summary_participation_factors(
         sm::SmallSignalOutput,
-)

Function to obtain the participation factor of each state to each eigenvalue. It returns a DataFrame with the participation factors of each state to all eigenvalues.

Arguments

  • sm::SmallSignalOutput : Small Signal Output object that contains the eigenvalues and participation factors
source
+)

Function to obtain the participation factor of each state to each eigenvalue. It returns a DataFrame with the participation factors of each state to all eigenvalues.

Arguments

source diff --git a/dev/code_base_developer_guide/developer/index.html b/dev/code_base_developer_guide/developer/index.html index 98ff43465..5075bad79 100644 --- a/dev/code_base_developer_guide/developer/index.html +++ b/dev/code_base_developer_guide/developer/index.html @@ -1,2 +1,2 @@ -Developer Guide · PowerSimulationsDynamics.jl
+Developer Guide · PowerSimulationsDynamics.jl
diff --git a/dev/component_models/avr/index.html b/dev/component_models/avr/index.html index 51f2a7f01..335860a2c 100644 --- a/dev/component_models/avr/index.html +++ b/dev/component_models/avr/index.html @@ -72,4 +72,4 @@ \sqrt{0.75 - I_N^2} & \text{ if } 0.433 < I_N \le 0.75 \\ 1.732(1-I_N) & \text{ if } 0.75 < I_N \le 1 \\ 0 & \text{ if } I_N > 1 \end{array} \right. -\end{align*}\]

on which $X_{ad}I_{fd}$ is the field current coming from the generator and $V_{h}$ is the terminal voltage, and $A,B$ are the saturation coefficients computed using the $E_1, E_2, S_e(E_1), S_e(E_2)$ data.

+\end{align*}\]

on which $X_{ad}I_{fd}$ is the field current coming from the generator and $V_{h}$ is the terminal voltage, and $A,B$ are the saturation coefficients computed using the $E_1, E_2, S_e(E_1), S_e(E_2)$ data.

diff --git a/dev/component_models/converter/index.html b/dev/component_models/converter/index.html index a2d959653..bba983b1d 100644 --- a/dev/component_models/converter/index.html +++ b/dev/component_models/converter/index.html @@ -22,4 +22,4 @@ Z_{sorce} &= R_{sorce} + jX_{sorce} \\ I_{cv} &= I_r + jI_i \\ v_r^\text{cv} + jv_i^\text{cv} &= \frac{I_{cv} + \frac{v^\text{grid}}{Z_f}}{\frac{1}{Z_{sorce}} + \frac{1}{Z_f}} \tag{2i} -\end{align*}\]

+\end{align*}\]

diff --git a/dev/component_models/dc_source/index.html b/dev/component_models/dc_source/index.html index 403cdcc8d..f9547c6cc 100644 --- a/dev/component_models/dc_source/index.html +++ b/dev/component_models/dc_source/index.html @@ -1,2 +1,2 @@ -DC Sources · PowerSimulationsDynamics.jl

DC Source

This component can be used to model the dynamics of the DC side of the converter.

Fixed DC Source [FixedDCSource]

This is a model that set the DC voltage to a fixed value $v_{\text{dc}} = v_{\text{dc}}^{\text{fix}}$.

+DC Sources · PowerSimulationsDynamics.jl

DC Source

This component can be used to model the dynamics of the DC side of the converter.

Fixed DC Source [FixedDCSource]

This is a model that set the DC voltage to a fixed value $v_{\text{dc}} = v_{\text{dc}}^{\text{fix}}$.

diff --git a/dev/component_models/filters/index.html b/dev/component_models/filters/index.html index 5fdf4468b..fa9c91875 100644 --- a/dev/component_models/filters/index.html +++ b/dev/component_models/filters/index.html @@ -10,4 +10,4 @@ v_r^\text{cv} + jv_i^\text{cv} = (v_d^\text{cv} + jv_q^\text{cv})e^{j\delta\theta_{olc}} \end{align*}\]

that comes from the converter model.

RL Filter [RLFilter]

The algebraic RL filter is used to connect the output of the converter through a RL series filter using algebraic phasor equations. The equations for the output current are:

\[\begin{align} i_r + ji_i &= \frac{(v_r^\text{cv} + j v_i^\text{cv}) - (v_r^\text{grid} + jv_i^\text{grid})}{r_f + jl_f} \tag{2a} -\end{align}\]

on which $v_r^\text{cv} + jv_i^\text{cv}$ comes from the converter model.

+\end{align}\]

on which $v_r^\text{cv} + jv_i^\text{cv}$ comes from the converter model.

diff --git a/dev/component_models/freq_esti/index.html b/dev/component_models/freq_esti/index.html index 0ab876f07..8a33d18ec 100644 --- a/dev/component_models/freq_esti/index.html +++ b/dev/component_models/freq_esti/index.html @@ -17,4 +17,4 @@ \delta\omega_{\text{pll}} &= 1.0 - \omega_{\text{sys}} + k_{p,\text{pll}} v_{q,\text{pll}} + k_{i,\text{pll}} \varepsilon_{\text{pll}} \tag{2d} \\ \omega_{\text{pll}} &= \delta\omega_{\text{pll}} + \omega_{\text{sys}} \tag{2e} \\ v_{d,\text{out}} + jv_{q,\text{out}} &= (v_r + jv_i)e^{-\delta\theta_\text{pll}} \tag{2f} -\end{align}\]

on which $v_r + jv_i$ is the voltage in the grid reference frame on which the PLL is measuring (i.e. point of common coupling), that could be in the capacitor of an LCL filter or the last branch of such filter.

+\end{align}\]

on which $v_r + jv_i$ is the voltage in the grid reference frame on which the PLL is measuring (i.e. point of common coupling), that could be in the capacitor of an LCL filter or the last branch of such filter.

diff --git a/dev/component_models/inner_control/index.html b/dev/component_models/inner_control/index.html index 9d4887523..069b20caf 100644 --- a/dev/component_models/inner_control/index.html +++ b/dev/component_models/inner_control/index.html @@ -41,4 +41,4 @@ I_\text{pcmd} &= I_\text{oc, pcmd} \tag{3i} \\ I_\text{qcmd} &= I_{icv} + I_\text{qinj} \tag{3j} \\ I_{\text{qinj}} &= K_{qv} (V_\text{ref0} - V_\text{t,flt}) \tag{3k} -\end{align}\]

+\end{align}\]

diff --git a/dev/component_models/loads/index.html b/dev/component_models/loads/index.html index 83b4d5ab5..c53aaa54f 100644 --- a/dev/component_models/loads/index.html +++ b/dev/component_models/loads/index.html @@ -72,4 +72,4 @@ \dot{\gamma}_q &= i_\text{cv}^q - i_\text{cv}^{q,\star} \tag{4h} \\ v_\text{cv}^{d,\star} &= k_\text{pc}( i_\text{cv}^d - i_\text{cv}^{d,\star}) + k_\text{ic} \gamma_d + \omega_\text{pll} l_f i_\text{cv}^q \tag{4i}\\ v_\text{cv}^{q,\star} &= k_\text{pc}( i_\text{cv}^q - i_\text{cv}^{q,\star}) + k_\text{ic} \gamma_q - \omega_\text{pll} l_f i_\text{cv}^d \tag{4j} -\end{align}\]

Equations (4a)–(4c) describes the PLL dynamics to lock the active load to the grid. Equations (4d)-(4e) describes the DC Voltage Controller to steer the DC voltage to $v_\text{DC}^\star$, while equation (4f) describes the DC voltage dynamics at the capacitor assuming an ideal converter. Finally, equations (4g)–(4j) describes the dynamics of the AC Current Controller. Additionally six states are defined for the LCL filter in a similar fashion of GFM inverters.

+\end{align}\]

Equations (4a)–(4c) describes the PLL dynamics to lock the active load to the grid. Equations (4d)-(4e) describes the DC Voltage Controller to steer the DC voltage to $v_\text{DC}^\star$, while equation (4f) describes the DC voltage dynamics at the capacitor assuming an ideal converter. Finally, equations (4g)–(4j) describes the dynamics of the AC Current Controller. Additionally six states are defined for the LCL filter in a similar fashion of GFM inverters.

diff --git a/dev/component_models/machines/index.html b/dev/component_models/machines/index.html index 7a0d38b41..82fb4b671 100644 --- a/dev/component_models/machines/index.html +++ b/dev/component_models/machines/index.html @@ -100,4 +100,4 @@ \gamma_{q1} &= \frac{x_q'' - x_l}{x_q' - x_l} \\ \gamma_{d2} &= \frac{1 - \gamma_d1}{x_d' - x_l} \\ \gamma_{q2} &= \frac{1 - \gamma_q1}{x_q' - x_l} -\end{align*}\]

+\end{align*}\]

diff --git a/dev/component_models/network/index.html b/dev/component_models/network/index.html index b803ae250..fa68bd024 100644 --- a/dev/component_models/network/index.html +++ b/dev/component_models/network/index.html @@ -10,4 +10,4 @@ \frac{l}{\Omega_b} \frac{d\boldsymbol{i}_{\ell}}{dt} &= (\boldsymbol{v}_n - \boldsymbol{v}_m) - (r+jl) \boldsymbol{i}_{\ell} \\ \frac{c_n}{\Omega_b} \frac{d\boldsymbol{v}_n}{dt} &= \boldsymbol{i}_n^{\text{cap}} - jc_n\boldsymbol{v}_n \\ \frac{c_m}{\Omega_b} \frac{d\boldsymbol{v}_m}{dt} &= \boldsymbol{i}_m^{\text{cap}} - jc_m\boldsymbol{v}_m -\end{align}\]

Since all the values are in per unit, the reactance is equal to the inductance.

A detail discussion about the effects of different line models in the modeling of inverters is presented in Grid Forming Inverter Small Signal Stability: Examining Role of Line and Voltage Dynamics

+\end{align}\]

Since all the values are in per unit, the reactance is equal to the inductance.

A detail discussion about the effects of different line models in the modeling of inverters is presented in Grid Forming Inverter Small Signal Stability: Examining Role of Line and Voltage Dynamics

diff --git a/dev/component_models/outer_control/index.html b/dev/component_models/outer_control/index.html index 7e40cec81..d587aee4d 100644 --- a/dev/component_models/outer_control/index.html +++ b/dev/component_models/outer_control/index.html @@ -66,4 +66,4 @@ \dot{q}_\text{flt} &= \frac{1}{T_\text{fltr}} (q_e - q_\text{flt}) \tag{5t} \\ \dot{\xi}_\text{q,oc} &= q_\text{err} \tag{5u} \\ \dot{q}_{LL} &= \frac{1}{T_{fv}}(Q_\text{pi} ( 1 - T_{ft}/T_{fv}) - q_{LL}) \tag{5v} \\ -\end{align}\]

The remaining models for other flags will be included when implemented in PowerSimulationsDynamics.jl.

+\end{align}\]

The remaining models for other flags will be included when implemented in PowerSimulationsDynamics.jl.

diff --git a/dev/component_models/pss/index.html b/dev/component_models/pss/index.html index 196fdceb6..5a327b609 100644 --- a/dev/component_models/pss/index.html +++ b/dev/component_models/pss/index.html @@ -23,4 +23,4 @@ y_{LL} = x_2 + \frac{T_1}{T_3} x_1 \\ y_{out} = x_3 + \frac{T_2}{T_4} y_{LL} \\ V_s = \text{clamp}(y_{out}, -H_{lim}, H_{lim}) -\end{align*}\]

+\end{align*}\]

diff --git a/dev/component_models/shafts/index.html b/dev/component_models/shafts/index.html index 97fb9d781..2945eb973 100644 --- a/dev/component_models/shafts/index.html +++ b/dev/component_models/shafts/index.html @@ -13,4 +13,4 @@ \dot{\omega}_{lp} &= \frac{1}{2H_{lp}} \left[ - D_{lp}(\omega_{lp}-\omega_s) - D_{23}(\omega_{lp} - \omega_{ip}) -D_{34}(\omega_{lp} - \omega ) + K_{ip}(\delta_{ip} - \delta_{lp}) + K_{lp}(\delta-\delta_{lp}) \right] \tag{2h} \\ \dot{\delta}_{ex} &= \Omega_b(\omega_{ex}-\omega_s) \tag{2i} \\ \dot{\omega}_{ex} &= \frac{1}{2H_{ex}} \left[ - D_{ex}(\omega_{ex}-\omega_s) - D_{45}(\omega_{ex} - \omega) + K_{ex}(\delta - \delta_{ex}) \right] \tag{2j} -\end{align}\]

+\end{align}\]

diff --git a/dev/component_models/turbine_gov/index.html b/dev/component_models/turbine_gov/index.html index ea5462221..f0177fc83 100644 --- a/dev/component_models/turbine_gov/index.html +++ b/dev/component_models/turbine_gov/index.html @@ -42,4 +42,4 @@ c &= \frac{x_{g1}}{r} + \frac{x_{g2}}{rT_r} \tag{5f} \\ h &= \left(\frac{x_{g4}}{x_{g3}}\right)^2 \tag{5g}\\ \tau_m &= h\cdot A_t(x_{g4} - q_{NL}) - D_{turb} \Delta\omega \cdot x_{g3} \tag{5h} -\end{align}\]

+\end{align}\]

diff --git a/dev/execute/index.html b/dev/execute/index.html index 2f4b60d71..1bcf6523b 100644 --- a/dev/execute/index.html +++ b/dev/execute/index.html @@ -15,4 +15,4 @@ (0.0, 20.0), perturbation, ) -execute!(sim2, Rodas4())

Exploring the Solution

Once a Simulation is executed and the results are stored via results = read_results(sim), the following functions can be used to explore the Simulation solution:

Show initial conditions

The function show_states_initial_value(results) can be used to display the initial condition of the voltages and dynamic states of each dynamic component.

Explore bus voltages

The function get_voltage_magnitude_series(results, BusNumber) can be used to obtain the voltage magnitude time series of the specified bus. Similarly, get_voltage_angle_series(results, BusNumber) can be used to obtain the voltage angle time series of the specified bus.

Explore output currents

The functions get_real_current_series(results, "DeviceName") and get_imaginary_current_series(results, "DeviceName") can be used to obtain the output current time series of the specified device.

Explore output power

The functions get_activepower_series(results, "DeviceName") and get_reactivepower_series(results, "DeviceName") can be used to obtain the output power time series of the specified device.

Explore dynamic states

The function get_state_series(results, ("DeviceName", :StateSymbol) can be used to obtain the specified state time series of the specified device.

Explore Reference Setpoints

The function get_setpoints(sim) can be used to obtain the reference setpoints of each dynamic device. Note: If a setpoint was changed via a perturbation, this function will return the modified setpoint.

Keyword Arguments

Any solver option available in DifferentialEquations.jl can be passed as keyword arguments in the execute! function. Please see the Common Solver Options in the DifferentialEquations.jl documentation for more details.

Most common solver options used are dtmax to control the maximum dt for adaptive timestepping. abstol and reltol are also commonly used to control the tolerance in the adaptive timestepping. saveat is also used to store the results at a specified time stamps. For example, the following code is valid to further specify your solver options:

execute!(sim, IDA(), dtmax = 0.01, abstol = 1e-9, reltol = 1e-6, saveat = 0.01)

In addition, the keyword argument enable_progress_bar = false can be used to disable the progress bar.

+execute!(sim2, Rodas4())

Exploring the Solution

Once a Simulation is executed and the results are stored via results = read_results(sim), the following functions can be used to explore the Simulation solution:

Show initial conditions

The function show_states_initial_value(results) can be used to display the initial condition of the voltages and dynamic states of each dynamic component.

Explore bus voltages

The function get_voltage_magnitude_series(results, BusNumber) can be used to obtain the voltage magnitude time series of the specified bus. Similarly, get_voltage_angle_series(results, BusNumber) can be used to obtain the voltage angle time series of the specified bus.

Explore output currents

The functions get_real_current_series(results, "DeviceName") and get_imaginary_current_series(results, "DeviceName") can be used to obtain the output current time series of the specified device.

Explore output power

The functions get_activepower_series(results, "DeviceName") and get_reactivepower_series(results, "DeviceName") can be used to obtain the output power time series of the specified device.

Explore dynamic states

The function get_state_series(results, ("DeviceName", :StateSymbol) can be used to obtain the specified state time series of the specified device.

Explore Reference Setpoints

The function get_setpoints(sim) can be used to obtain the reference setpoints of each dynamic device. Note: If a setpoint was changed via a perturbation, this function will return the modified setpoint.

Keyword Arguments

Any solver option available in DifferentialEquations.jl can be passed as keyword arguments in the execute! function. Please see the Common Solver Options in the DifferentialEquations.jl documentation for more details.

Most common solver options used are dtmax to control the maximum dt for adaptive timestepping. abstol and reltol are also commonly used to control the tolerance in the adaptive timestepping. saveat is also used to store the results at a specified time stamps. For example, the following code is valid to further specify your solver options:

execute!(sim, IDA(), dtmax = 0.01, abstol = 1e-9, reltol = 1e-6, saveat = 0.01)

In addition, the keyword argument enable_progress_bar = false can be used to disable the progress bar.

diff --git a/dev/generic/index.html b/dev/generic/index.html index 30486869e..fc7eadf4e 100644 --- a/dev/generic/index.html +++ b/dev/generic/index.html @@ -1,2 +1,2 @@ -Industrial Renewable Models · PowerSimulationsDynamics.jl

Industrial (Generic) Renewable Models

Connection with the Inverter Metamodel

Generic Renewable Models for PV solar or battery devices used in industrial tools, such as PSS/E or PowerWorld, does not necessary resemble the proposed structure of our proposed metamodel.

In general terms, a generic renewable model (for PV plant or battery) is typically a Grid Following inverter that uses a Renewable Energy Plant Controller (REPC), a Renewable Energy Electrical Controller (REEC) and a Renewable Energy Generic Converter (REGC) model. The following figure is useful to understand the general structure of such models:

In comparison to the proposed inverter metamodel it is clear that the REPC resembles the Outer Control. However, the REEC has a purpose of both Outer Control and Inner Control and the REGC has a similar purpose of the Converter and Filter in the proposed structure. For such purpose, it was necessary to split the REEC and part of its model was included in both Outer Control and Inner Control.

Example of implementation of generic models

The following includes examples of the implementation of the proposed model in the inverter metamodel.

Active Renewable Outer Control

The following example join the active power controllers from REPCA and REECB as ActiveRenewableControllerAB in PowerSimulationsDynamics.jl

An important thing to consider with the industrial models, is that the change of Flags can significantly vary the model and purpose of the controller.

Reactive Renewable Outer Control

Similar to the active controller, the following figure presents the reactive controller part from REPCA and REECB as ReactiveRenewableControllerAB in PowerSimulationsDynamics.jl

Inner Controller

Finally, the remaining part from REECB was included RECurrentControllerB

The REGCAmodel was directly included in a Converter Block, and the filter can be bypassed using an RLFilter block with rf = lf = 0.

Current availability of model flags in PSID

Active Controller

For the active controller, both Freq_Flag = 0 (ignoring frequency regulation) and Freq_Flag = 1 (considering frequency regulation) are available.

Reactive Controller

The following table describes the current available combination of flags in PSID:

REF_FlagPF_FlagV_FlagQ_Flag
0000
0010
1011
1000

Any combination outside of these cases may not converge to a feasible operating point. Check the following CAISO report for the description and compliance of each flag combination.

+Industrial Renewable Models · PowerSimulationsDynamics.jl

Industrial (Generic) Renewable Models

Connection with the Inverter Metamodel

Generic Renewable Models for PV solar or battery devices used in industrial tools, such as PSS/E or PowerWorld, does not necessary resemble the proposed structure of our proposed metamodel.

In general terms, a generic renewable model (for PV plant or battery) is typically a Grid Following inverter that uses a Renewable Energy Plant Controller (REPC), a Renewable Energy Electrical Controller (REEC) and a Renewable Energy Generic Converter (REGC) model. The following figure is useful to understand the general structure of such models:

In comparison to the proposed inverter metamodel it is clear that the REPC resembles the Outer Control. However, the REEC has a purpose of both Outer Control and Inner Control and the REGC has a similar purpose of the Converter and Filter in the proposed structure. For such purpose, it was necessary to split the REEC and part of its model was included in both Outer Control and Inner Control.

Example of implementation of generic models

The following includes examples of the implementation of the proposed model in the inverter metamodel.

Active Renewable Outer Control

The following example join the active power controllers from REPCA and REECB as ActiveRenewableControllerAB in PowerSimulationsDynamics.jl

An important thing to consider with the industrial models, is that the change of Flags can significantly vary the model and purpose of the controller.

Reactive Renewable Outer Control

Similar to the active controller, the following figure presents the reactive controller part from REPCA and REECB as ReactiveRenewableControllerAB in PowerSimulationsDynamics.jl

Inner Controller

Finally, the remaining part from REECB was included RECurrentControllerB

The REGCAmodel was directly included in a Converter Block, and the filter can be bypassed using an RLFilter block with rf = lf = 0.

Current availability of model flags in PSID

Active Controller

For the active controller, both Freq_Flag = 0 (ignoring frequency regulation) and Freq_Flag = 1 (considering frequency regulation) are available.

Reactive Controller

The following table describes the current available combination of flags in PSID:

REF_FlagPF_FlagV_FlagQ_Flag
0000
0010
1011
1000

Any combination outside of these cases may not converge to a feasible operating point. Check the following CAISO report for the description and compliance of each flag combination.

diff --git a/dev/index.html b/dev/index.html index 70c409c86..0a2d0051f 100644 --- a/dev/index.html +++ b/dev/index.html @@ -4,4 +4,4 @@ author={Lara, Jose Daniel and Henriquez-Auba, Rodrigo and Ramasubramanian, Deepak and Dhople, Sairaj and Callaway, Duncan S and Sanders, Seth}, journal={arXiv preprint arXiv:2301.10043}, year={2023} -}

Installation

The latest stable release of PowerSimulationsDynamics.jl can be installed using the Julia package manager with

] add PowerSimulationsDynamics

For the current development version, "checkout" this package with

] add PowerSimulationsDynamics#master

Structure

The following figure shows the interactions between PowerSimulationsDynamics.jl, PowerSystems.jl, ForwardDiff.jl, DiffEqBase.jl and the integrators. The architecture of PowerSimulationsDynamics.jl is such that the power system models are all self-contained and return the model function evaluations. The Jacobian is calculated using automatic differentiation through ForwardDiff.jl, that is used for both numerical integration and small signal analysis. Considering that the resulting models are differential-algebraic equations (DAE), the implementation focuses on the use of implicit solvers, in particular BDF and Rosenbrock methods.


PowerSimulationsDynamics.jl has been developed as part of the Scalable Integrated Infrastructure Planning (SIIP) initiative at the U.S. Department of Energy's National Renewable Energy Laboratory (NREL)

+}

Installation

The latest stable release of PowerSimulationsDynamics.jl can be installed using the Julia package manager with

] add PowerSimulationsDynamics

For the current development version, "checkout" this package with

] add PowerSimulationsDynamics#master

Structure

The following figure shows the interactions between PowerSimulationsDynamics.jl, PowerSystems.jl, ForwardDiff.jl, DiffEqBase.jl and the integrators. The architecture of PowerSimulationsDynamics.jl is such that the power system models are all self-contained and return the model function evaluations. The Jacobian is calculated using automatic differentiation through ForwardDiff.jl, that is used for both numerical integration and small signal analysis. Considering that the resulting models are differential-algebraic equations (DAE), the implementation focuses on the use of implicit solvers, in particular BDF and Rosenbrock methods.


PowerSimulationsDynamics.jl has been developed as part of the Scalable Integrated Infrastructure Planning (SIIP) initiative at the U.S. Department of Energy's National Renewable Energy Laboratory (NREL)

diff --git a/dev/initialization/index.html b/dev/initialization/index.html index 20fe9038d..502baf065 100644 --- a/dev/initialization/index.html +++ b/dev/initialization/index.html @@ -20,4 +20,4 @@ (0.0, 20.0); initialize_simulation = false, initial_conditions = x0_init, - )

<span style="color:red">WARNING!</span>: when the initialize_simulation is set to false, neither the device set points nor the inner vars are initialized. Use these keywords with care and make sure the values in the system components match the initial conditions provided.

System-wide initialization routine

The initialization routine starts from the solution of the power flow equations. For each dynamic injection device PowerSimulationsDynamics.jl finds the solution of the systems of non-linear equations for each dynamic component following the sequences described in the forthcoming sections.

Once each device is individually initialized, the system-wide initial guess is used to solve the system (1). In a first attempt at finding the solution, the tolerance is set to a stringent tolerance. If the non-linear solver is unable to get a solution, it might usually reflect small signal stability problems in the system. In a second attempt, the tolerances are relaxed. If the solver succeeds, the simulation continues, but the user is warned.

Initialization of the Synchronous Machines

The initialization of Synchronous Machines is standard in power systems and follows the scheme shown in the figure. Other internal variables are calculated recursively from the power flow solution for the node on which the dynamic device isconnected. (Adapted from Power System Modelling and Scripting Figure 9.2)

init_machine

Initialization of the Inverters

Initializing the inverters follows the sequence shown in the figure and has been developed to be compatible with the implementation of custom dynamic components. Given that the process is less studied and standard than the one of the synchronous machine, this page contains more detailed documentation of the process.

init_machine

  1. The first component to be initialized is the filter. Given that the filter is an RLC circuit connected to the grid, its currents and voltages need to match the results of the power flow. The initialization of the filter provides the values for the $P$ and $Q$ used in the outer control and the $V$ and $I$ needed in the inner controls.
  2. Based on the bus voltage in the system's reference frame $V_r$ and the bus angle $\theta$ the PLL's can be initialized to obtain the angle and frequency estimates needed by the outer control.
  3. The Outer Control calculates the internal angle $\delta_{olc}$ required by the inner control to estimate the voltage and current phase difference.
  4. The DC Source uses the power set-point consistent with the power outputs of the filter to initialize the $V_{dc}$ set-points. This value is used in the inner control.
  5. The inner control takes the phase angle $\delta_{olc}$ and the $V_{dc}$ to estimate the modulation values of the PWM converter.

Note: The initialization of an inverter through the proposed meta-model is actively under development and subject to change. This page will maintain the latest version of the sequence.

+ )

<span style="color:red">WARNING!</span>: when the initialize_simulation is set to false, neither the device set points nor the inner vars are initialized. Use these keywords with care and make sure the values in the system components match the initial conditions provided.

System-wide initialization routine

The initialization routine starts from the solution of the power flow equations. For each dynamic injection device PowerSimulationsDynamics.jl finds the solution of the systems of non-linear equations for each dynamic component following the sequences described in the forthcoming sections.

Once each device is individually initialized, the system-wide initial guess is used to solve the system (1). In a first attempt at finding the solution, the tolerance is set to a stringent tolerance. If the non-linear solver is unable to get a solution, it might usually reflect small signal stability problems in the system. In a second attempt, the tolerances are relaxed. If the solver succeeds, the simulation continues, but the user is warned.

Initialization of the Synchronous Machines

The initialization of Synchronous Machines is standard in power systems and follows the scheme shown in the figure. Other internal variables are calculated recursively from the power flow solution for the node on which the dynamic device isconnected. (Adapted from Power System Modelling and Scripting Figure 9.2)

init_machine

Initialization of the Inverters

Initializing the inverters follows the sequence shown in the figure and has been developed to be compatible with the implementation of custom dynamic components. Given that the process is less studied and standard than the one of the synchronous machine, this page contains more detailed documentation of the process.

init_machine

  1. The first component to be initialized is the filter. Given that the filter is an RLC circuit connected to the grid, its currents and voltages need to match the results of the power flow. The initialization of the filter provides the values for the $P$ and $Q$ used in the outer control and the $V$ and $I$ needed in the inner controls.
  2. Based on the bus voltage in the system's reference frame $V_r$ and the bus angle $\theta$ the PLL's can be initialized to obtain the angle and frequency estimates needed by the outer control.
  3. The Outer Control calculates the internal angle $\delta_{olc}$ required by the inner control to estimate the voltage and current phase difference.
  4. The DC Source uses the power set-point consistent with the power outputs of the filter to initialize the $V_{dc}$ set-points. This value is used in the inner control.
  5. The inner control takes the phase angle $\delta_{olc}$ and the $V_{dc}$ to estimate the modulation values of the PWM converter.

Note: The initialization of an inverter through the proposed meta-model is actively under development and subject to change. This page will maintain the latest version of the sequence.

diff --git a/dev/models/index.html b/dev/models/index.html index 5d4beb154..add687790 100644 --- a/dev/models/index.html +++ b/dev/models/index.html @@ -5,4 +5,4 @@ r(t) = \frac{dx(t)}{dt} - f(x(t)) \end{align}\]

At this stage we have not conducted extensive tests with all the solvers in DifferentialEquations if you are solving a larger system use IDA().

The dynamic system model in PowerSimulationsDynamics

In order to support both formulations, the default implementation of the ResidualModel solves the following problem:

\[\begin{align} r(t) = M\frac{dx(t)}{dt} - f(x(t)) -\end{align}\]

Solution approaches

PowerSimulationsDynamics.jl construct the entire function that is passed to DifferentialEquations to solve it using different solvers. This is called the Simultaneous-solution approach to numerically integrate over time. It gives the user the flexibility to model devices with a combination of differential and algebraic states. In addition, it gives the flexibility to model the network using an algebraic or differential model.

On the other hand, industrial tools such as PSS/E uses a Partitioned-solution approach, on which the network must be modeled using an algebraic approach, and the differential equations and algebraic equations are solved sequentially. This method is usually faster if the heuristics for convergence when solving sequentially are properly tuned. However, boundary techniques must be considered when the connection with the devices and network is not converging when applying the partitioned-solution approach.

The difference in solution methods can complicate the validation and comparison between software tools. In addition it can affect the computational properties due to reliance of heuristics. These solution aspects are important to consider when using different tools for simulating power systems dynamics.

For more details, check Brian Stott paper "Power system dynamic response calculations".

Generator Models

Here we discuss the structure and models used to model generators in PowerSimulationsDynamics.jl. See PowerSystems.jl dynamic devices for details.

Each generator is a data structure composed of the following components defined in PowerSystems.jl:

The implementation of Synchronous generators as components uses the following structure to share values across components.

Inverter Models

Here we discuss the structure and models used to model inverters in PowerSimulationsDynamics.jl. See PowerSystems.jl dynamic devices for details. One of the key contributions in this software package is a separation of the components in a way that resembles current practices for synchronoues machine modeling.

The following figure summarizes the components of a inverter and which variables they share:

Contrary to the generator, there are many control structures that can be used to model inverter controllers (e.g. grid-following, grid feeding or virtual synchronous machine). For this purpose, more variables are shared among the components in order to cover all these posibilities.

Reference

For models, check the library in PowerSystems.jl

+\end{align}\]

Solution approaches

PowerSimulationsDynamics.jl construct the entire function that is passed to DifferentialEquations to solve it using different solvers. This is called the Simultaneous-solution approach to numerically integrate over time. It gives the user the flexibility to model devices with a combination of differential and algebraic states. In addition, it gives the flexibility to model the network using an algebraic or differential model.

On the other hand, industrial tools such as PSS/E uses a Partitioned-solution approach, on which the network must be modeled using an algebraic approach, and the differential equations and algebraic equations are solved sequentially. This method is usually faster if the heuristics for convergence when solving sequentially are properly tuned. However, boundary techniques must be considered when the connection with the devices and network is not converging when applying the partitioned-solution approach.

The difference in solution methods can complicate the validation and comparison between software tools. In addition it can affect the computational properties due to reliance of heuristics. These solution aspects are important to consider when using different tools for simulating power systems dynamics.

For more details, check Brian Stott paper "Power system dynamic response calculations".

Generator Models

Here we discuss the structure and models used to model generators in PowerSimulationsDynamics.jl. See PowerSystems.jl dynamic devices for details.

Each generator is a data structure composed of the following components defined in PowerSystems.jl:

The implementation of Synchronous generators as components uses the following structure to share values across components.

Inverter Models

Here we discuss the structure and models used to model inverters in PowerSimulationsDynamics.jl. See PowerSystems.jl dynamic devices for details. One of the key contributions in this software package is a separation of the components in a way that resembles current practices for synchronoues machine modeling.

The following figure summarizes the components of a inverter and which variables they share:

Contrary to the generator, there are many control structures that can be used to model inverter controllers (e.g. grid-following, grid feeding or virtual synchronous machine). For this purpose, more variables are shared among the components in order to cover all these posibilities.

Reference

For models, check the library in PowerSystems.jl

diff --git a/dev/perturbations/index.html b/dev/perturbations/index.html index 89cf4442f..9a39ed39a 100644 --- a/dev/perturbations/index.html +++ b/dev/perturbations/index.html @@ -41,4 +41,4 @@ crc = ControlReferenceChange(1.0, g, :P_ref, 0.5)

Example 7: LoadChange

Consider that you have a load at bus 103, named "load-103-1" in your system called sys. The constructor to change is active power reference to 0.8 per unit at $t = 1.0$ seconds is:

l_device = get_component(ElectricLoad, sys, "load-103-1")
 l_change = LoadChange(1.0, l_device, :P_ref, 0.8)

Example 8: LoadTrip

Consider that you have a load at bus 103, named "load-103-1" in your system called sys. The constructor to disconnect such load at $t = 1.0$ seconds is:

l_device = get_component(ElectricLoad, sys, "load-103-1")
 l_trip = LoadTrip(1.0, l_device)

Example 9: SourceBusVoltageChange

Consider that you have a voltage source at bus 101, named "source-101-1" in your system called sys. The constructor to change is voltage magnitude reference to 1.02 per unit at $t = 1.0$ seconds is:

s_device = get_component(Source, sys, "source-101-1")
-s_change = SourceBusVoltageChange(1.0, s_device, 1, 1.02)
+s_change = SourceBusVoltageChange(1.0, s_device, 1, 1.02) diff --git a/dev/power-simulations-dynamics.log b/dev/power-simulations-dynamics.log index 114016d3d..40de915da 100644 --- a/dev/power-simulations-dynamics.log +++ b/dev/power-simulations-dynamics.log @@ -1,44 +1,44 @@ -┌ Info: 2024-07-02T15:42:29.036 [5598:1]: The reference Bus has a Source connected to it. The frequency reference model will change to ConstantFrequency +┌ Info: 2024-07-08T22:42:18.552 [5549:1]: The reference Bus has a Source connected to it. The frequency reference model will change to ConstantFrequency └ @ PowerSimulationsDynamics /home/runner/work/PowerSimulationsDynamics.jl/PowerSimulationsDynamics.jl/src/base/frequency_reference.jl:70 -┌ Info: 2024-07-02T15:42:29.066 [5598:1]: Pre-Initializing Simulation States +┌ Info: 2024-07-08T22:42:18.576 [5549:1]: Pre-Initializing Simulation States └ @ PowerSimulationsDynamics /home/runner/work/PowerSimulationsDynamics.jl/PowerSimulationsDynamics.jl/src/base/simulation.jl:265 -┌ Info: 2024-07-02T15:42:29.066 [5598:1]: Unit System changed to UnitSystem.SYSTEM_BASE = 0 -└ @ PowerSystems /home/runner/.julia/packages/PowerSystems/xh3fM/src/base.jl:395 -┌ Info: 2024-07-02T15:42:30.770 [5598:1]: PowerFlow solve converged, the results have been stored in the system -└ @ PowerFlows /home/runner/.julia/packages/PowerFlows/6nw6s/src/nlsolve_ac_powerflow.jl:47 -┌ Info: 2024-07-02T15:42:30.770 [5598:1]: Unit System changed to UnitSystem.DEVICE_BASE = 1 -└ @ PowerSystems /home/runner/.julia/packages/PowerSystems/xh3fM/src/base.jl:395 -┌ Info: 2024-07-02T15:42:43.379 [5598:1]: Residual from initial guess: max = 4.212807880321634e-11 at 4, total = 5.4841923110646186e-11 +┌ Info: 2024-07-08T22:42:18.576 [5549:1]: Unit System changed to UnitSystem.SYSTEM_BASE = 0 +└ @ PowerSystems /home/runner/.julia/packages/PowerSystems/OQdiE/src/base.jl:491 +┌ Info: 2024-07-08T22:42:20.455 [5549:1]: PowerFlow solve converged, the results have been stored in the system +└ @ PowerFlows /home/runner/.julia/packages/PowerFlows/zesCE/src/nlsolve_ac_powerflow.jl:47 +┌ Info: 2024-07-08T22:42:20.455 [5549:1]: Unit System changed to UnitSystem.DEVICE_BASE = 1 +└ @ PowerSystems /home/runner/.julia/packages/PowerSystems/OQdiE/src/base.jl:491 +┌ Info: 2024-07-08T22:42:32.763 [5549:1]: Residual from initial guess: max = 4.212807880321634e-11 at 4, total = 5.4841923110646186e-11 └ @ PowerSimulationsDynamics /home/runner/work/PowerSimulationsDynamics.jl/PowerSimulationsDynamics.jl/src/base/nlsolve_wrapper.jl:115 -┌ Info: 2024-07-02T15:42:43.419 [5598:1]: Initialization non-linear solve succeeded with a tolerance of 1.0e-9 using solver trust_region. Saving solution. +┌ Info: 2024-07-08T22:42:32.800 [5549:1]: Initialization non-linear solve succeeded with a tolerance of 1.0e-9 using solver trust_region. Saving solution. └ @ PowerSimulationsDynamics /home/runner/work/PowerSimulationsDynamics.jl/PowerSimulationsDynamics.jl/src/base/nlsolve_wrapper.jl:82 -┌ Info: 2024-07-02T15:42:43.419 [5598:1]: Attaching Perturbations +┌ Info: 2024-07-08T22:42:32.800 [5549:1]: Attaching Perturbations └ @ PowerSimulationsDynamics /home/runner/work/PowerSimulationsDynamics.jl/PowerSimulationsDynamics.jl/src/base/simulation.jl:299 -┌ Info: 2024-07-02T15:42:43.918 [5598:1]: Simulations status = BUILT +┌ Info: 2024-07-08T22:42:33.313 [5549:1]: Simulations status = BUILT └ @ PowerSimulationsDynamics /home/runner/work/PowerSimulationsDynamics.jl/PowerSimulationsDynamics.jl/src/base/simulation.jl:462 -┌ Info: 2024-07-02T15:42:43.919 [5598:1]: +┌ Info: 2024-07-08T22:42:33.313 [5549:1]: │ ─────────────────────────────────────────────────────────────────────────────── │ Time Allocations │ ─────────────── ─────────────── -│ Total measured: 16.7s 837MiB +│ Total measured: 16.8s 828MiB │ │ Section ncalls time %tot alloc %tot │ ─────────────────────────────────────────────────────────────────────────────── -│ Build Simulation 1 16.7s 100.0% 837MiB 100.0% -│ Build Simulation Inputs 1 1.88s 11.2% 126MiB 15.0% -│ Wrap Branches 1 10.0μs 0.0% 208B 0.0% -│ Wrap Dynamic Injectors 1 1.09s 6.5% 80.2MiB 9.6% -│ Calculate MM, DAE_vector, Tota... 1 70.1ms 0.4% 6.28MiB 0.7% -│ Wrap Static Injectors 1 59.0ms 0.4% 1.63MiB 0.2% -│ Pre-initialization 1 4.85s 29.0% 259MiB 30.9% -│ Power Flow solution 1 1.74s 10.4% 41.6MiB 5.0% -│ Initialize Static Injectors 1 2.16s 12.9% 27.4MiB 3.3% -│ Initialize Dynamic Injectors 1 944ms 5.6% 190MiB 22.7% -│ Calculate Jacobian 1 4.51s 26.9% 395MiB 47.2% -│ Make Model Function 1 6.08ms 0.0% 122KiB 0.0% -│ Initial Condition NLsolve refine... 1 4.99s 29.8% 29.9MiB 3.6% -│ Build Perturbations 1 218ms 1.3% 13.4MiB 1.6% -│ Make DiffEq Problem 1 276ms 1.6% 14.0MiB 1.7% +│ Build Simulation 1 16.8s 100.0% 828MiB 100.0% +│ Build Simulation Inputs 1 2.04s 12.2% 124MiB 14.9% +│ Wrap Branches 1 9.46μs 0.0% 208B 0.0% +│ Wrap Dynamic Injectors 1 1.27s 7.6% 77.9MiB 9.4% +│ Calculate MM, DAE_vector, Tota... 1 68.7ms 0.4% 6.28MiB 0.8% +│ Wrap Static Injectors 1 54.9ms 0.3% 1.63MiB 0.2% +│ Pre-initialization 1 4.94s 29.4% 251MiB 30.3% +│ Power Flow solution 1 1.92s 11.4% 43.3MiB 5.2% +│ Initialize Static Injectors 1 2.12s 12.6% 27.4MiB 3.3% +│ Initialize Dynamic Injectors 1 900ms 5.4% 180MiB 21.8% +│ Calculate Jacobian 1 4.47s 26.6% 395MiB 47.8% +│ Make Model Function 1 5.72ms 0.0% 122KiB 0.0% +│ Initial Condition NLsolve refine... 1 4.81s 28.7% 29.9MiB 3.6% +│ Build Perturbations 1 238ms 1.4% 13.6MiB 1.6% +│ Make DiffEq Problem 1 269ms 1.6% 14.0MiB 1.7% │ ─────────────────────────────────────────────────────────────────────────────── │ └ @ PowerSimulationsDynamics /home/runner/work/PowerSimulationsDynamics.jl/PowerSimulationsDynamics.jl/src/base/simulation.jl:487 diff --git a/dev/quick_start_guide/index.html b/dev/quick_start_guide/index.html index 53822ec21..6412201a6 100644 --- a/dev/quick_start_guide/index.html +++ b/dev/quick_start_guide/index.html @@ -1,24 +1,14 @@ Quick Start Guide · PowerSimulationsDynamics.jl

Quick Start Guide

The data for these tutorials is provided in PowerSystemCaseBuilder. If you want to build your own case, take a look at the tutorial Creating and Handling Data for Dynamic Simulations

For more details about loading data and adding more dynamic components check the Creating a System with Dynamic devices section of the documentation in PowerSystems.jl.

For a detailed tutorial about this case visit One Machine against Infinite Bus (OMIB) Simulation

Loading data

Data can be loaded from a pss/e raw file and a pss/e dyr file.

julia> using PowerSystems
julia> using PowerSimulationsDynamics
julia> using PowerSystemCaseBuilder
julia> using Sundials
julia> using Plots
julia> omib_sys = build_system(PSIDSystems, "OMIB System")┌ Info: Building new system OMIB System from raw data └ sys_descriptor.raw_data = "" -┌ Warning: System is saved in the data format version 2.0.0 will be automatically upgraded to 3.0.0 upon saving -└ @ PowerSystems ~/.julia/packages/PowerSystems/xh3fM/src/data_format_conversions.jl:82 -┌ Warning: struct ACBus does not exist in validation configuration file, validation skipped -└ @ InfrastructureSystems ~/.julia/packages/InfrastructureSystems/9btGb/src/validation.jl:51 -┌ Warning: struct ACBus does not exist in validation configuration file, validation skipped -└ @ InfrastructureSystems ~/.julia/packages/InfrastructureSystems/9btGb/src/validation.jl:51 ┌ Warning: struct DynamicGenerator does not exist in validation configuration file, validation skipped -└ @ InfrastructureSystems ~/.julia/packages/InfrastructureSystems/9btGb/src/validation.jl:51 -┌ Warning: field prime_mover_type does not exist in ThermalStandard validation config -└ @ InfrastructureSystems ~/.julia/packages/InfrastructureSystems/9btGb/src/validation.jl:65 +└ @ InfrastructureSystems ~/.julia/packages/InfrastructureSystems/SIMc0/src/validation.jl:51 ┌ Warning: struct DynamicGenerator does not exist in validation configuration file, validation skipped -└ @ InfrastructureSystems ~/.julia/packages/InfrastructureSystems/9btGb/src/validation.jl:51 -┌ Warning: System is saved in the data format version 2.0.0 will be automatically upgraded to 3.0.0 upon saving -└ @ PowerSystems ~/.julia/packages/PowerSystems/xh3fM/src/data_format_conversions.jl:110 +└ @ InfrastructureSystems ~/.julia/packages/InfrastructureSystems/SIMc0/src/validation.jl:51 ┌ Warning: There are no ElectricLoad Components in the System -└ @ PowerSystems ~/.julia/packages/PowerSystems/xh3fM/src/utils/IO/system_checks.jl:59 -[ Info: Serialized System to /home/runner/.julia/packages/PowerSystemCaseBuilder/vlTjU/data/serialized_system/NoArgs/OMIB System.json -[ Info: Serialized System metadata to /home/runner/.julia/packages/PowerSystemCaseBuilder/vlTjU/data/serialized_system/NoArgs/OMIB System_metadata.json +└ @ PowerSystems ~/.julia/packages/PowerSystems/OQdiE/src/utils/IO/system_checks.jl:59 +[ Info: Serialized System to /home/runner/.julia/packages/PowerSystemCaseBuilder/9AsiG/data/serialized_system/e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855/OMIB System.json +[ Info: Serialized System metadata to /home/runner/.julia/packages/PowerSystemCaseBuilder/9AsiG/data/serialized_system/e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855/OMIB System_metadata.json System ┌───────────────────┬─────────────┐ │ Property │ Value │ @@ -32,24 +22,25 @@ └───────────────────┴─────────────┘ Static Components -┌─────────────────┬───────┬────────────────────────┬───────────────┐ -│ Type │ Count │ Has Static Time Series │ Has Forecasts │ -├─────────────────┼───────┼────────────────────────┼───────────────┤ -│ ACBus │ 2 │ false │ false │ -│ Arc │ 1 │ false │ false │ -│ Area │ 1 │ false │ false │ -│ Line │ 2 │ false │ false │ -│ LoadZone │ 1 │ false │ false │ -│ Source │ 1 │ false │ false │ -│ ThermalStandard │ 1 │ false │ false │ -└─────────────────┴───────┴────────────────────────┴───────────────┘ +┌─────────────────┬───────┐ +│ Type │ Count │ +├─────────────────┼───────┤ +│ ACBus │ 2 │ +│ Arc │ 1 │ +│ Area │ 1 │ +│ Line │ 2 │ +│ LoadZone │ 1 │ +│ Source │ 1 │ +│ ThermalStandard │ 1 │ +└─────────────────┴───────┘ Dynamic Components -┌──────────────────┬───────┐ -│ Type │ Count │ -├──────────────────┼───────┤ -│ DynamicGenerator │ 1 │ -└──────────────────┴───────┘

Define the Simulation

julia> time_span = (0.0, 30.0)(0.0, 30.0)
julia> perturbation_trip = BranchTrip(1.0, Line, "BUS 1-BUS 2-i_1")BranchTrip(1.0, Line, "BUS 1-BUS 2-i_1")
julia> sim = Simulation!(ResidualModel, omib_sys, pwd(), time_span, perturbation_trip)[ Info: Unit System changed to UnitSystem.DEVICE_BASE = 1 +┌────────────────────────────────────────────────────────────────────────┬────── +│ Type │ Cou ⋯ +├────────────────────────────────────────────────────────────────────────┼────── +│ DynamicGenerator{BaseMachine, SingleMass, AVRFixed, TGFixed, PSSFixed} │ 1 ⋯ +└────────────────────────────────────────────────────────────────────────┴────── + 1 column omitted

Define the Simulation

julia> time_span = (0.0, 30.0)(0.0, 30.0)
julia> perturbation_trip = BranchTrip(1.0, Line, "BUS 1-BUS 2-i_1")BranchTrip(1.0, Line, "BUS 1-BUS 2-i_1")
julia> sim = Simulation!(ResidualModel, omib_sys, pwd(), time_span, perturbation_trip)[ Info: Unit System changed to UnitSystem.DEVICE_BASE = 1 Simulation Summary ┌─────────────────────────┬────────────────┐ │ Property │ Value │ @@ -99,5 +90,5 @@ │ Time Span │ (0.0, 30.0) │ │ Total Time Steps │ 1502 │ │ Number of States │ 6 │ -│ Total solve time │ 2.067370594 │ -└────────────────────────────┴─────────────┘
julia> angle = get_state_series(results, ("generator-102-1", :δ));
julia> plot(angle, xlabel = "time", ylabel = "rotor angle [rad]", label = "gen-102-1")Plot{Plots.GRBackend() n=1}

plot

If you miss PSS/e's plotting aesthetics and want something that resembles that, you can use UnicodePlots.

julia> using UnicodePlots
julia> unicodeplots()Plots.UnicodePlotsBackend()
julia> plot(angle, xlabel = "time", ylabel = "rotor angle [rad]", label = "gen-102-1");

plot

+│ Total solve time │ 2.022155497 │ +└────────────────────────────┴─────────────┘
julia> angle = get_state_series(results, ("generator-102-1", :δ));
julia> plot(angle, xlabel = "time", ylabel = "rotor angle [rad]", label = "gen-102-1")Plot{Plots.GRBackend() n=1}

plot

If you miss PSS/e's plotting aesthetics and want something that resembles that, you can use UnicodePlots.

julia> using UnicodePlots
julia> unicodeplots()Plots.UnicodePlotsBackend()
julia> plot(angle, xlabel = "time", ylabel = "rotor angle [rad]", label = "gen-102-1");

plot

diff --git a/dev/reference_frames/index.html b/dev/reference_frames/index.html index 8ea2fe3e0..2c2fd4efe 100644 --- a/dev/reference_frames/index.html +++ b/dev/reference_frames/index.html @@ -8,4 +8,4 @@ v_d + jv_q &= (v_r + jv_i) e^{-j \delta} \tag{2a} \\ v_d &= v_h \cos(\delta - \theta) \tag{2b} \\ v_q &= -v_h \sin(\delta - \theta) \tag{2c} -\end{align}\]

That, contrary to the previous case, when $\delta = \theta = 0$ implies that $v_d = 1.0$ and $v_q = 0.0$. This yields the typical PLL conditions that steer $v_q \to 0$ when $\delta$ locks in $\theta$, or when both SRF lock between each other.

Transformation used

Given the predominancy of both convention in current work, the software uses both conventions depending on the device modeled. For synchronous machines we used the standard convention (1a)-(1d), while for inverter models we use the predominant convention used nowadays in such models, i.e. (2a)-(2c).

+\end{align}\]

That, contrary to the previous case, when $\delta = \theta = 0$ implies that $v_d = 1.0$ and $v_q = 0.0$. This yields the typical PLL conditions that steer $v_q \to 0$ when $\delta$ locks in $\theta$, or when both SRF lock between each other.

Transformation used

Given the predominancy of both convention in current work, the software uses both conventions depending on the device modeled. For synchronous machines we used the standard convention (1a)-(1d), while for inverter models we use the predominant convention used nowadays in such models, i.e. (2a)-(2c).

diff --git a/dev/search/index.html b/dev/search/index.html index 7ac970dd3..e0eb3b559 100644 --- a/dev/search/index.html +++ b/dev/search/index.html @@ -1,2 +1,2 @@ -Search · PowerSimulationsDynamics.jl

Loading search...

    +Search · PowerSimulationsDynamics.jl

    Loading search...

      diff --git a/dev/search_index.js b/dev/search_index.js index 4680e1366..aeab4f138 100644 --- a/dev/search_index.js +++ b/dev/search_index.js @@ -1,3 +1,3 @@ var documenterSearchIndex = {"docs": -[{"location":"execute/#Executing-a-Simulation","page":"Simulation Execution","title":"Executing a Simulation","text":"","category":"section"},{"location":"execute/","page":"Simulation Execution","title":"Simulation Execution","text":"After constructing the System data from PowerSystems.jl with its dynamic components, a Simulation structure must be constructed. Check the API for Simulation and Simulation! for its construction and available arguments.","category":"page"},{"location":"execute/","page":"Simulation Execution","title":"Simulation Execution","text":"Once a Simulation is constructed and properly initialized, the execute! command is used to run the Simulation. If no perturbation was included, then a steady state simulation will be run over the time span defined. See the API of execute! for more details.","category":"page"},{"location":"execute/#Solvers","page":"Simulation Execution","title":"Solvers","text":"","category":"section"},{"location":"execute/","page":"Simulation Execution","title":"Simulation Execution","text":"Solvers must be chosen accordingly depending on the type of model used in the Simulation. For example, a Residual model can be executed using Sundials IDA solver:","category":"page"},{"location":"execute/","page":"Simulation Execution","title":"Simulation Execution","text":"using Sundials\nsim = Simulation(\n ResidualModel,\n sys,\n pwd(),\n (0.0, 20.0),\n perturbation,\n)\nexecute!(sim, IDA())","category":"page"},{"location":"execute/","page":"Simulation Execution","title":"Simulation Execution","text":"Results can be explored using:","category":"page"},{"location":"execute/","page":"Simulation Execution","title":"Simulation Execution","text":"results = read_results(sim)","category":"page"},{"location":"execute/","page":"Simulation Execution","title":"Simulation Execution","text":"Similarly, a Mass Matrix model can be executed using Rodas4 solver.","category":"page"},{"location":"execute/","page":"Simulation Execution","title":"Simulation Execution","text":"using OrdinaryDiffEq\nsim2 = Simulation(\n MassMatrixModel,\n sys,\n pwd(),\n (0.0, 20.0),\n perturbation,\n)\nexecute!(sim2, Rodas4())","category":"page"},{"location":"execute/#Exploring-the-Solution","page":"Simulation Execution","title":"Exploring the Solution","text":"","category":"section"},{"location":"execute/","page":"Simulation Execution","title":"Simulation Execution","text":"Once a Simulation is executed and the results are stored via results = read_results(sim), the following functions can be used to explore the Simulation solution:","category":"page"},{"location":"execute/#Show-initial-conditions","page":"Simulation Execution","title":"Show initial conditions","text":"","category":"section"},{"location":"execute/","page":"Simulation Execution","title":"Simulation Execution","text":"The function show_states_initial_value(results) can be used to display the initial condition of the voltages and dynamic states of each dynamic component.","category":"page"},{"location":"execute/#Explore-bus-voltages","page":"Simulation Execution","title":"Explore bus voltages","text":"","category":"section"},{"location":"execute/","page":"Simulation Execution","title":"Simulation Execution","text":"The function get_voltage_magnitude_series(results, BusNumber) can be used to obtain the voltage magnitude time series of the specified bus. Similarly, get_voltage_angle_series(results, BusNumber) can be used to obtain the voltage angle time series of the specified bus.","category":"page"},{"location":"execute/#Explore-output-currents","page":"Simulation Execution","title":"Explore output currents","text":"","category":"section"},{"location":"execute/","page":"Simulation Execution","title":"Simulation Execution","text":"The functions get_real_current_series(results, \"DeviceName\") and get_imaginary_current_series(results, \"DeviceName\") can be used to obtain the output current time series of the specified device.","category":"page"},{"location":"execute/#Explore-output-power","page":"Simulation Execution","title":"Explore output power","text":"","category":"section"},{"location":"execute/","page":"Simulation Execution","title":"Simulation Execution","text":"The functions get_activepower_series(results, \"DeviceName\") and get_reactivepower_series(results, \"DeviceName\") can be used to obtain the output power time series of the specified device.","category":"page"},{"location":"execute/#Explore-dynamic-states","page":"Simulation Execution","title":"Explore dynamic states","text":"","category":"section"},{"location":"execute/","page":"Simulation Execution","title":"Simulation Execution","text":"The function get_state_series(results, (\"DeviceName\", :StateSymbol) can be used to obtain the specified state time series of the specified device.","category":"page"},{"location":"execute/#Explore-Reference-Setpoints","page":"Simulation Execution","title":"Explore Reference Setpoints","text":"","category":"section"},{"location":"execute/","page":"Simulation Execution","title":"Simulation Execution","text":"The function get_setpoints(sim) can be used to obtain the reference setpoints of each dynamic device. Note: If a setpoint was changed via a perturbation, this function will return the modified setpoint.","category":"page"},{"location":"execute/#Keyword-Arguments","page":"Simulation Execution","title":"Keyword Arguments","text":"","category":"section"},{"location":"execute/","page":"Simulation Execution","title":"Simulation Execution","text":"Any solver option available in DifferentialEquations.jl can be passed as keyword arguments in the execute! function. Please see the Common Solver Options in the DifferentialEquations.jl documentation for more details.","category":"page"},{"location":"execute/","page":"Simulation Execution","title":"Simulation Execution","text":"Most common solver options used are dtmax to control the maximum dt for adaptive timestepping. abstol and reltol are also commonly used to control the tolerance in the adaptive timestepping. saveat is also used to store the results at a specified time stamps. For example, the following code is valid to further specify your solver options:","category":"page"},{"location":"execute/","page":"Simulation Execution","title":"Simulation Execution","text":"execute!(sim, IDA(), dtmax = 0.01, abstol = 1e-9, reltol = 1e-6, saveat = 0.01)","category":"page"},{"location":"execute/","page":"Simulation Execution","title":"Simulation Execution","text":"In addition, the keyword argument enable_progress_bar = false can be used to disable the progress bar.","category":"page"},{"location":"component_models/inner_control/#Inner-Loop-Controls","page":"Inner Control","title":"Inner Loop Controls","text":"","category":"section"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"This component defines voltage and current controllers to generate the reference signal for the converter. Although in many controls the current and voltage control are separate blocks we propose a more general control approach that considers them as a joint control logic.","category":"page"},{"location":"component_models/inner_control/#Integrated-Virtual-Impedance,-Voltage-and-Current-Controller-[VoltageModeControl]","page":"Inner Control","title":"Integrated Virtual Impedance, Voltage and Current Controller [VoltageModeControl]","text":"","category":"section"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"The following model receives both the outer loop control frequency and reference voltage signal to generate the reference signal for the converters. The virtual impedance plays a similar role of the impedance of a synchronous generator. A PI voltage controller is used to generate the current signal that is used in the PI current controller to finally generate the voltage reference signal for the converters.","category":"page"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"beginalign*\n dotxi_d = v_dtextvi^textref - v_d tag1a \n dotxi_q = v_qtextvi^textref - v_q tag1b \n dotgamma_d = i_dtextcv^textref - i_dtextcv tag1c \n dotgamma_q = i_qtextcv^textref - i_qtextcv tag1d \n dotphi_d = omega_textad(v_d - phi_d) tag1e \n dotphi_q = omega_textad(v_q - phi_q) tag1f\nendalign*","category":"page"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"with","category":"page"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"beginalign\n v_dtextvi^textref = v_textolc^textref - r_v i_d + omega_textolc l_v i_q tag1g \n v_qtextvi^textref = - r_v i_q - omega_textolc l_v i_d tag1h \n i_dtextcv^textref = k_pvleft(v_dtextvi^textref - v_dright) + k_iv xi_d - c_f omega_textolc v_q + k_textffii_d tag1i \n i_qtextcv^textref = k_pvleft(v_qtextvi^textref - v_qright) + k_iv xi_q + c_f omega_textolc v_d + k_textffii_q tag1j \n v_d^textref-signal = k_pc left(i_dtextcv^textref - i_dtextcvright) + k_ic gamma_d - omega_textolc l_f i_qtextcv + k_textffvv_d - k_textad(v_d - phi_d) tag1k \n v_q^textref-signal = k_pc left(i_qtextcv^textref - i_qtextcvright) + k_ic gamma_q + omega_textolc l_f i_dtextcv + k_textffvv_q - k_textad(v_q - phi_q) tag1l\nendalign","category":"page"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"In here the transformation to the dq reference frame is using the outer-loop reference angle as:","category":"page"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"beginalign*\nv_d + jv_q = (v_r + jv_i)e^-jdeltatheta_olc \ni_d + ji_q = (i_r + ji_i)e^-jdeltatheta_olc\nendalign*","category":"page"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"that again v_r + jv_i could be in the capacitor or the last branch of the filter (i.e. the point of common coupling). For LCL filters it is considered in the capacitor. In the case of the converter, the transformation is directly","category":"page"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"beginalign*\ni_dtextcv + ji_qtextcv = (i_rtextcv + ji_itextcv)e^-jdeltatheta_olc\nendalign*","category":"page"},{"location":"component_models/inner_control/#Current-Mode-Controller-[CurrentModeControl]","page":"Inner Control","title":"Current Mode Controller [CurrentModeControl]","text":"","category":"section"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"The following model receives the current reference (in dq axis) from an outer loop controller that outputs current references such as the PI outer controller used for grid following inverters. A PI current controller is used to generate the voltage reference signal for the converters.","category":"page"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"beginalign*\n dotgamma_d = i_dtextcv^textref - i_dtextcv tag2a \n dotgamma_q = i_qtextcv^textref - i_qtextcv tag2b \nendalign*","category":"page"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"with","category":"page"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"beginalign\n v_d^textref-signal = k_pc left(i_dtextcv^textref - i_dtextcvright) + k_ic gamma_d - omega_textolc l_f i_qtextcv + k_textffvv_d tag2b \n v_q^textref-signal = k_pc left(i_qtextcv^textref - i_qtextcvright) + k_ic gamma_q + omega_textolc l_f i_dtextcv + k_textffvv_q tag2c\nendalign","category":"page"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"The transformation for the converter current is computed as:","category":"page"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"beginalign*\ni_dtextcv + ji_qtextcv = (i_rtextcv + ji_itextcv)e^-jtheta_olc\nendalign*","category":"page"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"In here theta_olc is the outer-loop angle. In the case of grid-following models, this angle is equal to the angle provided from the PLL.","category":"page"},{"location":"component_models/inner_control/#Generic-Renewable-Inner-Controller-Type-B-[RECurrentControlB]","page":"Inner Control","title":"Generic Renewable Inner Controller Type B [RECurrentControlB]","text":"","category":"section"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"This models the inner control part of the REECB model. The equations (without limiters) when Q_Flag = 1 are:","category":"page"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"beginalign\n T_rv dotV_texttflt = V_t - dotV_texttflt tag3a \n dotxi_icv = V_textocqcmd tag3b\nendalign","category":"page"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"on which V_textocqcmd comes from the Outer Controller and the output current commands I_textpcmd and I_textqcmd are computed as:","category":"page"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"beginalign\n I_textpcmd = I_textoc pcmd tag3c \n I_textqcmd = I_icv + I_textqinj tag3d \n I_icv = K_vp V_textocqcmd + K_vi xi_icv tag3e \n I_textqinj = K_qv (V_textref0 - V_texttflt) tag3f\nendalign","category":"page"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"The equations when Q_Flag = 0 are:","category":"page"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"beginalign\n T_rv dotV_texttflt = V_t - dotV_texttflt tag3g \n T_iq dotI_icv = I_textocqcmd - I_icv tag3h\nendalign","category":"page"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"on which I_textocqcmd comes from the Outer Controller and the output current commands I_textpcmd and I_textqcmd are computed as:","category":"page"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"beginalign\n I_textpcmd = I_textoc pcmd tag3i \n I_textqcmd = I_icv + I_textqinj tag3j \n I_textqinj = K_qv (V_textref0 - V_texttflt) tag3k\nendalign","category":"page"},{"location":"quick_start_guide/#Quick-Start-Guide","page":"Quick Start Guide","title":"Quick Start Guide","text":"","category":"section"},{"location":"quick_start_guide/","page":"Quick Start Guide","title":"Quick Start Guide","text":"The data for these tutorials is provided in PowerSystemCaseBuilder. If you want to build your own case, take a look at the tutorial Creating and Handling Data for Dynamic Simulations","category":"page"},{"location":"quick_start_guide/","page":"Quick Start Guide","title":"Quick Start Guide","text":"For more details about loading data and adding more dynamic components check the Creating a System with Dynamic devices section of the documentation in PowerSystems.jl.","category":"page"},{"location":"quick_start_guide/","page":"Quick Start Guide","title":"Quick Start Guide","text":"For a detailed tutorial about this case visit One Machine against Infinite Bus (OMIB) Simulation","category":"page"},{"location":"quick_start_guide/#Loading-data","page":"Quick Start Guide","title":"Loading data","text":"","category":"section"},{"location":"quick_start_guide/","page":"Quick Start Guide","title":"Quick Start Guide","text":"Data can be loaded from a pss/e raw file and a pss/e dyr file.","category":"page"},{"location":"quick_start_guide/","page":"Quick Start Guide","title":"Quick Start Guide","text":"using PowerSystems\nusing PowerSimulationsDynamics\nusing PowerSystemCaseBuilder\nusing Sundials\nusing Plots\n\nomib_sys = build_system(PSIDSystems, \"OMIB System\")","category":"page"},{"location":"quick_start_guide/#Define-the-Simulation","page":"Quick Start Guide","title":"Define the Simulation","text":"","category":"section"},{"location":"quick_start_guide/","page":"Quick Start Guide","title":"Quick Start Guide","text":"time_span = (0.0, 30.0)\nperturbation_trip = BranchTrip(1.0, Line, \"BUS 1-BUS 2-i_1\")\nsim = Simulation!(ResidualModel, omib_sys, pwd(), time_span, perturbation_trip)","category":"page"},{"location":"quick_start_guide/#Explore-initial-conditions-for-the-simulation","page":"Quick Start Guide","title":"Explore initial conditions for the simulation","text":"","category":"section"},{"location":"quick_start_guide/","page":"Quick Start Guide","title":"Quick Start Guide","text":"x0_init = read_initial_conditions(sim)","category":"page"},{"location":"quick_start_guide/","page":"Quick Start Guide","title":"Quick Start Guide","text":"show_states_initial_value(sim)","category":"page"},{"location":"quick_start_guide/#Obtain-small-signal-results-for-initial-conditions","page":"Quick Start Guide","title":"Obtain small signal results for initial conditions","text":"","category":"section"},{"location":"quick_start_guide/","page":"Quick Start Guide","title":"Quick Start Guide","text":"Show eigenvalues for operating point","category":"page"},{"location":"quick_start_guide/","page":"Quick Start Guide","title":"Quick Start Guide","text":" small_sig = small_signal_analysis(sim)\n summary_eigenvalues(small_sig)","category":"page"},{"location":"quick_start_guide/#Execute-the-simulation","page":"Quick Start Guide","title":"Execute the simulation","text":"","category":"section"},{"location":"quick_start_guide/","page":"Quick Start Guide","title":"Quick Start Guide","text":" execute!(sim, IDA(), dtmax = 0.02, saveat = 0.02, enable_progress_bar = false)","category":"page"},{"location":"quick_start_guide/#Make-a-plot-of-the-results","page":"Quick Start Guide","title":"Make a plot of the results","text":"","category":"section"},{"location":"quick_start_guide/","page":"Quick Start Guide","title":"Quick Start Guide","text":"results = read_results(sim)\nangle = get_state_series(results, (\"generator-102-1\", :δ));\nplot(angle, xlabel = \"time\", ylabel = \"rotor angle [rad]\", label = \"gen-102-1\")","category":"page"},{"location":"quick_start_guide/","page":"Quick Start Guide","title":"Quick Start Guide","text":"(Image: plot)","category":"page"},{"location":"quick_start_guide/","page":"Quick Start Guide","title":"Quick Start Guide","text":"If you miss PSS/e's plotting aesthetics and want something that resembles that, you can use UnicodePlots.","category":"page"},{"location":"quick_start_guide/","page":"Quick Start Guide","title":"Quick Start Guide","text":"using UnicodePlots\nunicodeplots()\nplot(angle, xlabel = \"time\", ylabel = \"rotor angle [rad]\", label = \"gen-102-1\");","category":"page"},{"location":"quick_start_guide/","page":"Quick Start Guide","title":"Quick Start Guide","text":"(Image: plot)","category":"page"},{"location":"component_models/filters/#Filters","page":"Filter","title":"Filters","text":"","category":"section"},{"location":"component_models/filters/#LCL-Filter-[LCLFilter]","page":"Filter","title":"LCL Filter [LCLFilter]","text":"","category":"section"},{"location":"component_models/filters/","page":"Filter","title":"Filter","text":"A standard LCL filter is proposed to connect the output of the converter to the grid. In this case, v_r and v_i are voltages in the capacitor, while v_r^textgrid and v_i^textgrid represent the voltage at the bus. The L filter after the capacitor can also include a step-up transformer to increase the voltage, that is model as an extra impedance.","category":"page"},{"location":"component_models/filters/","page":"Filter","title":"Filter","text":"beginalign\n doti_rtextcv = fracOmega_bl_fleft( v_r^textcv - v_r - r_f i_rtextcv + omega_textgrid l_f i_itextcv right) tag1a \n doti_itextcv = fracOmega_bl_fleft( v_i^textcv - v_i - r_f i_itextcv - omega_textgrid l_f i_rtextcv right) tag1b \n dotv_r = fracOmega_bc_fleft( i_r^textcv - i_r + omega_textgrid c_f v_i right) tag1c \n dotv_i = fracOmega_bc_fleft( i_i^textcv - i_i - omega_textgrid c_f v_r right) tag1d \n doti_r = fracOmega_bl_gleft( v_r - v_r^textgrid - r_g i_r + omega_textgrid l_g i_i right) tag1e \n doti_i = fracOmega_bl_gleft( v_i - v_i^textgrid - r_g i_i - omega_textgrid l_g i_r right) tag1f\nendalign","category":"page"},{"location":"component_models/filters/","page":"Filter","title":"Filter","text":"on which","category":"page"},{"location":"component_models/filters/","page":"Filter","title":"Filter","text":"beginalign*\nv_r^textcv + jv_i^textcv = (v_d^textcv + jv_q^textcv)e^jdeltatheta_olc\nendalign*","category":"page"},{"location":"component_models/filters/","page":"Filter","title":"Filter","text":"that comes from the converter model.","category":"page"},{"location":"component_models/filters/#RL-Filter-[RLFilter]","page":"Filter","title":"RL Filter [RLFilter]","text":"","category":"section"},{"location":"component_models/filters/","page":"Filter","title":"Filter","text":"The algebraic RL filter is used to connect the output of the converter through a RL series filter using algebraic phasor equations. The equations for the output current are:","category":"page"},{"location":"component_models/filters/","page":"Filter","title":"Filter","text":"beginalign\n i_r + ji_i = frac(v_r^textcv + j v_i^textcv) - (v_r^textgrid + jv_i^textgrid)r_f + jl_f tag2a\nendalign","category":"page"},{"location":"component_models/filters/","page":"Filter","title":"Filter","text":"on which v_r^textcv + jv_i^textcv comes from the converter model.","category":"page"},{"location":"tutorials/tutorial_activeload/#Tutorial-Active-Constant-Power-Load-model","page":"Active Load Model","title":"Tutorial Active Constant Power Load model","text":"","category":"section"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"Originally Contributed by: Rodrigo Henriquez-Auba","category":"page"},{"location":"tutorials/tutorial_activeload/#Introduction","page":"Active Load Model","title":"Introduction","text":"","category":"section"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"This tutorial will introduce you to the functionality of PowerSimulationsDynamics and PowerSystems to explore active load components and a small-signal analysis.","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"This tutorial presents a simulation of a two-bus system with a GFM inverter at bus 1, and a load on bus 2. We will change the model from a constant power load model, to a constant impedance model and then to a 12-state active constant power load model.","category":"page"},{"location":"tutorials/tutorial_activeload/#Dependencies","page":"Active Load Model","title":"Dependencies","text":"","category":"section"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"using PowerSimulationsDynamics;\nPSID = PowerSimulationsDynamics\nusing PowerSystemCaseBuilder\nusing PowerSystems\nconst PSY = PowerSystems;","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"note: Note\nPowerSystemCaseBuilder.jl is a helper library that makes it easier to reproduce examples in the documentation and tutorials. Normally you would pass your local files to create the system data instead of calling the function build_system. For more details visit PowerSystemCaseBuilder Documentation","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"PowerSystems (abbreviated with PSY) is used to properly define the data structure and establish an equilibrium point initial condition with a power flow routine using PowerFlows.","category":"page"},{"location":"tutorials/tutorial_activeload/#Load-the-system","page":"Active Load Model","title":"Load the system","text":"","category":"section"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"We load the system using PowerSystemCaseBuilder.jl. This system has an inverter located at bus 1.","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"sys = build_system(PSIDSystems, \"2 Bus Load Tutorial Droop\")","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"first(get_components(DynamicInverter, sys))","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"The load is an exponential load modeled as a constant power load since the coefficients are set to zero.","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"first(get_components(PSY.ExponentialLoad, sys))","category":"page"},{"location":"tutorials/tutorial_activeload/#Run-a-small-signal-analysis","page":"Active Load Model","title":"Run a small-signal analysis","text":"","category":"section"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"We set up the Simulation. Since the droop model does not have a frequency state, we use a constant frequency reference frame for the network.","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"sim = Simulation(ResidualModel,\n sys,\n mktempdir(),\n (0.0, 1.0),\n frequency_reference = ConstantFrequency())","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"The following provides a summary of eigenvalues for this droop system with a constant power load:","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"sm = small_signal_analysis(sim);\ndf = summary_eigenvalues(sm);\nshow(df, allrows = true, allcols = true)","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"In this inverter model, the filter is modeled using differential equations, and as described in the literature, interfacing a RL filter against an algebraic constant power load usually results in unstable behavior as observed with the positive real part eigenvalue.","category":"page"},{"location":"tutorials/tutorial_activeload/#Change-to-a-constant-impedance-load-model","page":"Active Load Model","title":"Change to a constant impedance load model","text":"","category":"section"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"Since the load is an exponential load model we can change the exponent coefficients to 2.0 to behave as a constant impedance model:","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"# Update load coefficients to 2.0\nload = first(get_components(PSY.ExponentialLoad, sys));\nPSY.set_active_power_coefficient!(load, 2.0);\nPSY.set_reactive_power_coefficient!(load, 2.0);","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"We then re-run the small-signal analysis:","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"sim = Simulation(ResidualModel,\n sys,\n mktempdir(),\n (0.0, 1.0),\n frequency_reference = ConstantFrequency())","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"sm = small_signal_analysis(sim);\ndf = summary_eigenvalues(sm);\nshow(df, allrows = true, allcols = true)","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"Observe that now the system is small-signal stable (since there is only one device the angle of the inverter is used as a reference, and hence is zero).","category":"page"},{"location":"tutorials/tutorial_activeload/#Adding-a-dynamic-active-load-model","page":"Active Load Model","title":"Adding a dynamic active load model","text":"","category":"section"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"To consider a dynamic model in the load it is only required to attach a dynamic component to the static load model. When a dynamic load model is attached, the active and reactive power of the static model are used to define reference parameters to ensure that the dynamic load model matches the static load output power.","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"Note that when a dynamic model is attached to a static model, the static model does not participate in the dynamic system equations, i.e. the only model interfacing to the network equations is the dynamic model and not the static model (the exponential load).","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"We define a function to create a active load model with the specific parameters:","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"# Parameters taken from active load model from N. Bottrell Masters\n# Thesis \"Small-Signal Analysis of Active Loads and Large-signal Analysis\n# of Faults in Inverter Interfaced Microgrid Applications\", 2014.\n\n# The parameters are then per-unitized to be scalable to represent an aggregation\n# of multiple active loads\n\n# Base AC Voltage: Vb = 380 V\n# Base Power (AC and DC): Pb = 10000 VA\n# Base AC Current: Ib = 10000 / 380 = 26.32 A\n# Base AC Impedance: Zb = 380 / 26.32 = 14.44 Ω\n# Base AC Inductance: Lb = Zb / Ωb = 14.44 / 377 = 0.3831 H\n# Base AC Capacitance: Cb = 1 / (Zb * Ωb) = 0.000183697 F\n# Base DC Voltage: Vb_dc = (√8/√3) Vb = 620.54 V\n# Base DC Current: Ib_dc = Pb / V_dc = 10000/620.54 = 16.12 A\n# Base DC Impedance: Zb_dc = Vb_dc / Ib_dc = 38.50 Ω\n# Base DC Capacitance: Cb_dc = 1 / (Zb_dc * Ωb) = 6.8886315e-5 F\n\nΩb = 2*pi*60;\nVb = 380;\nPb = 10000;\nIb = Pb / Vb;\nZb = Vb / Ib;\nLb = Zb / Ωb;\nCb = 1 / (Zb * Ωb);\nVb_dc = sqrt(8)/sqrt(3) * Vb;\nIb_dc = Pb / Vb_dc;\nZb_dc = Vb_dc / Ib_dc;\nCb_dc = 1/(Zb_dc * Ωb);\n\nfunction active_cpl(load)\n return PSY.ActiveConstantPowerLoad(\n name = get_name(load),\n r_load = 70.0 / Zb_dc,\n c_dc = 2040e-6 / Cb_dc,\n rf = 0.1 / Zb,\n lf = 2.3e-3 / Lb,\n cf = 8.8e-6 / Cb,\n rg = 0.03 / Zb,\n lg = 0.93e-3 / Lb,\n kp_pll = 0.4,\n ki_pll = 4.69,\n kpv = 0.5 * (Vb_dc / Ib_dc),\n kiv = 150.0 * (Vb_dc / Ib_dc),\n kpc = 15.0 * (Ib / Vb),\n kic = 30000.0 * (Ib / Vb),\n base_power = 100.0,\n )\nend","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"We then attach the model to the system:","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"load = first(get_components(PSY.ExponentialLoad, sys));\ndyn_load = active_cpl(load)\nadd_component!(sys, dyn_load, load)","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"Finally, we set up the simulation:","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"sim = Simulation(ResidualModel,\n sys,\n mktempdir(),\n (0.0, 1.0),\n frequency_reference = ConstantFrequency())","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"sm = small_signal_analysis(sim);\ndf = summary_eigenvalues(sm);\nshow(df, allrows = true, allcols = true)","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"Observe the new states of the active load model and that the system is small-signal stable.","category":"page"},{"location":"component_models/turbine_gov/#Prime-Movers-and-Turbine-Governors-(TG)","page":"Turbine and Governor","title":"Prime Movers and Turbine Governors (TG)","text":"","category":"section"},{"location":"component_models/turbine_gov/","page":"Turbine and Governor","title":"Turbine and Governor","text":"This section describes how mechanical power is modified to provide primary frequency control with synchronous generators. It is assumed that tau_textref = P_textref since they are decided at nominal frequency omega = 1.","category":"page"},{"location":"component_models/turbine_gov/#Fixed-TG-[TGFixed]","page":"Turbine and Governor","title":"Fixed TG [TGFixed]","text":"","category":"section"},{"location":"component_models/turbine_gov/","page":"Turbine and Governor","title":"Turbine and Governor","text":"This a simple model that set the mechanical torque to be equal to a proportion of the desired reference tau_m = eta P_textref. To set the mechanical torque to be equal to the desired power, the value of eta is set to 1.","category":"page"},{"location":"component_models/turbine_gov/#TG-Type-I-[TGTypeI]","page":"Turbine and Governor","title":"TG Type I [TGTypeI]","text":"","category":"section"},{"location":"component_models/turbine_gov/","page":"Turbine and Governor","title":"Turbine and Governor","text":"This turbine governor is described by a droop controller and a low-pass filter to model the governor and two lead-lag blocks to model the servo and reheat of the turbine governor.","category":"page"},{"location":"component_models/turbine_gov/","page":"Turbine and Governor","title":"Turbine and Governor","text":"beginalign\ndotx_g1 = frac1T_s(p_textin - x_g1) tag1a \ndotx_g2 = frac1T_c left left(1- fract_3T_cright)x_g1 - x_g2 right tag1b \ndotx_g3 = frac1T_5 leftleft(1 - fracT_4T_5right)left(x_g2 + fracT_3T_cx_g1right) - x_g3 right tag1c \ntau_m = x_g3 + fracT_4T_5left(x_g2 + fracT_3T_cx_g1right) tag1d\nendalign","category":"page"},{"location":"component_models/turbine_gov/","page":"Turbine and Governor","title":"Turbine and Governor","text":"with","category":"page"},{"location":"component_models/turbine_gov/","page":"Turbine and Governor","title":"Turbine and Governor","text":"beginalign*\np_textin = P_textref + frac1R(omega_s - 10)\nendalign*","category":"page"},{"location":"component_models/turbine_gov/#TG-Type-II-[TGTypeII]","page":"Turbine and Governor","title":"TG Type II [TGTypeII]","text":"","category":"section"},{"location":"component_models/turbine_gov/","page":"Turbine and Governor","title":"Turbine and Governor","text":"This turbine governor is a simplified model of the Type I.","category":"page"},{"location":"component_models/turbine_gov/","page":"Turbine and Governor","title":"Turbine and Governor","text":"beginalign\ndotx_g = frac1T_2leftfrac1Rleft(1 - fracT_1T_2right) (omega_s - omega) - x_gright tag2a \ntau_m = P_textref + frac1RfracT_1T_2(omega_s - omega) tag2b\nendalign","category":"page"},{"location":"component_models/turbine_gov/#TGOV1-[SteamTurbineGov1]","page":"Turbine and Governor","title":"TGOV1 [SteamTurbineGov1]","text":"","category":"section"},{"location":"component_models/turbine_gov/","page":"Turbine and Governor","title":"Turbine and Governor","text":"This represents a classical Steam-Turbine Governor, known as TGOV1.","category":"page"},{"location":"component_models/turbine_gov/","page":"Turbine and Governor","title":"Turbine and Governor","text":"beginalign\ndotx_g1 = frac1T_1 (textref_in - x_g1) tag3a \ndotx_g2 = frac1T_3 left(x_g1^textsat left(1 - fracT_2T_3right) - x_g2right) tag3b\nendalign","category":"page"},{"location":"component_models/turbine_gov/","page":"Turbine and Governor","title":"Turbine and Governor","text":"with","category":"page"},{"location":"component_models/turbine_gov/","page":"Turbine and Governor","title":"Turbine and Governor","text":"beginalign\ntextref_in = frac1R (P_ref - (omega - 10)) tag3c \nx_g1^textsat = left beginarraycl\n x_g1 text if V_min le x_g1 le V_max\n V_max text if x_g1 V_max \n V_min text if x_g1 V_min\n endarray right tag3d \ntau_m = x_g2 + fracT_2T_3 x_g1 - D_T(omega - 10) tag3e\nendalign","category":"page"},{"location":"component_models/turbine_gov/#GAST-[GasTG]","page":"Turbine and Governor","title":"GAST [GasTG]","text":"","category":"section"},{"location":"component_models/turbine_gov/","page":"Turbine and Governor","title":"Turbine and Governor","text":"This turbine governor represents the Gas Turbine representation, known as GAST.","category":"page"},{"location":"component_models/turbine_gov/","page":"Turbine and Governor","title":"Turbine and Governor","text":"beginalign\ndotx_g1 = frac1T_1 (x_in - x_g1) tag4a \ndotx_g2 = frac1T_2 left(x_g1^textsat - x_g2right) tag4b \ndotx_g3 = frac1T_3 (x_g2 - x_g3) tag4c\nendalign","category":"page"},{"location":"component_models/turbine_gov/","page":"Turbine and Governor","title":"Turbine and Governor","text":"with","category":"page"},{"location":"component_models/turbine_gov/","page":"Turbine and Governor","title":"Turbine and Governor","text":"beginalign\nx_in = minleftP_ref - frac1R(omega - 10) A_T + K_T (A_T - x_g3) right tag4d \nx_g1^textsat = left beginarraycl\n x_g1 text if V_min le x_g1 le V_max\n V_max text if x_g1 V_max \n V_min text if x_g1 V_min\n endarray right tag4e \ntau_m = x_g2 - D_T(omega - 10) tag4f\nendalign","category":"page"},{"location":"component_models/turbine_gov/#HYGOV-[HydroTurbineGov]","page":"Turbine and Governor","title":"HYGOV [HydroTurbineGov]","text":"","category":"section"},{"location":"component_models/turbine_gov/","page":"Turbine and Governor","title":"Turbine and Governor","text":"This represents a classical hydro governor, known as HYGOV.","category":"page"},{"location":"component_models/turbine_gov/","page":"Turbine and Governor","title":"Turbine and Governor","text":"beginalign\nT_fdotx_g1 = P_in - x_g1 tag5a \ndotx_g2 = x_g1 tag5b\nT_g dotx_g3 = c - x_g3 tag5c\ndotx_g4 = frac1 - hT_w tag5d\nendalign","category":"page"},{"location":"component_models/turbine_gov/","page":"Turbine and Governor","title":"Turbine and Governor","text":"with","category":"page"},{"location":"component_models/turbine_gov/","page":"Turbine and Governor","title":"Turbine and Governor","text":"beginalign\nP_in = P_ref - Delta omega - R x_g2 tag5e \nc = fracx_g1r + fracx_g2rT_r tag5f \nh = left(fracx_g4x_g3right)^2 tag5g\ntau_m = hcdot A_t(x_g4 - q_NL) - D_turb Deltaomega cdot x_g3 tag5h\nendalign","category":"page"},{"location":"small/#Small-Signal-Analysis","page":"Small Signal","title":"Small Signal Analysis","text":"","category":"section"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"Here we discuss the method used to do a small signal analysis on the DAE system defined in PowerSimulationsDynamics.jl. The package defines algebraic variables for both real and imaginary voltages on all buses (except if they have a dynamic line connected, on which the voltage of those buses are treated as differential variables). In addition, each dynamic device can add differential variables (or states) that are concatenated to construct the system of differential algebraic equations.","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"Note: The validation of small signal results is still work in progress due to the differences in the way that different software packages perform the calculations.","category":"page"},{"location":"small/#Automatic-Differentiation","page":"Small Signal","title":"Automatic Differentiation","text":"","category":"section"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"Once an equilibrium point is found, the complete jacobian of the non-linear system can be obtained using automatic differentiation in Julia. In particular, the package ForwardDiff.jl is used to obtain the jacobian of the non-linear algebraic system of equations. PowerSimulationsDynamics.jl handles the resulting jacobian and reports the reduced jacobian and the corresponding eigenvalues and eigenvectors.","category":"page"},{"location":"small/#Jacobian-Reduction","page":"Small Signal","title":"Jacobian Reduction","text":"","category":"section"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"We define y as the vector of algebraic variables, x as the vector of differential variables (states) and p the parameters of the system, we can define g(yxp) as the vector of algebraic equations and f(yxp) as the vector of differential equations. With that, the non-linear differential algebraic system of equations can be written as:","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"beginalign\nleftbeginarrayc\n 0 \n dotx\n endarrayright = leftbeginarrayc\n g(yxp) \n f(yxp) endarrayright\nendalign","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"For small signal analysis, we are interested in the stability around an equilbrium point y_eqx_eq that satisfies dotx = 0 or equivalently f(y_eqx_eqp) = 0, while obviously satisfying g(y_eq x_eq p) = 0. To do that we use a first order approximation:","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"beginalign\nleftbeginarrayc\n 0 \n Deltadotx\n endarrayright = underbraceleftbeginarray\n g(y_eqx_eqp) \n f(y_eqx_eqp) endarrayright_ = 0\n + Jy_eq x_eq p leftbeginarrayc\n Delta y \n Delta x\n endarrayright\n endalign","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"The first to note is that the jacobian matrix can be splitted in 4 blocks depending on the specific variables we are taking the partial derivatives:","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"beginalign\nJy_eq x_eq p =\nleftbeginarraycc\n g_y g_x \n f_y f_x \n endarrayright\nendalign","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"For small signal analyses, we are interested in the stability of the differential states, while still considering that those need to evolve in the manifold defined by the linearized algebraic equations. Assuming that g_y is not singular (see chapter 7 of Federico Milano's book: Power System Modelling and Scripting or the following paper) we can eliminate the algebraic variables to obtain the reduced jacobian:","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"beginalign\nJ_textred = f_x - f_y g_y^-1 g_x\nendalign","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"that defines our reduced system for the differential variables","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"beginalign\nDelta dotx = J_textred Delta x\nendalign","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"on which we can compute its eigenvalues to analyze local stability.","category":"page"},{"location":"small/#Accessing-the-Jacobian-function","page":"Small Signal","title":"Accessing the Jacobian function","text":"","category":"section"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"You can retrieve the Jacobian function for a simulation using the get_jacobian function as follows:","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"jacobian = function get_jacobian(ResidualModel, system)","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"optionally you can pass the number of iterations to check for sparsity as follows:","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"jacobian = function get_jacobian(ResidualModel, system, 0)","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"if you specify 0, the jacobian function will use a full matrix.","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"The return of get_jacobian is known as a functor in Julia and can be used to make evaluations. Currently, any function can be evaluated with the following inputs:","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"jacobian(x)","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"This version of the function is type unstable should only be used for non-critial ops. It works to get the eigenvalues given an operating point x","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"jacobian(JM, x)","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"This version evaluates in place the value of the jacobian for an operating point x and writes to the matrix JM","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"jacobian(JM, x, p, t)","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"This version complied with the requirements to be used in DiffEq for ODE solvers. p and t aren't used they just mean to match the interfaces. See DiffEqDocs","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"jacobian(JM, dx, x, p, gamma, t)","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"This version complied with the requirements to be used in DiffEq for DAE solvers. p and t aren't used they just mean to match the interfaces. It assumes that the jacobian has the form:","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"beginalign\n JM = gamma * I + J(x)\nendalign","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"See DiffEqDocs for additional details.","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"Here we discuss the models used to describe load modeling in PowerSimulationsDynamics.jl. In a similar fashion of other devices, loads will withdraw power (i.e. current) from the current-injection balances at the nodal level. Based on the specified parameters and model chosen, the equations for computing such withdrawal will change.","category":"page"},{"location":"component_models/loads/#Static-Loads-(or-Algebraic-Loads)","page":"Load Models","title":"Static Loads (or Algebraic Loads)","text":"","category":"section"},{"location":"component_models/loads/#ZIP-Exponential-Load-Model","page":"Load Models","title":"ZIP + Exponential Load Model","text":"","category":"section"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"PowerSimulationsDynamics.jl uses all the static ZIP and exponential loads at each bus to obtain a single structure that creates an aggregate ZIP load model and a collection of all exponential loads.","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"The ZIP load model given by:","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"beginalign\nP_textzip = P_textpower + P_textcurrent cdot fracVV_0 + P_textimpedance cdot left(fracVV_0right)^2 tag1a\nQ_textzip = Q_textpower + Q_textcurrent cdot fracVV_0 + Q_textimpedance cdot left(fracVV_0right)^2tag1b\nendalign","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"with V = sqrtV_r^2 + V_i^2 and V_0 the voltage magnitude from the power flow solution.","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"The current taken for the load is computed as:","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"beginalign\nI_textzip = frac(P_textzip + j Q_textzip)^*(V_r + j V_i)^*tag1c \nI_textzip = fracP_textzip - j Q_textzipV_r - j V_itag1d\nendalign","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"For constant impedance load, the current obtained is:","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"beginalign\nI_textre^z = frac1V_0^2 cdot (V_r cdot P_textimpedance + V_i cdot Q_textimpedance)tag1e \nI_textim^z = frac1V_0^2 cdot (V_i cdot P_textimpedance - V_r cdot Q_textimpedance)tag1f\nendalign","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"For constant current load, the current obtained is:","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"beginalign\nI_textre^i = frac1V_0 cdot fracV_r * P_textcurrent + V_i * Q_textcurrentV tag1g\nI_textim^i = frac1V_0 cdot fracV_i * P_textcurrent - V_r * Q_textcurrentV tag1h\nendalign","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"For constant power load, the current obtained is:","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"beginalign\nI_textre^p = fracV_r cdot P_textpower + V_i cdot Q_textpowerV^2 tag1i \nI_textim^p = fracV_i cdot P_textpower - V_r cdot Q_textpowerV^2 tag1j\nendalign","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"Then the total current withdrawed from the ZIP load model is simply","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"beginalign\nI_textzip^textre = I_textre^z + I_textre^i + I_textre^p tag1k \nI_textzip^textim = I_textim^z + I_textim^i + I_textim^p tag1l\nendalign","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"On the case of Exponential Loads, the model is given by:","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"beginalign\nP_textexp = P_0 cdot left(fracVV_0right)^alpha tag1m\nQ_textexp = Q_0 cdot left(fracVV_0right)^beta tag1n\nendalign","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"The current taken for the load is computed as:","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"beginalign\nI_textexp = frac(P_textexp + j Q_textexp)^*(V_r + j V_i)^* tag1o \nI_textexp = fracP_textexp - j Q_textexpV_r - j V_i tag1p\nendalign","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"that results:","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"beginalign\nI_textexp^textre = V_r cdot P_0 cdot fracV^alpha - 2V_0^alpha + V_i cdot Q_0 cdot fracV^beta - 2V_0^beta tag1q\nI_textexp^textim = V_i cdot P_0 cdot fracV^alpha - 2V_0^alpha - V_r cdot Q_0 cdot fracV^beta - 2V_0^beta tag1r\nendalign","category":"page"},{"location":"component_models/loads/#Dynamic-loads","page":"Load Models","title":"Dynamic loads","text":"","category":"section"},{"location":"component_models/loads/#th-order-Single-Cage-Induction-Machine-[SingleCageInductionMachine]","page":"Load Models","title":"5th-order Single Cage Induction Machine [SingleCageInductionMachine]","text":"","category":"section"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"The following model is used to model a 5th-order induction machine with a quadratic relationship speed-torque. Refer to \"Analysis of Electric Machinery and Drive Systems\" by Paul Krause, Oleg Wasynczuk and Scott Sudhoff for the equations derivation","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"beginalign\ndotpsi_qs = Omega_b (v_qs - omega_textsys psi_ds - R_s i_qs) tag2a\ndotpsi_ds = Omega_b (v_ds + omega_textsys psi_qs - R_s i_ds) tag2b \ndotpsi_qr = Omega_b left(v_qr - (omega_textsys - omega_r) psi_dr + fracR_rX_lr (psi_mq - psi_qr)right) tag2c\ndotpsi_dr = Omega_b left(v_dr + (omega_textsys - omega_r) psi_qr + fracR_rX_lr (psi_md - psi_dr)right) tag2d\ndotomega_r = frac12H (tau_e - tau_m0(A omega_r^2 + B omega_r + C)) tag2e\nendalign","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"where:","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"beginalign*\nX_ad = X_aq = left(frac1X_m + frac1X_ls + frac1X_lrright)^-1 \nv_qs = V_i^textbus \nv_ds = V_r^textbus \nv_qr = v_dr = 0 \npsi_mq = X_aq left(fracpsi_qsX_ls+ fracpsi_qrX_lrright) \npsi_md = X_ad left(fracpsi_dsX_ls+ fracpsi_drX_lrright) \ni_qs = frac1X_ls (psi_qs - psi_mq) \ni_ds = frac1X_ls (psi_ds - psi_md) \ntau_e = psi_ds i_qs - psi_qs i_ds \nendalign*","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"Finally, the withdrawed current from the bus is:","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"beginalign*\nI_r = left(fracS_textmotorS_textbaseright) (i_ds - v_qs B_sh) \nI_i = left(fracS_textmotorS_textbaseright) (i_qs + v_ds B_sh) \nendalign*","category":"page"},{"location":"component_models/loads/#rd-order-Single-Cage-Induction-Machine-[SimplifiedSingleCageInductionMachine]","page":"Load Models","title":"3rd-order Single Cage Induction Machine [SimplifiedSingleCageInductionMachine]","text":"","category":"section"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"The following models approximates the stator fluxes dynamics of the 5th-order model by using algebraic equations.","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"beginalign\ndotpsi_qr = Omega_b left(v_qr - (omega_textsys - omega_r) psi_dr - R_r i_qr right) tag3a \ndotpsi_dr = Omega_b left(v_dr + (omega_textsys - omega_r) psi_qr - R_r i_drright) tag3b \ndotomega_r = frac12H (tau_e - tau_m0(A omega_r^2 + B omega_r + C)) tag3c\nendalign","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"where","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"beginalign*\nv_qs = V_i^textbus \nv_ds = V_r^textbus \nv_qr = v_dr = 0 \ni_qs = frac1R_s^2 + omega_textsys^2 X_p^2 left( (R_s v_qs - omega_textsys X_p v_ds) - left(R_s omega_textsys fracX_mX_rr psi_dr + omega_textsys^2 X_p fracX_mX_rr psi_qr right) right) \ni_ds = frac1R_s^2 + omega_textsys^2 X_p^2 left( (R_s v_ds + omega_textsys X_p v_qs) - left(-R_s omega_textsys fracX_mX_rr psi_qr + omega_textsys^2 X_p fracX_mX_rr psi_dr right) right) \ni_qr = frac1X_rr (psi_qr - X_m i_qs) \ni_dr = frac1X_rr (psi_dr - X_m i_ds) \ntau_e = psi_qr i_dr - psi_dr i_qr \nendalign*","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"Finally, the withdrawed current from the bus is:","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"beginalign*\nI_r = left(fracS_textmotorS_textbaseright) (i_ds - v_qs B_sh) \nI_i = left(fracS_textmotorS_textbaseright) (i_qs + v_ds B_sh) \nendalign*","category":"page"},{"location":"component_models/loads/#Active-Constant-Power-Load-Model","page":"Load Models","title":"Active Constant Power Load Model","text":"","category":"section"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"The following 12-state model Active Load model that measures the AC side using a Phase-Lock-Loop (PLL) and regulates a DC voltage to supply a resistor r_L. This model induces a constant power load-like behavior as it tries to maintain a fixed DC voltage to supply P = v_textDC^2 r_L. The model is based on the following reference. ","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"The complete model is given by:","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"beginalign\n dottheta = Omega_b (omega_textpll - omega_s) tag4a \n dotepsilon = v_texto^q tag4b\n omega_textpll = omega^star + k^p_textpll v_texto^q + k_textpll^i epsilon tag4c\n dotzeta = v_textDC^star - v_textDC tag4d \n i_textcv^dstar = k_textDC^p ( v_textDC^star - v_textDC) + k_textDC^i zeta tag4e \n fracc_textDCOmega_b dotv_textDC = fracp_textcvv_textDC - fracv_textDCr_L tag4f \n dotgamma_d = i_textcv^d - i_textcv^dstar tag4g\n dotgamma_q = i_textcv^q - i_textcv^qstar tag4h \n v_textcv^dstar = k_textpc( i_textcv^d - i_textcv^dstar) + k_textic gamma_d + omega_textpll l_f i_textcv^q tag4i\n v_textcv^qstar = k_textpc( i_textcv^q - i_textcv^qstar) + k_textic gamma_q - omega_textpll l_f i_textcv^d tag4j\nendalign","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"Equations (4a)–(4c) describes the PLL dynamics to lock the active load to the grid. Equations (4d)-(4e) describes the DC Voltage Controller to steer the DC voltage to v_textDC^star, while equation (4f) describes the DC voltage dynamics at the capacitor assuming an ideal converter. Finally, equations (4g)–(4j) describes the dynamics of the AC Current Controller. Additionally six states are defined for the LCL filter in a similar fashion of GFM inverters.","category":"page"},{"location":"tutorials/tutorial_240bus/#[PSSE-240-Bus-Case-system-with-Renewables](https://www.nrel.gov/grid/test-case-repository.html)","page":"240 WECC solver comparison","title":"PSSE 240 Bus Case system with Renewables","text":"","category":"section"},{"location":"tutorials/tutorial_240bus/","page":"240 WECC solver comparison","title":"240 WECC solver comparison","text":"Originally Contributed by: José Daniel Lara","category":"page"},{"location":"tutorials/tutorial_240bus/#Introduction","page":"240 WECC solver comparison","title":"Introduction","text":"","category":"section"},{"location":"tutorials/tutorial_240bus/","page":"240 WECC solver comparison","title":"240 WECC solver comparison","text":"This tutorial will introduce the industry models of Renewable Energy the comparisons between DiffEq Integration techniques for comparison. We show the uses of Sundials and OrdinaryDiffEq to obtain the transient response of a system to a perturbation.","category":"page"},{"location":"tutorials/tutorial_240bus/","page":"240 WECC solver comparison","title":"240 WECC solver comparison","text":"using PowerSimulationsDynamics\nusing PowerSystemCaseBuilder\nusing PowerSystems\nconst PSY = PowerSystems\nusing Sundials\nusing Plots\nusing OrdinaryDiffEq","category":"page"},{"location":"tutorials/tutorial_240bus/","page":"240 WECC solver comparison","title":"240 WECC solver comparison","text":"note: Note\nPowerSystemCaseBuilder.jl is a helper library that makes it easier to reproduce examples in the documentation and tutorials. Normally you would pass your local files to create the system data instead of calling the function build_system. For more details visit PowerSystemCaseBuilder Documentation","category":"page"},{"location":"tutorials/tutorial_240bus/#Load-the-system-and-transform-load-data","page":"240 WECC solver comparison","title":"Load the system and transform load data","text":"","category":"section"},{"location":"tutorials/tutorial_240bus/","page":"240 WECC solver comparison","title":"240 WECC solver comparison","text":"To load the system we use PowerSystemCaseBuilder.jl:","category":"page"},{"location":"tutorials/tutorial_240bus/","page":"240 WECC solver comparison","title":"240 WECC solver comparison","text":"# We remove the checks in this example to avoid large prints\nsys = build_system(PSIDSystems, \"WECC 240 Bus\"; runchecks = false)\n\n# Transform the system's load\nfor l in get_components(PSY.StandardLoad, sys)\n transform_load_to_constant_impedance(l)\nend","category":"page"},{"location":"tutorials/tutorial_240bus/#Build-the-simulation-and-initialize-the-problem","page":"240 WECC solver comparison","title":"Build the simulation and initialize the problem","text":"","category":"section"},{"location":"tutorials/tutorial_240bus/","page":"240 WECC solver comparison","title":"240 WECC solver comparison","text":"The next step is to create the simulation structure. This will create the indexing of our system that will be used to formulate the differential-algebraic system of equations. To do so, it is required to specify the perturbation that will occur in the system. In this case, we will use a ResidualModel formulation, for more details about the formulation checkout the Models Section in PowerSimulationsDynamics.jl documentation.","category":"page"},{"location":"tutorials/tutorial_240bus/","page":"240 WECC solver comparison","title":"240 WECC solver comparison","text":"using Logging\nsim_ida = Simulation(\n ResidualModel,\n sys, #system\n pwd(),\n (0.0, 20.0), #time span\n BranchTrip(1.0, Line, \"CORONADO -1101-PALOVRDE -1401-i_10\");\n console_level = Logging.Info,\n)","category":"page"},{"location":"tutorials/tutorial_240bus/#Run-the-simulation-using-Sundials","page":"240 WECC solver comparison","title":"Run the simulation using Sundials","text":"","category":"section"},{"location":"tutorials/tutorial_240bus/","page":"240 WECC solver comparison","title":"240 WECC solver comparison","text":"We will now run the simulation using Sundials.jl solver IDA() by specifying the maximum dt we want for the simulation. In our experience with this solver, solution times are faster when supplying information about the maximum time step than the tolerances as we can see in the example","category":"page"},{"location":"tutorials/tutorial_240bus/","page":"240 WECC solver comparison","title":"240 WECC solver comparison","text":"execute!(sim_ida, IDA(), dtmax = 0.01)","category":"page"},{"location":"tutorials/tutorial_240bus/#Read-the-results-and-plot-a-system-variable","page":"240 WECC solver comparison","title":"Read the results and plot a system variable","text":"","category":"section"},{"location":"tutorials/tutorial_240bus/","page":"240 WECC solver comparison","title":"240 WECC solver comparison","text":"After the simulation is completed, we can extract the results and make plots as desired. In this case, we will plot the voltage magnitude at the bus at which the line was connected.","category":"page"},{"location":"tutorials/tutorial_240bus/","page":"240 WECC solver comparison","title":"240 WECC solver comparison","text":"res_ida = read_results(sim_ida)\nv1101_ida = get_voltage_magnitude_series(res_ida, 1101);\nplot(v1101_ida);","category":"page"},{"location":"tutorials/tutorial_240bus/","page":"240 WECC solver comparison","title":"240 WECC solver comparison","text":"(Image: plot)","category":"page"},{"location":"tutorials/tutorial_240bus/#Run-the-simulation-using-Rodas4()","page":"240 WECC solver comparison","title":"Run the simulation using Rodas4()","text":"","category":"section"},{"location":"tutorials/tutorial_240bus/","page":"240 WECC solver comparison","title":"240 WECC solver comparison","text":"In this case, we will use a MassMatrixModel formulation, for more details about the formulation checkout the Models Section in PowerSimulationsDynamics.jl documentation","category":"page"},{"location":"tutorials/tutorial_240bus/","page":"240 WECC solver comparison","title":"240 WECC solver comparison","text":"sim_rodas = Simulation(\n MassMatrixModel,\n sys, #system\n pwd(),\n (0.0, 20.0), #time span\n BranchTrip(1.0, Line, \"CORONADO -1101-PALOVRDE -1401-i_10\");\n console_level = Logging.Info,\n)","category":"page"},{"location":"tutorials/tutorial_240bus/","page":"240 WECC solver comparison","title":"240 WECC solver comparison","text":"We will now run the simulation using OrdinaryDiffEq.jl solver Rodas4() by specifying the tolerance we want for the simulation. In our experience with this solver, solution times are faster when supplying information about the atol and rtol values as we can see in the example. The solver will also work with a specified dtmax but take a significantly longer time to solve. When using OrdinaryDiffEq.jl solvers always pass the option initializealg = NoInit() to avoid unnecessary re-initialization of the algebraic equations.","category":"page"},{"location":"tutorials/tutorial_240bus/","page":"240 WECC solver comparison","title":"240 WECC solver comparison","text":"execute!(\n sim_rodas,\n Rodas4(),\n saveat = 0.01,\n atol = 1e-10,\n rtol = 1e-10,\n initializealg = NoInit(),\n)","category":"page"},{"location":"tutorials/tutorial_240bus/#Read-the-results","page":"240 WECC solver comparison","title":"Read the results","text":"","category":"section"},{"location":"tutorials/tutorial_240bus/","page":"240 WECC solver comparison","title":"240 WECC solver comparison","text":"After the simulation is completed, we can extract the results and make plots as desired. In this case, we will plot the voltage magnitude at the bus at which the line was connected.","category":"page"},{"location":"tutorials/tutorial_240bus/","page":"240 WECC solver comparison","title":"240 WECC solver comparison","text":"res_rodas = read_results(sim_rodas)","category":"page"},{"location":"tutorials/tutorial_240bus/#Compare-the-results","page":"240 WECC solver comparison","title":"Compare the results","text":"","category":"section"},{"location":"tutorials/tutorial_240bus/","page":"240 WECC solver comparison","title":"240 WECC solver comparison","text":"After the simulation is completed, we can extract the results and make plots as desired. In this case, we will plot the voltage magnitude at the bus at which the line was connected. For both of the solution techniques.","category":"page"},{"location":"tutorials/tutorial_240bus/","page":"240 WECC solver comparison","title":"240 WECC solver comparison","text":"v1101 = get_voltage_magnitude_series(res_rodas, 1101);\nplot(v1101, label = \"RODAS4\");\nplot!(v1101_ida, label = \"IDA\");","category":"page"},{"location":"tutorials/tutorial_240bus/","page":"240 WECC solver comparison","title":"240 WECC solver comparison","text":"(Image: plot)","category":"page"},{"location":"component_models/freq_esti/#Frequency-Estimators","page":"Frequency Estimators","title":"Frequency Estimators","text":"","category":"section"},{"location":"component_models/freq_esti/","page":"Frequency Estimators","title":"Frequency Estimators","text":"This component is used to estimate the frequency of the grid based on the voltage at the bus.","category":"page"},{"location":"component_models/freq_esti/#Fixed-Frequency-[FixedFrequency]","page":"Frequency Estimators","title":"Fixed Frequency [FixedFrequency]","text":"","category":"section"},{"location":"component_models/freq_esti/","page":"Frequency Estimators","title":"Frequency Estimators","text":"This is a simple model that set the measured frequency to a desired constant value (i.e. does not measure the frequency) omega_pll = omega_textfix (usually omega_textfix = 10 p.u.). Used by default when grid-forming inverters do not use frequency estimators. ","category":"page"},{"location":"component_models/freq_esti/#Phase-Locked-Loop-(PLL)-for-VSM-[KauraPLL]","page":"Frequency Estimators","title":"Phase-Locked Loop (PLL) for VSM [KauraPLL]","text":"","category":"section"},{"location":"component_models/freq_esti/","page":"Frequency Estimators","title":"Frequency Estimators","text":"The following equations present a PLL used to estimate the frequency and PLL angle of the grid. There are two reference frames considered in this inverter. Those are the VSM of the outer-loop control theta_textolc and the PLL one theta_textpll. The notation used a deltatheta refers as the variation of the respective angle theta^textgrid with respect to the grid SRF (instead of the fixed alpha component of the alphabeta transformation):","category":"page"},{"location":"component_models/freq_esti/","page":"Frequency Estimators","title":"Frequency Estimators","text":"beginalign\n\ndotv_dtextpll = omega_textlp left v_dtextout - v_dtextpll right tag1a \ndotv_qtextpll = omega_textlp left v_qtextout - v_qtextpll right tag1b \ndotvarepsilon_textpll = tan^-1left(fracv_qtextpllv_dtextpll right) tag1c \ndottheta_textpll = Omega_b delta omega_textpll tag1d\nendalign","category":"page"},{"location":"component_models/freq_esti/","page":"Frequency Estimators","title":"Frequency Estimators","text":"with","category":"page"},{"location":"component_models/freq_esti/","page":"Frequency Estimators","title":"Frequency Estimators","text":"beginalign\ndeltaomega_textpll = 10 - omega_textsys + k_ptextpll tan^-1 left(fracv_qtextpllv_dtextpll right) + k_itextpll varepsilon_textpll tag1e \nomega_textpll = deltaomega_textpll + omega_textsys tag1f \nv_dtextout + jv_qtextout = (v_r + jv_i)e^-deltatheta_textpll tag1g\nendalign","category":"page"},{"location":"component_models/freq_esti/","page":"Frequency Estimators","title":"Frequency Estimators","text":"on which v_r + jv_i is the voltage in the grid reference frame on which the PLL is measuring (i.e. point of common coupling), that could be in the capacitor of an LCL filter or the last branch of such filter.","category":"page"},{"location":"component_models/freq_esti/#Reduced-Order-Phase-Locked-Loop-(PLL)-[ReducedOrderPLL]","page":"Frequency Estimators","title":"Reduced Order Phase-Locked Loop (PLL) [ReducedOrderPLL]","text":"","category":"section"},{"location":"component_models/freq_esti/","page":"Frequency Estimators","title":"Frequency Estimators","text":"The following equations presents a simplified PLL used to estimate the frequency and PLL angle of the grid. The model attempts to steer the voltage in the q-axis to zero (i.e. lock the q-axis to zero) using a PI controller. With that the equations are given by:","category":"page"},{"location":"component_models/freq_esti/","page":"Frequency Estimators","title":"Frequency Estimators","text":"beginalign\ndotv_qtextpll = omega_textlp left v_qtextout - v_qtextpll right tag2a \ndotvarepsilon_textpll = v_qtextpll tag2b \ndottheta_textpll = Omega_b delta omega_textpll tag2c\nendalign","category":"page"},{"location":"component_models/freq_esti/","page":"Frequency Estimators","title":"Frequency Estimators","text":"with","category":"page"},{"location":"component_models/freq_esti/","page":"Frequency Estimators","title":"Frequency Estimators","text":"beginalign\ndeltaomega_textpll = 10 - omega_textsys + k_ptextpll v_qtextpll + k_itextpll varepsilon_textpll tag2d \nomega_textpll = deltaomega_textpll + omega_textsys tag2e \nv_dtextout + jv_qtextout = (v_r + jv_i)e^-deltatheta_textpll tag2f\nendalign","category":"page"},{"location":"component_models/freq_esti/","page":"Frequency Estimators","title":"Frequency Estimators","text":"on which v_r + jv_i is the voltage in the grid reference frame on which the PLL is measuring (i.e. point of common coupling), that could be in the capacitor of an LCL filter or the last branch of such filter.","category":"page"},{"location":"code_base_developer_guide/developer/#Guidelines-for-Developers","page":"Developer Guide","title":"Guidelines for Developers","text":"","category":"section"},{"location":"code_base_developer_guide/developer/","page":"Developer Guide","title":"Developer Guide","text":"In order to contribute to PowerSimulationsDynamics.jl repository please read the following sections of InfrastructureSystems.jl documentation in detail:","category":"page"},{"location":"code_base_developer_guide/developer/","page":"Developer Guide","title":"Developer Guide","text":"Style Guide\nContributing Guidelines","category":"page"},{"location":"code_base_developer_guide/developer/","page":"Developer Guide","title":"Developer Guide","text":"Pull requests are always welcome to fix bugs or add additional modeling capabilities.","category":"page"},{"location":"code_base_developer_guide/developer/","page":"Developer Guide","title":"Developer Guide","text":"All the code contributions need to include tests with a minimum coverage of 70%","category":"page"},{"location":"tutorials/tutorial_dynamic_data/#Creating-and-Handling-Data-for-Dynamic-Simulations","page":"Create Dynamic Data","title":"Creating and Handling Data for Dynamic Simulations","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"Originally Contributed by: Rodrigo Henriquez and José Daniel Lara","category":"page"},{"location":"tutorials/tutorial_dynamic_data/#Introduction","page":"Create Dynamic Data","title":"Introduction","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"This tutorial briefly introduces how to create a system using PowerSystems.jl data structures. For more details visit PowerSystems.jl Documentation","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"Start by calling PowerSystems.jl and PowerSystemCaseBuilder.jl:","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"using PowerSystems\nusing PowerSystemCaseBuilder\nconst PSY = PowerSystems;","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"note: Note\nPowerSystemCaseBuilder.jl is a helper library that makes it easier to reproduce examples in the documentation and tutorials. Normally you would pass your local files to create the system data instead of calling the function build_system. For more details visit PowerSystemCaseBuilder Documentation","category":"page"},{"location":"tutorials/tutorial_dynamic_data/#System-description","page":"Create Dynamic Data","title":"System description","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"Next we need to define the different elements required to run a simulation. To run a simulation in PowerSimulationsDynamics, it is required to define a System that contains the following components:","category":"page"},{"location":"tutorials/tutorial_dynamic_data/#Static-Components","page":"Create Dynamic Data","title":"Static Components","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"We called static components to those that are used to run a Power Flow problem.","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"Vector of Bus elements, that define all the buses in the network.\nVector of Branch elements, that define all the branches elements (that connect two buses) in the network.\nVector of StaticInjection elements, that define all the devices connected to buses that can inject (or withdraw) power. These static devices, typically generators, in PowerSimulationsDynamics are used to solve the Power Flow problem that determines the active and reactive power provided for each device.\nVector of PowerLoad elements, that define all the loads connected to buses that can withdraw current. These are also used to solve the Power Flow.\nVector of Source elements, that define source components behind a reactance that can inject or withdraw current.\nThe base of power used to define per unit values, in MVA as a Float64 value.\nThe base frequency used in the system, in Hz as a Float64 value.","category":"page"},{"location":"tutorials/tutorial_dynamic_data/#Dynamic-Components","page":"Create Dynamic Data","title":"Dynamic Components","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"Dynamic components are those that define differential equations to run a transient simulation.","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"Vector of DynamicInjection elements. These components must be attached to a StaticInjection that connects the power flow solution to the dynamic formulation of such device. DynamicInjection can be DynamicGenerator or DynamicInverter, and its specific formulation (i.e. differential equations) will depend on the specific components that define such device.\n(Optional) Selecting which of the Lines (of the Branch vector) elements must be modeled of DynamicLines elements, that can be used to model lines with differential equations.","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"To start we will define the data structures for the network.","category":"page"},{"location":"tutorials/tutorial_dynamic_data/#Three-Bus-case-manual-data-creation","page":"Create Dynamic Data","title":"Three Bus case manual data creation","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"The following describes the system creation for this dynamic simulation case.","category":"page"},{"location":"tutorials/tutorial_dynamic_data/#Static-System-creation","page":"Create Dynamic Data","title":"Static System creation","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"To create the system you need to load data using PowerSystemCaseBuilder.jl. This system was originally created from following raw file. ","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"sys = build_system(PSIDSystems, \"3 Bus Inverter Base\"; force_build=true)","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"This system does not have an injection device in bus 1 (the reference bus). We can add a source with small impedance directly as follows:","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"slack_bus = [b for b in get_components(ACBus, sys) if get_bustype(b) == ACBusTypes.REF][1]\ninf_source = Source(\n name = \"InfBus\", #name\n available = true, #availability\n active_power = 0.0,\n reactive_power = 0.0,\n bus = slack_bus, #bus\n R_th = 0.0, #Rth\n X_th = 5e-6, #Xth\n)\nadd_component!(sys, inf_source)","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"We just added a infinite source with X_th = 5cdot 10^-6 pu. The system can be explored directly using functions like:","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"show_components(sys, Source)","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"show_components(sys, ThermalStandard)","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"By exploring those it can be seen that the generators are named as: generator-bus_number-id. Then, the generator attached at bus 2 is named generator-102-1.","category":"page"},{"location":"tutorials/tutorial_dynamic_data/#Dynamic-Injections","page":"Create Dynamic Data","title":"Dynamic Injections","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"We are now interested in attaching to the system the dynamic component that will be modeling our dynamic generator.","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"Dynamic generator devices are composed by 5 components, namely, machine, shaft, avr, tg and pss. So we will be adding functions to create all of its components and the generator itself:","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"# *Machine*\nmachine_classic() = BaseMachine(\n 0.0, #R\n 0.2995, #Xd_p\n 0.7087, #eq_p\n)\n\n# *Shaft*\nshaft_damping() = SingleMass(\n 3.148, #H\n 2.0, #D\n)\n\n# *AVR: No AVR*\navr_none() = AVRFixed(0.0)\n\n# *TG: No TG*\ntg_none() = TGFixed(1.0) #efficiency\n\n# *PSS: No PSS*\npss_none() = PSSFixed(0.0)","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"The next lines receives a static generator name, and creates a DynamicGenerator based on that specific static generator, with the specific components defined previously. This is a classic machine model without AVR, Turbine Governor and PSS.","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"static_gen = get_component(Generator, sys, \"generator-102-1\")\n\ndyn_gen = DynamicGenerator(\n name = get_name(static_gen),\n ω_ref = 1.0,\n machine = machine_classic(),\n shaft = shaft_damping(),\n avr = avr_none(),\n prime_mover = tg_none(),\n pss = pss_none(),\n)","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"The dynamic generator is added to the system by specifying the dynamic and static generator","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"add_component!(sys, dyn_gen, static_gen)","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"Then we can serialize our system data to a json file that can be later read as:","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"file_dir = @__DIR__ #hide\nto_json(sys, joinpath(file_dir, \"modified_sys.json\"), force = true)","category":"page"},{"location":"tutorials/tutorial_dynamic_data/#Dynamic-Lines-case:-Data-creation","page":"Create Dynamic Data","title":"Dynamic Lines case: Data creation","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"We will now create a three bus system with one inverter and one generator. In order to do so, we will parse the following ThreebusInverter.raw network:","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"threebus_sys = build_system(PSIDSystems, \"3 Bus Inverter Base\")\nslack_bus = first(get_components(x -> get_bustype(x) == BusTypes.REF, Bus, threebus_sys))\ninf_source = Source(\n name = \"InfBus\", #name\n available = true, #availability\n active_power = 0.0,\n reactive_power = 0.0,\n bus = slack_bus, #bus\n R_th = 0.0, #Rth\n X_th = 5e-6, #Xth\n)\nadd_component!(threebus_sys, inf_source)","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"We will connect a One-d-one-q machine at bus 102, and a Virtual Synchronous Generator Inverter at bus 103. An inverter is composed by a converter, outer control, inner control, dc source, frequency estimator and a filter.","category":"page"},{"location":"tutorials/tutorial_dynamic_data/#Dynamic-Inverter-definition","page":"Create Dynamic Data","title":"Dynamic Inverter definition","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"We will create specific functions to create the components of the inverter as follows:","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"#Define converter as an AverageConverter\nconverter_high_power() = AverageConverter(\n rated_voltage = 138.0,\n rated_current = 100.0\n )\n\n#Define Outer Control as a composition of Virtual Inertia + Reactive Power Droop\nouter_control() = OuterControl(\n VirtualInertia(Ta = 2.0, kd = 400.0, kω = 20.0),\n ReactivePowerDroop(kq = 0.2, ωf = 1000.0),\n)\n\n#Define an Inner Control as a Voltage+Current Controler with Virtual Impedance:\ninner_control() = VoltageModeControl(\n kpv = 0.59, #Voltage controller proportional gain\n kiv = 736.0, #Voltage controller integral gain\n kffv = 0.0, #Binary variable enabling voltage feed-forward in current controllers\n rv = 0.0, #Virtual resistance in pu\n lv = 0.2, #Virtual inductance in pu\n kpc = 1.27, #Current controller proportional gain\n kic = 14.3, #Current controller integral gain\n kffi = 0.0, #Binary variable enabling the current feed-forward in output of current controllers\n ωad = 50.0, #Active damping low pass filter cut-off frequency\n kad = 0.2, #Active damping gain\n)\n\n#Define DC Source as a FixedSource:\ndc_source_lv() = FixedDCSource(voltage = 600.0)\n\n#Define a Frequency Estimator as a PLL\n#based on Vikram Kaura and Vladimir Blaskoc 1997 paper:\npll() = KauraPLL(\n ω_lp = 500.0, #Cut-off frequency for LowPass filter of PLL filter.\n kp_pll = 0.084, #PLL proportional gain\n ki_pll = 4.69, #PLL integral gain\n)\n\n#Define an LCL filter:\nfilt() = LCLFilter(lf = 0.08, rf = 0.003, cf = 0.074, lg = 0.2, rg = 0.01)","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"We will construct the inverter later by specifying to which static device is assigned.","category":"page"},{"location":"tutorials/tutorial_dynamic_data/#Dynamic-Generator-definition","page":"Create Dynamic Data","title":"Dynamic Generator definition","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"Similarly we will construct a dynamic generator as follows:","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"# Create the machine\nmachine_oneDoneQ() = OneDOneQMachine(\n 0.0, #R\n 1.3125, #Xd\n 1.2578, #Xq\n 0.1813, #Xd_p\n 0.25, #Xq_p\n 5.89, #Td0_p\n 0.6, #Tq0_p\n)\n\n# Shaft\nshaft_no_damping() = SingleMass(\n 3.01, #H (M = 6.02 -> H = M/2)\n 0.0, #D\n)\n\n# AVR: Type I: Resembles a DC1 AVR\navr_type1() = AVRTypeI(\n 20.0, #Ka - Gain\n 0.01, #Ke\n 0.063, #Kf\n 0.2, #Ta\n 0.314, #Te\n 0.35, #Tf\n 0.001, #Tr\n (min = -5.0, max = 5.0),\n 0.0039, #Ae - 1st ceiling coefficient\n 1.555, #Be - 2nd ceiling coefficient\n)\n\n#No TG\ntg_none() = TGFixed(1.0) #efficiency\n\n#No PSS\npss_none() = PSSFixed(0.0) #Vs","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"Now we will construct the dynamic generator and inverter.","category":"page"},{"location":"tutorials/tutorial_dynamic_data/#Add-the-components-to-the-system","page":"Create Dynamic Data","title":"Add the components to the system","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"for g in get_components(Generator, threebus_sys)\n #Find the generator at bus 102\n if get_number(get_bus(g)) == 102\n #Create the dynamic generator\n case_gen = DynamicGenerator(\n get_name(g),\n 1.0, # ω_ref,\n machine_oneDoneQ(), #machine\n shaft_no_damping(), #shaft\n avr_type1(), #avr\n tg_none(), #tg\n pss_none(), #pss\n )\n #Attach the dynamic generator to the system by\n # specifying the dynamic and static components\n add_component!(threebus_sys, case_gen, g)\n #Find the generator at bus 103\n elseif get_number(get_bus(g)) == 103\n #Create the dynamic inverter\n case_inv = DynamicInverter(\n get_name(g),\n 1.0, # ω_ref,\n converter_high_power(), #converter\n outer_control(), #outer control\n inner_control(), #inner control voltage source\n dc_source_lv(), #dc source\n pll(), #pll\n filt(), #filter\n )\n #Attach the dynamic inverter to the system\n add_component!(threebus_sys, case_inv, g)\n end\nend","category":"page"},{"location":"tutorials/tutorial_dynamic_data/#Save-the-system-in-a-JSON-file","page":"Create Dynamic Data","title":"Save the system in a JSON file","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"file_dir = @__DIR__ #hide\nto_json(threebus_sys, joinpath(file_dir, \"threebus_sys.json\"), force = true)","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/#Line-Modeling-Simulations","page":"Dynamic Lines Simulation","title":"Line Modeling Simulations","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"Originally Contributed by: Rodrigo Henriquez-Auba and José Daniel Lara","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/#Introduction","page":"Dynamic Lines Simulation","title":"Introduction","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"This tutorial will introduce an example of considering dynamic lines in PowerSimulationsDynamics.","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"This tutorial presents a simulation of a three-bus system, with an infinite bus (represented as a voltage source behind an impedance) at bus 1, a one d- one q- machine on bus 2 and an inverter of 19 states, as a virtual synchronous machine at bus 3. The perturbation will be the trip of two of the three circuits (triplicating its resistance and impedance) of the line that connects bus 1 and bus 3. This case also consider a dynamic line model for connection between buses 2 and 3. We will compare it against a system without dynamic lines.","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"It is recommended to check the OMIB tutorial first, since that includes more details and explanations on all definitions and functions.","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/#Step-1:-Package-Initialization","page":"Dynamic Lines Simulation","title":"Step 1: Package Initialization","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"using PowerSimulationsDynamics\nusing PowerSystems\nusing PowerNetworkMatrices\nusing PowerSystemCaseBuilder\nusing Sundials\nusing Plots","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"note: Note\nPowerSystemCaseBuilder.jl is a helper library that makes it easier to reproduce examples in the documentation and tutorials. Normally you would pass your local files to create the system data instead of calling the function build_system. For more details visit PowerSystemCaseBuilder Documentation","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/#Step-2:-Data-creation","page":"Dynamic Lines Simulation","title":"Step 2: Data creation","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"Load the system using PowerSystemCaseBuilder.jl:","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"threebus_sys = build_system(PSIDSystems, \"Three Bus Dynamic data Example System\")","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"In addition, we will create a new copy of the system on which we will simulate the same case, but will consider dynamic lines:","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"threebus_sys_dyn = deepcopy(threebus_sys);","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/#Step-3:-Create-the-fault-and-simulation-on-the-Static-Lines-system","page":"Dynamic Lines Simulation","title":"Step 3: Create the fault and simulation on the Static Lines system","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"First, we construct the perturbation, by properly computing the new Ybus on the system:","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"#Make a copy of the original system\nsys2 = deepcopy(threebus_sys)\n#Triplicates the impedance of the line named \"BUS 1-BUS 3-i_1\"\nfault_branches = get_components(ACBranch, sys2)\nfor br in fault_branches\n if get_name(br) == \"BUS 1-BUS 3-i_1\"\n br.r = 3 * br.r\n br.x = 3 * br.x\n b_new = (from = br.b.from / 3, to = br.b.to / 3)\n br.b = b_new\n end\nend\n#Obtain the new Ybus\nYbus_fault = Ybus(sys2).data\n#Define Fault: Change of YBus\nYbus_change = NetworkSwitch(\n 1.0, #change at t = 1.0\n Ybus_fault, #New YBus\n);","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"Now, we construct the simulation:","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"#Time span of our simulation\ntspan = (0.0, 30.0)\n\n#Define Simulation\nsim = Simulation(\n ResidualModel, #Type of model used\n threebus_sys, #system\n pwd(), #folder to output results\n tspan, #time span\n Ybus_change, #Type of perturbation\n)","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"We can obtain the initial conditions as:","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"#Print the initial states. It also give the symbols used to describe those states.\nshow_states_initial_value(sim)","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/#Step-4:-Run-the-simulation-of-the-Static-Lines-System","page":"Dynamic Lines Simulation","title":"Step 4: Run the simulation of the Static Lines System","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"#Run the simulation\nexecute!(\n sim, #simulation structure\n IDA(), #Sundials DAE Solver\n dtmax = 0.02, #Maximum step size\n)","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/#Step-5:-Store-the-solution","page":"Dynamic Lines Simulation","title":"Step 5: Store the solution","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"results = read_results(sim)\nseries2 = get_voltage_magnitude_series(results, 102)\nzoom = [\n (series2[1][ix], series2[2][ix]) for\n (ix, s) in enumerate(series2[1]) if (s > 0.90 && s < 1.6)\n];","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/#Step-3.1:-Create-the-fault-and-simulation-on-the-Dynamic-Lines-system","page":"Dynamic Lines Simulation","title":"Step 3.1: Create the fault and simulation on the Dynamic Lines system","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"An important aspect to consider is that DynamicLines must not be considered in the computation of the Ybus. First we construct the Dynamic Line, by finding the Line named \"BUS 2-BUS 3-i_1\", and then adding it to the system.","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"# get component return the Branch on threebus_sys_dyn named \"BUS 2-BUS 3-i_1\"\ndyn_branch = DynamicBranch(get_component(Line, threebus_sys_dyn,\"BUS 2-BUS 3-i_1\"))\n# Adding a dynamic line will immediately remove the static line from the system.\nadd_component!(threebus_sys_dyn, dyn_branch)","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"Similarly, we construct the Ybus fault by creating a copy of the original system, but removing the Line \"BUS 2-BUS 3-i_1\" to avoid considering it in the Ybus:","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"#Make a copy of the original system\nsys3 = deepcopy(threebus_sys);\n#Remove Line \"BUS 2-BUS 3-i_1\"\nremove_component!(Line, sys3, \"BUS 2-BUS 3-i_1\")\n#Triplicates the impedance of the line named \"BUS 1-BUS 2-i_1\"\nfault_branches2 = get_components(Line, sys3)\nfor br in fault_branches2\n if get_name(br) == \"BUS 1-BUS 3-i_1\"\n br.r = 3 * br.r\n br.x = 3 * br.x\n b_new = (from = br.b.from / 3, to = br.b.to / 3)\n br.b = b_new\n end\nend\n#Obtain the new Ybus\nYbus_fault_dyn = Ybus(sys3).data\n#Define Fault: Change of YBus\nYbus_change_dyn = NetworkSwitch(\n 1.0, #change at t = 1.0\n Ybus_fault_dyn, #New YBus\n)","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/#Step-4.1:-Run-the-simulation-of-the-Dynamic-Lines-System","page":"Dynamic Lines Simulation","title":"Step 4.1: Run the simulation of the Dynamic Lines System","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"Now, we construct the simulation:","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"# Define Simulation\nsim_dyn = Simulation(\n ResidualModel, #Type of model used\n threebus_sys_dyn, #system\n pwd(), #folder to output results\n (0.0, 30.0), #time span\n Ybus_change_dyn, #Type of perturbation\n)","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"# Run the simulation\nexecute!(\n sim_dyn, #simulation structure\n IDA(), #Sundials DAE Solver\n dtmax = 0.02, #Maximum step size\n)","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"We can obtain the initial conditions as:","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"#Print the initial states. It also give the symbols used to describe those states.\nshow_states_initial_value(sim_dyn)","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/#Step-5.1:-Store-the-solution","page":"Dynamic Lines Simulation","title":"Step 5.1: Store the solution","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"results_dyn = read_results(sim_dyn)\nseries2_dyn = get_voltage_magnitude_series(results_dyn, 102);\nzoom_dyn = [\n (series2_dyn[1][ix], series2_dyn[2][ix]) for\n (ix, s) in enumerate(series2_dyn[1]) if (s > 0.90 && s < 1.6)\n];","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/#Step-6.1:-Compare-the-solutions:","page":"Dynamic Lines Simulation","title":"Step 6.1: Compare the solutions:","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"We can observe the effect of Dynamic Lines","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"plot(series2_dyn, label = \"V_gen_dyn\");\nplot!(series2, label = \"V_gen_st\", xlabel = \"Time [s]\", ylabel = \"Voltage [pu]\");","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"(Image: plot)","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"that looks quite similar. The differences can be observed in the zoom plot:","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"plot(zoom_dyn, label = \"V_gen_dyn\");\nplot!(zoom, label = \"V_gen_st\", xlabel = \"Time [s]\", ylabel = \"Voltage [pu]\");","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"(Image: plot)","category":"page"},{"location":"models/#Models","page":"Models","title":"Models","text":"","category":"section"},{"location":"models/#Simulation-Models","page":"Models","title":"Simulation Models","text":"","category":"section"},{"location":"models/","page":"Models","title":"Models","text":"PowerSimulations dynamics supports two formulations for the simulation model and define different methods for each simulation model. You can pass ResidualModel or MassMatrixModel to a call to Simulation to define the preferred formulation.","category":"page"},{"location":"models/","page":"Models","title":"Models","text":"In this way, we provide a common set of development requirements for contributors of new models that maintains the same flexibility in choosing the solving algorithm.","category":"page"},{"location":"models/","page":"Models","title":"Models","text":"MassMatrixModel: Defines models that can be solved using Mass-Matrix Solvers. The model is formulated as follows:","category":"page"},{"location":"models/","page":"Models","title":"Models","text":"beginalign\nMfracdx(t)dt = f(x(t))\nendalign","category":"page"},{"location":"models/","page":"Models","title":"Models","text":"At this stage we have not conducted extensive tests with all the solvers in DifferentialEquations most of our tests use Rodas5().","category":"page"},{"location":"models/","page":"Models","title":"Models","text":"ResidualModel: Define models that can be solved using Implicit ODE solvers and also the solver IDA from Sundials. The model is formulated to solved the following problem:","category":"page"},{"location":"models/","page":"Models","title":"Models","text":"beginalign\nr(t) = fracdx(t)dt - f(x(t))\nendalign","category":"page"},{"location":"models/","page":"Models","title":"Models","text":"At this stage we have not conducted extensive tests with all the solvers in DifferentialEquations if you are solving a larger system use IDA().","category":"page"},{"location":"models/#The-dynamic-system-model-in-PowerSimulationsDynamics","page":"Models","title":"The dynamic system model in PowerSimulationsDynamics","text":"","category":"section"},{"location":"models/","page":"Models","title":"Models","text":"In order to support both formulations, the default implementation of the ResidualModel solves the following problem:","category":"page"},{"location":"models/","page":"Models","title":"Models","text":"beginalign\nr(t) = Mfracdx(t)dt - f(x(t))\nendalign","category":"page"},{"location":"models/#Solution-approaches","page":"Models","title":"Solution approaches","text":"","category":"section"},{"location":"models/","page":"Models","title":"Models","text":"PowerSimulationsDynamics.jl construct the entire function that is passed to DifferentialEquations to solve it using different solvers. This is called the Simultaneous-solution approach to numerically integrate over time. It gives the user the flexibility to model devices with a combination of differential and algebraic states. In addition, it gives the flexibility to model the network using an algebraic or differential model.","category":"page"},{"location":"models/","page":"Models","title":"Models","text":"On the other hand, industrial tools such as PSS/E uses a Partitioned-solution approach, on which the network must be modeled using an algebraic approach, and the differential equations and algebraic equations are solved sequentially. This method is usually faster if the heuristics for convergence when solving sequentially are properly tuned. However, boundary techniques must be considered when the connection with the devices and network is not converging when applying the partitioned-solution approach.","category":"page"},{"location":"models/","page":"Models","title":"Models","text":"The difference in solution methods can complicate the validation and comparison between software tools. In addition it can affect the computational properties due to reliance of heuristics. These solution aspects are important to consider when using different tools for simulating power systems dynamics.","category":"page"},{"location":"models/","page":"Models","title":"Models","text":"For more details, check Brian Stott paper \"Power system dynamic response calculations\".","category":"page"},{"location":"models/#Generator-Models","page":"Models","title":"Generator Models","text":"","category":"section"},{"location":"models/","page":"Models","title":"Models","text":"Here we discuss the structure and models used to model generators in PowerSimulationsDynamics.jl. See PowerSystems.jl dynamic devices for details.","category":"page"},{"location":"models/","page":"Models","title":"Models","text":"Each generator is a data structure composed of the following components defined in PowerSystems.jl:","category":"page"},{"location":"models/","page":"Models","title":"Models","text":"Machine: That defines the stator electro-magnetic dynamics.\nShaft: That describes the rotor electro-mechanical dynamics.\nAutomatic Voltage Regulator: Electromotive dynamics to model an AVR controller.\nPower System Stabilizer: Control dynamics to define an stabilization signal for the AVR.\nPrime Mover and Turbine Governor: Thermo-mechanical dynamics and associated controllers.","category":"page"},{"location":"models/","page":"Models","title":"Models","text":"The implementation of Synchronous generators as components uses the following structure to share values across components.","category":"page"},{"location":"models/","page":"Models","title":"Models","text":"","category":"page"},{"location":"models/#Inverter-Models","page":"Models","title":"Inverter Models","text":"","category":"section"},{"location":"models/","page":"Models","title":"Models","text":"Here we discuss the structure and models used to model inverters in PowerSimulationsDynamics.jl. See PowerSystems.jl dynamic devices for details. One of the key contributions in this software package is a separation of the components in a way that resembles current practices for synchronoues machine modeling.","category":"page"},{"location":"models/","page":"Models","title":"Models","text":"DC Source: Defines the dynamics of the DC side of the converter.\nFrequency Estimator: That describes how the frequency of the grid can be estimated using the grid voltages. Typically a phase-locked loop (PLL).\nOuter Loop Control: That describes the active and reactive power control dynamics.\nInner Loop Control: That can describe virtual impedance, voltage control and current control dynamics.\nConverter: That describes the dynamics of the pulse width modulation (PWM) or space vector modulation (SVM).\nFilter: Used to connect the converter output to the grid.","category":"page"},{"location":"models/","page":"Models","title":"Models","text":"The following figure summarizes the components of a inverter and which variables they share:","category":"page"},{"location":"models/","page":"Models","title":"Models","text":"","category":"page"},{"location":"models/","page":"Models","title":"Models","text":"Contrary to the generator, there are many control structures that can be used to model inverter controllers (e.g. grid-following, grid feeding or virtual synchronous machine). For this purpose, more variables are shared among the components in order to cover all these posibilities.","category":"page"},{"location":"models/#Reference","page":"Models","title":"Reference","text":"","category":"section"},{"location":"models/","page":"Models","title":"Models","text":"For models, check the library in PowerSystems.jl","category":"page"},{"location":"component_models/avr/#Automatic-Voltage-Regulators-(AVR)","page":"AVR","title":"Automatic Voltage Regulators (AVR)","text":"","category":"section"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"AVR are used to determine the voltage in the field winding v_f (or V_f) in the model.","category":"page"},{"location":"component_models/avr/#Fixed-AVR-[AVRFixed]","page":"AVR","title":"Fixed AVR [AVRFixed]","text":"","category":"section"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"This is a simple model that set the field voltage to be equal to a desired constant value v_f = v_textfix.","category":"page"},{"location":"component_models/avr/#Simple-AVR-[AVRSimple]","page":"AVR","title":"Simple AVR [AVRSimple]","text":"","category":"section"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"This depicts the most basic AVR, on which the field voltage is an integrator over the difference of the measured voltage and a reference:","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"beginalign\ndotv_f = K_v(v_textref - v_h) tag1a\nendalign","category":"page"},{"location":"component_models/avr/#AVR-Type-I-[AVRTypeI]","page":"AVR","title":"AVR Type I [AVRTypeI]","text":"","category":"section"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"This AVR is a simplified version of the IEEE DC1 AVR model:","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"beginalign\ndotv_f = -frac1T_e left V_f(K_e + S_e(v_f))-v_r1 right tag2a \ndotv_r1 = frac1T_a left K_aleft(v_textref - v_m - v_r2 - fracK_fT_fv_fright) - v_r1 right tag2b \ndotv_r2 = -frac1T_f left fracK_fT_fv_f + v_r2 right tag2c \ndotv_m = frac1T_r (v_h - v_m) tag2d\nendalign","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"with the ceiling function:","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"beginalign*\nS_e(v_f) = A_e exp(B_ev_f)\nendalign*","category":"page"},{"location":"component_models/avr/#AVR-Type-II-[AVRTypeII]","page":"AVR","title":"AVR Type II [AVRTypeII]","text":"","category":"section"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"This model represents a static exciter with higher gains and faster response than the Type I:","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"beginalign\ndotv_f = -frac1T_e left V_f(1 + S_e(v_f))-v_r right tag3a \ndotv_r1 = frac1T_1 left K_0left(1 - fracT_2T_1 right)(v_textref - v_m) - v_r1 right tag3b \ndotv_r2 = frac1K_0 T_3 left left( 1 - fracT_4T_3 right) left( v_r1 + K_0fracT_2T_1(v_textref - v_m)right) - K_0 v_r2 right tag3c \ndotv_m = frac1T_r (v_h - v_m) tag3d\nendalign","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"with","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"beginalign*\nv_r = K_0v_r2 + fracT_4T_3 left( v_r1 + K_0fracT_2T_1(v_textref - v_m)right) \nS_e(v_f) = A_e exp(B_ev_f)\nendalign*","category":"page"},{"location":"component_models/avr/#Excitation-System-AC1A-[ESAC1A]","page":"AVR","title":"Excitation System AC1A [ESAC1A]","text":"","category":"section"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"The model represents the 5-states IEEE Type AC1A Excitation System Model:","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"beginalign\ndotV_m = frac1T_r (V_h - V_m) tag4a \ndotV_r1 = frac1T_b left(V_in left(1 - fracT_cT_bright) - V_r1right) tag4b \ndotV_r2 = frac1T_a (K_a V_out - V_r2) tag4c \ndotV_e = frac1T_e (V_r - V_FE) tag4d \ndotV_r3 = frac1T_f left( - fracK_fT_fV_FE - V_r3 right) tag4e \nendalign","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"with","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"beginalign*\nI_N = fracK_cV_e X_adI_fd \nV_FE = K_d X_adI_fd + K_e V_e + S_e V_e \nS_e = Bfrac(V_e-A)^2V_e \nV_F1 = V_r3 + fracK_fT_f V_FE \nV_in = V_ref - V_m - V_F1 \nV_out = V_r1 + fracT_cT_b V_in \nV_f = V_e f(I_N) \nf(I_N) = leftbeginarraycl\n 1 text if I_N le 0 \n 1 - 0577 I_N text if 0 I_N le 0433 \n sqrt075 - I_N^2 text if 0433 I_N le 075 \n 1732(1-I_N) text if 075 I_N le 1 \n 0 text if I_N 1 endarray right\nendalign*","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"on which X_adI_fd is the field current coming from the generator and V_h is the terminal voltage, and AB are the saturation coefficients computed using the E_1 E_2 S_e(E_1) S_e(E_2) data.","category":"page"},{"location":"component_models/avr/#Simplified-Excitation-System-[SEXS]","page":"AVR","title":"Simplified Excitation System [SEXS]","text":"","category":"section"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"The model for the 2 states excitation system SEXS:","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"beginalign\ndotV_f = frac1T_e (V_LL - V_f) tag5a \ndotV_r = frac1T_b leftleft(1 - fracT_aT_bright) V_in - V_r right tag5b\nendalign","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"with","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"beginalign*\nV_in = V_ref + V_s - V_h \nV_LL = V_r + fracT_aT_bV_in \nendalign*","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"on which V_h is the terminal voltage and V_s is the PSS output signal.","category":"page"},{"location":"component_models/avr/#Excitation-System-ST1-[EXST1]","page":"AVR","title":"Excitation System ST1 [EXST1]","text":"","category":"section"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"The model represents the 4-states IEEE Type ST1 Excitation System Model:","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"beginalign\ndotV_m = frac1T_r (V_h - V_m) tag6a \ndotV_rll = frac1T_b left(V_in left(1 - fracT_cT_bright) - V_rllright) tag6b \ndotV_r = frac1T_a (V_LL - V_r) tag6c \ndotV_fb = frac1T_f left( - fracK_fT_fV_r - V_fb right) tag6d \nendalign","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"with ","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"beginalign*\nV_in = V_ref - V_m - y_hp \nV_LL = V_r + fracT_cT_b V_in \ny_hp = V_fb + fracK_fT_f V_r \nV_f = V_r \nendalign*","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"on which V_h is the terminal voltage.","category":"page"},{"location":"component_models/avr/#Excitation-System-EXAC1-[EXAC1]","page":"AVR","title":"Excitation System EXAC1 [EXAC1]","text":"","category":"section"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"The model represents the 5-states IEEE Type EXAC1 Excitation System Model:","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"beginalign\ndotV_m = frac1T_r (V_h - V_m) tag7a \ndotV_r1 = frac1T_b left(V_in left(1 - fracT_cT_bright) - V_r1right) tag7b \ndotV_r2 = frac1T_a (K_a V_out - V_r2) tag7c \ndotV_e = frac1T_e (V_r - V_FE) tag7d \ndotV_r3 = frac1T_f left( - fracK_fT_fV_FE - V_r3 right) tag7e \nendalign","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"with","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"beginalign*\nI_N = fracK_cV_e X_adI_fd \nV_FE = K_d X_adI_fd + K_e V_e + S_e V_e \nS_e = Bfrac(V_e-A)^2V_e \nV_F1 = V_r3 + fracK_fT_f V_FE \nV_in = V_ref - V_m - V_F1 \nV_out = V_r1 + fracT_cT_b V_in \nV_f = V_e f(I_N) \nf(I_N) = leftbeginarraycl\n 1 text if I_N le 0 \n 1 - 0577 I_N text if 0 I_N le 0433 \n sqrt075 - I_N^2 text if 0433 I_N le 075 \n 1732(1-I_N) text if 075 I_N le 1 \n 0 text if I_N 1 endarray right\nendalign*","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"on which X_adI_fd is the field current coming from the generator and V_h is the terminal voltage, and AB are the saturation coefficients computed using the E_1 E_2 S_e(E_1) S_e(E_2) data.","category":"page"},{"location":"component_models/outer_control/#Outer-Loop-Controls","page":"Outer Control","title":"Outer Loop Controls","text":"","category":"section"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"This component defines controllers for both active and reactive power. The joint design is based on the fact that many novel control techniques can be based on joint control of active and reactive power.","category":"page"},{"location":"component_models/outer_control/#Virtual-Inertia-and-Q-droop-[OuterControl]","page":"Outer Control","title":"Virtual Inertia and Q-droop [OuterControl]","text":"","category":"section"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"The following model represent a virtual synchronous machine model to represent how active power is going to be deployed. The constructor is OuterControl{VirtualInertia, ReactivePowerDroop}. It defines a new SRF denoted as theta_textolc for the active power controller and uses a simple voltage droop for dispatching reactive power:","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"beginalign\n dotomega_textolc = fracp_textrefT_a - fracp_eT_a - frack_d(omega_textolc - omega_textpll)T_a - frack_omega(omega_textolc - omega_textref)T_a tag1a \n dottheta_textolc = Omega_b (omega_textolc - omega_textsys) tag1b \n dotq_m = omega_f (q_e - q_m) tag1c\nendalign","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"with","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"beginalign\n p_e = v_ri_r + v_ii_i tag1d \n q_e = v_ii_r - v_ri_i tag1e \n v_textolc^textref = v_textref + k_q(q_textref - q_m) tag1f\nendalign","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"In this case, the measurement of power are being done in the capacitor of the LCL filter. However, depending on the model, this measurements could be different depending on where is the point of common coupling.","category":"page"},{"location":"component_models/outer_control/#Active-Power-Droop-(P-droop)-and-Q-droop-[OuterControl]","page":"Outer Control","title":"Active Power Droop (P-droop) and Q-droop [OuterControl]","text":"","category":"section"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"The following model represent a Ptext-f droop model to represent how active power is going to be deployed. The constructor is OuterControl{ActivePowerDroop, ReactivePowerDroop}. It defines a new SRF denoted as theta_textolc for the active power controller and uses a simple voltage droop for dispatching reactive power. Both active and reactive power are measured via a low-pass filter:","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"beginalign\n dottheta_textolc = Omega_b (omega_textolc - omega_textsys) tag2a \n dotp_m = omega_z (p_e - p_m) tag2b \n dotq_m = omega_f (q_e - q_m) tag2c\nendalign","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"with","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"beginalign\n p_e = v_ri_r + v_ii_i tag2d \n q_e = v_ii_r - v_ri_i tag2e \n omega_textolc = omega_textref + R_p (p_textref - p_m) tag2f \n v_textolc^textref = v_textref + k_q(q_textref - q_m) tag2g\nendalign","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"In this case, the measurement of power are being done in the capacitor of the LCL filter. However, depending on the model, this measurements could be different depending on where is the point of common coupling.","category":"page"},{"location":"component_models/outer_control/#Active-and-Reactive-Virtual-Oscillator-Controllers-[OuterControl]","page":"Outer Control","title":"Active and Reactive Virtual Oscillator Controllers [OuterControl]","text":"","category":"section"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"The following model represents a Virtual Oscillator Controller for both active and reactive power to generate the voltage references that will be used in the Voltage Controller. The contructor is OuterControl{ActiveVirtualOscillator, ReactiveVirtualOscillator} It defines a new SRF denoted as theta_textolc and a voltage reference E_textolc. The equations are:","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"beginalign\n dottheta_textolc = Omega_b (omega_textolc - omega_textsys) tag3a \n dotE_olc = Omega_b left(frack_1E_oc (-sin(gamma) (p_textref - p_e) + cos(gamma)(q_textref - q_e)) + k_2 (V_textref - E_oc^2)E_oc right) tag3b \nendalign","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"with","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"beginalign\n gamma = psi - fracpi2 tag3c \n omega_textolc = omega_textsys + frack_1E_oc^2 left(cos(gamma) (p_textref - p_e) + sin(gamma)(q_textref - q_e) right) tag3d \n p_e = v_ri_r + v_ii_i tag3e \n q_e = v_ii_r - v_ri_i tag3f \nendalign","category":"page"},{"location":"component_models/outer_control/#Active-and-Reactive-Power-PI-Controllers-(Grid-Following)-[OuterControl]","page":"Outer Control","title":"Active and Reactive Power PI Controllers (Grid Following) [OuterControl]","text":"","category":"section"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"The following model represents a PI controller for both active and reactive power to generate the current references that will be used in the Current Controller of the inner control CurrentModeControl. The constructor is OuterControl{ActivePowerPI, ReactivePowerPI}. The equations are:","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"beginalign\n dotsigma_p = p_textref - p_m tag4a \n dotp_m = omega_z (p_e - p_m) tag4b \n dotsigma_q = q_textref - q_m tag4c \n dotq_m = omega_f (q_e - p_m) tag4d \nendalign","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"with","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"beginalign\n p_e = v_ri_r + v_ii_i tag4e \n q_e = v_ii_r - v_ri_i tag4f \n omega_textolc = omega_textpll tag4g \n theta_textolc = theta_textpll tag4h \n i_textdcv^textref = k_p^q (q_textref - q_m) + k_i^q sigma_q tag4i \n i_textqcv^textref = k_p^p (p_textref - p_m) + k_i^p sigma_p tag4j \nendalign","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"This models requires a PLL to have a SRF for an internal dq reference frame. Contrary to the Grid-Forming model, it cannot work without a PLL. Since this Outer Control outputs a current reference, it can only be used with a current mode inner control (i.e. that receives a current reference instead of a voltage reference).","category":"page"},{"location":"component_models/outer_control/#Active-and-Reactive-Generic-Renewable-Controller-Type-AB-[OuterControl]","page":"Outer Control","title":"Active and Reactive Generic Renewable Controller Type AB [OuterControl]","text":"","category":"section"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"The following model represents an outer controller for both active and reactive power from generic industrial models REPCA and REECB to generate the current references that will be used in the Current Controller of the inner control RECurrentControlB. The constructor is OuterControl{ActiveRenewableControllerAB, ReactiveRenewableControllerAB}. The equations will depend on the flags used.","category":"page"},{"location":"component_models/outer_control/#Active-part","page":"Outer Control","title":"Active part","text":"","category":"section"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"In the case of F_Flag = 1 the equations (without limits and freezing) are:","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"beginalign\n dotp_textflt = frac1T_p (p_e - p_textflt) tag5a \n dotxi_P = p_texterr tag5b \n dotp_textext = frac1T_g (K_pg p_texterr + K_ig xi_P) tag5c \n dotp_textord = frac1T_textpord (p_textext - p_textord) tag5d\nendalign","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"with","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"beginalign\n p_e = v_ri_r + v_ii_i tag5e \n p_texterr = p_textref + p_textdroop - p_textflt tag5f \nendalign","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"In the case of F_Flag = 0 the equations (without limits) are simply","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"beginalign\n dotp_textord = frac1T_textpord (p_textref - p_textord) tag5g\nendalign","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"The current command going to the Inner Loop is computed as:","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"beginalign\n I_textocpcmd = fracp_textordV_texttflt tag5h\nendalign","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"on which V_texttflt is the filtered terminal bus voltage coming from the inner controller.","category":"page"},{"location":"component_models/outer_control/#Reactive-part","page":"Outer Control","title":"Reactive part","text":"","category":"section"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"In the case of VC_Flag = 0, Ref_Flag = 0, PF_Flag = 0, V_Flag = 1 the equations (without limits and freezing) are:","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"beginalign\n dotq_textflt = frac1T_textfltr (q_e - q_textflt) tag5i \n dotxi_textqoc = q_texterr tag5j \n dotq_LL = frac1T_fv(Q_textpi ( 1 - T_ftT_fv) - q_LL) tag5k \n dotxi_Q = V_textpiin tag5l \nendalign","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"with","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"beginalign\n q_e = v_ii_r - v_ri_i tag5m \n q_texterr = q_textref - q_flt tag5n \n Q_textpi = K_p q_texterr + K_i xi_textqoc tag5o \n Q_textext = q_LL + fracT_ftT_fv Q_textpi tag5p \n V_textpiin = Q_textext - q_e tag5q \nendalign","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"The output to the inner controller are V_textocqcmd if the Q_Flag = 1 on the Inner Controller, or I_textocqcmd if Q_Flag = 0:","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"beginalign\n V_textocqcmd = (K_qp V_textpiin + K_qi xi_Q) - V_texttflt tag5r \n I_textocqmcd = fracQ_textextmax(V_texttflt 001) tag5s\nendalign","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"In the case of VC_Flag = 0, Ref_Flag = 0, PF_Flag = 0, V_Flag = 1 the equations (without limits and freezing) are:","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"beginalign\n dotq_textflt = frac1T_textfltr (q_e - q_textflt) tag5t \n dotxi_textqoc = q_texterr tag5u \n dotq_LL = frac1T_fv(Q_textpi ( 1 - T_ftT_fv) - q_LL) tag5v \nendalign","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"The remaining models for other flags will be included when implemented in PowerSimulationsDynamics.jl.","category":"page"},{"location":"perturbations/#Perturbations","page":"Perturbations","title":"Perturbations","text":"","category":"section"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"Perturbations are used to alter the system from its steady state operation. If a Simulation is properly initialized, all states will remain fixed in their initial condition if no perturbation is applied to the system.","category":"page"},{"location":"perturbations/#List-of-perturbations","page":"Perturbations","title":"List of perturbations","text":"","category":"section"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"NetworkSwitch: allows to modify directly the admittance matrix, Ybus, used in the Simulation.\nBranchTrip: completely disconnects a branch from the system.\nBranchImpedanceChange: change the impedance of a branch by a user defined multiplier. \nGeneratorTrip: allows to disconnect a Dynamic Generation unit from the system.\nControlReferenceChange: allows to change the reference setpoint provided by a generator/inverter.\nLoadChange: allows to change the active or reactive power setpoint from a load.\nLoadTrip: allows the user to disconnect a load from the system.\nSourceBusVoltageChange: allows to change the reference setpoint provided by a voltage source.","category":"page"},{"location":"perturbations/#Examples","page":"Perturbations","title":"Examples","text":"","category":"section"},{"location":"perturbations/#Example-1:-Circuit-Disconnection-using-NetworkSwitch","page":"Perturbations","title":"Example 1: Circuit Disconnection using NetworkSwitch","text":"","category":"section"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"Consider a two bus system connected via a double circuit line, on which each circuit has parameters, r = 0.0, x = 0.1, b = 0.0 per unit, then the admittance matrix of the original system is given by:","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"yb = [0.0 - 20.0im 0.0 + 20.0im\n 0.0 + 20.0im 0.0 - 20.0im]","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"Triping one circuit can be modeled by doubling the impedance, i.e., dividing by 2 the admittance:","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"new_yb = [0.0 - 10.0im 0.0 + 10.0im\n 0.0 + 10.0im 0.0 - 10.0im]","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"To apply a Network Switch, we require to use a sparse matrix, so we can do this by simply:","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"using SparseArrays\nnew_yb = sparse(new_yb)","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"Then, this perturbation ocurring at t = 10 seconds can be included as:","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"ns1 = NetworkSwitch(1.0, new_yb)","category":"page"},{"location":"perturbations/#Example-2:-Three-Phase-Fault-using-NetworkSwitch","page":"Perturbations","title":"Example 2: Three Phase Fault using NetworkSwitch","text":"","category":"section"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"Another perturbation that can be modeled is a three phase fault at Bus 1 with impedance r_f = 0.0001, x_f = 0.0 per unit, then the admittance of this new system is:","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"new_yb2 = [10000.0 - 20.0im 0.0 + 20.0im\n 0.0 + 20.0im 0.0 - 20.0im]","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"Then, this perturbation ocurring at t = 10 seconds can be included as:","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"new_yb2 = sparse(new_yb2)\nns2 = NetworkSwitch(1.0, new_yb2)","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"Now, consider that the fault is cleared at t = 105 seconds by disconnecting the Circuit 2 of the line. This can be modeled with the single circuit admittance matrix:","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"new_yb3 = [0.0 - 10.0im 0.0 + 10.0im\n 0.0 + 10.0im 0.0 - 10.0im]","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"and the perturbation as:","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"new_yb3 = sparse(new_yb3)\nns3 = NetworkSwitch(1.05, new_yb3)","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"Then, the entire perturbation for the Simulation can be included in a vector of perturbations as:","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"three_fault = [ns2, ns3]","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"that can be passed as a perturbation argument in the Simulation construction.","category":"page"},{"location":"perturbations/#Example-3:-BranchTrip","page":"Perturbations","title":"Example 3: BranchTrip","text":"","category":"section"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"Consider the following 2 bus system defined by:","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"buses = [\n Bus(1, \"nodeA\", \"REF\", 0, 1.0, (min = 0.9, max = 1.05), 230, nothing, nothing),\n Bus(2, \"nodeB\", \"PV\", 0, 1.0, (min = 0.9, max = 1.05), 230, nothing, nothing),\n]\n\nline1 = Line(\n \"Circuit1\",\n true,\n 0.0,\n 0.0,\n Arc(from = buses[1], to = buses[2]),\n 0.00,\n 0.1,\n (from = 0.0, to = 0.0),\n 2.0,\n (min = -0.7, max = 0.7),\n )\nline2 = Line(\n \"Circuit2\",\n true,\n 0.0,\n 0.0,\n Arc(from = buses[1], to = buses[2]),\n 0.0,\n 0.1,\n (from = 0.0, to = 0.0),\n 2.0,\n (min = -0.7, max = 0.7),\n )\n\nsys = System(100.0, buses, [], [], [line1, line2])","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"A Branch Trip of Circuit 2 at time t = 10 seconds, can be implemented as:","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"b_trip = BranchTrip(1.0, Line, \"Circuit2\")","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"Note: Islanding is currently not supported in PowerSimulationsDynamics.jl. If a BranchTrip isolates a generation unit, the system may diverge due to the isolated generator.","category":"page"},{"location":"perturbations/#Example-4:-BranchImpedanceChange","page":"Perturbations","title":"Example 4: BranchImpedanceChange","text":"","category":"section"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"Following the same example as before, it is possible to amplify the impedance of a single circuit by 2.0 (that would represent that this Circuit is actually composed by 2 circuits) using the following perturbation:","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"b_change = BranchImpedanceChange(1.0, Line, \"Circuit2\", 2.0)","category":"page"},{"location":"perturbations/#Example-5:-GeneratorTrip","page":"Perturbations","title":"Example 5: GeneratorTrip","text":"","category":"section"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"Consider that you have a generator at bus 102, named \"generator-102-1\" in your system called sys. The constructor to trip it from the system is:","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"g = get_component(DynamicGenerator, sys, \"generator-102-1\")\ng_trip = GeneratorTrip(1.0, g)","category":"page"},{"location":"perturbations/#Example-6:-ControlReferenceChange","page":"Perturbations","title":"Example 6: ControlReferenceChange","text":"","category":"section"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"Consider that you have a generator at bus 102, named \"generator-102-1\" in your system called sys. The constructor to change is active power reference to 0.5 is:","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"g = get_component(DynamicGenerator, sys, \"generator-102-1\")\ncrc = ControlReferenceChange(1.0, g, :P_ref, 0.5)","category":"page"},{"location":"perturbations/#Example-7:-LoadChange","page":"Perturbations","title":"Example 7: LoadChange","text":"","category":"section"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"Consider that you have a load at bus 103, named \"load-103-1\" in your system called sys. The constructor to change is active power reference to 0.8 per unit at t = 10 seconds is:","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"l_device = get_component(ElectricLoad, sys, \"load-103-1\")\nl_change = LoadChange(1.0, l_device, :P_ref, 0.8)","category":"page"},{"location":"perturbations/#Example-8:-LoadTrip","page":"Perturbations","title":"Example 8: LoadTrip","text":"","category":"section"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"Consider that you have a load at bus 103, named \"load-103-1\" in your system called sys. The constructor to disconnect such load at t = 10 seconds is:","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"l_device = get_component(ElectricLoad, sys, \"load-103-1\")\nl_trip = LoadTrip(1.0, l_device)","category":"page"},{"location":"perturbations/#Example-9:-SourceBusVoltageChange","page":"Perturbations","title":"Example 9: SourceBusVoltageChange","text":"","category":"section"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"Consider that you have a voltage source at bus 101, named \"source-101-1\" in your system called sys. The constructor to change is voltage magnitude reference to 1.02 per unit at t = 10 seconds is:","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"s_device = get_component(Source, sys, \"source-101-1\")\ns_change = SourceBusVoltageChange(1.0, s_device, 1, 1.02)","category":"page"},{"location":"component_models/machines/#Machines","page":"Machine","title":"Machines","text":"","category":"section"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"The machine component describes the stator-rotor electromagnetic dynamics.","category":"page"},{"location":"component_models/machines/#Classical-Model-(Zero-Order)-[BaseMachine]","page":"Machine","title":"Classical Model (Zero Order) [BaseMachine]","text":"","category":"section"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"This is the classical order model that does not have differential equations in its machine model (delta and omega are defined in the shaft):","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"beginalign\n left beginarrayc i_d i_q endarray right = left beginarraycc r_a -x_d x_d r_a endarray right^-1 left beginarrayc -v_d e_q - v_q endarray right tag1a\np_e approx tau_e = (v_q + r_a i_q)i_q + (v_d + r_ai_d)i_d tag1b\nendalign","category":"page"},{"location":"component_models/machines/#One-d-One-q-Model-(2nd-Order)-[OneDOneQMachine]","page":"Machine","title":"One d- One q- Model (2nd Order) [OneDOneQMachine]","text":"","category":"section"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"This model includes two transient emf with their respective differential equations:","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"beginalign\ndote_q = frac1T_d0 left-e_q + (x_d-x_d)i_d + v_fright tag2a\ndote_d = frac1T_q0 left-e_d + (x_q-x_q)i_q right tag2b\n left beginarrayc i_d i_q endarray right = left beginarraycc r_a -x_q x_d r_a endarray right^-1 left beginarrayc e_d-v_d e_q - v_q endarray right tag2c\np_e approx tau_e = (v_q + r_a i_q)i_q + (v_d + r_ai_d)i_d tag2d\nendalign","category":"page"},{"location":"component_models/machines/#Marconato-Machine-(6th-Order)-[MarconatoMachine]","page":"Machine","title":"Marconato Machine (6th Order) [MarconatoMachine]","text":"","category":"section"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"The Marconato model defines 6 differential equations, two for stator fluxes and 4 for transient and subtransient emfs:","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"beginalign\ndotpsi_d = Omega_b(r_ai_d + omega psi_q + v_d) tag3a \ndotpsi_q = Omega_b(r_ai_q - omega psi_d + v_q) tag3b \ndote_q = frac1T_d0 left-e_q - (x_d-x_d-gamma_d)i_d + left(1- fracT_AAT_d0 right) v_fright tag3c\ndote_d = frac1T_q0 left-e_d + (x_q-x_q-gamma_q)i_q right tag3d\ndote_q = frac1T_d0 left-e_q + e_q - (x_d-x_d+gamma_d)i_d + fracT_AAT_d0v_f right tag3e \ndote_d = frac1T_q0 left-e_d + e_d + (x_q-x_q+gamma_q)i_q right tag3f \ni_d = frac1x_d (e_q - psi_d) tag3g \ni_q = frac1x_q (-e_d - psi_q) tag3h \ntau_e = psi_d i_q - psi_q i_d tag3i\nendalign","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"with","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"beginalign*\n gamma_d = fracT_d0 x_dT_d0 x_d (x_d - x_d) \n gamma_q = fracT_q0 x_qT_q0 x_q (x_q - x_q)\nendalign*","category":"page"},{"location":"component_models/machines/#Simplified-Marconato-Machine-(4th-Order)-[SimpleMarconatoMachine]","page":"Machine","title":"Simplified Marconato Machine (4th Order) [SimpleMarconatoMachine]","text":"","category":"section"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"This model neglects the derivative of stator fluxes (dotpsi_d and dotpsi_q) and assume that the rotor speed stays close to 1 pu (omegapsi_d=psi_d and omegapsi_q=psi_q) that allows to remove the stator fluxes variables from the Marconato model.","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"beginalign\ndote_q = frac1T_d0 left-e_q - (x_d-x_d-gamma_d)i_d + left(1- fracT_AAT_d0 right) v_fright tag4a\ndote_d = frac1T_q0 left-e_d + (x_q-x_q-gamma_q)i_q right tag4b\ndote_q = frac1T_d0 left-e_q + e_q - (x_d-x_d+gamma_d)i_d + fracT_AAT_d0v_f right tag4c \ndote_d = frac1T_q0 left-e_d + e_d + (x_q-x_q+gamma_q)i_q right tag4d \nleft beginarrayc i_d i_q endarray right = left beginarraycc r_a -x_q x_d r_a endarray right^-1 left beginarrayc e_d-v_d e_q - v_q endarray right tag4e\np_e approx tau_e = (v_q + r_a i_q)i_q + (v_d + r_ai_d)i_d tag4f\nendalign","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"with","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"beginalign*\n gamma_d = fracT_d0 x_dT_d0 x_d (x_d - x_d) \n gamma_q = fracT_q0 x_qT_q0 x_q (x_q - x_q)\nendalign*","category":"page"},{"location":"component_models/machines/#Anderson-Fouad-Machine-(6th-Order)-[AndersonFouadMachine]","page":"Machine","title":"Anderson-Fouad Machine (6th Order) [AndersonFouadMachine]","text":"","category":"section"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"The Anderson-Fouad model also defines 6 differential equations, two for stator fluxes and 4 for transient and subtransient emfs and is derived from the Marconato model by defining gamma_d approx gamma_q approx T_AA approx 0:","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"beginalign\ndotpsi_d = Omega_b(r_ai_d + omega psi_q + v_d) tag5a \ndotpsi_q = Omega_b(r_ai_q - omega psi_d + v_q) tag5b \ndote_q = frac1T_d0 left-e_q - (x_d-x_d)i_d + v_fright tag5c\ndote_d = frac1T_q0 left-e_d + (x_q-x_q)i_q right tag5d\ndote_q = frac1T_d0 left-e_q + e_q - (x_d-x_d)i_d right tag5e \ndote_d = frac1T_q0 left-e_d + e_d + (x_q-x_q)i_q right tag5f \ni_d = frac1x_d (e_q - psi_d) tag5g \ni_q = frac1x_q (-e_d - psi_q) tag5h \ntau_e = psi_d i_q - psi_q i_d tag5i\nendalign","category":"page"},{"location":"component_models/machines/#Simplified-Anderson-Fouad-Machine-(4th-Order)-[SimpleAFMachine]","page":"Machine","title":"Simplified Anderson-Fouad Machine (4th Order) [SimpleAFMachine]","text":"","category":"section"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"Similar to the Simplified Marconato Model, this model neglects the derivative of stator fluxes (dotpsi_d and dotpsi_q) and assume that the rotor speed stays close to 1 pu (omega psi_d = psi_d and omega psi_q = psi_q) that allows to remove the stator fluxes variables from the model:","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"beginalign\ndote_q = frac1T_d0 left-e_q - (x_d-x_d)i_d + v_fright tag6a\ndote_d = frac1T_q0 left-e_d + (x_q-x_q)i_q right tag6b\ndote_q = frac1T_d0 left-e_q + e_q - (x_d-x_d)i_d right tag6c \ndote_d = frac1T_q0 left-e_d + e_d + (x_q-x_q)i_q right tag6d \nleft beginarrayc i_d i_q endarray right = left beginarraycc r_a -x_q x_d r_a endarray right^-1 left beginarrayc e_d-v_d e_q - v_q endarray right tag6e\np_e approx tau_e = (v_q + r_a i_q)i_q + (v_d + r_ai_d)i_d tag6f\nendalign","category":"page"},{"location":"component_models/machines/#Round-Rotor-Machine-(4th-Order)-[RoundRotorQuadratic,-RoundRotorExponential]","page":"Machine","title":"Round Rotor Machine (4th Order) [RoundRotorQuadratic, RoundRotorExponential]","text":"","category":"section"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"This model represents the traditional round rotor models GENROU/GENROE models implemented in PSLF/PSSE/PowerWorld. Similar to the Simplified Marconato Model, this model neglects the derivative of stator fluxes (dotpsi_d and dotpsi_q). Round rotor machines must satisfy x_d = x_q.","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"beginalign\ndote_q = frac1T_d0 leftv_f - X_adI_fdright tag7a\ndote_d = frac1T_q0 left-X_aqI_1q right tag7b\ndotpsi_kd = frac1T_d0 left-psi_kd + e_q - (x_d-x_l)i_d right tag7c \ndotpsi_kq = frac1T_q0 left-psi_kq + e_d + (x_q-x_l)i_q right tag7d \nendalign","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"with:","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"beginalign\ngamma_d1 = fracx_d - x_lx_d - x_l tag7e\ngamma_q1 = fracx_q - x_lx_q - x_l tag7f\ngamma_d2 = fracx_d - x_d(x_d-x_l)^2 tag7g\ngamma_q2 = fracx_q - x_q(x_q - x_l)^2 tag7h\ngamma_qd = fracx_q - x_lx_d - x_l tag7i\npsi_q = gamma_q1 e_d + psi_kq (1 - gamma_q1) tag7j\npsi_d = gamma_d1 e_q + gamma_d2 (x_d - x_l) psi_kd tag7k\npsi = sqrt(psi_d)^2 + (psi_q)^2 tag7l\nleft beginarrayc i_d i_q endarray right = left beginarraycc -r_a x_q -x_d r_a endarray right^-1 left beginarrayc v_d - psi_q -v_q + psi_d endarray right tag7m\nX_adI_fd = e_q + (x_d - x_d) (gamma_d1 i_d - gamma_d2 psi_kd + gamma_d2 + e_q) + textSe(psi) psi_d tag7n\nX_aqI_1q = e_d + (x_q - x_q) (gamma_q2 e_d - gamma_q2psi_kq - gamma_q1 i_q) + textSe(psi) psi_q gamma_qd tag7o \ntau_e = i_d (r_a i_d + v_d) + i_q(r_a i_q + v_q) tag7p\nendalign","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"The difference between GENROU and GENROE occurs in which additive saturation function textSe(psi) is used. Input data is provided by the saturation values at psi = 10 and psi = 12 p.u. For the GENROU model, the function used is:","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"beginalign\ntextSe(psi) = fracB(psi - A)^2 psi tag7q\nendalign","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"and for the GENROE model the function used is:","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"beginalign\ntextSe(psi) = B(psi)^A tag7r\nendalign","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"The parameters A and B for each function are computed using the two points given (10 textSe(10)) and (12 textSe(12)).","category":"page"},{"location":"component_models/machines/#Salient-Pole-Machine-(3rd-Order)-[SalientPoleQuadratic,-SalientPoleExponential]","page":"Machine","title":"Salient Pole Machine (3rd Order) [SalientPoleQuadratic, SalientPoleExponential]","text":"","category":"section"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"This model represents the traditional round rotor models GENSAL/GENSAE models implemented in PSLF/PSSE/PowerWorld. Similar to the GENROU Model, this model neglects the derivative of stator fluxes (dotpsi_d and dotpsi_q).","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"beginalign\ndote_q = frac1T_d0 leftv_f - X_adI_fdright tag8a\ndotpsi_kd = frac1T_d0 left-psi_kd + e_q - (x_d-x_l)i_d right tag8b \ndotpsi_q = frac1T_q0 left-psi_q - (x_q-x_q)i_q right tag8c \nendalign","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"with:","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"beginalign\ngamma_d1 = fracx_d - x_lx_d - x_l tag8d\ngamma_q1 = fracx_q - x_lx_q - x_l tag8e\ngamma_d2 = fracx_d - x_d(x_d-x_l)^2 tag8f\npsi_d = gamma_d1 e_q + gamma_q1 psi_kd tag8g\nleft beginarrayc i_d i_q endarray right = left beginarraycc -r_a x_q -x_d r_a endarray right^-1 left beginarrayc v_d - psi_q -v_q + psi_d endarray right tag8h\nX_adI_fd = e_q + textSe(e_q) e_q + (x_d - x_d) (i_d + gamma_d2 (e_q - psi_kd - (x_d - x_l)i_d) tag8i\ntau_e = i_d (r_a i_d + v_d) + i_q(r_a i_q + v_q) tag8j\nendalign","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"The difference between GENSAL and GENSAE occurs in which additive saturation function textSe(e_q) is used. Input data is provided by the saturation values at e_q = 10 and e_q = 12 p.u. For the GENSAL model, the function used is:","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"beginalign\ntextSe(e_q) = fracB(e_q - A)^2 e_q tag8k\nendalign","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"and for the GENSAE model the function used is:","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"beginalign\ntextSe(e_q) = B(e_q)^A tag8l\nendalign","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"The parameters A and B for each function are computed using the two points given (10 textSe(10)) and (12 textSe(12)).","category":"page"},{"location":"component_models/machines/#SauerPai-Machine-(6th-Order)-[SauerPaiMachine]","page":"Machine","title":"SauerPai Machine (6th Order) [SauerPaiMachine]","text":"","category":"section"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"The Sauer Pai model defines 6 differential equations as follows:","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"beginalign\ndotpsi_d = Omega_b(r_ai_d + omega psi_q + v_d) tag9a \ndotpsi_q = Omega_b(r_ai_q - omega psi_d + v_q) tag9b \ndote_q = frac1T_d0 left(-e_q - (x_d - x_d)(i_d + gamma_d2 cdot dotpsi_d) + v_f)right tag9c\ndote_q = frac1T_q0 left(-e_d + (x_q - x_q)(i_q + gamma_q2 cdot dotpsi_q))right tag9d\ndotpsi_d = frac1T_d0 left(-psi_d + e_q - (x_d - x_l)cdot i_d)right tag9e \ndotpsi_q = frac1T_q0 left(-psi_q - e_d - (x_q - x_l)cdot i_q)right tag9f \ni_d = frac1x_d (gamma_d1 cdot e_q - psi_d + (1 - gamma_d1) * psi_d) tag9g \ni_q = frac1x_q ((-gamma_q1 cdot e_d - psi_q + (1 - gamma_q1) cdot psi_q) tag9h \ntau_e = psi_d i_q - psi_q i_d tag9i\nendalign","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"with","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"beginalign*\n gamma_d1 = fracx_d - x_lx_d - x_l \n gamma_q1 = fracx_q - x_lx_q - x_l \n gamma_d2 = frac1 - gamma_d1x_d - x_l \n gamma_q2 = frac1 - gamma_q1x_q - x_l\nendalign*","category":"page"},{"location":"component_models/shafts/#Shafts","page":"Shaft","title":"Shafts","text":"","category":"section"},{"location":"component_models/shafts/","page":"Shaft","title":"Shaft","text":"The shaft component defines the rotating mass of the synchronous generator.","category":"page"},{"location":"component_models/shafts/#Rotor-Mass-Shaft-[SingleMass]","page":"Shaft","title":"Rotor Mass Shaft [SingleMass]","text":"","category":"section"},{"location":"component_models/shafts/","page":"Shaft","title":"Shaft","text":"This is the standard model, on which one single mass (typically the rotor) is used to model the entire inertia of the synchronous generator. Each generator's rotating frame use a reference frequency omega_s, that typically is the synchronous one (i.e. omega_s = 10). The model defines two differential equations for the rotor angle delta and the rotor speed omega:","category":"page"},{"location":"component_models/shafts/","page":"Shaft","title":"Shaft","text":"beginalign\ndotdelta = Omega_b(omega - omega_s) tag1a \ndotomega = frac12H(tau_m - tau_e - D(omega-omega_s)) tag1b\nendalign","category":"page"},{"location":"component_models/shafts/#Five-Mass-Shaft-[FiveMassShaft]","page":"Shaft","title":"Five-Mass Shaft [FiveMassShaft]","text":"","category":"section"},{"location":"component_models/shafts/","page":"Shaft","title":"Shaft","text":"This model describes model connecting a high-pressure (hp) steam turbine, intermediate-pressure (ip) steam turbine, low-pressure (lp) steam pressure, rotor and exciter (ex) connected in series (in that order) in the same shaft using a spring-mass model:","category":"page"},{"location":"component_models/shafts/","page":"Shaft","title":"Shaft","text":"beginalign\ndotdelta = Omega_b(omega - omega_s) tag2a \ndotomega = frac12H left- tau_e - D(omega-omega_s)) - D_34 (omega-omega_lp) - D_45(omega-omega_ex) + K_lp(delta_lp-delta) +K_ex(delta_ex-delta) right tag2b \ndotdelta_hp = Omega_b(omega_hp - omega_s) tag2c \ndotomega_hp = frac12H_hp left tau_m - D_hp(omega_hp-omega_s) - D_12(omega_hp - omega_ip) + K_hp(delta_ip - delta_hp) right tag2d \ndotdelta_ip = Omega_b(omega_ip - omega_s) tag2e \ndotomega_ip = frac12H_ip left- D_ip(omega_ip-omega_s) - D_12(omega_ip - omega_hp) -D_23(omega_ip - omega_lp ) + K_hp(delta_hp - delta_ip) + K_ip(delta_lp-delta_ip) right tag2f \ndotdelta_lp = Omega_b(omega_lp-omega_s) tag2g \ndotomega_lp = frac12H_lp left - D_lp(omega_lp-omega_s) - D_23(omega_lp - omega_ip) -D_34(omega_lp - omega ) + K_ip(delta_ip - delta_lp) + K_lp(delta-delta_lp) right tag2h \ndotdelta_ex = Omega_b(omega_ex-omega_s) tag2i \ndotomega_ex = frac12H_ex left - D_ex(omega_ex-omega_s) - D_45(omega_ex - omega) + K_ex(delta - delta_ex) right tag2j\nendalign","category":"page"},{"location":"api/public/#PowerSimulationsDynamics","page":"Public API Reference","title":"PowerSimulationsDynamics","text":"","category":"section"},{"location":"api/public/","page":"Public API Reference","title":"Public API Reference","text":"CurrentModule = PowerSimulationsDynamics\nDocTestSetup = quote\n using PowerSimulationsDynamics\nend","category":"page"},{"location":"api/public/","page":"Public API Reference","title":"Public API Reference","text":"Modules = [PowerSimulationsDynamics]\nPublic = true\nPrivate = false","category":"page"},{"location":"api/public/#PowerSimulationsDynamics.BranchImpedanceChange","page":"Public API Reference","title":"PowerSimulationsDynamics.BranchImpedanceChange","text":"mutable struct BranchImpedanceChange <: Perturbation\n time::Float64\n branch_type::Type{<:PSY.ACBranch}\n branch_name::String\n multiplier::Float64\nend\n\nA BranchImpedanceChange change the impedance of a branch by a user defined multiplier. Currently there is only support for static branches disconnection, PowerSystems.Line and PowerSystems.Transformer2W. Future releases will provide support for a Dynamic Line disconnection.\n\nArguments:\n\ntime::Float64 : Defines when the Branch Impedance Change will happen. This time should be inside the time span considered in the Simulation\nbranch_tipe::Type{<:PowerSystems.ACBranch} : Type of branch modified\nbranch_name::String : User defined name for identifying the branch\nmultiplier::Float64 : User defined value for impedance multiplier.\n\n\n\n\n\n","category":"type"},{"location":"api/public/#PowerSimulationsDynamics.BranchTrip","page":"Public API Reference","title":"PowerSimulationsDynamics.BranchTrip","text":"mutable struct BranchTrip <: Perturbation\n time::Float64\n branch_type::Type{<:PowerSystems.ACBranch}\n branch_name::String\nend\n\nA BranchTrip completely disconnects a branch from the system. Currently there is only support for static branches disconnection, PowerSystems.Line and PowerSystems.Transformer2W. Future releases will provide support for a Dynamic Line disconnection. Note: Islanding is currently not supported in PowerSimulationsDynamics.jl. If a BranchTrip isolates a generation unit, the system may diverge due to the isolated generator.\n\nArguments:\n\ntime::Float64 : Defines when the Branch Trip will happen. This time should be inside the time span considered in the Simulation\nbranch_tipe::Type{<:PowerSystems.ACBranch} : Type of branch disconnected\nbranch_name::String : User defined name for identifying the branch\n\n\n\n\n\n","category":"type"},{"location":"api/public/#PowerSimulationsDynamics.ControlReferenceChange","page":"Public API Reference","title":"PowerSimulationsDynamics.ControlReferenceChange","text":"mutable struct ControlReferenceChange <: Perturbation\n time::Float64\n device::PowerSystems.DynamicInjection\n signal::Symbol\n ref_value::Float64\nend\n\nA ControlReferenceChange allows to change the reference setpoint provided by a generator/inverter.\n\nArguments:\n\ntime::Float64 : Defines when the Control Reference Change will happen. This time should be inside the time span considered in the Simulation\ndevice::Type{<:PowerSystems.DynamicInjection} : Dynamic device modified\nsignal::Symbol : determines which reference setpoint will be modified. The accepted signals are:\n:P_ref: Modifies the active power reference setpoint.\n:V_ref: Modifies the voltage magnitude reference setpoint (if used).\n:Q_ref: Modifies the reactive power reference setpoint (if used).\n:ω_ref: Modifies the frequency setpoint.\nref_value::Float64 : User defined value for setpoint reference.\n\n\n\n\n\n","category":"type"},{"location":"api/public/#PowerSimulationsDynamics.GeneratorTrip","page":"Public API Reference","title":"PowerSimulationsDynamics.GeneratorTrip","text":"mutable struct GeneratorTrip <: Perturbation\n time::Float64\n device::PowerSystems.DynamicInjection\nend\n\nA GeneratorTrip allows to disconnect a Dynamic Generation unit from the system at a specified time.\n\nArguments:\n\ntime::Float64 : Defines when the Generator Trip will happen. This time should be inside the time span considered in the Simulation\ndevice::Type{<:PowerSystems.DynamicInjection} : Device to be disconnected\n\n\n\n\n\n","category":"type"},{"location":"api/public/#PowerSimulationsDynamics.LoadChange","page":"Public API Reference","title":"PowerSimulationsDynamics.LoadChange","text":"mutable struct LoadChange <: Perturbation\n time::Float64\n device::PowerSystems.ElectricLoad\n signal::Symbol\n ref_value::Float64\nend\n\nA LoadChange allows to change the active or reactive power setpoint from a load.\n\nArguments:\n\ntime::Float64 : Defines when the Load Change will happen. This time should be inside the time span considered in the Simulation\ndevice::Type{<:PowerSystems.ElectricLoad} : Dynamic device modified\nsignal::Symbol : determines which reference setpoint will be modified. The accepted signals are:\n:P_ref: Modifies the active power reference setpoint.\n:Q_ref: Modifies the reactive power reference setpoint.\nref_value::Float64 : User defined value for setpoint reference.\n\n\n\n\n\n","category":"type"},{"location":"api/public/#PowerSimulationsDynamics.LoadTrip","page":"Public API Reference","title":"PowerSimulationsDynamics.LoadTrip","text":"mutable struct LoadTrip <: Perturbation\n time::Float64\n device::PowerSystems.ElectricLoad\nend\n\nA LoadTrip allows the user to disconnect a load from the system.\n\nArguments:\n\ntime::Float64 : Defines when the Generator Trip will happen. This time should be inside the time span considered in the Simulation\ndevice::Type{<:PowerSystems.ElectricLoad} : Device to be disconnected\n\n\n\n\n\n","category":"type"},{"location":"api/public/#PowerSimulationsDynamics.MassMatrixModel-Union{Tuple{Ctype}, Tuple{Any, Vector{Float64}, Type{Ctype}}} where Ctype<:PowerSimulationsDynamics.SimCache","page":"Public API Reference","title":"PowerSimulationsDynamics.MassMatrixModel","text":"Instantiate a MassMatrixModel for ODE inputs.\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.MassMatrixModel-Union{Tuple{Ctype}, Tuple{T}, Tuple{PowerSimulationsDynamics.SimulationInputs, Vector{T}, Type{Ctype}}} where {T<:Float64, Ctype<:PowerSimulationsDynamics.JacobianCache}","page":"Public API Reference","title":"PowerSimulationsDynamics.MassMatrixModel","text":"Instantiate a MassMatrixModel for ForwardDiff calculations\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.NetworkSwitch","page":"Public API Reference","title":"PowerSimulationsDynamics.NetworkSwitch","text":"function NetworkSwitch(\n time::Float64,\n ybus::SparseArrays.SparseMatrixCSC{Complex{Float64}, Int},\n)\n\nAllows to modify directly the admittance matrix, Ybus, used in the Simulation. This allows the user to perform branch modifications, three phase faults (with impedance larger than zero) or branch trips, as long as the new Ybus provided captures that perturbation.\n\nArguments:\n\ntime::Float64 : Defines when the Network Switch will happen. This time should be inside the time span considered in the Simulation\nybus::SparseArrays.SparseMatrixCSC{Complex{Float64}, Int} : Complex admittance matrix\n\n\n\n\n\n","category":"type"},{"location":"api/public/#PowerSimulationsDynamics.PerturbState","page":"Public API Reference","title":"PowerSimulationsDynamics.PerturbState","text":"function PerturbState(\n time::Float64,\n index::Int,\n value::Float64,\n)\n\nAllows the user to modify the state index by adding value. The user should modify dynamic states only, since algebraic state may require to do a reinitialization.\n\nArguments:\n\ntime::Float64 : Defines when the modification of the state will happen. This time should be inside the time span considered in the Simulation.\nindex::Int : Defines which state index you want to modify\nvalue::Float64 : Defines how much the state will increase in value\n\n\n\n\n\n","category":"type"},{"location":"api/public/#PowerSimulationsDynamics.ResidualModel-Union{Tuple{Ctype}, Tuple{Any, Vector{Float64}, Type{Ctype}}} where Ctype<:PowerSimulationsDynamics.SimCache","page":"Public API Reference","title":"PowerSimulationsDynamics.ResidualModel","text":"Instantiate an ResidualModel for ODE inputs.\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.ResidualModel-Union{Tuple{Ctype}, Tuple{T}, Tuple{PowerSimulationsDynamics.SimulationInputs, Vector{T}, Type{Ctype}}} where {T<:Float64, Ctype<:PowerSimulationsDynamics.JacobianCache}","page":"Public API Reference","title":"PowerSimulationsDynamics.ResidualModel","text":"Instantiate an ResidualModel for ForwardDiff calculations\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.Simulation-Union{Tuple{T}, Tuple{Type{T}, System, String, Tuple{Float64, Float64}}, Tuple{Type{T}, System, String, Tuple{Float64, Float64}, Vector{<:PowerSimulationsDynamics.Perturbation}}} where T<:PowerSimulationsDynamics.SimulationModel","page":"Public API Reference","title":"PowerSimulationsDynamics.Simulation","text":"function Simulation\n ::SimulationModel\n system::PowerSystems.System\n simulation_folder::String\n tspan::NTuple{2, Float64},\n perturbations::Vector{<:Perturbation} = Vector{Perturbation}();\n kwargs...,\nend\n\nBuilds the simulation object and conducts the indexing process. The original system is not modified and a copy its created and stored in the Simulation.\n\nArguments:\n\n::SimulationModel : Type of Simulation Model. ResidualModel or MassMatrixModel. See Models Section for more details\nsystem::PowerSystems.System : System data\nsimulation_folder::String : Folder directory\ntspan::NTuple{2, Float64} : Time span for simulation\nperturbations::Vector{<:Perturbation} : Vector of Perturbations for the Simulation. Default: No Perturbations\ninitialize_simulation::Bool : Runs the initialization routine. If false, simulation runs based on the operation point stored in System\ninitial_conditions::Vector{Float64} : Allows the user to pass a vector with the initial condition values desired in the simulation. If initialize_simulation = true, these values are used as a first guess and overwritten.\nfrequency_reference : Default ReferenceBus. Determines which frequency model is used for the network. Currently there are two options available:\nConstantFrequency assumes that the network frequency is 1.0 per unit at all times.\nReferenceBus will use the frequency state of a Dynamic Generator (rotor speed) or Dynamic Inverter (virtual speed) connected to the Reference Bus (defined in the Power Flow data) as the network frequency. If multiple devices are connected to such bus, the device with larger base power will be used as a reference. If a Voltage Source is connected to the Reference Bus, then a ConstantFrequency model will be used.\nsystem_to_file::Bool : Default false. Serializes the initialized system\nconsole_level::Logging : Default Logging.Warn. Sets the level of logging output to the console. Can be set to Logging.Error, Logging.Warn, Logging.Info or Logging.Debug\nfile_level::Logging : Default Logging.Info. Sets the level of logging output to file. Can be set to Logging.Error, Logging.Warn, Logging.Info or Logging.Debug\ndisable_timer_outputs::Bool : Default false. Allows the user to display timer information about the construction and initilization of the Simulation.\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.SourceBusVoltageChange","page":"Public API Reference","title":"PowerSimulationsDynamics.SourceBusVoltageChange","text":"mutable struct SourceBusVoltageChange <: Perturbation\n time::Float64\n device::PSY.Source\n signal::Symbol\n ref_value::Float64\nend\n\nA SourceBusVoltageChange allows to change the reference setpoint provided by a voltage source.\n\nArguments:\n\ntime::Float64 : Defines when the Control Reference Change will happen. This time should be inside the time span considered in the Simulation\ndevice::Type{<:PowerSystems.Source} : Device modified\nsignal::Symbol : determines which reference setpoint will be modified. The accepted signals are:\n:V_ref Modifies the internal voltage magnitude reference setpoint.\n:θ_ref Modifies the internal voltage angle reference setpoint.\nref_value::Float64 : User defined value for setpoint reference.\n\n\n\n\n\n","category":"type"},{"location":"api/public/#PowerSimulationsDynamics.Simulation!-Union{Tuple{T}, Tuple{Type{T}, System, String, Tuple{Float64, Float64}}, Tuple{Type{T}, System, String, Tuple{Float64, Float64}, Vector{<:PowerSimulationsDynamics.Perturbation}}} where T<:PowerSimulationsDynamics.SimulationModel","page":"Public API Reference","title":"PowerSimulationsDynamics.Simulation!","text":"function Simulation!\n ::SimulationModel\n system::PowerSystems.System\n simulation_folder::String\n tspan::NTuple{2, Float64},\n perturbations::Vector{<:Perturbation} = Vector{Perturbation}();\n kwargs...,\nend\n\nBuilds the simulation object and conducts the indexing process. The initial conditions are stored in the system.\n\nArguments:\n\n::SimulationModel : Type of Simulation Model. ResidualModel or MassMatrixModel. See Models Section for more details\nsystem::PowerSystems.System : System data\nsimulation_folder::String : Folder directory\ntspan::NTuple{2, Float64} : Time span for simulation\nperturbations::Vector{<:Perturbation} : Vector of Perturbations for the Simulation. Default: No Perturbations\ninitialize_simulation::Bool : Runs the initialization routine. If false, simulation runs based on the operation point stored in System\ninitial_conditions::Vector{Float64} : Allows the user to pass a vector with the initial condition values desired in the simulation. If initialize_simulation = true, these values are used as a first guess and overwritten.\nfrequency_reference : Default ReferenceBus. Determines which frequency model is used for the network. Currently there are two options available:\nConstantFrequency assumes that the network frequency is 1.0 per unit at all times.\nReferenceBus will use the frequency state of a Dynamic Generator (rotor speed) or Dynamic Inverter (virtual speed) connected to the Reference Bus (defined in the Power Flow data) as the network frequency. If multiple devices are connected to such bus, the device with larger base power will be used as a reference. If a Voltage Source is connected to the Reference Bus, then a ConstantFrequency model will be used.\nsystem_to_file::Bool : Default false. Serializes the initialized system\nconsole_level::Logging : Default Logging.Warn. Sets the level of logging output to the console. Can be set to Logging.Error, Logging.Warn, Logging.Info or Logging.Debug\nfile_level::Logging : Default Logging.Info. Sets the level of logging output to file. Can be set to Logging.Error, Logging.Warn, Logging.Info or Logging.Debug\ndisable_timer_outputs::Bool : Default false. Allows the user to display timer information about the construction and initilization of the Simulation.\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.execute!-Tuple{Simulation, Any}","page":"Public API Reference","title":"PowerSimulationsDynamics.execute!","text":"execute!(\n sim::Simulation,\n solver;\n kwargs...\n)\n\nSolves the time-domain dynamic simulation model.\n\nArguments\n\nsim::Simulation : Initialized simulation object\nsolver : Solver used for numerical integration. Must be passed correctly depending on the Type of Simulation Model\nenable_progress_bar::Bool : Default: true. Enables progress bar for the integration routine.\nAdditional solver keyword arguments can be included. See Common Solver Options in the DifferentialEquations.jl documentation for more details.\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.get_activepower_branch_flow-Tuple{SimulationResults, String, Symbol}","page":"Public API Reference","title":"PowerSimulationsDynamics.get_activepower_branch_flow","text":"get_activepower_branch_flow(\n res::SimulationResults,\n name::String,\n location::Symbol,\n)\n\nFunction to obtain the active power flowing through the series element of a Branch. The user must specified is the power should be computed in the :from or to :bus, by specifying a symbol.\n\nIf :from is specified, the power is computed flowing outwards the :from bus. If :to is specified, the power is computed flowing into the :to bus.\n\nArguments\n\nres::SimulationResults : Simulation Results object that contains the solution\nname::String : Name to identify the specified line\nlocation::Symbol : :from or :to to specify a bus\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.get_activepower_series-Tuple{SimulationResults, String}","page":"Public API Reference","title":"PowerSimulationsDynamics.get_activepower_series","text":"get_activepower_series(\n res::SimulationResults,\n name::String,\n)\n\nFunction to obtain the active power output time series of a Dynamic Injection series out of the DAE Solution.\n\nArguments\n\nres::SimulationResults : Simulation Results object that contains the solution\nname::String : Name to identify the specified device\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.get_field_current_series-Tuple{SimulationResults, String}","page":"Public API Reference","title":"PowerSimulationsDynamics.get_field_current_series","text":"get_field_current_series(\n res::SimulationResults,\n name::String,\n)\n\nFunction to obtain the field current time series of a Dynamic Generator out of the DAE Solution.\n\nArguments\n\nres::SimulationResults : Simulation Results object that contains the solution\nname::String : Name to identify the specified device\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.get_field_voltage_series-Tuple{SimulationResults, String}","page":"Public API Reference","title":"PowerSimulationsDynamics.get_field_voltage_series","text":"get_field_voltage_series(\n res::SimulationResults,\n name::String,\n)\n\nFunction to obtain the field voltage time series of a Dynamic Generator out of the DAE Solution.\n\nArguments\n\nres::SimulationResults : Simulation Results object that contains the solution\nname::String : Name to identify the specified device\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.get_frequency_series-Tuple{SimulationResults, String}","page":"Public API Reference","title":"PowerSimulationsDynamics.get_frequency_series","text":"get_frequency_series(\n res::SimulationResults,\n name::String,\n)\n\nFunction to obtain the frequency time series of a Dynamic Injection out of the DAE Solution.\n\nArguments\n\nres::SimulationResults : Simulation Results object that contains the solution\nname::String : Name to identify the specified device\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.get_imaginary_current_branch_flow-Tuple{SimulationResults, String}","page":"Public API Reference","title":"PowerSimulationsDynamics.get_imaginary_current_branch_flow","text":"get_imaginary_current_branch_flow(\n res::SimulationResults,\n name::String,\n)\n\nFunction to obtain the imaginary current flowing through the series element of a Branch\n\nArguments\n\nres::SimulationResults : Simulation Results object that contains the solution\nname::String : Name to identify the specified line\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.get_imaginary_current_series-Tuple{SimulationResults, String}","page":"Public API Reference","title":"PowerSimulationsDynamics.get_imaginary_current_series","text":"get_imaginary_current_series(\n res::SimulationResults,\n name::String,\n)\n\nFunction to obtain the imaginary current time series of a Dynamic Injection series out of the DAE Solution.\n\nArguments\n\nres::SimulationResults : Simulation Results object that contains the solution\nname::String : Name to identify the specified device\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.get_jacobian-Union{Tuple{T}, Tuple{Type{T}, System}, Tuple{Type{T}, System, Int64}} where T<:PowerSimulationsDynamics.SimulationModel","page":"Public API Reference","title":"PowerSimulationsDynamics.get_jacobian","text":"function get_jacobian(\n::Type{T},\nsystem::PSY.System,\nsparse_retrieve_loop::Int = 3,\n) where {T <: SimulationModel}\n\nReturns the jacobian function of the system model resulting from the system data.\n\nArguments:\n\n::SimulationModel : Type of Simulation Model. ResidualModel or MassMatrixModel. See Models Section for more details\nsystem::PowerSystems.System : System data\nsparse_retrieve_loop::Int : Number of loops for sparsity detection. If 0, builds the Jacobian with a DenseMatrix\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.get_mechanical_torque_series-Tuple{SimulationResults, String}","page":"Public API Reference","title":"PowerSimulationsDynamics.get_mechanical_torque_series","text":"get_mechanical_torque_series(\n res::SimulationResults,\n name::String,\n)\n\nFunction to obtain the mechanical torque time series of the mechanical torque out of the DAE Solution.\n\nArguments\n\nres::SimulationResults : Simulation Results object that contains the solution\nname::String : Name to identify the specified device\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.get_pss_output_series-Tuple{SimulationResults, String}","page":"Public API Reference","title":"PowerSimulationsDynamics.get_pss_output_series","text":"get_pss_output_series(\n res::SimulationResults,\n name::String,\n)\n\nFunction to obtain the pss output time series of a Dynamic Generator out of the DAE Solution.\n\nArguments\n\nres::SimulationResults : Simulation Results object that contains the solution\nname::String : Name to identify the specified device\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.get_reactivepower_branch_flow-Tuple{SimulationResults, String, Symbol}","page":"Public API Reference","title":"PowerSimulationsDynamics.get_reactivepower_branch_flow","text":"get_reactivepower_branch_flow(\n res::SimulationResults,\n name::String,\n location::Symbol,\n)\n\nFunction to obtain the reactive power flowing through the series element of a Branch. The user must specified is the power should be computed in the :from or to :bus, by specifying a symbol.\n\nIf :from is specified, the power is computed flowing outwards the :from bus. If :to is specified, the power is computed flowing into the :to bus.\n\nArguments\n\nres::SimulationResults : Simulation Results object that contains the solution\nname::String : Name to identify the specified line\nlocation::Symbol : :from or :to to specify a bus\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.get_reactivepower_series-Tuple{SimulationResults, String}","page":"Public API Reference","title":"PowerSimulationsDynamics.get_reactivepower_series","text":"get_reactivepower_series(\n res::SimulationResults,\n name::String,\n)\n\nFunction to obtain the reactive power output time series of a Dynamic Injection series out of the DAE Solution.\n\nArguments\n\nres::SimulationResults : Simulation Results object that contains the solution\nname::String : Name to identify the specified device\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.get_real_current_branch_flow-Tuple{SimulationResults, String}","page":"Public API Reference","title":"PowerSimulationsDynamics.get_real_current_branch_flow","text":"get_real_current_branch_flow(\n res::SimulationResults,\n name::String,\n)\n\nFunction to obtain the real current flowing through the series element of a Branch\n\nArguments\n\nres::SimulationResults : Simulation Results object that contains the solution\nname::String : Name to identify the specified line\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.get_real_current_series-Tuple{SimulationResults, String}","page":"Public API Reference","title":"PowerSimulationsDynamics.get_real_current_series","text":"get_real_current_series(\n res::SimulationResults,\n name::String,\n)\n\nFunction to obtain the real current time series of a Dynamic Injection series out of the DAE Solution.\n\nArguments\n\nres::SimulationResults : Simulation Results object that contains the solution\nname::String : Name to identify the specified device\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.get_setpoints-Tuple{Simulation}","page":"Public API Reference","title":"PowerSimulationsDynamics.get_setpoints","text":"get_setpoints(sim::Simulation)\n\nFunction that returns the reference setpoints for all the dynamic devices.\n\nArguments\n\nsim::Simulation : Simulation object that contains the initial condition and setpoints.\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.get_source_imaginary_current_series","page":"Public API Reference","title":"PowerSimulationsDynamics.get_source_imaginary_current_series","text":"Function to obtain output imaginary current for a source. It receives the simulation results, the Source name and an optional argument of the time step of the results.\n\n\n\n\n\n","category":"function"},{"location":"api/public/#PowerSimulationsDynamics.get_source_real_current_series","page":"Public API Reference","title":"PowerSimulationsDynamics.get_source_real_current_series","text":"Function to obtain output real current for a source. It receives the simulation results, the Source name and an optional argument of the time step of the results.\n\n\n\n\n\n","category":"function"},{"location":"api/public/#PowerSimulationsDynamics.get_state_series-Tuple{SimulationResults, Tuple{String, Symbol}}","page":"Public API Reference","title":"PowerSimulationsDynamics.get_state_series","text":"get_state_series(\n res::SimulationResults,\n ref::Tuple{String, Symbol};\n dt::Union{Nothing, Float64, Vector{Float64}} = nothing\n)\nend\n\nFunction to obtain series of states out of DAE Solution.\n\nArguments\n\nres::SimulationResults : Simulation Results object that contains the solution\nref:Tuple{String, Symbol} : Tuple used to identify the dynamic device, via its name, as a String, and the associated state as a Symbol.\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.get_voltage_angle_series-Tuple{SimulationResults, Int64}","page":"Public API Reference","title":"PowerSimulationsDynamics.get_voltage_angle_series","text":"get_voltage_angle_series(\n res::SimulationResults,\n bus_number::Int\n)\n\nFunction to obtain the voltage angle series out of the DAE Solution.\n\nArguments\n\nres::SimulationResults : Simulation Results object that contains the solution\nbus_number::Int : Bus number identifier\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.get_voltage_magnitude_series-Tuple{SimulationResults, Int64}","page":"Public API Reference","title":"PowerSimulationsDynamics.get_voltage_magnitude_series","text":"get_voltage_magnitude_series(\n res::SimulationResults,\n bus_number::Int\n)\n\nFunction to obtain the voltage magnitude series out of the DAE Solution.\n\nArguments:\n\nres::SimulationResults : Simulation Results object that contains the solution\nbus_number::Int : Bus number identifier\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.read_initial_conditions-Tuple{Simulation}","page":"Public API Reference","title":"PowerSimulationsDynamics.read_initial_conditions","text":"Returns a Dictionary with the resulting initial conditions of the simulation\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.show_states_initial_value-Tuple{SimulationResults}","page":"Public API Reference","title":"PowerSimulationsDynamics.show_states_initial_value","text":"show_states_initial_value(res::SimulationResults)\n\nFunction to print initial states.\n\nArguments\n\nres::SimulationResults : Simulation Results object that contains the solution\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.show_states_initial_value-Tuple{Simulation}","page":"Public API Reference","title":"PowerSimulationsDynamics.show_states_initial_value","text":"show_states_initial_value(sim::Simulation)\n\nFunction to print initial states.\n\nArguments\n\nsim::Simulation : Simulation object that contains the initial condition\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.small_signal_analysis-Union{Tuple{Simulation{T}}, Tuple{T}} where T<:PowerSimulationsDynamics.SimulationModel","page":"Public API Reference","title":"PowerSimulationsDynamics.small_signal_analysis","text":"small_signal_analysis(\n sim::Simulation,\n)\n\nReturns the Small Signal Output object that contains the eigenvalues and participation factors.\n\nArguments\n\nsim::Simulation : Small Signal Output object that contains the eigenvalues and participation factors\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.summary_eigenvalues-Tuple{PowerSimulationsDynamics.SmallSignalOutput}","page":"Public API Reference","title":"PowerSimulationsDynamics.summary_eigenvalues","text":"summary_eigenvalues(\n sm::SmallSignalOutput,\n)\n\nFunction to obtain a summary of the eigenvalues of the Jacobian at the operating point. It returns a DataFrame with the most associated state for each eigenvalue, its real and imaginary part, damping and frequency.\n\nArguments\n\nsm::SmallSignalOutput : Small Signal Output object that contains the eigenvalues and participation factors\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.summary_participation_factors-Tuple{PowerSimulationsDynamics.SmallSignalOutput}","page":"Public API Reference","title":"PowerSimulationsDynamics.summary_participation_factors","text":"summary_participation_factors(\n sm::SmallSignalOutput,\n)\n\nFunction to obtain the participation factor of each state to each eigenvalue. It returns a DataFrame with the participation factors of each state to all eigenvalues.\n\nArguments\n\nsm::SmallSignalOutput : Small Signal Output object that contains the eigenvalues and participation factors\n\n\n\n\n\n","category":"method"},{"location":"component_models/network/#Network-model","page":"Network","title":"Network model","text":"","category":"section"},{"location":"component_models/network/","page":"Network","title":"Network","text":"Here we discuss the models used to describe the network in PowerSimulationsDynamics.jl. This is based on a standard current injection model as defined in Power System Modelling and Scripting. The numerical advantages of current injection models outweigh the complexities of implementing constant power loads for longer-term transient stability analysis. The network is defined in a synchronous reference frame (SRF), named the RI (real-imaginary) reference frame, rotating at the constant base frequency Omega_b.","category":"page"},{"location":"component_models/network/","page":"Network","title":"Network","text":"In simple terms, PowerSimulationsDynamics.jl internally tracks the current-injection balances at the nodal level from all the devices on the system. Based on the buses and branches information, the system constructor computes the admittance matrix boldsymbolY assuming nominal frequency and this is used for static branch modeling. The algebraic equations for the static portions of the network are as follows:","category":"page"},{"location":"component_models/network/","page":"Network","title":"Network","text":" beginalign\n 0 = boldsymboli(boldsymbolx boldsymbolv) - boldsymbolYboldsymbolv\n endalign","category":"page"},{"location":"component_models/network/","page":"Network","title":"Network","text":"where boldsymboli = i_r + ji_i is the vector of the sum of complex current injections from devices , boldsymbolx is the vector of states and boldsymbolv = v_r + jv_i is the vector of complex bus voltages. Equations (1) connect all the port variables, i.e., currents, defined for each injection device. Components that contribute to (1) by modifying the current boldsymboli are (i) static injection devices, (ii) dynamic injection devices, and (iii) dynamic network branches. Components that contribute to modify the admittance matrix boldsymbolY are static branches.","category":"page"},{"location":"component_models/network/#Static-Branches-(or-Algebraic-Branches)","page":"Network","title":"Static Branches (or Algebraic Branches)","text":"","category":"section"},{"location":"component_models/network/#Lines","page":"Network","title":"Lines","text":"","category":"section"},{"location":"component_models/network/","page":"Network","title":"Network","text":"Each line is defined using a pi model connecting two buses (nm), with a series resistance r and reactance x, and a shunt capacitance at both ends (c_n c_m). The values are already in system per unit. Then each branch contributes to the admittance matrix as follows:","category":"page"},{"location":"component_models/network/","page":"Network","title":"Network","text":"beginalign\nY_nn += frac1r+jx + jc_n \nY_nm += frac-1r+jx \nY_mm += frac1r+jx + jc_m \nY_mn += frac-1r+jx \nendalign","category":"page"},{"location":"component_models/network/#Two-Windings-Transformers","page":"Network","title":"Two-Windings Transformers","text":"","category":"section"},{"location":"component_models/network/","page":"Network","title":"Network","text":"Similarly to lines these are defined by a series reactance and impedance. The equations are equivalently of the lines without the shunt capacitance.","category":"page"},{"location":"component_models/network/#Dynamic-Branches","page":"Network","title":"Dynamic Branches","text":"","category":"section"},{"location":"component_models/network/","page":"Network","title":"Network","text":"Dynamic network branches contribute directly to (1) by modifying the vector of complex currents. Their parameters are also the series resistance r and reactance x, and a shunt capacitance at both ends (c_n c_m) for a line ell. In addition, they define 3 new additional differential equations per line (6 in total for real and imaginary part):","category":"page"},{"location":"component_models/network/","page":"Network","title":"Network","text":"beginalign\n fraclOmega_b fracdboldsymboli_elldt = (boldsymbolv_n - boldsymbolv_m) - (r+jl) boldsymboli_ell \n fracc_nOmega_b fracdboldsymbolv_ndt = boldsymboli_n^textcap - jc_nboldsymbolv_n \n fracc_mOmega_b fracdboldsymbolv_mdt = boldsymboli_m^textcap - jc_mboldsymbolv_m\nendalign","category":"page"},{"location":"component_models/network/","page":"Network","title":"Network","text":"Since all the values are in per unit, the reactance is equal to the inductance.","category":"page"},{"location":"component_models/network/","page":"Network","title":"Network","text":"A detail discussion about the effects of different line models in the modeling of inverters is presented in Grid Forming Inverter Small Signal Stability: Examining Role of Line and Voltage Dynamics","category":"page"},{"location":"component_models/pss/#Power-System-Stabilizers-(PSS)","page":"PSS","title":"Power System Stabilizers (PSS)","text":"","category":"section"},{"location":"component_models/pss/","page":"PSS","title":"PSS","text":"PSS are used to add an additional signal v_s to the input signal of the AVR: v_textref = v_textref^textavr + v_s.","category":"page"},{"location":"component_models/pss/#Fixed-PSS-[PSSFixed]","page":"PSS","title":"Fixed PSS [PSSFixed]","text":"","category":"section"},{"location":"component_models/pss/","page":"PSS","title":"PSS","text":"This is a simple model that set the stabilization signal to be equal to a desired constant value v_s = v_s^textfix. The absence of PSS can be modelled using this component with v_s^textfix = 0.","category":"page"},{"location":"component_models/pss/#Simple-PSS-[PSSSimple]","page":"PSS","title":"Simple PSS [PSSSimple]","text":"","category":"section"},{"location":"component_models/pss/","page":"PSS","title":"PSS","text":"This is the most basic PSS that can be implemented, on which the stabilization signal is a proportional controller over the frequency and electrical power:","category":"page"},{"location":"component_models/pss/","page":"PSS","title":"PSS","text":"beginalign\nv_s = K_omega(omega - omega_s) + K_p(omega tau_e - P_textref) tag1a\nendalign","category":"page"},{"location":"component_models/pss/#IEEE-Stabilizer-[IEEEST]","page":"PSS","title":"IEEE Stabilizer [IEEEST]","text":"","category":"section"},{"location":"component_models/pss/","page":"PSS","title":"PSS","text":"The 7th-order PSS model is:","category":"page"},{"location":"component_models/pss/","page":"PSS","title":"PSS","text":"beginalign\nA_4 dotx_1 = u - A_3 x_1 - x_2 tag2a \ndotx_2 = x_1 tag2b \nA_2dotx_3 = x_2 - A_1 x_3 - x_4 tag2c\ndotx_4 = x_3 tag2d\nT_2dotx_5 = left(1 - fracT_1T_2right) y_f - x_5 tag2e\nT_4dotx_6 = left(1 - fracT_3T_4right) y_LL1 - x_6 tag2f\nT_6dotx_7 = -left(fracK_s T_5T_6 y_LL2 + x_7 right) tag2g\nendalign","category":"page"},{"location":"component_models/pss/","page":"PSS","title":"PSS","text":"with","category":"page"},{"location":"component_models/pss/","page":"PSS","title":"PSS","text":"beginalign*\ny_f = fracT_4T_2 x_2 + left(T_3 - T_1 fracT_4T_2right) x_3 + left(1 - fracT_4T_2right)x_4 \ny_LL1 = x_5 + fracT_1T_2 y_f \ny_LL2 = x_6 + fracT_3T_4 y_LL1 \ny_out = x_7 + fracK_s T_5T_6 y_LL2 \nV_s = textclamp(y_out textLs_textmin textLs_textmax)\nendalign*","category":"page"},{"location":"component_models/pss/","page":"PSS","title":"PSS","text":"on which u is the input signal to the PSS, that depends on the flag. Currently, rotor speed, electric torque, mechanical torque and voltage magnitude are supported inputs.","category":"page"},{"location":"component_models/pss/#STAB1-PSS-[STAB1]","page":"PSS","title":"STAB1 PSS [STAB1]","text":"","category":"section"},{"location":"component_models/pss/","page":"PSS","title":"PSS","text":"The 3rd-order PSS model is:","category":"page"},{"location":"component_models/pss/","page":"PSS","title":"PSS","text":"beginalign\nT dotx_1 = K omega - x_1 tag3a \nT_3dotx_2 = left(1 - fracT_1T_3right) x_1 - x_2 tag3b \nT_4dotx_3 = left(1 - fracT_2T_4right) y_LL - x_2 tag3c \nendalign","category":"page"},{"location":"component_models/pss/","page":"PSS","title":"PSS","text":"with","category":"page"},{"location":"component_models/pss/","page":"PSS","title":"PSS","text":"beginalign*\ny_LL = x_2 + fracT_1T_3 x_1 \ny_out = x_3 + fracT_2T_4 y_LL \nV_s = textclamp(y_out -H_lim H_lim)\nendalign*","category":"page"},{"location":"initialization/#Initialization-Routine","page":"Initialization","title":"Initialization Routine","text":"","category":"section"},{"location":"initialization/","page":"Initialization","title":"Initialization","text":"Dynamic Simulations require a reasonable initial condition for the system model. In most analysis, power systems models are initialized at a stable equilibrium, which implies that:","category":"page"},{"location":"initialization/","page":"Initialization","title":"Initialization","text":"beginalign\n0 = F(x u eta)\nendalign","category":"page"},{"location":"initialization/","page":"Initialization","title":"Initialization","text":"Finding the solution of a large non-linear system is challenging and requires a reasonable initial guess. In classical power systems literature, the routine to find equilibrium points for the dynamic injection devices' components is well known and used in free and commercial software (see Power System Modelling and Scripting page 224). However, in the case of converter interface dynamic injection models, such routines are not documented.","category":"page"},{"location":"initialization/","page":"Initialization","title":"Initialization","text":"Initializing the system also requires finding valid set-points for the devices in the system. For instance, finding the reference voltage in an AVR to match the voltage magnitude resulting from the power flow solution. PowerSimulationsDynamics.jl prioritizes mathching the dynamic components control references to match the power flow results.","category":"page"},{"location":"initialization/","page":"Initialization","title":"Initialization","text":"Finally, the initialization must instantiate not only the values of the states but also the inner vars. PowerSimulationsDynamics.jl handles all this initializations by default.","category":"page"},{"location":"initialization/#Initialization-interface","page":"Initialization","title":"Initialization interface","text":"","category":"section"},{"location":"initialization/","page":"Initialization","title":"Initialization","text":"By default PowerSimulationsDynamics.jl initializes the system following the steps described below. it is possible to provide an initial guess for the initial conditions to speed up the initialization process.","category":"page"},{"location":"initialization/","page":"Initialization","title":"Initialization","text":"Simulation(\n ResidualModel,\n sys,\n pwd(),\n (0.0, 20.0);\n initial_conditions = x0_init,\n )","category":"page"},{"location":"initialization/","page":"Initialization","title":"Initialization","text":"It is also possible to initialize the simulation using a flat start (V_mag = 1.0, V_angle = 0.0 and x0 = zeros) using initialize_simulation = false. However, for medium or large system this is unlikely to result in a valid initial condition for the simulation.","category":"page"},{"location":"initialization/","page":"Initialization","title":"Initialization","text":"Simulation(\n ResidualModel,\n sys,\n pwd(),\n (0.0, 20.0);\n initialize_simulation = false,\n )","category":"page"},{"location":"initialization/","page":"Initialization","title":"Initialization","text":"If you want to avoid PowerSimulationsDynamics.jl from finding an stable equilibrium automatically and provide the initial condition manually you can use the following flag combination.","category":"page"},{"location":"initialization/","page":"Initialization","title":"Initialization","text":"Simulation(\n ResidualModel,\n sys,\n pwd(),\n (0.0, 20.0);\n initialize_simulation = false,\n initial_conditions = x0_init,\n )","category":"page"},{"location":"initialization/","page":"Initialization","title":"Initialization","text":"WARNING!: when the initialize_simulation is set to false, neither the device set points nor the inner vars are initialized. Use these keywords with care and make sure the values in the system components match the initial conditions provided.","category":"page"},{"location":"initialization/#System-wide-initialization-routine","page":"Initialization","title":"System-wide initialization routine","text":"","category":"section"},{"location":"initialization/","page":"Initialization","title":"Initialization","text":"The initialization routine starts from the solution of the power flow equations. For each dynamic injection device PowerSimulationsDynamics.jl finds the solution of the systems of non-linear equations for each dynamic component following the sequences described in the forthcoming sections.","category":"page"},{"location":"initialization/","page":"Initialization","title":"Initialization","text":"Once each device is individually initialized, the system-wide initial guess is used to solve the system (1). In a first attempt at finding the solution, the tolerance is set to a stringent tolerance. If the non-linear solver is unable to get a solution, it might usually reflect small signal stability problems in the system. In a second attempt, the tolerances are relaxed. If the solver succeeds, the simulation continues, but the user is warned.","category":"page"},{"location":"initialization/","page":"Initialization","title":"Initialization","text":"","category":"page"},{"location":"initialization/#Initialization-of-the-Synchronous-Machines","page":"Initialization","title":"Initialization of the Synchronous Machines","text":"","category":"section"},{"location":"initialization/","page":"Initialization","title":"Initialization","text":"The initialization of Synchronous Machines is standard in power systems and follows the scheme shown in the figure. Other internal variables are calculated recursively from the power flow solution for the node on which the dynamic device isconnected. (Adapted from Power System Modelling and Scripting Figure 9.2)","category":"page"},{"location":"initialization/","page":"Initialization","title":"Initialization","text":"(Image: init_machine)","category":"page"},{"location":"initialization/#Initialization-of-the-Inverters","page":"Initialization","title":"Initialization of the Inverters","text":"","category":"section"},{"location":"initialization/","page":"Initialization","title":"Initialization","text":"Initializing the inverters follows the sequence shown in the figure and has been developed to be compatible with the implementation of custom dynamic components. Given that the process is less studied and standard than the one of the synchronous machine, this page contains more detailed documentation of the process.","category":"page"},{"location":"initialization/","page":"Initialization","title":"Initialization","text":"(Image: init_machine)","category":"page"},{"location":"initialization/","page":"Initialization","title":"Initialization","text":"The first component to be initialized is the filter. Given that the filter is an RLC circuit connected to the grid, its currents and voltages need to match the results of the power flow. The initialization of the filter provides the values for the P and Q used in the outer control and the V and I needed in the inner controls.\nBased on the bus voltage in the system's reference frame V_r and the bus angle theta the PLL's can be initialized to obtain the angle and frequency estimates needed by the outer control.\nThe Outer Control calculates the internal angle delta_olc required by the inner control to estimate the voltage and current phase difference.\nThe DC Source uses the power set-point consistent with the power outputs of the filter to initialize the V_dc set-points. This value is used in the inner control.\nThe inner control takes the phase angle delta_olc and the V_dc to estimate the modulation values of the PWM converter.","category":"page"},{"location":"initialization/","page":"Initialization","title":"Initialization","text":"Note: The initialization of an inverter through the proposed meta-model is actively under development and subject to change. This page will maintain the latest version of the sequence.","category":"page"},{"location":"tutorials_page/#SIIP-Examples","page":"SIIP-Examples","title":"SIIP-Examples","text":"","category":"section"},{"location":"tutorials_page/","page":"SIIP-Examples","title":"SIIP-Examples","text":"All the tutorials for the SIIP project are part of a separate repository SIIP-Examples. You can access the latest PowerSimulationsDynamics.jl tutorial notebooks in this link","category":"page"},{"location":"tutorials_page/","page":"SIIP-Examples","title":"SIIP-Examples","text":"Specific examples of common workflows and models:","category":"page"},{"location":"tutorials_page/","page":"SIIP-Examples","title":"SIIP-Examples","text":"Loading Dynamic Data\nSolving a One Machine against Infinite Bus model\nChanging line modeling assumptions\nUsing an Inverter in a Multi-Machine Model","category":"page"},{"location":"tutorials/tutorial_continuation_pf/#Tutorial-Small-Signal-Analysis-with-Continuation-Power-Flow","page":"Small-Signal Analysis","title":"Tutorial Small Signal Analysis with Continuation Power Flow","text":"","category":"section"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"Originally Contributed by: Rodrigo Henriquez-Auba","category":"page"},{"location":"tutorials/tutorial_continuation_pf/#Introduction","page":"Small-Signal Analysis","title":"Introduction","text":"","category":"section"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"This tutorial will introduce you to the functionality of PowerSimulationsDynamics and PowerFlows for running small signal analysis in a continuation power flow.","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"This tutorial presents a simulation of a two-bus system with a generator (represented with a GENROU + SEXS + TGOV1 model) at bus 1, and a load on bus 2. We will increase the load demand to observe the P-V curve and run a small-signal analysis to check if the system satisfies small-signal stability at different operating points.","category":"page"},{"location":"tutorials/tutorial_continuation_pf/#Dependencies","page":"Small-Signal Analysis","title":"Dependencies","text":"","category":"section"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"using PowerSimulationsDynamics\nPSID = PowerSimulationsDynamics\nusing PowerSystemCaseBuilder\nusing PowerSystems\nusing PowerFlows\nconst PSY = PowerSystems\nusing Plots\ngr()\n\n# Disable Logging to avoid excessive information\nusing Logging\nLogging.disable_logging(Logging.Info); \nLogging.disable_logging(Logging.Warn); ","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"note: Note\nPowerSystemCaseBuilder.jl is a helper library that makes it easier to reproduce examples in the documentation and tutorials. Normally you would pass your local files to create the system data instead of calling the function build_system. For more details visit PowerSystemCaseBuilder Documentation","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"PowerSystems (abbreviated with PSY) is used to properly define the data structure and establish an equilibrium point initial condition with a power flow routine using PowerFlows.","category":"page"},{"location":"tutorials/tutorial_continuation_pf/#Load-the-system","page":"Small-Signal Analysis","title":"Load the system","text":"","category":"section"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"We load the system using PowerSystemCaseBuilder.jl. This system only have a generator without dynamic data on which we can use PowerFlows to generate a P-V (or nose) curve.","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"sys_static = build_system(PSIDSystems, \"2 Bus Load Tutorial\")","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"Note that this system contains an Exponential Load, but the parameters are set up to zero, so it behaves a Constant Power Load:","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"first(get_components(PSY.ExponentialLoad, sys_static))","category":"page"},{"location":"tutorials/tutorial_continuation_pf/#Create-a-P-V-curve","page":"Small-Signal Analysis","title":"Create a P-V curve","text":"","category":"section"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"The next step is to run multiple power flows and store the voltage at the load and the active power. For this example we will set up the power factor to be unitary (i.e. no reactive power at the load). ","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"# Create a Power Range to change the power load active power\nP_range = 0.01:0.01:4.6;\n# Choose the power factor\nload_pf = 1.0;","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"Then create vectors to store the results","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"# PV Curve Results\nP_load_p = Vector{Float64}();\nV_load_p = Vector{Float64}();","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"Then, we run multiple power flows in a for loop by changing the active power of the load:","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"for p in P_range\n # Change the active power and reactive power of the load\n power = p * 1.0\n load = get_component(PSY.ExponentialLoad, sys_static, \"load1021\")\n set_active_power!(load, power)\n q_power = power * tan(acos(load_pf))\n set_reactive_power!(load, q_power)\n # Run Power Flow\n status = solve_ac_powerflow!(sys_static)\n if !status\n # Finish the loop if the power flow fails\n print(\"Power Flow failed at p = $(power)\")\n break\n end\n # Obtain the bus voltage information\n bus = get_component(Bus, sys_static, \"BUS 2\")\n Vm = get_magnitude(bus)\n # Store values in the vectors\n push!(V_load_p, Vm)\n push!(P_load_p, power)\nend","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"The plot can be visualized with:","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"plot(P_load_p,\n V_load_p,\n label = \"PV Curve\",\n xlabel = \"Load Power [pu]\",\n ylabel = \"Load Bus Voltage [pu]\",\n color = :black\n)","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"(Image: plot)","category":"page"},{"location":"tutorials/tutorial_continuation_pf/#Run-Small-Signal-Analysis-besides-the-Continuation-Power-Flow","page":"Small-Signal Analysis","title":"Run Small-Signal Analysis besides the Continuation Power Flow","text":"","category":"section"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"To run a small-signal analysis we require a dynamic model of the machine. We can use PowerSystemCaseBuilder to the load the same system, but with a dynamic model for the generator, including a GENROU + SEXS exciter + TGOV1 governor.","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"sys = build_system(PSIDSystems, \"2 Bus Load Tutorial GENROU\")","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"Here are the components of the generator:","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"first(get_components(DynamicGenerator, sys))","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"Besides the results of the P-V curve, we need to store if the system is small-signal stable or not by looking if there is a positive real part eigenvalue.","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"# Vectors to store stability using a boolean (true for stable).\nstable_vec = Vector{Bool}();\nstatus_vec = Vector{Bool}();\n\n# PV Curve Results\nP_load_p = Vector{Float64}();\nV_load_p = Vector{Float64}();","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"We then run the main for loop by updating the load active power, but in addition we create a PowerSimulationsDynamics simulation on which we can run a small-signal analysis to check stability.","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"for p in P_range\n # Change the active power and reactive power of the load\n power = p * 1.0\n load = get_component(PSY.ExponentialLoad, sys_static, \"load1021\")\n set_active_power!(load, power)\n q_power = power * tan(acos(load_pf))\n set_reactive_power!(load, q_power)\n # Run Power Flow\n status = solve_ac_powerflow!(sys_static)\n if !status\n # Finish the loop if the power flow fails\n print(\"Power Flow failed at p = $(power)\")\n break\n end\n # Obtain the bus voltage information\n bus = get_component(Bus, sys_static, \"BUS 2\")\n Vm = get_magnitude(bus)\n # Store values in the vectors\n push!(V_load_p, Vm)\n push!(P_load_p, power)\n\n # Update Load Power in the GENROU system\n load = get_component(PSY.ExponentialLoad, sys, \"load1021\")\n set_active_power!(load, power)\n q_power = power * tan(acos(load_pf))\n set_reactive_power!(load, q_power)\n # Construct Simulation\n sim = Simulation(ResidualModel, sys, mktempdir(), (0.0, 1.0))\n if sim.status == PSID.BUILT\n # Check small-signal stability\n sm = small_signal_analysis(sim).stable\n # Push results of small-signal stability\n push!(stable_vec, sm)\n # Push results if the simulation was able to be constructed\n push!(status_vec, true)\n else\n # Push results if the simulation was not able to be constructed\n push!(status_vec, false)\n end\nend","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"The following plot showcases the P-V curve, while also showcasing (in red) the regions on which the system is small-signal stable.","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"\n# Find where is stable and unstable\ndict_true_ixs_p = Vector();\ndict_false_ixs_p = Vector();\ndict_true_ixs_p = findall(x->x, stable_vec);\ndict_false_ixs_p = findall(x->!x, stable_vec);\n\n# Create plot\ntrue_ixs = dict_true_ixs_p;\nplot(P_load_p, V_load_p, color = :blue, label = \"PV Curve\", xlabel = \"Load Power [pu]\", ylabel = \"Load Bus Voltage [pu]\")\nplot!(Plots.scatter!(P_load_p[true_ixs] , V_load_p[true_ixs], markerstrokewidth= 0, label = \"GENROU SSA\"))","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"(Image: plot)","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"This results is consistent with most of the literature for dynamic generator models supplying constant power loads, on which by increasing the active power of the load, produce critical eigenvalues which cross the jomega axis at some point. This is called a Hopf Bifurcation, in this case a subcritical one since the limit cycles are unstable.","category":"page"},{"location":"reference_frames/#Reference-Frames","page":"Reference Frames","title":"Reference Frames","text":"","category":"section"},{"location":"reference_frames/","page":"Reference Frames","title":"Reference Frames","text":"Each dynamic device is defined in its own dq synchronous reference frame (SRF). It is important to note that there are several conventions to do reference frame transformations.","category":"page"},{"location":"reference_frames/#Synchronous-Machines","page":"Reference Frames","title":"Synchronous Machines","text":"","category":"section"},{"location":"reference_frames/","page":"Reference Frames","title":"Reference Frames","text":"The grid is modeled in its own real-imaginary (RI) reference frame. With such, this follows the standard convention that for a voltage angle theta = 0, there is no imaginary part and hence v_h = v_r + j0. Traditionally, the reference frame dq with rotor angle delta for synchronous machines connected to a bus v_hangle theta = v_r + jv_i follows the following convention for transformation of per-unit RMS phasors:","category":"page"},{"location":"reference_frames/","page":"Reference Frames","title":"Reference Frames","text":"beginalign\nv_d + jv_q = (v_r + jv_i) e^-j(delta- pi2) tag1a \nv_d = v_h sin(delta - theta) tag1b \nv_q = v_h cos(delta - theta) tag1c \nleft beginarrayc v_d v_q endarray right = left beginarraycc sin(delta) -cos(delta) cos(delta) sin(delta) endarray right left beginarrayc v_r v_i endarray right tag1d\nendalign","category":"page"},{"location":"reference_frames/","page":"Reference Frames","title":"Reference Frames","text":"Note that hence in a bus of 10angle 0, a rotor angle of delta = 0 implies that v_q = 10 and v_d = 00. This transformation is the one that can be found in most books of Power Systems, such as Kundur, Sauer Pai and in Milano too, and is the convention used in the software to model dynamic models of synchronous machines in their own reference frame.","category":"page"},{"location":"reference_frames/#Inverters","page":"Reference Frames","title":"Inverters","text":"","category":"section"},{"location":"reference_frames/","page":"Reference Frames","title":"Reference Frames","text":"The previously convention is not the standard one used for modeling inverters. Most of inverter and phase-lock loop (PLL) models follow the next convention:","category":"page"},{"location":"reference_frames/","page":"Reference Frames","title":"Reference Frames","text":"beginalign\nv_d + jv_q = (v_r + jv_i) e^-j delta tag2a \nv_d = v_h cos(delta - theta) tag2b \nv_q = -v_h sin(delta - theta) tag2c\nendalign","category":"page"},{"location":"reference_frames/","page":"Reference Frames","title":"Reference Frames","text":"That, contrary to the previous case, when delta = theta = 0 implies that v_d = 10 and v_q = 00. This yields the typical PLL conditions that steer v_q to 0 when delta locks in theta, or when both SRF lock between each other.","category":"page"},{"location":"reference_frames/#Transformation-used","page":"Reference Frames","title":"Transformation used","text":"","category":"section"},{"location":"reference_frames/","page":"Reference Frames","title":"Reference Frames","text":"Given the predominancy of both convention in current work, the software uses both conventions depending on the device modeled. For synchronous machines we used the standard convention (1a)-(1d), while for inverter models we use the predominant convention used nowadays in such models, i.e. (2a)-(2c).","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/#Inverter-Modeling-simulation","page":"Inverter Modeling","title":"Inverter Modeling simulation","text":"","category":"section"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"Originally Contributed by: José Daniel Lara","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/#Introduction","page":"Inverter Modeling","title":"Introduction","text":"","category":"section"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"This tutorial will introduce the modeling of an inverter with Virtual Inertia in a multi-machine model of the system. We will load the data directly from PSS/e dynamic files.","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"The tutorial uses a modified 14-bus system on which all the synchronous machines have been substituted by generators with ESAC1A AVR's and no Turbine Governors.","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"In the first portion of the tutorial we will simulate the system with the original data and cause a line trip between Buses 2 and 4. In the second part of the simulation, we will switch generator 6 with a battery using an inverter and perform the same fault.","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/#Load-the-packages","page":"Inverter Modeling","title":"Load the packages","text":"","category":"section"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"using PowerSimulationsDynamics\nusing PowerSystemCaseBuilder\nusing PowerSystems\nconst PSY = PowerSystems\nusing PowerFlows\nusing Logging\nusing Sundials\nusing Plots","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"note: Note\nPowerSystemCaseBuilder.jl is a helper library that makes it easier to reproduce examples in the documentation and tutorials. Normally you would pass your local files to create the system data instead of calling the function build_system. For more details visit PowerSystemCaseBuilder Documentation","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"Create the system using PowerSystemCaseBuilder.jl:","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"sys = build_system(PSIDSystems, \"14 Bus Base Case\")","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"PowerSystemCaseBuilder.jl is a helper library that makes it easier to reproduce examples in the documentation and tutorials. Normally you would pass your local files to create the system data.","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"Define Simulation Problem with a 20 second simulation period and the branch trip at t = 1.0:","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"sim = Simulation(\n ResidualModel, #Type of model used\n sys, #system\n mktempdir(), #path for the simulation output\n (0.0, 20.0), #time span\n BranchTrip(1.0, Line, \"BUS 02-BUS 04-i_1\");\n console_level = Logging.Info,\n)","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"Now that the system is initialized, we can verify the system states for potential issues.","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"show_states_initial_value(sim)","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"We execute the simulation with an additional tolerance for the solver set at 1e-8:","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"execute!(sim, IDA(); abstol = 1e-8)","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"Using PowerSimulationsDynamics tools for exploring the results, we can plot all the voltage results for the buses:","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"result = read_results(sim)\np = plot();\nfor b in get_components(ACBus, sys)\n voltage_series = get_voltage_magnitude_series(result, get_number(b))\n plot!(\n p,\n voltage_series;\n xlabel = \"Time\",\n ylabel = \"Voltage Magnitude [pu]\",\n label = \"Bus - $(get_name(b))\",\n );\nend","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"(Image: plot)","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"We can also explore the frequency of the different generators","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"p2 = plot();\nfor g in get_components(ThermalStandard, sys)\n state_series = get_state_series(result, (get_name(g), :ω))\n plot!(\n p2,\n state_series;\n xlabel = \"Time\",\n ylabel = \"Speed [pu]\",\n label = \"$(get_name(g)) - ω\",\n );\nend","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"(Image: plot)","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"It is also possible to explore the small signal stability of this system we created.","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"res = small_signal_analysis(sim)","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/#The-eigenvalues-can-be-explored","page":"Inverter Modeling","title":"The eigenvalues can be explored","text":"","category":"section"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"res.eigenvalues","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/#Modifying-the-system-and-adding-storage","page":"Inverter Modeling","title":"Modifying the system and adding storage","text":"","category":"section"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"Reload the system for this example:","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"sys = build_system(PSIDSystems, \"14 Bus Base Case\")\n\n# We want to remove the generator 6 and the dynamic component attached to it.\nthermal_gen = get_component(ThermalStandard, sys, \"generator-6-1\")\nremove_component!(sys, get_dynamic_injector(thermal_gen))\nremove_component!(sys, thermal_gen)\n\n# We can now define our storage device and add it to the system\nstorage = GenericBattery(\n name = \"Battery\",\n bus = get_component(Bus, sys, \"BUS 06\"),\n available = true,\n prime_mover = PrimeMovers.BA,\n active_power = 0.6,\n reactive_power = 0.16,\n rating = 1.1,\n base_power = 25.0,\n initial_energy = 50.0,\n state_of_charge_limits = (min = 5.0, max = 100.0),\n input_active_power_limits = (min = 0.0, max = 1.0),\n output_active_power_limits = (min = 0.0, max = 1.0),\n reactive_power_limits = (min = -1.0, max = 1.0),\n efficiency = (in = 0.80, out = 0.90),\n)\n\nadd_component!(sys, storage)","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"A good sanity check it running a power flow on the system to make sure all the components are properly scaled and that the system is properly balanced. We can use PowerSystems to perform this check. We can get the results back and perform a sanity check.","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"res = solve_powerflow(ACPowerFlow(), sys)\nres[\"bus_results\"]","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"After verifying that the system works, we can define our inverter dynamics and add it to the battery that has already been stored in the system.","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"inverter = DynamicInverter(\n name = get_name(storage),\n ω_ref = 1.0, # ω_ref,\n converter = AverageConverter(rated_voltage = 138.0, rated_current = 100.0),\n outer_control = OuterControl(\n VirtualInertia(Ta = 2.0, kd = 400.0, kω = 20.0),\n ReactivePowerDroop(kq = 0.2, ωf = 1000.0),\n ),\n inner_control = VoltageModeControl(\n kpv = 0.59, #Voltage controller proportional gain\n kiv = 736.0, #Voltage controller integral gain\n kffv = 0.0, #Binary variable enabling the voltage feed-forward in output of current controllers\n rv = 0.0, #Virtual resistance in pu\n lv = 0.2, #Virtual inductance in pu\n kpc = 1.27, #Current controller proportional gain\n kic = 14.3, #Current controller integral gain\n kffi = 0.0, #Binary variable enabling the current feed-forward in output of current controllers\n ωad = 50.0, #Active damping low pass filter cut-off frequency\n kad = 0.2,\n ),\n dc_source = FixedDCSource(voltage = 600.0),\n freq_estimator = KauraPLL(\n ω_lp = 500.0, #Cut-off frequency for LowPass filter of PLL filter.\n kp_pll = 0.084, #PLL proportional gain\n ki_pll = 4.69, #PLL integral gain\n ),\n filter = LCLFilter(lf = 0.08, rf = 0.003, cf = 0.074, lg = 0.2, rg = 0.01),\n)\nadd_component!(sys, inverter, storage)","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"These are the current system components:","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"sys","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"Define Simulation problem using the same parameters:","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"sim = Simulation(\n ResidualModel, #Type of model used\n sys, #system\n mktempdir(), #path for the simulation output\n (0.0, 20.0), #time span\n BranchTrip(1.0, Line, \"BUS 02-BUS 04-i_1\");\n console_level = Logging.Info,\n)","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"We can verify the small signal stability of the system before running the simulation:","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"res = small_signal_analysis(sim)","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"Exploring the eigenvalues:","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"res.eigenvalues","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"We execute the simulation","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"execute!(sim, IDA(); abstol = 1e-8)","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"Using PowerSimulationsDynamics tools for exploring the results, we can plot all the voltage results for the buses","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"result = read_results(sim)\np = plot();\nfor b in get_components(ACBus, sys)\n voltage_series = get_voltage_magnitude_series(result, get_number(b))\n plot!(\n p,\n voltage_series;\n xlabel = \"Time\",\n ylabel = \"Voltage Magnitude [pu]\",\n label = \"Bus - $(get_name(b))\",\n );\nend","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"(Image: plot)","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"We can also explore the frequency of the different static generators and storage","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"p2 = plot();\nfor g in get_components(ThermalStandard, sys)\n state_series = get_state_series(result, (get_name(g), :ω))\n plot!(\n p2,\n state_series;\n xlabel = \"Time\",\n ylabel = \"Speed [pu]\",\n label = \"$(get_name(g)) - ω\",\n );\nend\nstate_series = get_state_series(result, (\"Battery\", :ω_oc))\nplot!(p2, state_series; xlabel = \"Time\", ylabel = \"Speed [pu]\", label = \"Battery - ω\");","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"(Image: plot)","category":"page"},{"location":"time_delays/#Delays","page":"Time Delays","title":"Delays","text":"","category":"section"},{"location":"time_delays/","page":"Time Delays","title":"Time Delays","text":"PowerSimulationsDynamics supports models with constant delays in a mass matrix formulation:","category":"page"},{"location":"time_delays/","page":"Time Delays","title":"Time Delays","text":"beginalign\nMfracdx(t)dt = f(x(t) x(t-tau_1) x(t-tau_N)) \nendalign","category":"page"},{"location":"time_delays/","page":"Time Delays","title":"Time Delays","text":"For more information on solving such models, refer to the documentation for DelayDiffEq.jl package.","category":"page"},{"location":"time_delays/","page":"Time Delays","title":"Time Delays","text":"The following models include time delays:","category":"page"},{"location":"time_delays/","page":"Time Delays","title":"Time Delays","text":"DEGOV","category":"page"},{"location":"time_delays/","page":"Time Delays","title":"Time Delays","text":"There is currently limited support for including models with time delays. The following limitations apply:","category":"page"},{"location":"time_delays/","page":"Time Delays","title":"Time Delays","text":"Only constant delays are supported (state dependent delays are not).\nSystem models with delays must use MassMatrixModel formulation (ResidualModel is not currently compatible).\nSystem models with delays are not compatible with small signal analysis tools.\nThe system formulation with delays is not compatible with automatic differentiation for calculating the gradient with respect to time. The setting autodiff=false should be set when passing the solver (e.g. MethodofSteps(Rodas5(autodiff=false))).","category":"page"},{"location":"component_models/dc_source/#DC-Source","page":"DC Sources","title":"DC Source","text":"","category":"section"},{"location":"component_models/dc_source/","page":"DC Sources","title":"DC Sources","text":"This component can be used to model the dynamics of the DC side of the converter.","category":"page"},{"location":"component_models/dc_source/#Fixed-DC-Source-[FixedDCSource]","page":"DC Sources","title":"Fixed DC Source [FixedDCSource]","text":"","category":"section"},{"location":"component_models/dc_source/","page":"DC Sources","title":"DC Sources","text":"This is a model that set the DC voltage to a fixed value v_textdc = v_textdc^textfix.","category":"page"},{"location":"tutorials/tutorial_omib/#One-Machine-against-Infinite-Bus-(OMIB)-Simulation","page":"OMIB","title":"One Machine against Infinite Bus (OMIB) Simulation","text":"","category":"section"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"Originally Contributed by: Rodrigo Henriquez-Auba and José Daniel Lara","category":"page"},{"location":"tutorials/tutorial_omib/#Introduction","page":"OMIB","title":"Introduction","text":"","category":"section"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"This tutorial will introduce you to the functionality of PowerSimulationsDynamics for running power system dynamic simulations.","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"This tutorial presents a simulation of a two-bus system with an infinite bus (represented as a voltage source behind an impedance) at bus 1, and a classic machine on bus 2. The perturbation will be the trip of one of the two circuits (doubling its resistance and impedance) of the line that connects both buses.","category":"page"},{"location":"tutorials/tutorial_omib/#Dependencies","page":"OMIB","title":"Dependencies","text":"","category":"section"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"using PowerSimulationsDynamics\nPSID = PowerSimulationsDynamics\nusing PowerSystemCaseBuilder\nusing PowerSystems\nconst PSY = PowerSystems\nusing Sundials\nusing Plots\ngr()","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"note: Note\nPowerSystemCaseBuilder.jl is a helper library that makes it easier to reproduce examples in the documentation and tutorials. Normally you would pass your local files to create the system data instead of calling the function build_system. For more details visit PowerSystemCaseBuilder Documentation","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"PowerSystems (abbreviated with PSY) is used to properly define the data structure and establish an equilibrium point initial condition with a power flow routine, while Sundials is used to solve the problem defined in PowerSimulationsDynamics.","category":"page"},{"location":"tutorials/tutorial_omib/#Load-the-system","page":"OMIB","title":"Load the system","text":"","category":"section"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"We load the system using PowerSystemCaseBuilder.jl:","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"omib_sys = build_system(PSIDSystems, \"OMIB System\")","category":"page"},{"location":"tutorials/tutorial_omib/#Build-the-simulation-and-initialize-the-problem","page":"OMIB","title":"Build the simulation and initialize the problem","text":"","category":"section"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"The next step is to create the simulation structure. This will create the indexing of our system that will be used to formulate the differential-algebraic system of equations. To do so, it is required to specify the perturbation that will occur in the system. PowerSimulationsDynamics supports multiple types of perturbations. See Perturbations","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"Here, we will use a Branch Trip perturbation, that is modeled by modifying the specifying which line we want to trip. In this case we disconnect one of the lines that connects BUS 1 and BUS 2, named \"BUS 1-BUS 2-i_1\".","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"With this, we are ready to create our simulation structure:","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"time_span = (0.0, 30.0)\nperturbation_trip = BranchTrip(1.0, Line, \"BUS 1-BUS 2-i_1\")\nsim = PSID.Simulation(\n ResidualModel, # Type of formulation\n omib_sys, # System\n mktempdir(), # Output directory\n time_span,\n perturbation_trip)","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"This will automatically initialize the system by running a power flow and update V_ref, P_ref and hence eq_p (the internal voltage) to match the solution of the power flow. It will also initialize the states in the equilibrium, which can be printed with:","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"show_states_initial_value(sim)","category":"page"},{"location":"tutorials/tutorial_omib/#Run-the-Simulation","page":"OMIB","title":"Run the Simulation","text":"","category":"section"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"Finally, to run the simulation we simply use:","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"execute!(\n sim, #simulation structure\n IDA(), #Sundials DAE Solver\n dtmax = 0.02, #Arguments: Maximum timestep allowed\n);","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"In some cases, the dynamic time step used for the simulation may fail. In such case, the keyword argument dtmax can be used to limit the maximum time step allowed for the simulation.","category":"page"},{"location":"tutorials/tutorial_omib/#Exploring-the-solution","page":"OMIB","title":"Exploring the solution","text":"","category":"section"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"First, we need to load the simulation results into memory:","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"results = read_results(sim)","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"PowerSimulationsDynamics has two functions to obtain different states of the solution:","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"get_state_series(results, (\"generator-102-1\", :δ)): can be used to obtain the solution as a tuple of time and the required state. In this case, we are obtaining the rotor angle :δ of the generator named \"generator-102-1\"`.","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"angle = get_state_series(results, (\"generator-102-1\", :δ));\nplot(angle, xlabel = \"time\", ylabel = \"rotor angle [rad]\", label = \"rotor angle\")","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"(Image: plot)","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"get_voltage_magnitude_series(results, 102): can be used to obtain the voltage magnitude as a tuple of time and voltage. In this case, we are obtaining the voltage magnitude at bus 102 (where the generator is located).","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"volt = get_voltage_magnitude_series(results, 102);\nplot(volt, xlabel = \"time\", ylabel = \"Voltage [pu]\", label = \"V_2\")","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"(Image: plot)","category":"page"},{"location":"tutorials/tutorial_omib/#Optional:-Small-Signal-Analysis","page":"OMIB","title":"Optional: Small Signal Analysis","text":"","category":"section"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"PowerSimulationsDynamics uses automatic differentiation to compute the reduced Jacobian of the system for the differential states. This can be used to analyze the local stability of the linearized system. We need to re-initialize our simulation:","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"sim2 = Simulation(ResidualModel, omib_sys, mktempdir(), time_span)\nsmall_sig = small_signal_analysis(sim2)","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"The small_sig result can report the reduced jacobian for delta and omega,","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"small_sig.reduced_jacobian","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"and can also be used to report the eigenvalues of the reduced linearized system:","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"small_sig.eigenvalues","category":"page"},{"location":"api/internal/#Internal","page":"Internal API Reference","title":"Internal","text":"","category":"section"},{"location":"api/internal/","page":"Internal API Reference","title":"Internal API Reference","text":"CurrentModule = PowerSimulationsDynamics\nDocTestSetup = quote\n using PowerSimulationsDynamics\nend","category":"page"},{"location":"api/internal/","page":"Internal API Reference","title":"Internal API Reference","text":"Modules = [PowerSimulationsDynamics]\nPublic = false\nPrivate = true","category":"page"},{"location":"api/internal/#PowerSimulationsDynamics.BUILD_STATUS","page":"Internal API Reference","title":"PowerSimulationsDynamics.BUILD_STATUS","text":"Defines the status of the simulation object\n\n\n\n\n\n","category":"type"},{"location":"api/internal/#PowerSimulationsDynamics.BranchWrapper","page":"Internal API Reference","title":"PowerSimulationsDynamics.BranchWrapper","text":"Wraps DynamicBranch devices from PowerSystems to handle changes in controls and connection status, and allocate the required indexes of the state space.\n\n\n\n\n\n","category":"type"},{"location":"api/internal/#PowerSimulationsDynamics.DynamicWrapper","page":"Internal API Reference","title":"PowerSimulationsDynamics.DynamicWrapper","text":"Wraps DynamicInjection devices from PowerSystems to handle changes in controls and connection status, and allocate the required indexes of the state space.\n\n\n\n\n\n","category":"type"},{"location":"api/internal/#PowerSimulationsDynamics.SimulationInputs-Tuple{Type{MassMatrixModel}, System, Union{ConstantFrequency, ReferenceBus}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.SimulationInputs","text":"SimulationInputs build function for MassMatrixModels\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.SimulationInputs-Tuple{Type{ResidualModel}, System, Union{ConstantFrequency, ReferenceBus}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.SimulationInputs","text":"SimulationInputs build function for ResidualModels\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.generator_inner_vars","page":"Internal API Reference","title":"PowerSimulationsDynamics.generator_inner_vars","text":"Generator Inner Vars:\n\nτe_var :: Electric torque\nτm_var :: Mechanical torque\nVf_var :: Field voltage\nV_pss_var :: Additional PSS voltage\nVR_gen_var :: Real part of the terminal voltage\nVI_gen_var :: Imaginary part of the terminal voltage\nψd_var :: Stator Flux (if defined) in the d-axis\nψq_var :: Stator Flux (if defined) in the q-axis\n\n\n\n\n\n","category":"type"},{"location":"api/internal/#PowerSimulationsDynamics.inverter_inner_vars","page":"Internal API Reference","title":"PowerSimulationsDynamics.inverter_inner_vars","text":"Inverter Inner Vars:\n\nmd_var :: Modulation signal on the d-component\nmq_var :: Modulation signal on the q-component\nVdc_var :: DC voltage supplied by the DC source\nVr_filter_var :: Voltage seen in the capacitor of the filter in the R-component\nVi_filter_var :: Voltage seen in the capacitor of the filter in the I-component\nθ_freq_estimator_var :: Angle estimated by the frequency estimator.\nω_freq_estimator_var :: Frequency estimated by the frequency estimator.\nV_oc_var :: Control voltage reference in the d-axis supplied from the outer loop control to the inner loop (for Voltage Mode Control)\nId_oc_var :: Control current reference in the d-axis supplied from the outer loop control to the inner loop (for Current Mode Control)\nIq_oc_var :: Control current reference in the q-axis supplied from the outer loop control to the inner loop (for Current Mode Control)\nId_ic_var :: Control current reference in the d-axis supplied from the inner loop control to the converter (for Generic Models)\nIq_ic_var :: Control current reference in the q-axis supplied from the inner loop control to the converter (for Generic Models)\nIr_cnv_var :: Control current reference in the R-axis supplied from the converter to the filter (for Generic Models)\nIi_cnv_var :: Control current reference in the I-axis supplied from the converter to the filter (for Generic Models)\nω_oc_var :: Control frequency supplied from the outer loop control the inner loop\nθ_oc_var :: Variation of the angle (PLL or VSM) of the inverter\nVr_inv_var :: Real terminal voltage on the inverter\nVi_inv_var :: Imaginary terminal voltage on the inverter\nVr_cnv_var :: Voltage supplied from the converter in the R-component\nVi_cnv_var :: Voltage supplied from the converter in the I-component\nP_ES_var :: Power supplied from the Energy Source side\n\n\n\n\n\n","category":"type"},{"location":"api/internal/#PowerSimulationsDynamics._field_current-Tuple{SalientPoleExponential, String, Vector{Float64}, Vector{Float64}, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics._field_current","text":"Function to obtain the field current time series of a Dynamic Generator with machine type GENSAE.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._field_current-Tuple{SalientPoleQuadratic, String, Vector{Float64}, Vector{Float64}, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics._field_current","text":"Function to obtain the field current time series of a Dynamic Generator with machine type GENSAL.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._field_current-Union{Tuple{M}, Tuple{M, String, Vector{Float64}, Vector{Float64}, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}} where M<:Machine","page":"Internal API Reference","title":"PowerSimulationsDynamics._field_current","text":"Function to obtain the field current time series of a Dynamic Generator. It is dispatched via the machine type. By default, machine does not have support for field current\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._field_current-Union{Tuple{M}, Tuple{M, String, Vector{Float64}, Vector{Float64}, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}} where M<:Union{RoundRotorExponential, RoundRotorQuadratic}","page":"Internal API Reference","title":"PowerSimulationsDynamics._field_current","text":"Function to obtain the field current time series of a Dynamic Generator with machine type GENROU/GENROE.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._field_voltage-Tuple{AVRFixed, String, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics._field_voltage","text":"Function to obtain the field voltage time series of a Dynamic Generator with avr AVRFixed.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._field_voltage-Tuple{ESST1A, String, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics._field_voltage","text":"Function to obtain the field voltage time series of a Dynamic Generator with avr ESST1A.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._field_voltage-Tuple{SCRX, String, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics._field_voltage","text":"Function to obtain the field voltage time series of a Dynamic Generator with avr SCRX.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._field_voltage-Tuple{Union{ESAC1A, EXAC1}, String, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics._field_voltage","text":"Function to obtain the field voltage time series of a Dynamic Generator with avr ESAC1A and EXAC1.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._field_voltage-Union{Tuple{A}, Tuple{A, String, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}} where A<:AVR","page":"Internal API Reference","title":"PowerSimulationsDynamics._field_voltage","text":"Function to obtain the field voltage time series of a Dynamic Generator with avrs that have the field voltage as a state. By default it is assumed that the models have that state.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._frequency-Union{Tuple{G}, Tuple{F}, Tuple{OuterControl{ActivePowerDroop, ReactivePowerDroop}, F, String, SimulationResults, G, Union{Nothing, Float64, Vector{Float64}}}} where {F<:FrequencyEstimator, G<:DynamicInverter}","page":"Internal API Reference","title":"PowerSimulationsDynamics._frequency","text":"Function to obtain the frequency time series of a droop grid forming inverter out of the DAE Solution. It is dispatched via the OuterControl type.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._frequency-Union{Tuple{G}, Tuple{F}, Tuple{OuterControl{ActiveVirtualOscillator, ReactiveVirtualOscillator}, F, String, SimulationResults, G, Union{Nothing, Float64, Vector{Float64}}}} where {F<:FrequencyEstimator, G<:DynamicInverter}","page":"Internal API Reference","title":"PowerSimulationsDynamics._frequency","text":"Function to obtain the frequency time series of a VOC grid forming inverter out of the DAE Solution. It is dispatched via the OuterControl type.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._frequency-Union{Tuple{G}, Tuple{F}, Tuple{OuterControl{VirtualInertia, ReactivePowerDroop}, F, String, SimulationResults, G, Union{Nothing, Float64, Vector{Float64}}}} where {F<:FrequencyEstimator, G<:DynamicInverter}","page":"Internal API Reference","title":"PowerSimulationsDynamics._frequency","text":"Function to obtain the frequency time series of a virtual inertia grid forming inverter out of the DAE Solution. It is dispatched via the OuterControl type.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._frequency-Union{Tuple{G}, Tuple{OuterControl{ActivePowerPI, ReactivePowerPI}, KauraPLL, String, SimulationResults, G, Union{Nothing, Float64, Vector{Float64}}}} where G<:DynamicInverter","page":"Internal API Reference","title":"PowerSimulationsDynamics._frequency","text":"Function to obtain the frequency time series of a grid-following inverter with KauraPLL out of the DAE Solution. It is dispatched via the OuterControl and FrequencyEstimator type.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._frequency-Union{Tuple{G}, Tuple{OuterControl{ActivePowerPI, ReactivePowerPI}, ReducedOrderPLL, String, SimulationResults, G, Union{Nothing, Float64, Vector{Float64}}}} where G<:DynamicInverter","page":"Internal API Reference","title":"PowerSimulationsDynamics._frequency","text":"Function to obtain the frequency time series of a grid-following inverter with ReducedOrderPLL out of the DAE Solution. It is dispatched via the OuterControl and FrequencyEstimator type.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._machine_current-Tuple{BaseMachine, String, Vector{Float64}, Vector{Float64}, Float64, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics._machine_current","text":"Function to obtain the output current time series of a Classic Machine model out of the DAE Solution. It is dispatched via the machine type.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._machine_current-Tuple{OneDOneQMachine, String, Vector{Float64}, Vector{Float64}, Float64, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics._machine_current","text":"Function to obtain the output current time series of a One-D-One-Q model out of the DAE Solution. It is dispatched via the machine type.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._machine_current-Tuple{SauerPaiMachine, String, Vector{Float64}, Vector{Float64}, Float64, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics._machine_current","text":"Function to obtain the output current time series of a SauerPaiMachine model out of the DAE Solution. It is dispatched via the machine type.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._machine_current-Tuple{Union{AndersonFouadMachine, MarconatoMachine}, String, Vector{Float64}, Vector{Float64}, Float64, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics._machine_current","text":"Function to obtain the output current time series of a Marconato or AndersonFouad model out of the DAE Solution. It is dispatched via the machine type.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._machine_current-Tuple{Union{RoundRotorExponential, RoundRotorQuadratic}, String, Vector{Float64}, Vector{Float64}, Float64, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics._machine_current","text":"Function to obtain the output current time series of a GENROU/GENROE model out of the DAE Solution. It is dispatched via the machine type.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._machine_current-Tuple{Union{SalientPoleExponential, SalientPoleQuadratic}, String, Vector{Float64}, Vector{Float64}, Float64, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics._machine_current","text":"Function to obtain the output current time series of a GENSAL/GENSAE model out of the DAE Solution. It is dispatched via the machine type.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._machine_current-Tuple{Union{SimpleAFMachine, SimpleMarconatoMachine}, String, Vector{Float64}, Vector{Float64}, Float64, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics._machine_current","text":"Function to obtain the output current time series of a SimpleMarconato or SimpleAndersonFouad model out of the DAE Solution. It is dispatched via the machine type.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._make_reduced_jacobian_index-Tuple{Any, Any}","page":"Internal API Reference","title":"PowerSimulationsDynamics._make_reduced_jacobian_index","text":"Finds the location of the differential states in the reduced Jacobian\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._mechanical_torque-Tuple{DEGOV, String, SimulationResults, Union{Nothing, Float64}}","page":"Internal API Reference","title":"PowerSimulationsDynamics._mechanical_torque","text":"Function to obtain the mechanical torque time series of a Dynamic Generator with DEGOV Turbine Governor.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._mechanical_torque-Tuple{GasTG, String, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics._mechanical_torque","text":"Function to obtain the mechanical torque time series of a Dynamic Generator with GasTG (GAST) Turbine Governor.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._mechanical_torque-Tuple{HydroTurbineGov, String, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics._mechanical_torque","text":"Function to obtain the mechanical torque time series of a Dynamic Generator with HydroTurbineGov (HYGOV) Turbine Governor.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._mechanical_torque-Tuple{SteamTurbineGov1, String, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics._mechanical_torque","text":"Function to obtain the mechanical torque time series of a Dynamic Generator with SteamTurbineGov1 (TGOV1) Turbine Governor.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._mechanical_torque-Tuple{TGFixed, String, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics._mechanical_torque","text":"Function to obtain the mechanical torque time series of a Dynamic Generator with TGFixed Turbine Governor.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._mechanical_torque-Tuple{TGTypeI, String, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics._mechanical_torque","text":"Function to obtain the mechanical torque time series of a Dynamic Generator with TGTypeI Turbine Governor.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._mechanical_torque-Tuple{TGTypeII, String, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics._mechanical_torque","text":"Function to obtain the mechanical torque time series of a Dynamic Generator with TGTypeII Turbine Governor.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._output_current-Union{Tuple{G}, Tuple{C}, Tuple{LCLFilter, C, String, Vector{Float64}, Vector{Float64}, Float64, SimulationResults, G, Union{Nothing, Float64, Vector{Float64}}}} where {C<:Converter, G<:DynamicInverter}","page":"Internal API Reference","title":"PowerSimulationsDynamics._output_current","text":"Function to obtain the output current time series of a LCL Filter model out of the DAE Solution. It is dispatched via the Filter type.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._output_current-Union{Tuple{G}, Tuple{RLFilter, RenewableEnergyConverterTypeA, String, Vector{Float64}, Vector{Float64}, Float64, SimulationResults, G, Union{Nothing, Float64, Vector{Float64}}}} where G<:DynamicInverter","page":"Internal API Reference","title":"PowerSimulationsDynamics._output_current","text":"Function to obtain the output current time series of a REGCA converter model out of the DAE Solution. It is dispatched via the Converter type.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._post_proc_state_series-Tuple{Any, Int64, Nothing}","page":"Internal API Reference","title":"PowerSimulationsDynamics._post_proc_state_series","text":"Internal function to obtain as a Vector of Float64 of a specific state. It receives the solution and the global index for a state.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._pss_output-Tuple{IEEEST, String, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics._pss_output","text":"Function to obtain the pss output time series of a Dynamic Generator with pss IEEEST.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._pss_output-Tuple{PSSFixed, String, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics._pss_output","text":"Function to obtain the pss output time series of a Dynamic Generator with pss PSSFixed.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.compute_field_current-Union{Tuple{G}, Tuple{SimulationResults, G, Vector{Float64}, Vector{Float64}, Union{Nothing, Float64, Vector{Float64}}}} where G<:DynamicGenerator","page":"Internal API Reference","title":"PowerSimulationsDynamics.compute_field_current","text":"Function to obtain the field current time series of a Dynamic Generator model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage. It is dispatched for device type to compute the specific current.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.compute_field_current-Union{Tuple{G}, Tuple{SimulationResults, G, Vector{Float64}, Vector{Float64}, Union{Nothing, Float64, Vector{Float64}}}} where G<:DynamicInverter","page":"Internal API Reference","title":"PowerSimulationsDynamics.compute_field_current","text":"Function to obtain the field current time series of a Dynamic Inverter model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage. It must return nothing since field current does not exists in inverters.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.compute_field_voltage-Union{Tuple{G}, Tuple{SimulationResults, G, Union{Nothing, Float64, Vector{Float64}}}} where G<:DynamicGenerator","page":"Internal API Reference","title":"PowerSimulationsDynamics.compute_field_voltage","text":"Function to obtain the field voltage time series of a Dynamic Generator model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage. It is dispatched for device type to compute the specific voltage.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.compute_field_voltage-Union{Tuple{G}, Tuple{SimulationResults, G, Union{Nothing, Float64, Vector{Float64}}}} where G<:DynamicInverter","page":"Internal API Reference","title":"PowerSimulationsDynamics.compute_field_voltage","text":"Function to obtain the field current time series of a Dynamic Inverter model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage. It must return nothing since field voltage does not exists in inverters.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.compute_frequency-Union{Tuple{G}, Tuple{SimulationResults, G, Union{Nothing, Float64, Vector{Float64}}}} where G<:DynamicGenerator","page":"Internal API Reference","title":"PowerSimulationsDynamics.compute_frequency","text":"Function to obtain the output frequency time series of a DynamicGenerator\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.compute_mechanical_torque-Union{Tuple{G}, Tuple{SimulationResults, G, Union{Nothing, Float64, Vector{Float64}}}} where G<:DynamicGenerator","page":"Internal API Reference","title":"PowerSimulationsDynamics.compute_mechanical_torque","text":"Function to obtain the mechanical torque time series of a Dynamic Generator model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage. It is dispatched for device type to compute the specific torque.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.compute_mechanical_torque-Union{Tuple{G}, Tuple{SimulationResults, G, Union{Nothing, Float64, Vector{Float64}}}} where G<:DynamicInverter","page":"Internal API Reference","title":"PowerSimulationsDynamics.compute_mechanical_torque","text":"Function to obtain the mechanical torque time series of a Dynamic Inverter model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage. It must return nothing since mechanical torque is not used in inverters.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.compute_output_current-Tuple{SimulationResults, AggregateDistributedGenerationA, Vector{Float64}, Vector{Float64}, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.compute_output_current","text":"Function to obtain the output current time series of a AggregateDistributedGenerationA (DERA) model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.compute_output_current-Tuple{SimulationResults, PeriodicVariableSource, Vector{Float64}, Vector{Float64}, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.compute_output_current","text":"Function to obtain the output current time series of a PeriodicVariableSource model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage. It is dispatched for device type to compute the specific current. computeoutputcurrent(::SimulationResults, ::PeriodicVariableSource, ::Vector{Float64}, ::Vector{Float64}, ::Nothing)\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.compute_output_current-Tuple{SimulationResults, PowerLoad, Vector{Float64}, Vector{Float64}, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.compute_output_current","text":"Function to obtain the output current time series of a PowerLoad model. \n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.compute_output_current-Tuple{SimulationResults, PowerSystems.ExponentialLoad, Vector{Float64}, Vector{Float64}, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.compute_output_current","text":"Function to obtain the output current time series of a ExponentialLoad model. \n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.compute_output_current-Tuple{SimulationResults, SimplifiedSingleCageInductionMachine, Vector{Float64}, Vector{Float64}, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.compute_output_current","text":"Function to obtain the output current time series of a 3th Order Induction Machine model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage. \n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.compute_output_current-Tuple{SimulationResults, SingleCageInductionMachine, Vector{Float64}, Vector{Float64}, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.compute_output_current","text":"Function to obtain the output current time series of a 5th Order Induction Machine model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage. \n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.compute_output_current-Tuple{SimulationResults, StandardLoad, Vector{Float64}, Vector{Float64}, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.compute_output_current","text":"Function to obtain the output current time series of a PowerLoad model. \n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.compute_output_current-Union{Tuple{G}, Tuple{SimulationResults, G, Vector{Float64}, Vector{Float64}, Union{Nothing, Float64, Vector{Float64}}}} where G<:DynamicGenerator","page":"Internal API Reference","title":"PowerSimulationsDynamics.compute_output_current","text":"Function to obtain the output current time series of a Dynamic Generator model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage. It is dispatched for device type to compute the specific current.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.compute_output_current-Union{Tuple{G}, Tuple{SimulationResults, G, Vector{Float64}, Vector{Float64}, Union{Nothing, Float64, Vector{Float64}}}} where G<:DynamicInverter","page":"Internal API Reference","title":"PowerSimulationsDynamics.compute_output_current","text":"Function to obtain the output current time series of a Dynamic Inverter model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage. It is dispatched for device type to compute the specific current.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.compute_output_current-Union{Tuple{I}, Tuple{SimulationResults, I, Vector{Float64}, Vector{Float64}, Union{Nothing, Float64, Vector{Float64}}}} where I<:DynamicInjection","page":"Internal API Reference","title":"PowerSimulationsDynamics.compute_output_current","text":"Default function to compute output current. Returns an error\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.compute_pss_output-Union{Tuple{G}, Tuple{SimulationResults, G, Union{Nothing, Float64, Vector{Float64}}}} where G<:DynamicGenerator","page":"Internal API Reference","title":"PowerSimulationsDynamics.compute_pss_output","text":"Function to obtain the pss output time series of a Dynamic Generator model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage. It is dispatched for device type to compute the specific output.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.configure_logging-Tuple{}","page":"Internal API Reference","title":"PowerSimulationsDynamics.configure_logging","text":"configure_logging(;\n console_level = Logging.Error,\n file_level = Logging.Info,\n filename = \"power-simulations.log\",\n)\n\nCreates console and file loggers.\n\nNote: Log messages may not be written to the file until flush() or close() is called on the returned logger.\n\nArguments\n\nconsole_level = Logging.Error: level for console messages\nfile_level = Logging.Info: level for file messages\nfilename::String = power-simulations.log: log file\n\nExample\n\nlogger = configure_logging(console_level = Logging.Info)\n@info \"log message\"\nclose(logger)\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.device!-Union{Tuple{T}, Tuple{AbstractArray{T}, AbstractArray{T}, T, T, AbstractArray{T}, AbstractArray{T}, AbstractArray{T}, AbstractArray{T}, PowerSimulationsDynamics.DynamicWrapper{ActiveConstantPowerLoad}, Any, Any}} where T<:Union{Float64, ForwardDiff.Dual}","page":"Internal API Reference","title":"PowerSimulationsDynamics.device!","text":"Model of 12-state Active Constant Power Load in Julia. Based on the paper Malicious Control of an Active Load in an Islanded Mixed-Source Microgrid by C. Roberts, U. Markovic, D. Arnold and D. Callaway.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.device!-Union{Tuple{T}, Tuple{AbstractArray{T}, AbstractArray{T}, T, T, AbstractArray{T}, AbstractArray{T}, AbstractArray{T}, AbstractArray{T}, PowerSimulationsDynamics.DynamicWrapper{CSVGN1}, Any, Any}} where T<:Union{Float64, ForwardDiff.Dual}","page":"Internal API Reference","title":"PowerSimulationsDynamics.device!","text":"Model of Static Shunt Compensator: CSVGN1.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.device!-Union{Tuple{T}, Tuple{AbstractArray{T}, AbstractArray{T}, T, T, AbstractArray{T}, AbstractArray{T}, AbstractArray{T}, AbstractArray{T}, PowerSimulationsDynamics.DynamicWrapper{SimplifiedSingleCageInductionMachine}, Any, Any}} where T<:Union{Float64, ForwardDiff.Dual}","page":"Internal API Reference","title":"PowerSimulationsDynamics.device!","text":"Model of 3-state (SimplifiedSingleCageInductionMachine) induction motor in Julia. Based on the 3rd order model derived in Prabha Kundur's Book and the equations in \"Analysis of Electric Machinery and Drive Systems\" by Paul Krause, Oleg Wasynczuk and Scott Sudhoff.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.device!-Union{Tuple{T}, Tuple{AbstractArray{T}, AbstractArray{T}, T, T, AbstractArray{T}, AbstractArray{T}, AbstractArray{T}, AbstractArray{T}, PowerSimulationsDynamics.DynamicWrapper{SingleCageInductionMachine}, Any, Any}} where T<:Union{Float64, ForwardDiff.Dual}","page":"Internal API Reference","title":"PowerSimulationsDynamics.device!","text":"Model of 5-state (SingleCageInductionMachine) induction motor in Julia. Refer to \"Analysis of Electric Machinery and Drive Systems\" by Paul Krause, Oleg Wasynczuk and Scott Sudhoff for the equations\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.initialize_mach_shaft!-Union{Tuple{P}, Tuple{TG}, Tuple{A}, Tuple{S}, Tuple{Any, StaticInjection, PowerSimulationsDynamics.DynamicWrapper{DynamicGenerator{AndersonFouadMachine, S, A, TG, P}}, AbstractVector}} where {S<:Shaft, A<:AVR, TG<:TurbineGov, P<:PSS}","page":"Internal API Reference","title":"PowerSimulationsDynamics.initialize_mach_shaft!","text":"Initialitation of model of 6-state (Anderson-Fouad) synchronous machine in Julia. Refer to Power System Modelling and Scripting by F. Milano for the equations\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.initialize_mach_shaft!-Union{Tuple{P}, Tuple{TG}, Tuple{A}, Tuple{S}, Tuple{Any, StaticInjection, PowerSimulationsDynamics.DynamicWrapper{DynamicGenerator{BaseMachine, S, A, TG, P}}, AbstractVector}} where {S<:Shaft, A<:AVR, TG<:TurbineGov, P<:PSS}","page":"Internal API Reference","title":"PowerSimulationsDynamics.initialize_mach_shaft!","text":"Initialitation of model of 0-state synchronous (classic model) machine in Julia. Refer to Power System Modelling and Scripting by F. Milano for the equations\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.initialize_mach_shaft!-Union{Tuple{P}, Tuple{TG}, Tuple{A}, Tuple{S}, Tuple{Any, StaticInjection, PowerSimulationsDynamics.DynamicWrapper{DynamicGenerator{MarconatoMachine, S, A, TG, P}}, AbstractVector}} where {S<:Shaft, A<:AVR, TG<:TurbineGov, P<:PSS}","page":"Internal API Reference","title":"PowerSimulationsDynamics.initialize_mach_shaft!","text":"Initialitation of model of 6-state (Marconato) synchronous machine in Julia. Refer to Power System Modelling and Scripting by F. Milano for the equations\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.initialize_mach_shaft!-Union{Tuple{P}, Tuple{TG}, Tuple{A}, Tuple{S}, Tuple{Any, StaticInjection, PowerSimulationsDynamics.DynamicWrapper{DynamicGenerator{OneDOneQMachine, S, A, TG, P}}, AbstractVector}} where {S<:Shaft, A<:AVR, TG<:TurbineGov, P<:PSS}","page":"Internal API Reference","title":"PowerSimulationsDynamics.initialize_mach_shaft!","text":"Initialitation of model of 2-state (One d- and One q-) synchronous machine in Julia. Refer to Power System Modelling and Scripting by F. Milano for the equations\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.initialize_mach_shaft!-Union{Tuple{P}, Tuple{TG}, Tuple{A}, Tuple{S}, Tuple{Any, StaticInjection, PowerSimulationsDynamics.DynamicWrapper{DynamicGenerator{SauerPaiMachine, S, A, TG, P}}, AbstractVector}} where {S<:Shaft, A<:AVR, TG<:TurbineGov, P<:PSS}","page":"Internal API Reference","title":"PowerSimulationsDynamics.initialize_mach_shaft!","text":"Initialitation of model of 6-state (SauerPai) synchronous machine in Julia. Refer to Power System Modelling and Scripting by F. Milano for the equations\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.initialize_mach_shaft!-Union{Tuple{P}, Tuple{TG}, Tuple{A}, Tuple{S}, Tuple{Any, StaticInjection, PowerSimulationsDynamics.DynamicWrapper{DynamicGenerator{SimpleAFMachine, S, A, TG, P}}, AbstractVector}} where {S<:Shaft, A<:AVR, TG<:TurbineGov, P<:PSS}","page":"Internal API Reference","title":"PowerSimulationsDynamics.initialize_mach_shaft!","text":"Initialitation of model of 4-state (Simple Anderson-Fouad) synchronous machine in Julia. Refer to Power System Modelling and Scripting by F. Milano for the equations\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.initialize_mach_shaft!-Union{Tuple{P}, Tuple{TG}, Tuple{A}, Tuple{S}, Tuple{Any, StaticInjection, PowerSimulationsDynamics.DynamicWrapper{DynamicGenerator{SimpleMarconatoMachine, S, A, TG, P}}, AbstractVector}} where {S<:Shaft, A<:AVR, TG<:TurbineGov, P<:PSS}","page":"Internal API Reference","title":"PowerSimulationsDynamics.initialize_mach_shaft!","text":"Initialitation of model of 4-state (Simple Marconato) synchronous machine in Julia. Refer to Power System Modelling and Scripting by F. Milano for the equations\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.low_pass_modified_mass_matrix-Union{Tuple{Z}, Tuple{W}, Tuple{V}, Tuple{Z, V, Float64, W, Float64}} where {V<:Union{Float64, ForwardDiff.Dual}, W<:Union{Float64, ForwardDiff.Dual}, Z<:Union{Float64, ForwardDiff.Dual}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.low_pass_modified_mass_matrix","text":"Low Pass Filter Modified ┌─────────────┐ │ K │ u -> │ ────────────│ -> y │ K_den + sT │ └─────────────┘\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.mass_matrix_entries-Tuple{DynamicInjection}","page":"Internal API Reference","title":"PowerSimulationsDynamics.mass_matrix_entries","text":"Default implementation of mass matrix entries. Keeps the default values in the identity matrix\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.mdl_machine_ode!-Union{Tuple{P}, Tuple{TG}, Tuple{A}, Tuple{S}, Tuple{AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, PowerSimulationsDynamics.DynamicWrapper{DynamicGenerator{AndersonFouadMachine, S, A, TG, P}}, Any, Any}} where {S<:Shaft, A<:AVR, TG<:TurbineGov, P<:PSS}","page":"Internal API Reference","title":"PowerSimulationsDynamics.mdl_machine_ode!","text":"Model of 6-state (AndersonFouadMachine) synchronous machine in Julia. Refer to Power System Modelling and Scripting by F. Milano for the equations\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.mdl_machine_ode!-Union{Tuple{P}, Tuple{TG}, Tuple{A}, Tuple{S}, Tuple{AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, PowerSimulationsDynamics.DynamicWrapper{DynamicGenerator{BaseMachine, S, A, TG, P}}, Any, Any}} where {S<:Shaft, A<:AVR, TG<:TurbineGov, P<:PSS}","page":"Internal API Reference","title":"PowerSimulationsDynamics.mdl_machine_ode!","text":"Model of 0-state synchronous machine in Julia. Refer to Power System Modelling and Scripting by F. Milano for the equations\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.mdl_machine_ode!-Union{Tuple{P}, Tuple{TG}, Tuple{A}, Tuple{S}, Tuple{AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, PowerSimulationsDynamics.DynamicWrapper{DynamicGenerator{MarconatoMachine, S, A, TG, P}}, Any, Any}} where {S<:Shaft, A<:AVR, TG<:TurbineGov, P<:PSS}","page":"Internal API Reference","title":"PowerSimulationsDynamics.mdl_machine_ode!","text":"Model of 6-state (MarconatoMachine) synchronous machine in Julia. Refer to Power System Modelling and Scripting by F. Milano for the equations\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.mdl_machine_ode!-Union{Tuple{P}, Tuple{TG}, Tuple{A}, Tuple{S}, Tuple{AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, PowerSimulationsDynamics.DynamicWrapper{DynamicGenerator{OneDOneQMachine, S, A, TG, P}}, Any, Any}} where {S<:Shaft, A<:AVR, TG<:TurbineGov, P<:PSS}","page":"Internal API Reference","title":"PowerSimulationsDynamics.mdl_machine_ode!","text":"Model of 2-state (One d- and One q-) synchronous machine in Julia. Refer to Power System Modelling and Scripting by F. Milano for the equations\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.mdl_machine_ode!-Union{Tuple{P}, Tuple{TG}, Tuple{A}, Tuple{S}, Tuple{AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, PowerSimulationsDynamics.DynamicWrapper{DynamicGenerator{SauerPaiMachine, S, A, TG, P}}, Any, Any}} where {S<:Shaft, A<:AVR, TG<:TurbineGov, P<:PSS}","page":"Internal API Reference","title":"PowerSimulationsDynamics.mdl_machine_ode!","text":"Model of 6-state (SauerPaiMachine) synchronous machine in Julia. Refer to Power System Modelling and Scripting by F. Milano for the equations\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.mdl_machine_ode!-Union{Tuple{P}, Tuple{TG}, Tuple{A}, Tuple{S}, Tuple{AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, PowerSimulationsDynamics.DynamicWrapper{DynamicGenerator{SimpleAFMachine, S, A, TG, P}}, Any, Any}} where {S<:Shaft, A<:AVR, TG<:TurbineGov, P<:PSS}","page":"Internal API Reference","title":"PowerSimulationsDynamics.mdl_machine_ode!","text":"Model of 4-state (SimpleAFMachine) synchronous machine in Julia. Refer to Power System Modelling and Scripting by F. Milano for the equations\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.mdl_machine_ode!-Union{Tuple{P}, Tuple{TG}, Tuple{A}, Tuple{S}, Tuple{AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, PowerSimulationsDynamics.DynamicWrapper{DynamicGenerator{SimpleMarconatoMachine, S, A, TG, P}}, Any, Any}} where {S<:Shaft, A<:AVR, TG<:TurbineGov, P<:PSS}","page":"Internal API Reference","title":"PowerSimulationsDynamics.mdl_machine_ode!","text":"Model of 4-state (SimpleMarconatoMachine) synchronous machine in Julia. Refer to Power System Modelling and Scripting by F. Milano for the equations\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.mdl_zip_load!-Union{Tuple{T}, Tuple{T, T, AbstractArray{T}, AbstractArray{T}, PowerSimulationsDynamics.StaticLoadWrapper}} where T<:Union{Float64, ForwardDiff.Dual}","page":"Internal API Reference","title":"PowerSimulationsDynamics.mdl_zip_load!","text":"Model for ZIP Load model given by:\n\nPzip = Ppower + Pcurrent * (V / V0) + Pimpedance * (V / V0)^2 Qzip = Qpower + Qcurrent * (V / V0) + Qimpedance * (V / V0)^2\n\nwith V = sqrt(Vr^2 + Vi^2) and V0 the voltage magnitude from the power flow solution\n\nThe current taken for the load is computed as: Izip = (Pzip + j Qzip)^* / (Vr + j Vi)^* Izip = (Pzip - j Qzip) / (Vr - j Vi)\n\nFor constant impedance it is obtained: Izre = (1 / V0)^2 * (Vr * Pimpedance + Vi * Qimpedance) Izim = (1 / V0)^2 * (Vi * Pimpedance - Vr * Qimpedance)\n\nFor constant current it is obtained: Iire = (1 / V0) * ( (Vr * Pcurrent + Vi * Qcurrent) / V ) Iiim = (1 / V0) * ( (Vi * Pcurrent - Vr * Qcurrent) / V )\n\nFor constant power it is obtained: Ipre = (Vr * Ppower + Vi * Qpower) / V^2 Ipim = (Vi * Ppower - Vr * Qpower) / V^2\n\nModel for Exponential Load model given by:\n\nPexp = P0 * (V / V0)^α Qexp = Q0 * (V / V0)^β\n\nThe current taken for the load is computed as: Iexp = (Pexp + j Qexp)^* / (Vr + j Vi)^* Iexp = (Pexp - j Qexp) / (Vr - j Vi)\n\nIt results: Irexp = Vr * P0 * (V^(α - 2) / V0^α) + Vi * Q0 * (V^(β - 2)/ V0^β) Iiim = Vi * P0 * (V^(α - 2) / V0^α) - Vr * Q0 * (V^(β - 2)/ V0^β)\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.post_proc_activepower_series-Tuple{SimulationResults, String, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.post_proc_activepower_series","text":"Function to compute the active power output time series of a Dynamic Injection series out of the DAE Solution. It receives the solution and the string name of the Dynamic Injection device.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.post_proc_branch_series-Tuple{SimulationResults, String, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.post_proc_branch_series","text":"Function to compute the current flowing through an AC branch through their series element. The current is computed through the from bus into the to bus.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.post_proc_field_current_series-Tuple{SimulationResults, String, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.post_proc_field_current_series","text":"Function to compute the field current output time series of a Dynamic Injection series out of the DAE Solution. It receives the solution and the string name of the Dynamic Injection device.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.post_proc_field_voltage_series-Tuple{SimulationResults, String, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.post_proc_field_voltage_series","text":"Function to compute the field voltage output time series of a Dynamic Injection series out of the DAE Solution. It receives the solution and the string name of the Dynamic Injection device.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.post_proc_frequency_series-Tuple{SimulationResults, String, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.post_proc_frequency_series","text":"Function to compute the frequency of a Dynamic Injection component.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.post_proc_imaginary_current_series-Tuple{SimulationResults, String, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.post_proc_imaginary_current_series","text":"Function to compute the imaginary current output time series of a Dynamic Injection series out of the DAE Solution. It receives the solution and the string name of the Dynamic Injection device.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.post_proc_mechanical_torque_series-Tuple{SimulationResults, String, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.post_proc_mechanical_torque_series","text":"Function to compute the mechanical torque output time series of a Dynamic Injection series out of the DAE Solution. It receives the solution and the string name of the Dynamic Injection device.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.post_proc_pss_output_series-Tuple{SimulationResults, String, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.post_proc_pss_output_series","text":"Function to compute the pss output time series of a Dynamic Injection series out of the DAE Solution. It receives the solution and the string name of the Dynamic Injection device.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.post_proc_reactivepower_series-Tuple{SimulationResults, String, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.post_proc_reactivepower_series","text":"Function to compute the active power output time series of a Dynamic Injection series out of the DAE Solution. It receives the solution and the string name of the Dynamic Injection device.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.post_proc_real_current_series-Tuple{SimulationResults, String, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.post_proc_real_current_series","text":"Function to compute the real current output time series of a Dynamic Injection series out of the DAE Solution. It receives the solution and the string name of the Dynamic Injection device.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.post_proc_source_voltage_current_series","page":"Internal API Reference","title":"PowerSimulationsDynamics.post_proc_source_voltage_current_series","text":"Function to obtain voltage and output currents for a source. It receives the simulation resutls and an optional argument of the time step of the results.\n\n\n\n\n\n","category":"function"},{"location":"api/internal/#PowerSimulationsDynamics.post_proc_state_series-Tuple{SimulationResults, Tuple{String, Symbol}, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.post_proc_state_series","text":"Function to obtain the state time series of a specific state. It receives the simulation, and a tuple containing the name of the Dynamic Device and the symbol of the state.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.post_proc_voltage_current_series-Tuple{SimulationResults, String, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.post_proc_voltage_current_series","text":"Function to obtain voltage and output currents for a dynamic device. It receives the simulation, and the name of the Dynamic Device.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.post_proc_voltage_series-Tuple{Any, Int64, Int64, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.post_proc_voltage_series","text":"Function to obtain voltage using the bus index (and not the bus number). It receives the solution, the bus index and the total number of buses.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.saturation_function-Tuple{Union{RoundRotorExponential, SalientPoleExponential}, Union{Float64, ForwardDiff.Dual}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.saturation_function","text":"Saturation function for exponential saturation models for machines\n Se(x) = B * x^A\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.saturation_function-Tuple{Union{RoundRotorQuadratic, SalientPoleQuadratic}, Union{Float64, ForwardDiff.Dual}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.saturation_function","text":"Saturation function for quadratic saturation models for machines\n Se(x) = B * (x - A)^2 / x\n\n\n\n\n\n","category":"method"},{"location":"component_models/converter/#Converter","page":"Converter","title":"Converter","text":"","category":"section"},{"location":"component_models/converter/","page":"Converter","title":"Converter","text":"This component can be used to model the dynamics of the switching process.","category":"page"},{"location":"component_models/converter/#Average-Model-[AverageConverter]","page":"Converter","title":"Average Model [AverageConverter]","text":"","category":"section"},{"location":"component_models/converter/","page":"Converter","title":"Converter","text":"The average model outputs the desired reference signal since:","category":"page"},{"location":"component_models/converter/","page":"Converter","title":"Converter","text":"beginalign\nv_d^textcv approx m_d v_textdc approx fracv_d^textref-signalv_textdc v_textdc approx v_d^textref-signal tag1a \nv_q^textcv approx m_q v_textdc approx fracv_q^textref-signalv_textdc v_textdc approx v_q^textref-signal tag1b\nendalign","category":"page"},{"location":"component_models/converter/","page":"Converter","title":"Converter","text":"where m_dq is the modulation signal, and v_dq^textref-signal is the voltage reference signal from the inner loop control.","category":"page"},{"location":"component_models/converter/#Generic-Renewable-Converter-Type-A-[RenewableEnergyConverterTypeA]","page":"Converter","title":"Generic Renewable Converter Type A ```[RenewableEnergyConverterTypeA]","text":"","category":"section"},{"location":"component_models/converter/","page":"Converter","title":"Converter","text":"This block represents the REGCA model. The equations (without the limiters) are:","category":"page"},{"location":"component_models/converter/","page":"Converter","title":"Converter","text":"beginalign\n dotI_p = frac1T_g (I_textpcmd - I_p) tag2a \n dotI_q = frac1T_g (I_textqcmd - I_q) tag2b \n dotV_textmeas = frac1T_fltr (V_t - V_textmeas tag2c)\nendalign","category":"page"},{"location":"component_models/converter/","page":"Converter","title":"Converter","text":"on which I_textpcmd and I_textqcmd are the current commands from the inner control and V_t is the bus voltage magnitude. The additional terms and output current are computed as:","category":"page"},{"location":"component_models/converter/","page":"Converter","title":"Converter","text":"beginalign\n I_q^textcv = -I_q - I_textqextra tag2d \n I_textqextra = max(K_hv (V_t - V_textolim)) tag2e \n I_p^textcv = G_lv I_p tag2f \nendalign","category":"page"},{"location":"component_models/converter/","page":"Converter","title":"Converter","text":"on which G_lv is the gain used for Low Voltage Active Current Management and I_textqextra is the additional current for High Voltage Reactive Current Management.","category":"page"},{"location":"component_models/converter/","page":"Converter","title":"Converter","text":"It is important to note that both current commands coming from the inner control were obtained by dividing the active (or reactive) power by the magnitude voltage instead of using the correct phasor formula I = (SV)^*. For that purpose, a correction factor must be applied to obtain the correct output currents in the network reference frame:","category":"page"},{"location":"component_models/converter/","page":"Converter","title":"Converter","text":"beginalign*\n I_r + jI_i = (I_p + jI_q) cdot V_t cdot frac1V_r + jV_i \n = (I_p + jI_q) cdot fracV_tV_t e^jtheta \n = (I_p + jI_q) cdot e^-jtheta\nendalign*","category":"page"},{"location":"component_models/converter/","page":"Converter","title":"Converter","text":"This correction factor looks like a reference transformation that must be used to properly inject current into the grid. With that the output current is computed as:","category":"page"},{"location":"component_models/converter/","page":"Converter","title":"Converter","text":"beginalign\n I_r = I_p^textcv cos(theta) - I_q^textcv sin(theta) tag2g \n I_i = I_p^textcv sin(theta) + I_q^textcv cos(theta) tag2h\nendalign","category":"page"},{"location":"component_models/converter/","page":"Converter","title":"Converter","text":"This current source is usually modeled as a Norton equivalent using a parallel impedance with values R_sorce and X_sorce provided in the .raw file. If an RL filter is used, a Voltage Source behind that RL filter (i.e. the converter output voltage) can be computed as:","category":"page"},{"location":"component_models/converter/","page":"Converter","title":"Converter","text":"beginalign*\n Z_f = r_f + jl_f \n Z_sorce = R_sorce + jX_sorce \n I_cv = I_r + jI_i \n v_r^textcv + jv_i^textcv = fracI_cv + fracv^textgridZ_ffrac1Z_sorce + frac1Z_f tag2i\nendalign*","category":"page"},{"location":"#PowerSimulationsDynamics.jl","page":"Welcome Page","title":"PowerSimulationsDynamics.jl","text":"","category":"section"},{"location":"","page":"Welcome Page","title":"Welcome Page","text":"CurrentModule = PowerSimulationsDynamics","category":"page"},{"location":"#Overview","page":"Welcome Page","title":"Overview","text":"","category":"section"},{"location":"","page":"Welcome Page","title":"Welcome Page","text":"PowerSimulationsDynamics.jl is a Julia package for doing Power Systems Dynamic Modeling with Low Inertia Energy Sources.","category":"page"},{"location":"","page":"Welcome Page","title":"Welcome Page","text":"The synchronous machine components supported here are based on commercial models and the academic components are derived from Power System Modelling and Scripting.","category":"page"},{"location":"","page":"Welcome Page","title":"Welcome Page","text":"Inverter models support both commercial models, such as REPC, REEC and REGC type of models; and academic models obtained from grid-following and grid-forming literature such as in \"A Virtual Synchronous Machine implementation for distributed control of power converters in SmartGrids\"","category":"page"},{"location":"","page":"Welcome Page","title":"Welcome Page","text":"The background work on PowerSimulationsDynamics.jl is explained in Revisiting Power Systems Time-domain Simulation Methods and Models","category":"page"},{"location":"","page":"Welcome Page","title":"Welcome Page","text":"@article{lara2023revisiting,\ntitle={Revisiting Power Systems Time-domain Simulation Methods and Models},\nauthor={Lara, Jose Daniel and Henriquez-Auba, Rodrigo and Ramasubramanian, Deepak and Dhople, Sairaj and Callaway, Duncan S and Sanders, Seth},\njournal={arXiv preprint arXiv:2301.10043},\nyear={2023}\n}","category":"page"},{"location":"#Installation","page":"Welcome Page","title":"Installation","text":"","category":"section"},{"location":"","page":"Welcome Page","title":"Welcome Page","text":"The latest stable release of PowerSimulationsDynamics.jl can be installed using the Julia package manager with","category":"page"},{"location":"","page":"Welcome Page","title":"Welcome Page","text":"] add PowerSimulationsDynamics","category":"page"},{"location":"","page":"Welcome Page","title":"Welcome Page","text":"For the current development version, \"checkout\" this package with","category":"page"},{"location":"","page":"Welcome Page","title":"Welcome Page","text":"] add PowerSimulationsDynamics#master","category":"page"},{"location":"#Structure","page":"Welcome Page","title":"Structure","text":"","category":"section"},{"location":"","page":"Welcome Page","title":"Welcome Page","text":"The following figure shows the interactions between PowerSimulationsDynamics.jl, PowerSystems.jl, ForwardDiff.jl, DiffEqBase.jl and the integrators. The architecture of PowerSimulationsDynamics.jl is such that the power system models are all self-contained and return the model function evaluations. The Jacobian is calculated using automatic differentiation through ForwardDiff.jl, that is used for both numerical integration and small signal analysis. Considering that the resulting models are differential-algebraic equations (DAE), the implementation focuses on the use of implicit solvers, in particular BDF and Rosenbrock methods.","category":"page"},{"location":"","page":"Welcome Page","title":"Welcome Page","text":"","category":"page"},{"location":"","page":"Welcome Page","title":"Welcome Page","text":"⠀","category":"page"},{"location":"","page":"Welcome Page","title":"Welcome Page","text":"","category":"page"},{"location":"","page":"Welcome Page","title":"Welcome Page","text":"PowerSimulationsDynamics.jl has been developed as part of the Scalable Integrated Infrastructure Planning (SIIP) initiative at the U.S. Department of Energy's National Renewable Energy Laboratory (NREL)","category":"page"},{"location":"generic/#Industrial-(Generic)-Renewable-Models","page":"Industrial Renewable Models","title":"Industrial (Generic) Renewable Models","text":"","category":"section"},{"location":"generic/#Connection-with-the-Inverter-Metamodel","page":"Industrial Renewable Models","title":"Connection with the Inverter Metamodel","text":"","category":"section"},{"location":"generic/","page":"Industrial Renewable Models","title":"Industrial Renewable Models","text":"Generic Renewable Models for PV solar or battery devices used in industrial tools, such as PSS/E or PowerWorld, does not necessary resemble the proposed structure of our proposed metamodel. ","category":"page"},{"location":"generic/","page":"Industrial Renewable Models","title":"Industrial Renewable Models","text":"In general terms, a generic renewable model (for PV plant or battery) is typically a Grid Following inverter that uses a Renewable Energy Plant Controller (REPC), a Renewable Energy Electrical Controller (REEC) and a Renewable Energy Generic Converter (REGC) model. The following figure is useful to understand the general structure of such models:","category":"page"},{"location":"generic/","page":"Industrial Renewable Models","title":"Industrial Renewable Models","text":"","category":"page"},{"location":"generic/","page":"Industrial Renewable Models","title":"Industrial Renewable Models","text":"In comparison to the proposed inverter metamodel it is clear that the REPC resembles the Outer Control. However, the REEC has a purpose of both Outer Control and Inner Control and the REGC has a similar purpose of the Converter and Filter in the proposed structure. For such purpose, it was necessary to split the REEC and part of its model was included in both Outer Control and Inner Control.","category":"page"},{"location":"generic/#Example-of-implementation-of-generic-models","page":"Industrial Renewable Models","title":"Example of implementation of generic models","text":"","category":"section"},{"location":"generic/","page":"Industrial Renewable Models","title":"Industrial Renewable Models","text":"The following includes examples of the implementation of the proposed model in the inverter metamodel.","category":"page"},{"location":"generic/#Active-Renewable-Outer-Control","page":"Industrial Renewable Models","title":"Active Renewable Outer Control","text":"","category":"section"},{"location":"generic/","page":"Industrial Renewable Models","title":"Industrial Renewable Models","text":"The following example join the active power controllers from REPCA and REECB as ActiveRenewableControllerAB in PowerSimulationsDynamics.jl","category":"page"},{"location":"generic/","page":"Industrial Renewable Models","title":"Industrial Renewable Models","text":"","category":"page"},{"location":"generic/","page":"Industrial Renewable Models","title":"Industrial Renewable Models","text":"⠀","category":"page"},{"location":"generic/","page":"Industrial Renewable Models","title":"Industrial Renewable Models","text":"An important thing to consider with the industrial models, is that the change of Flags can significantly vary the model and purpose of the controller.","category":"page"},{"location":"generic/#Reactive-Renewable-Outer-Control","page":"Industrial Renewable Models","title":"Reactive Renewable Outer Control","text":"","category":"section"},{"location":"generic/","page":"Industrial Renewable Models","title":"Industrial Renewable Models","text":"Similar to the active controller, the following figure presents the reactive controller part from REPCA and REECB as ReactiveRenewableControllerAB in PowerSimulationsDynamics.jl","category":"page"},{"location":"generic/","page":"Industrial Renewable Models","title":"Industrial Renewable Models","text":"","category":"page"},{"location":"generic/","page":"Industrial Renewable Models","title":"Industrial Renewable Models","text":"⠀","category":"page"},{"location":"generic/#Inner-Controller","page":"Industrial Renewable Models","title":"Inner Controller","text":"","category":"section"},{"location":"generic/","page":"Industrial Renewable Models","title":"Industrial Renewable Models","text":"Finally, the remaining part from REECB was included RECurrentControllerB","category":"page"},{"location":"generic/","page":"Industrial Renewable Models","title":"Industrial Renewable Models","text":"","category":"page"},{"location":"generic/","page":"Industrial Renewable Models","title":"Industrial Renewable Models","text":"⠀","category":"page"},{"location":"generic/","page":"Industrial Renewable Models","title":"Industrial Renewable Models","text":"The REGCAmodel was directly included in a Converter Block, and the filter can be bypassed using an RLFilter block with rf = lf = 0.","category":"page"},{"location":"generic/#Current-availability-of-model-flags-in-PSID","page":"Industrial Renewable Models","title":"Current availability of model flags in PSID","text":"","category":"section"},{"location":"generic/#Active-Controller","page":"Industrial Renewable Models","title":"Active Controller","text":"","category":"section"},{"location":"generic/","page":"Industrial Renewable Models","title":"Industrial Renewable Models","text":"For the active controller, both Freq_Flag = 0 (ignoring frequency regulation) and Freq_Flag = 1 (considering frequency regulation) are available.","category":"page"},{"location":"generic/#Reactive-Controller","page":"Industrial Renewable Models","title":"Reactive Controller","text":"","category":"section"},{"location":"generic/","page":"Industrial Renewable Models","title":"Industrial Renewable Models","text":"The following table describes the current available combination of flags in PSID:","category":"page"},{"location":"generic/","page":"Industrial Renewable Models","title":"Industrial Renewable Models","text":"REF_Flag PF_Flag V_Flag Q_Flag\n0 0 0 0\n0 0 1 0\n1 0 1 1\n1 0 0 0","category":"page"},{"location":"generic/","page":"Industrial Renewable Models","title":"Industrial Renewable Models","text":"Any combination outside of these cases may not converge to a feasible operating point. Check the following CAISO report for the description and compliance of each flag combination.","category":"page"}] +[{"location":"execute/#Executing-a-Simulation","page":"Simulation Execution","title":"Executing a Simulation","text":"","category":"section"},{"location":"execute/","page":"Simulation Execution","title":"Simulation Execution","text":"After constructing the System data from PowerSystems.jl with its dynamic components, a Simulation structure must be constructed. Check the API for Simulation and Simulation! for its construction and available arguments.","category":"page"},{"location":"execute/","page":"Simulation Execution","title":"Simulation Execution","text":"Once a Simulation is constructed and properly initialized, the execute! command is used to run the Simulation. If no perturbation was included, then a steady state simulation will be run over the time span defined. See the API of execute! for more details.","category":"page"},{"location":"execute/#Solvers","page":"Simulation Execution","title":"Solvers","text":"","category":"section"},{"location":"execute/","page":"Simulation Execution","title":"Simulation Execution","text":"Solvers must be chosen accordingly depending on the type of model used in the Simulation. For example, a Residual model can be executed using Sundials IDA solver:","category":"page"},{"location":"execute/","page":"Simulation Execution","title":"Simulation Execution","text":"using Sundials\nsim = Simulation(\n ResidualModel,\n sys,\n pwd(),\n (0.0, 20.0),\n perturbation,\n)\nexecute!(sim, IDA())","category":"page"},{"location":"execute/","page":"Simulation Execution","title":"Simulation Execution","text":"Results can be explored using:","category":"page"},{"location":"execute/","page":"Simulation Execution","title":"Simulation Execution","text":"results = read_results(sim)","category":"page"},{"location":"execute/","page":"Simulation Execution","title":"Simulation Execution","text":"Similarly, a Mass Matrix model can be executed using Rodas4 solver.","category":"page"},{"location":"execute/","page":"Simulation Execution","title":"Simulation Execution","text":"using OrdinaryDiffEq\nsim2 = Simulation(\n MassMatrixModel,\n sys,\n pwd(),\n (0.0, 20.0),\n perturbation,\n)\nexecute!(sim2, Rodas4())","category":"page"},{"location":"execute/#Exploring-the-Solution","page":"Simulation Execution","title":"Exploring the Solution","text":"","category":"section"},{"location":"execute/","page":"Simulation Execution","title":"Simulation Execution","text":"Once a Simulation is executed and the results are stored via results = read_results(sim), the following functions can be used to explore the Simulation solution:","category":"page"},{"location":"execute/#Show-initial-conditions","page":"Simulation Execution","title":"Show initial conditions","text":"","category":"section"},{"location":"execute/","page":"Simulation Execution","title":"Simulation Execution","text":"The function show_states_initial_value(results) can be used to display the initial condition of the voltages and dynamic states of each dynamic component.","category":"page"},{"location":"execute/#Explore-bus-voltages","page":"Simulation Execution","title":"Explore bus voltages","text":"","category":"section"},{"location":"execute/","page":"Simulation Execution","title":"Simulation Execution","text":"The function get_voltage_magnitude_series(results, BusNumber) can be used to obtain the voltage magnitude time series of the specified bus. Similarly, get_voltage_angle_series(results, BusNumber) can be used to obtain the voltage angle time series of the specified bus.","category":"page"},{"location":"execute/#Explore-output-currents","page":"Simulation Execution","title":"Explore output currents","text":"","category":"section"},{"location":"execute/","page":"Simulation Execution","title":"Simulation Execution","text":"The functions get_real_current_series(results, \"DeviceName\") and get_imaginary_current_series(results, \"DeviceName\") can be used to obtain the output current time series of the specified device.","category":"page"},{"location":"execute/#Explore-output-power","page":"Simulation Execution","title":"Explore output power","text":"","category":"section"},{"location":"execute/","page":"Simulation Execution","title":"Simulation Execution","text":"The functions get_activepower_series(results, \"DeviceName\") and get_reactivepower_series(results, \"DeviceName\") can be used to obtain the output power time series of the specified device.","category":"page"},{"location":"execute/#Explore-dynamic-states","page":"Simulation Execution","title":"Explore dynamic states","text":"","category":"section"},{"location":"execute/","page":"Simulation Execution","title":"Simulation Execution","text":"The function get_state_series(results, (\"DeviceName\", :StateSymbol) can be used to obtain the specified state time series of the specified device.","category":"page"},{"location":"execute/#Explore-Reference-Setpoints","page":"Simulation Execution","title":"Explore Reference Setpoints","text":"","category":"section"},{"location":"execute/","page":"Simulation Execution","title":"Simulation Execution","text":"The function get_setpoints(sim) can be used to obtain the reference setpoints of each dynamic device. Note: If a setpoint was changed via a perturbation, this function will return the modified setpoint.","category":"page"},{"location":"execute/#Keyword-Arguments","page":"Simulation Execution","title":"Keyword Arguments","text":"","category":"section"},{"location":"execute/","page":"Simulation Execution","title":"Simulation Execution","text":"Any solver option available in DifferentialEquations.jl can be passed as keyword arguments in the execute! function. Please see the Common Solver Options in the DifferentialEquations.jl documentation for more details.","category":"page"},{"location":"execute/","page":"Simulation Execution","title":"Simulation Execution","text":"Most common solver options used are dtmax to control the maximum dt for adaptive timestepping. abstol and reltol are also commonly used to control the tolerance in the adaptive timestepping. saveat is also used to store the results at a specified time stamps. For example, the following code is valid to further specify your solver options:","category":"page"},{"location":"execute/","page":"Simulation Execution","title":"Simulation Execution","text":"execute!(sim, IDA(), dtmax = 0.01, abstol = 1e-9, reltol = 1e-6, saveat = 0.01)","category":"page"},{"location":"execute/","page":"Simulation Execution","title":"Simulation Execution","text":"In addition, the keyword argument enable_progress_bar = false can be used to disable the progress bar.","category":"page"},{"location":"component_models/inner_control/#Inner-Loop-Controls","page":"Inner Control","title":"Inner Loop Controls","text":"","category":"section"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"This component defines voltage and current controllers to generate the reference signal for the converter. Although in many controls the current and voltage control are separate blocks we propose a more general control approach that considers them as a joint control logic.","category":"page"},{"location":"component_models/inner_control/#Integrated-Virtual-Impedance,-Voltage-and-Current-Controller-[VoltageModeControl]","page":"Inner Control","title":"Integrated Virtual Impedance, Voltage and Current Controller [VoltageModeControl]","text":"","category":"section"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"The following model receives both the outer loop control frequency and reference voltage signal to generate the reference signal for the converters. The virtual impedance plays a similar role of the impedance of a synchronous generator. A PI voltage controller is used to generate the current signal that is used in the PI current controller to finally generate the voltage reference signal for the converters.","category":"page"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"beginalign*\n dotxi_d = v_dtextvi^textref - v_d tag1a \n dotxi_q = v_qtextvi^textref - v_q tag1b \n dotgamma_d = i_dtextcv^textref - i_dtextcv tag1c \n dotgamma_q = i_qtextcv^textref - i_qtextcv tag1d \n dotphi_d = omega_textad(v_d - phi_d) tag1e \n dotphi_q = omega_textad(v_q - phi_q) tag1f\nendalign*","category":"page"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"with","category":"page"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"beginalign\n v_dtextvi^textref = v_textolc^textref - r_v i_d + omega_textolc l_v i_q tag1g \n v_qtextvi^textref = - r_v i_q - omega_textolc l_v i_d tag1h \n i_dtextcv^textref = k_pvleft(v_dtextvi^textref - v_dright) + k_iv xi_d - c_f omega_textolc v_q + k_textffii_d tag1i \n i_qtextcv^textref = k_pvleft(v_qtextvi^textref - v_qright) + k_iv xi_q + c_f omega_textolc v_d + k_textffii_q tag1j \n v_d^textref-signal = k_pc left(i_dtextcv^textref - i_dtextcvright) + k_ic gamma_d - omega_textolc l_f i_qtextcv + k_textffvv_d - k_textad(v_d - phi_d) tag1k \n v_q^textref-signal = k_pc left(i_qtextcv^textref - i_qtextcvright) + k_ic gamma_q + omega_textolc l_f i_dtextcv + k_textffvv_q - k_textad(v_q - phi_q) tag1l\nendalign","category":"page"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"In here the transformation to the dq reference frame is using the outer-loop reference angle as:","category":"page"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"beginalign*\nv_d + jv_q = (v_r + jv_i)e^-jdeltatheta_olc \ni_d + ji_q = (i_r + ji_i)e^-jdeltatheta_olc\nendalign*","category":"page"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"that again v_r + jv_i could be in the capacitor or the last branch of the filter (i.e. the point of common coupling). For LCL filters it is considered in the capacitor. In the case of the converter, the transformation is directly","category":"page"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"beginalign*\ni_dtextcv + ji_qtextcv = (i_rtextcv + ji_itextcv)e^-jdeltatheta_olc\nendalign*","category":"page"},{"location":"component_models/inner_control/#Current-Mode-Controller-[CurrentModeControl]","page":"Inner Control","title":"Current Mode Controller [CurrentModeControl]","text":"","category":"section"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"The following model receives the current reference (in dq axis) from an outer loop controller that outputs current references such as the PI outer controller used for grid following inverters. A PI current controller is used to generate the voltage reference signal for the converters.","category":"page"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"beginalign*\n dotgamma_d = i_dtextcv^textref - i_dtextcv tag2a \n dotgamma_q = i_qtextcv^textref - i_qtextcv tag2b \nendalign*","category":"page"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"with","category":"page"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"beginalign\n v_d^textref-signal = k_pc left(i_dtextcv^textref - i_dtextcvright) + k_ic gamma_d - omega_textolc l_f i_qtextcv + k_textffvv_d tag2b \n v_q^textref-signal = k_pc left(i_qtextcv^textref - i_qtextcvright) + k_ic gamma_q + omega_textolc l_f i_dtextcv + k_textffvv_q tag2c\nendalign","category":"page"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"The transformation for the converter current is computed as:","category":"page"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"beginalign*\ni_dtextcv + ji_qtextcv = (i_rtextcv + ji_itextcv)e^-jtheta_olc\nendalign*","category":"page"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"In here theta_olc is the outer-loop angle. In the case of grid-following models, this angle is equal to the angle provided from the PLL.","category":"page"},{"location":"component_models/inner_control/#Generic-Renewable-Inner-Controller-Type-B-[RECurrentControlB]","page":"Inner Control","title":"Generic Renewable Inner Controller Type B [RECurrentControlB]","text":"","category":"section"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"This models the inner control part of the REECB model. The equations (without limiters) when Q_Flag = 1 are:","category":"page"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"beginalign\n T_rv dotV_texttflt = V_t - dotV_texttflt tag3a \n dotxi_icv = V_textocqcmd tag3b\nendalign","category":"page"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"on which V_textocqcmd comes from the Outer Controller and the output current commands I_textpcmd and I_textqcmd are computed as:","category":"page"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"beginalign\n I_textpcmd = I_textoc pcmd tag3c \n I_textqcmd = I_icv + I_textqinj tag3d \n I_icv = K_vp V_textocqcmd + K_vi xi_icv tag3e \n I_textqinj = K_qv (V_textref0 - V_texttflt) tag3f\nendalign","category":"page"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"The equations when Q_Flag = 0 are:","category":"page"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"beginalign\n T_rv dotV_texttflt = V_t - dotV_texttflt tag3g \n T_iq dotI_icv = I_textocqcmd - I_icv tag3h\nendalign","category":"page"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"on which I_textocqcmd comes from the Outer Controller and the output current commands I_textpcmd and I_textqcmd are computed as:","category":"page"},{"location":"component_models/inner_control/","page":"Inner Control","title":"Inner Control","text":"beginalign\n I_textpcmd = I_textoc pcmd tag3i \n I_textqcmd = I_icv + I_textqinj tag3j \n I_textqinj = K_qv (V_textref0 - V_texttflt) tag3k\nendalign","category":"page"},{"location":"quick_start_guide/#Quick-Start-Guide","page":"Quick Start Guide","title":"Quick Start Guide","text":"","category":"section"},{"location":"quick_start_guide/","page":"Quick Start Guide","title":"Quick Start Guide","text":"The data for these tutorials is provided in PowerSystemCaseBuilder. If you want to build your own case, take a look at the tutorial Creating and Handling Data for Dynamic Simulations","category":"page"},{"location":"quick_start_guide/","page":"Quick Start Guide","title":"Quick Start Guide","text":"For more details about loading data and adding more dynamic components check the Creating a System with Dynamic devices section of the documentation in PowerSystems.jl.","category":"page"},{"location":"quick_start_guide/","page":"Quick Start Guide","title":"Quick Start Guide","text":"For a detailed tutorial about this case visit One Machine against Infinite Bus (OMIB) Simulation","category":"page"},{"location":"quick_start_guide/#Loading-data","page":"Quick Start Guide","title":"Loading data","text":"","category":"section"},{"location":"quick_start_guide/","page":"Quick Start Guide","title":"Quick Start Guide","text":"Data can be loaded from a pss/e raw file and a pss/e dyr file.","category":"page"},{"location":"quick_start_guide/","page":"Quick Start Guide","title":"Quick Start Guide","text":"using PowerSystems\nusing PowerSimulationsDynamics\nusing PowerSystemCaseBuilder\nusing Sundials\nusing Plots\n\nomib_sys = build_system(PSIDSystems, \"OMIB System\")","category":"page"},{"location":"quick_start_guide/#Define-the-Simulation","page":"Quick Start Guide","title":"Define the Simulation","text":"","category":"section"},{"location":"quick_start_guide/","page":"Quick Start Guide","title":"Quick Start Guide","text":"time_span = (0.0, 30.0)\nperturbation_trip = BranchTrip(1.0, Line, \"BUS 1-BUS 2-i_1\")\nsim = Simulation!(ResidualModel, omib_sys, pwd(), time_span, perturbation_trip)","category":"page"},{"location":"quick_start_guide/#Explore-initial-conditions-for-the-simulation","page":"Quick Start Guide","title":"Explore initial conditions for the simulation","text":"","category":"section"},{"location":"quick_start_guide/","page":"Quick Start Guide","title":"Quick Start Guide","text":"x0_init = read_initial_conditions(sim)","category":"page"},{"location":"quick_start_guide/","page":"Quick Start Guide","title":"Quick Start Guide","text":"show_states_initial_value(sim)","category":"page"},{"location":"quick_start_guide/#Obtain-small-signal-results-for-initial-conditions","page":"Quick Start Guide","title":"Obtain small signal results for initial conditions","text":"","category":"section"},{"location":"quick_start_guide/","page":"Quick Start Guide","title":"Quick Start Guide","text":"Show eigenvalues for operating point","category":"page"},{"location":"quick_start_guide/","page":"Quick Start Guide","title":"Quick Start Guide","text":" small_sig = small_signal_analysis(sim)\n summary_eigenvalues(small_sig)","category":"page"},{"location":"quick_start_guide/#Execute-the-simulation","page":"Quick Start Guide","title":"Execute the simulation","text":"","category":"section"},{"location":"quick_start_guide/","page":"Quick Start Guide","title":"Quick Start Guide","text":" execute!(sim, IDA(), dtmax = 0.02, saveat = 0.02, enable_progress_bar = false)","category":"page"},{"location":"quick_start_guide/#Make-a-plot-of-the-results","page":"Quick Start Guide","title":"Make a plot of the results","text":"","category":"section"},{"location":"quick_start_guide/","page":"Quick Start Guide","title":"Quick Start Guide","text":"results = read_results(sim)\nangle = get_state_series(results, (\"generator-102-1\", :δ));\nplot(angle, xlabel = \"time\", ylabel = \"rotor angle [rad]\", label = \"gen-102-1\")","category":"page"},{"location":"quick_start_guide/","page":"Quick Start Guide","title":"Quick Start Guide","text":"(Image: plot)","category":"page"},{"location":"quick_start_guide/","page":"Quick Start Guide","title":"Quick Start Guide","text":"If you miss PSS/e's plotting aesthetics and want something that resembles that, you can use UnicodePlots.","category":"page"},{"location":"quick_start_guide/","page":"Quick Start Guide","title":"Quick Start Guide","text":"using UnicodePlots\nunicodeplots()\nplot(angle, xlabel = \"time\", ylabel = \"rotor angle [rad]\", label = \"gen-102-1\");","category":"page"},{"location":"quick_start_guide/","page":"Quick Start Guide","title":"Quick Start Guide","text":"(Image: plot)","category":"page"},{"location":"component_models/filters/#Filters","page":"Filter","title":"Filters","text":"","category":"section"},{"location":"component_models/filters/#LCL-Filter-[LCLFilter]","page":"Filter","title":"LCL Filter [LCLFilter]","text":"","category":"section"},{"location":"component_models/filters/","page":"Filter","title":"Filter","text":"A standard LCL filter is proposed to connect the output of the converter to the grid. In this case, v_r and v_i are voltages in the capacitor, while v_r^textgrid and v_i^textgrid represent the voltage at the bus. The L filter after the capacitor can also include a step-up transformer to increase the voltage, that is model as an extra impedance.","category":"page"},{"location":"component_models/filters/","page":"Filter","title":"Filter","text":"beginalign\n doti_rtextcv = fracOmega_bl_fleft( v_r^textcv - v_r - r_f i_rtextcv + omega_textgrid l_f i_itextcv right) tag1a \n doti_itextcv = fracOmega_bl_fleft( v_i^textcv - v_i - r_f i_itextcv - omega_textgrid l_f i_rtextcv right) tag1b \n dotv_r = fracOmega_bc_fleft( i_r^textcv - i_r + omega_textgrid c_f v_i right) tag1c \n dotv_i = fracOmega_bc_fleft( i_i^textcv - i_i - omega_textgrid c_f v_r right) tag1d \n doti_r = fracOmega_bl_gleft( v_r - v_r^textgrid - r_g i_r + omega_textgrid l_g i_i right) tag1e \n doti_i = fracOmega_bl_gleft( v_i - v_i^textgrid - r_g i_i - omega_textgrid l_g i_r right) tag1f\nendalign","category":"page"},{"location":"component_models/filters/","page":"Filter","title":"Filter","text":"on which","category":"page"},{"location":"component_models/filters/","page":"Filter","title":"Filter","text":"beginalign*\nv_r^textcv + jv_i^textcv = (v_d^textcv + jv_q^textcv)e^jdeltatheta_olc\nendalign*","category":"page"},{"location":"component_models/filters/","page":"Filter","title":"Filter","text":"that comes from the converter model.","category":"page"},{"location":"component_models/filters/#RL-Filter-[RLFilter]","page":"Filter","title":"RL Filter [RLFilter]","text":"","category":"section"},{"location":"component_models/filters/","page":"Filter","title":"Filter","text":"The algebraic RL filter is used to connect the output of the converter through a RL series filter using algebraic phasor equations. The equations for the output current are:","category":"page"},{"location":"component_models/filters/","page":"Filter","title":"Filter","text":"beginalign\n i_r + ji_i = frac(v_r^textcv + j v_i^textcv) - (v_r^textgrid + jv_i^textgrid)r_f + jl_f tag2a\nendalign","category":"page"},{"location":"component_models/filters/","page":"Filter","title":"Filter","text":"on which v_r^textcv + jv_i^textcv comes from the converter model.","category":"page"},{"location":"tutorials/tutorial_activeload/#Tutorial-Active-Constant-Power-Load-model","page":"Active Load Model","title":"Tutorial Active Constant Power Load model","text":"","category":"section"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"Originally Contributed by: Rodrigo Henriquez-Auba","category":"page"},{"location":"tutorials/tutorial_activeload/#Introduction","page":"Active Load Model","title":"Introduction","text":"","category":"section"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"This tutorial will introduce you to the functionality of PowerSimulationsDynamics and PowerSystems to explore active load components and a small-signal analysis.","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"This tutorial presents a simulation of a two-bus system with a GFM inverter at bus 1, and a load on bus 2. We will change the model from a constant power load model, to a constant impedance model and then to a 12-state active constant power load model.","category":"page"},{"location":"tutorials/tutorial_activeload/#Dependencies","page":"Active Load Model","title":"Dependencies","text":"","category":"section"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"using PowerSimulationsDynamics;\nPSID = PowerSimulationsDynamics\nusing PowerSystemCaseBuilder\nusing PowerSystems\nconst PSY = PowerSystems;","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"note: Note\nPowerSystemCaseBuilder.jl is a helper library that makes it easier to reproduce examples in the documentation and tutorials. Normally you would pass your local files to create the system data instead of calling the function build_system. For more details visit PowerSystemCaseBuilder Documentation","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"PowerSystems (abbreviated with PSY) is used to properly define the data structure and establish an equilibrium point initial condition with a power flow routine using PowerFlows.","category":"page"},{"location":"tutorials/tutorial_activeload/#Load-the-system","page":"Active Load Model","title":"Load the system","text":"","category":"section"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"We load the system using PowerSystemCaseBuilder.jl. This system has an inverter located at bus 1.","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"sys = build_system(PSIDSystems, \"2 Bus Load Tutorial Droop\")","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"first(get_components(DynamicInverter, sys))","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"The load is an exponential load modeled as a constant power load since the coefficients are set to zero.","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"first(get_components(PSY.ExponentialLoad, sys))","category":"page"},{"location":"tutorials/tutorial_activeload/#Run-a-small-signal-analysis","page":"Active Load Model","title":"Run a small-signal analysis","text":"","category":"section"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"We set up the Simulation. Since the droop model does not have a frequency state, we use a constant frequency reference frame for the network.","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"sim = Simulation(ResidualModel,\n sys,\n mktempdir(),\n (0.0, 1.0),\n frequency_reference = ConstantFrequency())","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"The following provides a summary of eigenvalues for this droop system with a constant power load:","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"sm = small_signal_analysis(sim);\ndf = summary_eigenvalues(sm);\nshow(df, allrows = true, allcols = true)","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"In this inverter model, the filter is modeled using differential equations, and as described in the literature, interfacing a RL filter against an algebraic constant power load usually results in unstable behavior as observed with the positive real part eigenvalue.","category":"page"},{"location":"tutorials/tutorial_activeload/#Change-to-a-constant-impedance-load-model","page":"Active Load Model","title":"Change to a constant impedance load model","text":"","category":"section"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"Since the load is an exponential load model we can change the exponent coefficients to 2.0 to behave as a constant impedance model:","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"# Update load coefficients to 2.0\nload = first(get_components(PSY.ExponentialLoad, sys));\nPSY.set_α!(load, 2.0);\nPSY.set_β!(load, 2.0);","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"We then re-run the small-signal analysis:","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"sim = Simulation(ResidualModel,\n sys,\n mktempdir(),\n (0.0, 1.0),\n frequency_reference = ConstantFrequency())","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"sm = small_signal_analysis(sim);\ndf = summary_eigenvalues(sm);\nshow(df, allrows = true, allcols = true)","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"Observe that now the system is small-signal stable (since there is only one device the angle of the inverter is used as a reference, and hence is zero).","category":"page"},{"location":"tutorials/tutorial_activeload/#Adding-a-dynamic-active-load-model","page":"Active Load Model","title":"Adding a dynamic active load model","text":"","category":"section"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"To consider a dynamic model in the load it is only required to attach a dynamic component to the static load model. When a dynamic load model is attached, the active and reactive power of the static model are used to define reference parameters to ensure that the dynamic load model matches the static load output power.","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"Note that when a dynamic model is attached to a static model, the static model does not participate in the dynamic system equations, i.e. the only model interfacing to the network equations is the dynamic model and not the static model (the exponential load).","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"We define a function to create a active load model with the specific parameters:","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"# Parameters taken from active load model from N. Bottrell Masters\n# Thesis \"Small-Signal Analysis of Active Loads and Large-signal Analysis\n# of Faults in Inverter Interfaced Microgrid Applications\", 2014.\n\n# The parameters are then per-unitized to be scalable to represent an aggregation\n# of multiple active loads\n\n# Base AC Voltage: Vb = 380 V\n# Base Power (AC and DC): Pb = 10000 VA\n# Base AC Current: Ib = 10000 / 380 = 26.32 A\n# Base AC Impedance: Zb = 380 / 26.32 = 14.44 Ω\n# Base AC Inductance: Lb = Zb / Ωb = 14.44 / 377 = 0.3831 H\n# Base AC Capacitance: Cb = 1 / (Zb * Ωb) = 0.000183697 F\n# Base DC Voltage: Vb_dc = (√8/√3) Vb = 620.54 V\n# Base DC Current: Ib_dc = Pb / V_dc = 10000/620.54 = 16.12 A\n# Base DC Impedance: Zb_dc = Vb_dc / Ib_dc = 38.50 Ω\n# Base DC Capacitance: Cb_dc = 1 / (Zb_dc * Ωb) = 6.8886315e-5 F\n\nΩb = 2*pi*60;\nVb = 380;\nPb = 10000;\nIb = Pb / Vb;\nZb = Vb / Ib;\nLb = Zb / Ωb;\nCb = 1 / (Zb * Ωb);\nVb_dc = sqrt(8)/sqrt(3) * Vb;\nIb_dc = Pb / Vb_dc;\nZb_dc = Vb_dc / Ib_dc;\nCb_dc = 1/(Zb_dc * Ωb);\n\nfunction active_cpl(load)\n return PSY.ActiveConstantPowerLoad(\n name = get_name(load),\n r_load = 70.0 / Zb_dc,\n c_dc = 2040e-6 / Cb_dc,\n rf = 0.1 / Zb,\n lf = 2.3e-3 / Lb,\n cf = 8.8e-6 / Cb,\n rg = 0.03 / Zb,\n lg = 0.93e-3 / Lb,\n kp_pll = 0.4,\n ki_pll = 4.69,\n kpv = 0.5 * (Vb_dc / Ib_dc),\n kiv = 150.0 * (Vb_dc / Ib_dc),\n kpc = 15.0 * (Ib / Vb),\n kic = 30000.0 * (Ib / Vb),\n base_power = 100.0,\n )\nend","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"We then attach the model to the system:","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"load = first(get_components(PSY.ExponentialLoad, sys));\ndyn_load = active_cpl(load)\nadd_component!(sys, dyn_load, load)","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"Finally, we set up the simulation:","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"sim = Simulation(ResidualModel,\n sys,\n mktempdir(),\n (0.0, 1.0),\n frequency_reference = ConstantFrequency())","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"sm = small_signal_analysis(sim);\ndf = summary_eigenvalues(sm);\nshow(df, allrows = true, allcols = true)","category":"page"},{"location":"tutorials/tutorial_activeload/","page":"Active Load Model","title":"Active Load Model","text":"Observe the new states of the active load model and that the system is small-signal stable.","category":"page"},{"location":"component_models/turbine_gov/#Prime-Movers-and-Turbine-Governors-(TG)","page":"Turbine and Governor","title":"Prime Movers and Turbine Governors (TG)","text":"","category":"section"},{"location":"component_models/turbine_gov/","page":"Turbine and Governor","title":"Turbine and Governor","text":"This section describes how mechanical power is modified to provide primary frequency control with synchronous generators. It is assumed that tau_textref = P_textref since they are decided at nominal frequency omega = 1.","category":"page"},{"location":"component_models/turbine_gov/#Fixed-TG-[TGFixed]","page":"Turbine and Governor","title":"Fixed TG [TGFixed]","text":"","category":"section"},{"location":"component_models/turbine_gov/","page":"Turbine and Governor","title":"Turbine and Governor","text":"This a simple model that set the mechanical torque to be equal to a proportion of the desired reference tau_m = eta P_textref. To set the mechanical torque to be equal to the desired power, the value of eta is set to 1.","category":"page"},{"location":"component_models/turbine_gov/#TG-Type-I-[TGTypeI]","page":"Turbine and Governor","title":"TG Type I [TGTypeI]","text":"","category":"section"},{"location":"component_models/turbine_gov/","page":"Turbine and Governor","title":"Turbine and Governor","text":"This turbine governor is described by a droop controller and a low-pass filter to model the governor and two lead-lag blocks to model the servo and reheat of the turbine governor.","category":"page"},{"location":"component_models/turbine_gov/","page":"Turbine and Governor","title":"Turbine and Governor","text":"beginalign\ndotx_g1 = frac1T_s(p_textin - x_g1) tag1a \ndotx_g2 = frac1T_c left left(1- fract_3T_cright)x_g1 - x_g2 right tag1b \ndotx_g3 = frac1T_5 leftleft(1 - fracT_4T_5right)left(x_g2 + fracT_3T_cx_g1right) - x_g3 right tag1c \ntau_m = x_g3 + fracT_4T_5left(x_g2 + fracT_3T_cx_g1right) tag1d\nendalign","category":"page"},{"location":"component_models/turbine_gov/","page":"Turbine and Governor","title":"Turbine and Governor","text":"with","category":"page"},{"location":"component_models/turbine_gov/","page":"Turbine and Governor","title":"Turbine and Governor","text":"beginalign*\np_textin = P_textref + frac1R(omega_s - 10)\nendalign*","category":"page"},{"location":"component_models/turbine_gov/#TG-Type-II-[TGTypeII]","page":"Turbine and Governor","title":"TG Type II [TGTypeII]","text":"","category":"section"},{"location":"component_models/turbine_gov/","page":"Turbine and Governor","title":"Turbine and Governor","text":"This turbine governor is a simplified model of the Type I.","category":"page"},{"location":"component_models/turbine_gov/","page":"Turbine and Governor","title":"Turbine and Governor","text":"beginalign\ndotx_g = frac1T_2leftfrac1Rleft(1 - fracT_1T_2right) (omega_s - omega) - x_gright tag2a \ntau_m = P_textref + frac1RfracT_1T_2(omega_s - omega) tag2b\nendalign","category":"page"},{"location":"component_models/turbine_gov/#TGOV1-[SteamTurbineGov1]","page":"Turbine and Governor","title":"TGOV1 [SteamTurbineGov1]","text":"","category":"section"},{"location":"component_models/turbine_gov/","page":"Turbine and Governor","title":"Turbine and Governor","text":"This represents a classical Steam-Turbine Governor, known as TGOV1.","category":"page"},{"location":"component_models/turbine_gov/","page":"Turbine and Governor","title":"Turbine and Governor","text":"beginalign\ndotx_g1 = frac1T_1 (textref_in - x_g1) tag3a \ndotx_g2 = frac1T_3 left(x_g1^textsat left(1 - fracT_2T_3right) - x_g2right) tag3b\nendalign","category":"page"},{"location":"component_models/turbine_gov/","page":"Turbine and Governor","title":"Turbine and Governor","text":"with","category":"page"},{"location":"component_models/turbine_gov/","page":"Turbine and Governor","title":"Turbine and Governor","text":"beginalign\ntextref_in = frac1R (P_ref - (omega - 10)) tag3c \nx_g1^textsat = left beginarraycl\n x_g1 text if V_min le x_g1 le V_max\n V_max text if x_g1 V_max \n V_min text if x_g1 V_min\n endarray right tag3d \ntau_m = x_g2 + fracT_2T_3 x_g1 - D_T(omega - 10) tag3e\nendalign","category":"page"},{"location":"component_models/turbine_gov/#GAST-[GasTG]","page":"Turbine and Governor","title":"GAST [GasTG]","text":"","category":"section"},{"location":"component_models/turbine_gov/","page":"Turbine and Governor","title":"Turbine and Governor","text":"This turbine governor represents the Gas Turbine representation, known as GAST.","category":"page"},{"location":"component_models/turbine_gov/","page":"Turbine and Governor","title":"Turbine and Governor","text":"beginalign\ndotx_g1 = frac1T_1 (x_in - x_g1) tag4a \ndotx_g2 = frac1T_2 left(x_g1^textsat - x_g2right) tag4b \ndotx_g3 = frac1T_3 (x_g2 - x_g3) tag4c\nendalign","category":"page"},{"location":"component_models/turbine_gov/","page":"Turbine and Governor","title":"Turbine and Governor","text":"with","category":"page"},{"location":"component_models/turbine_gov/","page":"Turbine and Governor","title":"Turbine and Governor","text":"beginalign\nx_in = minleftP_ref - frac1R(omega - 10) A_T + K_T (A_T - x_g3) right tag4d \nx_g1^textsat = left beginarraycl\n x_g1 text if V_min le x_g1 le V_max\n V_max text if x_g1 V_max \n V_min text if x_g1 V_min\n endarray right tag4e \ntau_m = x_g2 - D_T(omega - 10) tag4f\nendalign","category":"page"},{"location":"component_models/turbine_gov/#HYGOV-[HydroTurbineGov]","page":"Turbine and Governor","title":"HYGOV [HydroTurbineGov]","text":"","category":"section"},{"location":"component_models/turbine_gov/","page":"Turbine and Governor","title":"Turbine and Governor","text":"This represents a classical hydro governor, known as HYGOV.","category":"page"},{"location":"component_models/turbine_gov/","page":"Turbine and Governor","title":"Turbine and Governor","text":"beginalign\nT_fdotx_g1 = P_in - x_g1 tag5a \ndotx_g2 = x_g1 tag5b\nT_g dotx_g3 = c - x_g3 tag5c\ndotx_g4 = frac1 - hT_w tag5d\nendalign","category":"page"},{"location":"component_models/turbine_gov/","page":"Turbine and Governor","title":"Turbine and Governor","text":"with","category":"page"},{"location":"component_models/turbine_gov/","page":"Turbine and Governor","title":"Turbine and Governor","text":"beginalign\nP_in = P_ref - Delta omega - R x_g2 tag5e \nc = fracx_g1r + fracx_g2rT_r tag5f \nh = left(fracx_g4x_g3right)^2 tag5g\ntau_m = hcdot A_t(x_g4 - q_NL) - D_turb Deltaomega cdot x_g3 tag5h\nendalign","category":"page"},{"location":"small/#Small-Signal-Analysis","page":"Small Signal","title":"Small Signal Analysis","text":"","category":"section"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"Here we discuss the method used to do a small signal analysis on the DAE system defined in PowerSimulationsDynamics.jl. The package defines algebraic variables for both real and imaginary voltages on all buses (except if they have a dynamic line connected, on which the voltage of those buses are treated as differential variables). In addition, each dynamic device can add differential variables (or states) that are concatenated to construct the system of differential algebraic equations.","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"Note: The validation of small signal results is still work in progress due to the differences in the way that different software packages perform the calculations.","category":"page"},{"location":"small/#Automatic-Differentiation","page":"Small Signal","title":"Automatic Differentiation","text":"","category":"section"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"Once an equilibrium point is found, the complete jacobian of the non-linear system can be obtained using automatic differentiation in Julia. In particular, the package ForwardDiff.jl is used to obtain the jacobian of the non-linear algebraic system of equations. PowerSimulationsDynamics.jl handles the resulting jacobian and reports the reduced jacobian and the corresponding eigenvalues and eigenvectors.","category":"page"},{"location":"small/#Jacobian-Reduction","page":"Small Signal","title":"Jacobian Reduction","text":"","category":"section"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"We define y as the vector of algebraic variables, x as the vector of differential variables (states) and p the parameters of the system, we can define g(yxp) as the vector of algebraic equations and f(yxp) as the vector of differential equations. With that, the non-linear differential algebraic system of equations can be written as:","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"beginalign\nleftbeginarrayc\n 0 \n dotx\n endarrayright = leftbeginarrayc\n g(yxp) \n f(yxp) endarrayright\nendalign","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"For small signal analysis, we are interested in the stability around an equilbrium point y_eqx_eq that satisfies dotx = 0 or equivalently f(y_eqx_eqp) = 0, while obviously satisfying g(y_eq x_eq p) = 0. To do that we use a first order approximation:","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"beginalign\nleftbeginarrayc\n 0 \n Deltadotx\n endarrayright = underbraceleftbeginarray\n g(y_eqx_eqp) \n f(y_eqx_eqp) endarrayright_ = 0\n + Jy_eq x_eq p leftbeginarrayc\n Delta y \n Delta x\n endarrayright\n endalign","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"The first to note is that the jacobian matrix can be splitted in 4 blocks depending on the specific variables we are taking the partial derivatives:","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"beginalign\nJy_eq x_eq p =\nleftbeginarraycc\n g_y g_x \n f_y f_x \n endarrayright\nendalign","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"For small signal analyses, we are interested in the stability of the differential states, while still considering that those need to evolve in the manifold defined by the linearized algebraic equations. Assuming that g_y is not singular (see chapter 7 of Federico Milano's book: Power System Modelling and Scripting or the following paper) we can eliminate the algebraic variables to obtain the reduced jacobian:","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"beginalign\nJ_textred = f_x - f_y g_y^-1 g_x\nendalign","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"that defines our reduced system for the differential variables","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"beginalign\nDelta dotx = J_textred Delta x\nendalign","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"on which we can compute its eigenvalues to analyze local stability.","category":"page"},{"location":"small/#Accessing-the-Jacobian-function","page":"Small Signal","title":"Accessing the Jacobian function","text":"","category":"section"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"You can retrieve the Jacobian function for a simulation using the get_jacobian function as follows:","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"jacobian = function get_jacobian(ResidualModel, system)","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"optionally you can pass the number of iterations to check for sparsity as follows:","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"jacobian = function get_jacobian(ResidualModel, system, 0)","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"if you specify 0, the jacobian function will use a full matrix.","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"The return of get_jacobian is known as a functor in Julia and can be used to make evaluations. Currently, any function can be evaluated with the following inputs:","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"jacobian(x)","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"This version of the function is type unstable should only be used for non-critial ops. It works to get the eigenvalues given an operating point x","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"jacobian(JM, x)","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"This version evaluates in place the value of the jacobian for an operating point x and writes to the matrix JM","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"jacobian(JM, x, p, t)","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"This version complied with the requirements to be used in DiffEq for ODE solvers. p and t aren't used they just mean to match the interfaces. See DiffEqDocs","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"jacobian(JM, dx, x, p, gamma, t)","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"This version complied with the requirements to be used in DiffEq for DAE solvers. p and t aren't used they just mean to match the interfaces. It assumes that the jacobian has the form:","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"beginalign\n JM = gamma * I + J(x)\nendalign","category":"page"},{"location":"small/","page":"Small Signal","title":"Small Signal","text":"See DiffEqDocs for additional details.","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"Here we discuss the models used to describe load modeling in PowerSimulationsDynamics.jl. In a similar fashion of other devices, loads will withdraw power (i.e. current) from the current-injection balances at the nodal level. Based on the specified parameters and model chosen, the equations for computing such withdrawal will change.","category":"page"},{"location":"component_models/loads/#Static-Loads-(or-Algebraic-Loads)","page":"Load Models","title":"Static Loads (or Algebraic Loads)","text":"","category":"section"},{"location":"component_models/loads/#ZIP-Exponential-Load-Model","page":"Load Models","title":"ZIP + Exponential Load Model","text":"","category":"section"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"PowerSimulationsDynamics.jl uses all the static ZIP and exponential loads at each bus to obtain a single structure that creates an aggregate ZIP load model and a collection of all exponential loads.","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"The ZIP load model given by:","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"beginalign\nP_textzip = P_textpower + P_textcurrent cdot fracVV_0 + P_textimpedance cdot left(fracVV_0right)^2 tag1a\nQ_textzip = Q_textpower + Q_textcurrent cdot fracVV_0 + Q_textimpedance cdot left(fracVV_0right)^2tag1b\nendalign","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"with V = sqrtV_r^2 + V_i^2 and V_0 the voltage magnitude from the power flow solution.","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"The current taken for the load is computed as:","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"beginalign\nI_textzip = frac(P_textzip + j Q_textzip)^*(V_r + j V_i)^*tag1c \nI_textzip = fracP_textzip - j Q_textzipV_r - j V_itag1d\nendalign","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"For constant impedance load, the current obtained is:","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"beginalign\nI_textre^z = frac1V_0^2 cdot (V_r cdot P_textimpedance + V_i cdot Q_textimpedance)tag1e \nI_textim^z = frac1V_0^2 cdot (V_i cdot P_textimpedance - V_r cdot Q_textimpedance)tag1f\nendalign","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"For constant current load, the current obtained is:","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"beginalign\nI_textre^i = frac1V_0 cdot fracV_r * P_textcurrent + V_i * Q_textcurrentV tag1g\nI_textim^i = frac1V_0 cdot fracV_i * P_textcurrent - V_r * Q_textcurrentV tag1h\nendalign","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"For constant power load, the current obtained is:","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"beginalign\nI_textre^p = fracV_r cdot P_textpower + V_i cdot Q_textpowerV^2 tag1i \nI_textim^p = fracV_i cdot P_textpower - V_r cdot Q_textpowerV^2 tag1j\nendalign","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"Then the total current withdrawed from the ZIP load model is simply","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"beginalign\nI_textzip^textre = I_textre^z + I_textre^i + I_textre^p tag1k \nI_textzip^textim = I_textim^z + I_textim^i + I_textim^p tag1l\nendalign","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"On the case of Exponential Loads, the model is given by:","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"beginalign\nP_textexp = P_0 cdot left(fracVV_0right)^alpha tag1m\nQ_textexp = Q_0 cdot left(fracVV_0right)^beta tag1n\nendalign","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"The current taken for the load is computed as:","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"beginalign\nI_textexp = frac(P_textexp + j Q_textexp)^*(V_r + j V_i)^* tag1o \nI_textexp = fracP_textexp - j Q_textexpV_r - j V_i tag1p\nendalign","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"that results:","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"beginalign\nI_textexp^textre = V_r cdot P_0 cdot fracV^alpha - 2V_0^alpha + V_i cdot Q_0 cdot fracV^beta - 2V_0^beta tag1q\nI_textexp^textim = V_i cdot P_0 cdot fracV^alpha - 2V_0^alpha - V_r cdot Q_0 cdot fracV^beta - 2V_0^beta tag1r\nendalign","category":"page"},{"location":"component_models/loads/#Dynamic-loads","page":"Load Models","title":"Dynamic loads","text":"","category":"section"},{"location":"component_models/loads/#th-order-Single-Cage-Induction-Machine-[SingleCageInductionMachine]","page":"Load Models","title":"5th-order Single Cage Induction Machine [SingleCageInductionMachine]","text":"","category":"section"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"The following model is used to model a 5th-order induction machine with a quadratic relationship speed-torque. Refer to \"Analysis of Electric Machinery and Drive Systems\" by Paul Krause, Oleg Wasynczuk and Scott Sudhoff for the equations derivation","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"beginalign\ndotpsi_qs = Omega_b (v_qs - omega_textsys psi_ds - R_s i_qs) tag2a\ndotpsi_ds = Omega_b (v_ds + omega_textsys psi_qs - R_s i_ds) tag2b \ndotpsi_qr = Omega_b left(v_qr - (omega_textsys - omega_r) psi_dr + fracR_rX_lr (psi_mq - psi_qr)right) tag2c\ndotpsi_dr = Omega_b left(v_dr + (omega_textsys - omega_r) psi_qr + fracR_rX_lr (psi_md - psi_dr)right) tag2d\ndotomega_r = frac12H (tau_e - tau_m0(A omega_r^2 + B omega_r + C)) tag2e\nendalign","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"where:","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"beginalign*\nX_ad = X_aq = left(frac1X_m + frac1X_ls + frac1X_lrright)^-1 \nv_qs = V_i^textbus \nv_ds = V_r^textbus \nv_qr = v_dr = 0 \npsi_mq = X_aq left(fracpsi_qsX_ls+ fracpsi_qrX_lrright) \npsi_md = X_ad left(fracpsi_dsX_ls+ fracpsi_drX_lrright) \ni_qs = frac1X_ls (psi_qs - psi_mq) \ni_ds = frac1X_ls (psi_ds - psi_md) \ntau_e = psi_ds i_qs - psi_qs i_ds \nendalign*","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"Finally, the withdrawed current from the bus is:","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"beginalign*\nI_r = left(fracS_textmotorS_textbaseright) (i_ds - v_qs B_sh) \nI_i = left(fracS_textmotorS_textbaseright) (i_qs + v_ds B_sh) \nendalign*","category":"page"},{"location":"component_models/loads/#rd-order-Single-Cage-Induction-Machine-[SimplifiedSingleCageInductionMachine]","page":"Load Models","title":"3rd-order Single Cage Induction Machine [SimplifiedSingleCageInductionMachine]","text":"","category":"section"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"The following models approximates the stator fluxes dynamics of the 5th-order model by using algebraic equations.","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"beginalign\ndotpsi_qr = Omega_b left(v_qr - (omega_textsys - omega_r) psi_dr - R_r i_qr right) tag3a \ndotpsi_dr = Omega_b left(v_dr + (omega_textsys - omega_r) psi_qr - R_r i_drright) tag3b \ndotomega_r = frac12H (tau_e - tau_m0(A omega_r^2 + B omega_r + C)) tag3c\nendalign","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"where","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"beginalign*\nv_qs = V_i^textbus \nv_ds = V_r^textbus \nv_qr = v_dr = 0 \ni_qs = frac1R_s^2 + omega_textsys^2 X_p^2 left( (R_s v_qs - omega_textsys X_p v_ds) - left(R_s omega_textsys fracX_mX_rr psi_dr + omega_textsys^2 X_p fracX_mX_rr psi_qr right) right) \ni_ds = frac1R_s^2 + omega_textsys^2 X_p^2 left( (R_s v_ds + omega_textsys X_p v_qs) - left(-R_s omega_textsys fracX_mX_rr psi_qr + omega_textsys^2 X_p fracX_mX_rr psi_dr right) right) \ni_qr = frac1X_rr (psi_qr - X_m i_qs) \ni_dr = frac1X_rr (psi_dr - X_m i_ds) \ntau_e = psi_qr i_dr - psi_dr i_qr \nendalign*","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"Finally, the withdrawed current from the bus is:","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"beginalign*\nI_r = left(fracS_textmotorS_textbaseright) (i_ds - v_qs B_sh) \nI_i = left(fracS_textmotorS_textbaseright) (i_qs + v_ds B_sh) \nendalign*","category":"page"},{"location":"component_models/loads/#Active-Constant-Power-Load-Model","page":"Load Models","title":"Active Constant Power Load Model","text":"","category":"section"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"The following 12-state model Active Load model that measures the AC side using a Phase-Lock-Loop (PLL) and regulates a DC voltage to supply a resistor r_L. This model induces a constant power load-like behavior as it tries to maintain a fixed DC voltage to supply P = v_textDC^2 r_L. The model is based on the following reference. ","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"The complete model is given by:","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"beginalign\n dottheta = Omega_b (omega_textpll - omega_s) tag4a \n dotepsilon = v_texto^q tag4b\n omega_textpll = omega^star + k^p_textpll v_texto^q + k_textpll^i epsilon tag4c\n dotzeta = v_textDC^star - v_textDC tag4d \n i_textcv^dstar = k_textDC^p ( v_textDC^star - v_textDC) + k_textDC^i zeta tag4e \n fracc_textDCOmega_b dotv_textDC = fracp_textcvv_textDC - fracv_textDCr_L tag4f \n dotgamma_d = i_textcv^d - i_textcv^dstar tag4g\n dotgamma_q = i_textcv^q - i_textcv^qstar tag4h \n v_textcv^dstar = k_textpc( i_textcv^d - i_textcv^dstar) + k_textic gamma_d + omega_textpll l_f i_textcv^q tag4i\n v_textcv^qstar = k_textpc( i_textcv^q - i_textcv^qstar) + k_textic gamma_q - omega_textpll l_f i_textcv^d tag4j\nendalign","category":"page"},{"location":"component_models/loads/","page":"Load Models","title":"Load Models","text":"Equations (4a)–(4c) describes the PLL dynamics to lock the active load to the grid. Equations (4d)-(4e) describes the DC Voltage Controller to steer the DC voltage to v_textDC^star, while equation (4f) describes the DC voltage dynamics at the capacitor assuming an ideal converter. Finally, equations (4g)–(4j) describes the dynamics of the AC Current Controller. Additionally six states are defined for the LCL filter in a similar fashion of GFM inverters.","category":"page"},{"location":"tutorials/tutorial_240bus/#[PSSE-240-Bus-Case-system-with-Renewables](https://www.nrel.gov/grid/test-case-repository.html)","page":"240 WECC solver comparison","title":"PSSE 240 Bus Case system with Renewables","text":"","category":"section"},{"location":"tutorials/tutorial_240bus/","page":"240 WECC solver comparison","title":"240 WECC solver comparison","text":"Originally Contributed by: José Daniel Lara","category":"page"},{"location":"tutorials/tutorial_240bus/#Introduction","page":"240 WECC solver comparison","title":"Introduction","text":"","category":"section"},{"location":"tutorials/tutorial_240bus/","page":"240 WECC solver comparison","title":"240 WECC solver comparison","text":"This tutorial will introduce the industry models of Renewable Energy the comparisons between DiffEq Integration techniques for comparison. We show the uses of Sundials and OrdinaryDiffEq to obtain the transient response of a system to a perturbation.","category":"page"},{"location":"tutorials/tutorial_240bus/","page":"240 WECC solver comparison","title":"240 WECC solver comparison","text":"using PowerSimulationsDynamics\nusing PowerSystemCaseBuilder\nusing PowerSystems\nconst PSY = PowerSystems\nusing Sundials\nusing Plots\nusing OrdinaryDiffEq","category":"page"},{"location":"tutorials/tutorial_240bus/","page":"240 WECC solver comparison","title":"240 WECC solver comparison","text":"note: Note\nPowerSystemCaseBuilder.jl is a helper library that makes it easier to reproduce examples in the documentation and tutorials. Normally you would pass your local files to create the system data instead of calling the function build_system. For more details visit PowerSystemCaseBuilder Documentation","category":"page"},{"location":"tutorials/tutorial_240bus/#Load-the-system-and-transform-load-data","page":"240 WECC solver comparison","title":"Load the system and transform load data","text":"","category":"section"},{"location":"tutorials/tutorial_240bus/","page":"240 WECC solver comparison","title":"240 WECC solver comparison","text":"To load the system we use PowerSystemCaseBuilder.jl:","category":"page"},{"location":"tutorials/tutorial_240bus/","page":"240 WECC solver comparison","title":"240 WECC solver comparison","text":"# We remove the checks in this example to avoid large prints\nsys = build_system(PSIDSystems, \"WECC 240 Bus\"; runchecks = false)\n\n# Transform the system's load\nfor l in get_components(PSY.StandardLoad, sys)\n transform_load_to_constant_impedance(l)\nend","category":"page"},{"location":"tutorials/tutorial_240bus/#Build-the-simulation-and-initialize-the-problem","page":"240 WECC solver comparison","title":"Build the simulation and initialize the problem","text":"","category":"section"},{"location":"tutorials/tutorial_240bus/","page":"240 WECC solver comparison","title":"240 WECC solver comparison","text":"The next step is to create the simulation structure. This will create the indexing of our system that will be used to formulate the differential-algebraic system of equations. To do so, it is required to specify the perturbation that will occur in the system. In this case, we will use a ResidualModel formulation, for more details about the formulation checkout the Models Section in PowerSimulationsDynamics.jl documentation.","category":"page"},{"location":"tutorials/tutorial_240bus/","page":"240 WECC solver comparison","title":"240 WECC solver comparison","text":"using Logging\nsim_ida = Simulation(\n ResidualModel,\n sys, #system\n pwd(),\n (0.0, 20.0), #time span\n BranchTrip(1.0, Line, \"CORONADO -1101-PALOVRDE -1401-i_10\");\n console_level = Logging.Info,\n)","category":"page"},{"location":"tutorials/tutorial_240bus/#Run-the-simulation-using-Sundials","page":"240 WECC solver comparison","title":"Run the simulation using Sundials","text":"","category":"section"},{"location":"tutorials/tutorial_240bus/","page":"240 WECC solver comparison","title":"240 WECC solver comparison","text":"We will now run the simulation using Sundials.jl solver IDA() by specifying the maximum dt we want for the simulation. In our experience with this solver, solution times are faster when supplying information about the maximum time step than the tolerances as we can see in the example","category":"page"},{"location":"tutorials/tutorial_240bus/","page":"240 WECC solver comparison","title":"240 WECC solver comparison","text":"execute!(sim_ida, IDA(), dtmax = 0.01)","category":"page"},{"location":"tutorials/tutorial_240bus/#Read-the-results-and-plot-a-system-variable","page":"240 WECC solver comparison","title":"Read the results and plot a system variable","text":"","category":"section"},{"location":"tutorials/tutorial_240bus/","page":"240 WECC solver comparison","title":"240 WECC solver comparison","text":"After the simulation is completed, we can extract the results and make plots as desired. In this case, we will plot the voltage magnitude at the bus at which the line was connected.","category":"page"},{"location":"tutorials/tutorial_240bus/","page":"240 WECC solver comparison","title":"240 WECC solver comparison","text":"res_ida = read_results(sim_ida)\nv1101_ida = get_voltage_magnitude_series(res_ida, 1101);\nplot(v1101_ida);","category":"page"},{"location":"tutorials/tutorial_240bus/","page":"240 WECC solver comparison","title":"240 WECC solver comparison","text":"(Image: plot)","category":"page"},{"location":"tutorials/tutorial_240bus/#Run-the-simulation-using-Rodas4()","page":"240 WECC solver comparison","title":"Run the simulation using Rodas4()","text":"","category":"section"},{"location":"tutorials/tutorial_240bus/","page":"240 WECC solver comparison","title":"240 WECC solver comparison","text":"In this case, we will use a MassMatrixModel formulation, for more details about the formulation checkout the Models Section in PowerSimulationsDynamics.jl documentation","category":"page"},{"location":"tutorials/tutorial_240bus/","page":"240 WECC solver comparison","title":"240 WECC solver comparison","text":"sim_rodas = Simulation(\n MassMatrixModel,\n sys, #system\n pwd(),\n (0.0, 20.0), #time span\n BranchTrip(1.0, Line, \"CORONADO -1101-PALOVRDE -1401-i_10\");\n console_level = Logging.Info,\n)","category":"page"},{"location":"tutorials/tutorial_240bus/","page":"240 WECC solver comparison","title":"240 WECC solver comparison","text":"We will now run the simulation using OrdinaryDiffEq.jl solver Rodas4() by specifying the tolerance we want for the simulation. In our experience with this solver, solution times are faster when supplying information about the atol and rtol values as we can see in the example. The solver will also work with a specified dtmax but take a significantly longer time to solve. When using OrdinaryDiffEq.jl solvers always pass the option initializealg = NoInit() to avoid unnecessary re-initialization of the algebraic equations.","category":"page"},{"location":"tutorials/tutorial_240bus/","page":"240 WECC solver comparison","title":"240 WECC solver comparison","text":"execute!(\n sim_rodas,\n Rodas4(),\n saveat = 0.01,\n atol = 1e-10,\n rtol = 1e-10,\n initializealg = NoInit(),\n)","category":"page"},{"location":"tutorials/tutorial_240bus/#Read-the-results","page":"240 WECC solver comparison","title":"Read the results","text":"","category":"section"},{"location":"tutorials/tutorial_240bus/","page":"240 WECC solver comparison","title":"240 WECC solver comparison","text":"After the simulation is completed, we can extract the results and make plots as desired. In this case, we will plot the voltage magnitude at the bus at which the line was connected.","category":"page"},{"location":"tutorials/tutorial_240bus/","page":"240 WECC solver comparison","title":"240 WECC solver comparison","text":"res_rodas = read_results(sim_rodas)","category":"page"},{"location":"tutorials/tutorial_240bus/#Compare-the-results","page":"240 WECC solver comparison","title":"Compare the results","text":"","category":"section"},{"location":"tutorials/tutorial_240bus/","page":"240 WECC solver comparison","title":"240 WECC solver comparison","text":"After the simulation is completed, we can extract the results and make plots as desired. In this case, we will plot the voltage magnitude at the bus at which the line was connected. For both of the solution techniques.","category":"page"},{"location":"tutorials/tutorial_240bus/","page":"240 WECC solver comparison","title":"240 WECC solver comparison","text":"v1101 = get_voltage_magnitude_series(res_rodas, 1101);\nplot(v1101, label = \"RODAS4\");\nplot!(v1101_ida, label = \"IDA\");","category":"page"},{"location":"tutorials/tutorial_240bus/","page":"240 WECC solver comparison","title":"240 WECC solver comparison","text":"(Image: plot)","category":"page"},{"location":"component_models/freq_esti/#Frequency-Estimators","page":"Frequency Estimators","title":"Frequency Estimators","text":"","category":"section"},{"location":"component_models/freq_esti/","page":"Frequency Estimators","title":"Frequency Estimators","text":"This component is used to estimate the frequency of the grid based on the voltage at the bus.","category":"page"},{"location":"component_models/freq_esti/#Fixed-Frequency-[FixedFrequency]","page":"Frequency Estimators","title":"Fixed Frequency [FixedFrequency]","text":"","category":"section"},{"location":"component_models/freq_esti/","page":"Frequency Estimators","title":"Frequency Estimators","text":"This is a simple model that set the measured frequency to a desired constant value (i.e. does not measure the frequency) omega_pll = omega_textfix (usually omega_textfix = 10 p.u.). Used by default when grid-forming inverters do not use frequency estimators. ","category":"page"},{"location":"component_models/freq_esti/#Phase-Locked-Loop-(PLL)-for-VSM-[KauraPLL]","page":"Frequency Estimators","title":"Phase-Locked Loop (PLL) for VSM [KauraPLL]","text":"","category":"section"},{"location":"component_models/freq_esti/","page":"Frequency Estimators","title":"Frequency Estimators","text":"The following equations present a PLL used to estimate the frequency and PLL angle of the grid. There are two reference frames considered in this inverter. Those are the VSM of the outer-loop control theta_textolc and the PLL one theta_textpll. The notation used a deltatheta refers as the variation of the respective angle theta^textgrid with respect to the grid SRF (instead of the fixed alpha component of the alphabeta transformation):","category":"page"},{"location":"component_models/freq_esti/","page":"Frequency Estimators","title":"Frequency Estimators","text":"beginalign\n\ndotv_dtextpll = omega_textlp left v_dtextout - v_dtextpll right tag1a \ndotv_qtextpll = omega_textlp left v_qtextout - v_qtextpll right tag1b \ndotvarepsilon_textpll = tan^-1left(fracv_qtextpllv_dtextpll right) tag1c \ndottheta_textpll = Omega_b delta omega_textpll tag1d\nendalign","category":"page"},{"location":"component_models/freq_esti/","page":"Frequency Estimators","title":"Frequency Estimators","text":"with","category":"page"},{"location":"component_models/freq_esti/","page":"Frequency Estimators","title":"Frequency Estimators","text":"beginalign\ndeltaomega_textpll = 10 - omega_textsys + k_ptextpll tan^-1 left(fracv_qtextpllv_dtextpll right) + k_itextpll varepsilon_textpll tag1e \nomega_textpll = deltaomega_textpll + omega_textsys tag1f \nv_dtextout + jv_qtextout = (v_r + jv_i)e^-deltatheta_textpll tag1g\nendalign","category":"page"},{"location":"component_models/freq_esti/","page":"Frequency Estimators","title":"Frequency Estimators","text":"on which v_r + jv_i is the voltage in the grid reference frame on which the PLL is measuring (i.e. point of common coupling), that could be in the capacitor of an LCL filter or the last branch of such filter.","category":"page"},{"location":"component_models/freq_esti/#Reduced-Order-Phase-Locked-Loop-(PLL)-[ReducedOrderPLL]","page":"Frequency Estimators","title":"Reduced Order Phase-Locked Loop (PLL) [ReducedOrderPLL]","text":"","category":"section"},{"location":"component_models/freq_esti/","page":"Frequency Estimators","title":"Frequency Estimators","text":"The following equations presents a simplified PLL used to estimate the frequency and PLL angle of the grid. The model attempts to steer the voltage in the q-axis to zero (i.e. lock the q-axis to zero) using a PI controller. With that the equations are given by:","category":"page"},{"location":"component_models/freq_esti/","page":"Frequency Estimators","title":"Frequency Estimators","text":"beginalign\ndotv_qtextpll = omega_textlp left v_qtextout - v_qtextpll right tag2a \ndotvarepsilon_textpll = v_qtextpll tag2b \ndottheta_textpll = Omega_b delta omega_textpll tag2c\nendalign","category":"page"},{"location":"component_models/freq_esti/","page":"Frequency Estimators","title":"Frequency Estimators","text":"with","category":"page"},{"location":"component_models/freq_esti/","page":"Frequency Estimators","title":"Frequency Estimators","text":"beginalign\ndeltaomega_textpll = 10 - omega_textsys + k_ptextpll v_qtextpll + k_itextpll varepsilon_textpll tag2d \nomega_textpll = deltaomega_textpll + omega_textsys tag2e \nv_dtextout + jv_qtextout = (v_r + jv_i)e^-deltatheta_textpll tag2f\nendalign","category":"page"},{"location":"component_models/freq_esti/","page":"Frequency Estimators","title":"Frequency Estimators","text":"on which v_r + jv_i is the voltage in the grid reference frame on which the PLL is measuring (i.e. point of common coupling), that could be in the capacitor of an LCL filter or the last branch of such filter.","category":"page"},{"location":"code_base_developer_guide/developer/#Guidelines-for-Developers","page":"Developer Guide","title":"Guidelines for Developers","text":"","category":"section"},{"location":"code_base_developer_guide/developer/","page":"Developer Guide","title":"Developer Guide","text":"In order to contribute to PowerSimulationsDynamics.jl repository please read the following sections of InfrastructureSystems.jl documentation in detail:","category":"page"},{"location":"code_base_developer_guide/developer/","page":"Developer Guide","title":"Developer Guide","text":"Style Guide\nContributing Guidelines","category":"page"},{"location":"code_base_developer_guide/developer/","page":"Developer Guide","title":"Developer Guide","text":"Pull requests are always welcome to fix bugs or add additional modeling capabilities.","category":"page"},{"location":"code_base_developer_guide/developer/","page":"Developer Guide","title":"Developer Guide","text":"All the code contributions need to include tests with a minimum coverage of 70%","category":"page"},{"location":"tutorials/tutorial_dynamic_data/#Creating-and-Handling-Data-for-Dynamic-Simulations","page":"Create Dynamic Data","title":"Creating and Handling Data for Dynamic Simulations","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"Originally Contributed by: Rodrigo Henriquez and José Daniel Lara","category":"page"},{"location":"tutorials/tutorial_dynamic_data/#Introduction","page":"Create Dynamic Data","title":"Introduction","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"This tutorial briefly introduces how to create a system using PowerSystems.jl data structures. For more details visit PowerSystems.jl Documentation","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"Start by calling PowerSystems.jl and PowerSystemCaseBuilder.jl:","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"using PowerSystems\nusing PowerSystemCaseBuilder\nconst PSY = PowerSystems;","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"note: Note\nPowerSystemCaseBuilder.jl is a helper library that makes it easier to reproduce examples in the documentation and tutorials. Normally you would pass your local files to create the system data instead of calling the function build_system. For more details visit PowerSystemCaseBuilder Documentation","category":"page"},{"location":"tutorials/tutorial_dynamic_data/#System-description","page":"Create Dynamic Data","title":"System description","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"Next we need to define the different elements required to run a simulation. To run a simulation in PowerSimulationsDynamics, it is required to define a System that contains the following components:","category":"page"},{"location":"tutorials/tutorial_dynamic_data/#Static-Components","page":"Create Dynamic Data","title":"Static Components","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"We called static components to those that are used to run a Power Flow problem.","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"Vector of Bus elements, that define all the buses in the network.\nVector of Branch elements, that define all the branches elements (that connect two buses) in the network.\nVector of StaticInjection elements, that define all the devices connected to buses that can inject (or withdraw) power. These static devices, typically generators, in PowerSimulationsDynamics are used to solve the Power Flow problem that determines the active and reactive power provided for each device.\nVector of PowerLoad elements, that define all the loads connected to buses that can withdraw current. These are also used to solve the Power Flow.\nVector of Source elements, that define source components behind a reactance that can inject or withdraw current.\nThe base of power used to define per unit values, in MVA as a Float64 value.\nThe base frequency used in the system, in Hz as a Float64 value.","category":"page"},{"location":"tutorials/tutorial_dynamic_data/#Dynamic-Components","page":"Create Dynamic Data","title":"Dynamic Components","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"Dynamic components are those that define differential equations to run a transient simulation.","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"Vector of DynamicInjection elements. These components must be attached to a StaticInjection that connects the power flow solution to the dynamic formulation of such device. DynamicInjection can be DynamicGenerator or DynamicInverter, and its specific formulation (i.e. differential equations) will depend on the specific components that define such device.\n(Optional) Selecting which of the Lines (of the Branch vector) elements must be modeled of DynamicLines elements, that can be used to model lines with differential equations.","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"To start we will define the data structures for the network.","category":"page"},{"location":"tutorials/tutorial_dynamic_data/#Three-Bus-case-manual-data-creation","page":"Create Dynamic Data","title":"Three Bus case manual data creation","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"The following describes the system creation for this dynamic simulation case.","category":"page"},{"location":"tutorials/tutorial_dynamic_data/#Static-System-creation","page":"Create Dynamic Data","title":"Static System creation","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"To create the system you need to load data using PowerSystemCaseBuilder.jl. This system was originally created from following raw file. ","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"sys = build_system(PSIDSystems, \"3 Bus Inverter Base\"; force_build=true)","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"This system does not have an injection device in bus 1 (the reference bus). We can add a source with small impedance directly as follows:","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"slack_bus = [b for b in get_components(ACBus, sys) if get_bustype(b) == ACBusTypes.REF][1]\ninf_source = Source(\n name = \"InfBus\", #name\n available = true, #availability\n active_power = 0.0,\n reactive_power = 0.0,\n bus = slack_bus, #bus\n R_th = 0.0, #Rth\n X_th = 5e-6, #Xth\n)\nadd_component!(sys, inf_source)","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"We just added a infinite source with X_th = 5cdot 10^-6 pu. The system can be explored directly using functions like:","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"show_components(sys, Source)","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"show_components(sys, ThermalStandard)","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"By exploring those it can be seen that the generators are named as: generator-bus_number-id. Then, the generator attached at bus 2 is named generator-102-1.","category":"page"},{"location":"tutorials/tutorial_dynamic_data/#Dynamic-Injections","page":"Create Dynamic Data","title":"Dynamic Injections","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"We are now interested in attaching to the system the dynamic component that will be modeling our dynamic generator.","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"Dynamic generator devices are composed by 5 components, namely, machine, shaft, avr, tg and pss. So we will be adding functions to create all of its components and the generator itself:","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"# *Machine*\nmachine_classic() = BaseMachine(\n 0.0, #R\n 0.2995, #Xd_p\n 0.7087, #eq_p\n)\n\n# *Shaft*\nshaft_damping() = SingleMass(\n 3.148, #H\n 2.0, #D\n)\n\n# *AVR: No AVR*\navr_none() = AVRFixed(0.0)\n\n# *TG: No TG*\ntg_none() = TGFixed(1.0) #efficiency\n\n# *PSS: No PSS*\npss_none() = PSSFixed(0.0)","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"The next lines receives a static generator name, and creates a DynamicGenerator based on that specific static generator, with the specific components defined previously. This is a classic machine model without AVR, Turbine Governor and PSS.","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"static_gen = get_component(Generator, sys, \"generator-102-1\")\n\ndyn_gen = DynamicGenerator(\n name = get_name(static_gen),\n ω_ref = 1.0,\n machine = machine_classic(),\n shaft = shaft_damping(),\n avr = avr_none(),\n prime_mover = tg_none(),\n pss = pss_none(),\n)","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"The dynamic generator is added to the system by specifying the dynamic and static generator","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"add_component!(sys, dyn_gen, static_gen)","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"Then we can serialize our system data to a json file that can be later read as:","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"file_dir = @__DIR__ #hide\nto_json(sys, joinpath(file_dir, \"modified_sys.json\"), force = true)","category":"page"},{"location":"tutorials/tutorial_dynamic_data/#Dynamic-Lines-case:-Data-creation","page":"Create Dynamic Data","title":"Dynamic Lines case: Data creation","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"We will now create a three bus system with one inverter and one generator. In order to do so, we will parse the following ThreebusInverter.raw network:","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"threebus_sys = build_system(PSIDSystems, \"3 Bus Inverter Base\")\nslack_bus = first(get_components(x -> get_bustype(x) == BusTypes.REF, Bus, threebus_sys))\ninf_source = Source(\n name = \"InfBus\", #name\n available = true, #availability\n active_power = 0.0,\n reactive_power = 0.0,\n bus = slack_bus, #bus\n R_th = 0.0, #Rth\n X_th = 5e-6, #Xth\n)\nadd_component!(threebus_sys, inf_source)","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"We will connect a One-d-one-q machine at bus 102, and a Virtual Synchronous Generator Inverter at bus 103. An inverter is composed by a converter, outer control, inner control, dc source, frequency estimator and a filter.","category":"page"},{"location":"tutorials/tutorial_dynamic_data/#Dynamic-Inverter-definition","page":"Create Dynamic Data","title":"Dynamic Inverter definition","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"We will create specific functions to create the components of the inverter as follows:","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"#Define converter as an AverageConverter\nconverter_high_power() = AverageConverter(\n rated_voltage = 138.0,\n rated_current = 100.0\n )\n\n#Define Outer Control as a composition of Virtual Inertia + Reactive Power Droop\nouter_control() = OuterControl(\n VirtualInertia(Ta = 2.0, kd = 400.0, kω = 20.0),\n ReactivePowerDroop(kq = 0.2, ωf = 1000.0),\n)\n\n#Define an Inner Control as a Voltage+Current Controler with Virtual Impedance:\ninner_control() = VoltageModeControl(\n kpv = 0.59, #Voltage controller proportional gain\n kiv = 736.0, #Voltage controller integral gain\n kffv = 0.0, #Binary variable enabling voltage feed-forward in current controllers\n rv = 0.0, #Virtual resistance in pu\n lv = 0.2, #Virtual inductance in pu\n kpc = 1.27, #Current controller proportional gain\n kic = 14.3, #Current controller integral gain\n kffi = 0.0, #Binary variable enabling the current feed-forward in output of current controllers\n ωad = 50.0, #Active damping low pass filter cut-off frequency\n kad = 0.2, #Active damping gain\n)\n\n#Define DC Source as a FixedSource:\ndc_source_lv() = FixedDCSource(voltage = 600.0)\n\n#Define a Frequency Estimator as a PLL\n#based on Vikram Kaura and Vladimir Blaskoc 1997 paper:\npll() = KauraPLL(\n ω_lp = 500.0, #Cut-off frequency for LowPass filter of PLL filter.\n kp_pll = 0.084, #PLL proportional gain\n ki_pll = 4.69, #PLL integral gain\n)\n\n#Define an LCL filter:\nfilt() = LCLFilter(lf = 0.08, rf = 0.003, cf = 0.074, lg = 0.2, rg = 0.01)","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"We will construct the inverter later by specifying to which static device is assigned.","category":"page"},{"location":"tutorials/tutorial_dynamic_data/#Dynamic-Generator-definition","page":"Create Dynamic Data","title":"Dynamic Generator definition","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"Similarly we will construct a dynamic generator as follows:","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"# Create the machine\nmachine_oneDoneQ() = OneDOneQMachine(\n 0.0, #R\n 1.3125, #Xd\n 1.2578, #Xq\n 0.1813, #Xd_p\n 0.25, #Xq_p\n 5.89, #Td0_p\n 0.6, #Tq0_p\n)\n\n# Shaft\nshaft_no_damping() = SingleMass(\n 3.01, #H (M = 6.02 -> H = M/2)\n 0.0, #D\n)\n\n# AVR: Type I: Resembles a DC1 AVR\navr_type1() = AVRTypeI(\n 20.0, #Ka - Gain\n 0.01, #Ke\n 0.063, #Kf\n 0.2, #Ta\n 0.314, #Te\n 0.35, #Tf\n 0.001, #Tr\n (min = -5.0, max = 5.0),\n 0.0039, #Ae - 1st ceiling coefficient\n 1.555, #Be - 2nd ceiling coefficient\n)\n\n#No TG\ntg_none() = TGFixed(1.0) #efficiency\n\n#No PSS\npss_none() = PSSFixed(0.0) #Vs","category":"page"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"Now we will construct the dynamic generator and inverter.","category":"page"},{"location":"tutorials/tutorial_dynamic_data/#Add-the-components-to-the-system","page":"Create Dynamic Data","title":"Add the components to the system","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"for g in get_components(Generator, threebus_sys)\n #Find the generator at bus 102\n if get_number(get_bus(g)) == 102\n #Create the dynamic generator\n case_gen = DynamicGenerator(\n get_name(g),\n 1.0, # ω_ref,\n machine_oneDoneQ(), #machine\n shaft_no_damping(), #shaft\n avr_type1(), #avr\n tg_none(), #tg\n pss_none(), #pss\n )\n #Attach the dynamic generator to the system by\n # specifying the dynamic and static components\n add_component!(threebus_sys, case_gen, g)\n #Find the generator at bus 103\n elseif get_number(get_bus(g)) == 103\n #Create the dynamic inverter\n case_inv = DynamicInverter(\n get_name(g),\n 1.0, # ω_ref,\n converter_high_power(), #converter\n outer_control(), #outer control\n inner_control(), #inner control voltage source\n dc_source_lv(), #dc source\n pll(), #pll\n filt(), #filter\n )\n #Attach the dynamic inverter to the system\n add_component!(threebus_sys, case_inv, g)\n end\nend","category":"page"},{"location":"tutorials/tutorial_dynamic_data/#Save-the-system-in-a-JSON-file","page":"Create Dynamic Data","title":"Save the system in a JSON file","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_data/","page":"Create Dynamic Data","title":"Create Dynamic Data","text":"file_dir = @__DIR__ #hide\nto_json(threebus_sys, joinpath(file_dir, \"threebus_sys.json\"), force = true)","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/#Line-Modeling-Simulations","page":"Dynamic Lines Simulation","title":"Line Modeling Simulations","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"Originally Contributed by: Rodrigo Henriquez-Auba and José Daniel Lara","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/#Introduction","page":"Dynamic Lines Simulation","title":"Introduction","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"This tutorial will introduce an example of considering dynamic lines in PowerSimulationsDynamics.","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"This tutorial presents a simulation of a three-bus system, with an infinite bus (represented as a voltage source behind an impedance) at bus 1, a one d- one q- machine on bus 2 and an inverter of 19 states, as a virtual synchronous machine at bus 3. The perturbation will be the trip of two of the three circuits (triplicating its resistance and impedance) of the line that connects bus 1 and bus 3. This case also consider a dynamic line model for connection between buses 2 and 3. We will compare it against a system without dynamic lines.","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"It is recommended to check the OMIB tutorial first, since that includes more details and explanations on all definitions and functions.","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/#Step-1:-Package-Initialization","page":"Dynamic Lines Simulation","title":"Step 1: Package Initialization","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"using PowerSimulationsDynamics\nusing PowerSystems\nusing PowerNetworkMatrices\nusing PowerSystemCaseBuilder\nusing Sundials\nusing Plots","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"note: Note\nPowerSystemCaseBuilder.jl is a helper library that makes it easier to reproduce examples in the documentation and tutorials. Normally you would pass your local files to create the system data instead of calling the function build_system. For more details visit PowerSystemCaseBuilder Documentation","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/#Step-2:-Data-creation","page":"Dynamic Lines Simulation","title":"Step 2: Data creation","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"Load the system using PowerSystemCaseBuilder.jl:","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"threebus_sys = build_system(PSIDSystems, \"Three Bus Dynamic data Example System\")","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"In addition, we will create a new copy of the system on which we will simulate the same case, but will consider dynamic lines:","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"threebus_sys_dyn = deepcopy(threebus_sys);","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/#Step-3:-Create-the-fault-and-simulation-on-the-Static-Lines-system","page":"Dynamic Lines Simulation","title":"Step 3: Create the fault and simulation on the Static Lines system","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"First, we construct the perturbation, by properly computing the new Ybus on the system:","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"#Make a copy of the original system\nsys2 = deepcopy(threebus_sys)\n#Triplicates the impedance of the line named \"BUS 1-BUS 3-i_1\"\nfault_branches = get_components(ACBranch, sys2)\nfor br in fault_branches\n if get_name(br) == \"BUS 1-BUS 3-i_1\"\n br.r = 3 * br.r\n br.x = 3 * br.x\n b_new = (from = br.b.from / 3, to = br.b.to / 3)\n br.b = b_new\n end\nend\n#Obtain the new Ybus\nYbus_fault = Ybus(sys2).data\n#Define Fault: Change of YBus\nYbus_change = NetworkSwitch(\n 1.0, #change at t = 1.0\n Ybus_fault, #New YBus\n);","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"Now, we construct the simulation:","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"#Time span of our simulation\ntspan = (0.0, 30.0)\n\n#Define Simulation\nsim = Simulation(\n ResidualModel, #Type of model used\n threebus_sys, #system\n pwd(), #folder to output results\n tspan, #time span\n Ybus_change, #Type of perturbation\n)","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"We can obtain the initial conditions as:","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"#Print the initial states. It also give the symbols used to describe those states.\nshow_states_initial_value(sim)","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/#Step-4:-Run-the-simulation-of-the-Static-Lines-System","page":"Dynamic Lines Simulation","title":"Step 4: Run the simulation of the Static Lines System","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"#Run the simulation\nexecute!(\n sim, #simulation structure\n IDA(), #Sundials DAE Solver\n dtmax = 0.02, #Maximum step size\n)","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/#Step-5:-Store-the-solution","page":"Dynamic Lines Simulation","title":"Step 5: Store the solution","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"results = read_results(sim)\nseries2 = get_voltage_magnitude_series(results, 102)\nzoom = [\n (series2[1][ix], series2[2][ix]) for\n (ix, s) in enumerate(series2[1]) if (s > 0.90 && s < 1.6)\n];","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/#Step-3.1:-Create-the-fault-and-simulation-on-the-Dynamic-Lines-system","page":"Dynamic Lines Simulation","title":"Step 3.1: Create the fault and simulation on the Dynamic Lines system","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"An important aspect to consider is that DynamicLines must not be considered in the computation of the Ybus. First we construct the Dynamic Line, by finding the Line named \"BUS 2-BUS 3-i_1\", and then adding it to the system.","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"# get component return the Branch on threebus_sys_dyn named \"BUS 2-BUS 3-i_1\"\ndyn_branch = DynamicBranch(get_component(Line, threebus_sys_dyn,\"BUS 2-BUS 3-i_1\"))\n# Adding a dynamic line will immediately remove the static line from the system.\nadd_component!(threebus_sys_dyn, dyn_branch)","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"Similarly, we construct the Ybus fault by creating a copy of the original system, but removing the Line \"BUS 2-BUS 3-i_1\" to avoid considering it in the Ybus:","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"#Make a copy of the original system\nsys3 = deepcopy(threebus_sys);\n#Remove Line \"BUS 2-BUS 3-i_1\"\nremove_component!(Line, sys3, \"BUS 2-BUS 3-i_1\")\n#Triplicates the impedance of the line named \"BUS 1-BUS 2-i_1\"\nfault_branches2 = get_components(Line, sys3)\nfor br in fault_branches2\n if get_name(br) == \"BUS 1-BUS 3-i_1\"\n br.r = 3 * br.r\n br.x = 3 * br.x\n b_new = (from = br.b.from / 3, to = br.b.to / 3)\n br.b = b_new\n end\nend\n#Obtain the new Ybus\nYbus_fault_dyn = Ybus(sys3).data\n#Define Fault: Change of YBus\nYbus_change_dyn = NetworkSwitch(\n 1.0, #change at t = 1.0\n Ybus_fault_dyn, #New YBus\n)","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/#Step-4.1:-Run-the-simulation-of-the-Dynamic-Lines-System","page":"Dynamic Lines Simulation","title":"Step 4.1: Run the simulation of the Dynamic Lines System","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"Now, we construct the simulation:","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"# Define Simulation\nsim_dyn = Simulation(\n ResidualModel, #Type of model used\n threebus_sys_dyn, #system\n pwd(), #folder to output results\n (0.0, 30.0), #time span\n Ybus_change_dyn, #Type of perturbation\n)","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"# Run the simulation\nexecute!(\n sim_dyn, #simulation structure\n IDA(), #Sundials DAE Solver\n dtmax = 0.02, #Maximum step size\n)","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"We can obtain the initial conditions as:","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"#Print the initial states. It also give the symbols used to describe those states.\nshow_states_initial_value(sim_dyn)","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/#Step-5.1:-Store-the-solution","page":"Dynamic Lines Simulation","title":"Step 5.1: Store the solution","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"results_dyn = read_results(sim_dyn)\nseries2_dyn = get_voltage_magnitude_series(results_dyn, 102);\nzoom_dyn = [\n (series2_dyn[1][ix], series2_dyn[2][ix]) for\n (ix, s) in enumerate(series2_dyn[1]) if (s > 0.90 && s < 1.6)\n];","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/#Step-6.1:-Compare-the-solutions:","page":"Dynamic Lines Simulation","title":"Step 6.1: Compare the solutions:","text":"","category":"section"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"We can observe the effect of Dynamic Lines","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"plot(series2_dyn, label = \"V_gen_dyn\");\nplot!(series2, label = \"V_gen_st\", xlabel = \"Time [s]\", ylabel = \"Voltage [pu]\");","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"(Image: plot)","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"that looks quite similar. The differences can be observed in the zoom plot:","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"plot(zoom_dyn, label = \"V_gen_dyn\");\nplot!(zoom, label = \"V_gen_st\", xlabel = \"Time [s]\", ylabel = \"Voltage [pu]\");","category":"page"},{"location":"tutorials/tutorial_dynamic_lines/","page":"Dynamic Lines Simulation","title":"Dynamic Lines Simulation","text":"(Image: plot)","category":"page"},{"location":"models/#Models","page":"Models","title":"Models","text":"","category":"section"},{"location":"models/#Simulation-Models","page":"Models","title":"Simulation Models","text":"","category":"section"},{"location":"models/","page":"Models","title":"Models","text":"PowerSimulations dynamics supports two formulations for the simulation model and define different methods for each simulation model. You can pass ResidualModel or MassMatrixModel to a call to Simulation to define the preferred formulation.","category":"page"},{"location":"models/","page":"Models","title":"Models","text":"In this way, we provide a common set of development requirements for contributors of new models that maintains the same flexibility in choosing the solving algorithm.","category":"page"},{"location":"models/","page":"Models","title":"Models","text":"MassMatrixModel: Defines models that can be solved using Mass-Matrix Solvers. The model is formulated as follows:","category":"page"},{"location":"models/","page":"Models","title":"Models","text":"beginalign\nMfracdx(t)dt = f(x(t))\nendalign","category":"page"},{"location":"models/","page":"Models","title":"Models","text":"At this stage we have not conducted extensive tests with all the solvers in DifferentialEquations most of our tests use Rodas5().","category":"page"},{"location":"models/","page":"Models","title":"Models","text":"ResidualModel: Define models that can be solved using Implicit ODE solvers and also the solver IDA from Sundials. The model is formulated to solved the following problem:","category":"page"},{"location":"models/","page":"Models","title":"Models","text":"beginalign\nr(t) = fracdx(t)dt - f(x(t))\nendalign","category":"page"},{"location":"models/","page":"Models","title":"Models","text":"At this stage we have not conducted extensive tests with all the solvers in DifferentialEquations if you are solving a larger system use IDA().","category":"page"},{"location":"models/#The-dynamic-system-model-in-PowerSimulationsDynamics","page":"Models","title":"The dynamic system model in PowerSimulationsDynamics","text":"","category":"section"},{"location":"models/","page":"Models","title":"Models","text":"In order to support both formulations, the default implementation of the ResidualModel solves the following problem:","category":"page"},{"location":"models/","page":"Models","title":"Models","text":"beginalign\nr(t) = Mfracdx(t)dt - f(x(t))\nendalign","category":"page"},{"location":"models/#Solution-approaches","page":"Models","title":"Solution approaches","text":"","category":"section"},{"location":"models/","page":"Models","title":"Models","text":"PowerSimulationsDynamics.jl construct the entire function that is passed to DifferentialEquations to solve it using different solvers. This is called the Simultaneous-solution approach to numerically integrate over time. It gives the user the flexibility to model devices with a combination of differential and algebraic states. In addition, it gives the flexibility to model the network using an algebraic or differential model.","category":"page"},{"location":"models/","page":"Models","title":"Models","text":"On the other hand, industrial tools such as PSS/E uses a Partitioned-solution approach, on which the network must be modeled using an algebraic approach, and the differential equations and algebraic equations are solved sequentially. This method is usually faster if the heuristics for convergence when solving sequentially are properly tuned. However, boundary techniques must be considered when the connection with the devices and network is not converging when applying the partitioned-solution approach.","category":"page"},{"location":"models/","page":"Models","title":"Models","text":"The difference in solution methods can complicate the validation and comparison between software tools. In addition it can affect the computational properties due to reliance of heuristics. These solution aspects are important to consider when using different tools for simulating power systems dynamics.","category":"page"},{"location":"models/","page":"Models","title":"Models","text":"For more details, check Brian Stott paper \"Power system dynamic response calculations\".","category":"page"},{"location":"models/#Generator-Models","page":"Models","title":"Generator Models","text":"","category":"section"},{"location":"models/","page":"Models","title":"Models","text":"Here we discuss the structure and models used to model generators in PowerSimulationsDynamics.jl. See PowerSystems.jl dynamic devices for details.","category":"page"},{"location":"models/","page":"Models","title":"Models","text":"Each generator is a data structure composed of the following components defined in PowerSystems.jl:","category":"page"},{"location":"models/","page":"Models","title":"Models","text":"Machine: That defines the stator electro-magnetic dynamics.\nShaft: That describes the rotor electro-mechanical dynamics.\nAutomatic Voltage Regulator: Electromotive dynamics to model an AVR controller.\nPower System Stabilizer: Control dynamics to define an stabilization signal for the AVR.\nPrime Mover and Turbine Governor: Thermo-mechanical dynamics and associated controllers.","category":"page"},{"location":"models/","page":"Models","title":"Models","text":"The implementation of Synchronous generators as components uses the following structure to share values across components.","category":"page"},{"location":"models/","page":"Models","title":"Models","text":"","category":"page"},{"location":"models/#Inverter-Models","page":"Models","title":"Inverter Models","text":"","category":"section"},{"location":"models/","page":"Models","title":"Models","text":"Here we discuss the structure and models used to model inverters in PowerSimulationsDynamics.jl. See PowerSystems.jl dynamic devices for details. One of the key contributions in this software package is a separation of the components in a way that resembles current practices for synchronoues machine modeling.","category":"page"},{"location":"models/","page":"Models","title":"Models","text":"DC Source: Defines the dynamics of the DC side of the converter.\nFrequency Estimator: That describes how the frequency of the grid can be estimated using the grid voltages. Typically a phase-locked loop (PLL).\nOuter Loop Control: That describes the active and reactive power control dynamics.\nInner Loop Control: That can describe virtual impedance, voltage control and current control dynamics.\nConverter: That describes the dynamics of the pulse width modulation (PWM) or space vector modulation (SVM).\nFilter: Used to connect the converter output to the grid.","category":"page"},{"location":"models/","page":"Models","title":"Models","text":"The following figure summarizes the components of a inverter and which variables they share:","category":"page"},{"location":"models/","page":"Models","title":"Models","text":"","category":"page"},{"location":"models/","page":"Models","title":"Models","text":"Contrary to the generator, there are many control structures that can be used to model inverter controllers (e.g. grid-following, grid feeding or virtual synchronous machine). For this purpose, more variables are shared among the components in order to cover all these posibilities.","category":"page"},{"location":"models/#Reference","page":"Models","title":"Reference","text":"","category":"section"},{"location":"models/","page":"Models","title":"Models","text":"For models, check the library in PowerSystems.jl","category":"page"},{"location":"component_models/avr/#Automatic-Voltage-Regulators-(AVR)","page":"AVR","title":"Automatic Voltage Regulators (AVR)","text":"","category":"section"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"AVR are used to determine the voltage in the field winding v_f (or V_f) in the model.","category":"page"},{"location":"component_models/avr/#Fixed-AVR-[AVRFixed]","page":"AVR","title":"Fixed AVR [AVRFixed]","text":"","category":"section"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"This is a simple model that set the field voltage to be equal to a desired constant value v_f = v_textfix.","category":"page"},{"location":"component_models/avr/#Simple-AVR-[AVRSimple]","page":"AVR","title":"Simple AVR [AVRSimple]","text":"","category":"section"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"This depicts the most basic AVR, on which the field voltage is an integrator over the difference of the measured voltage and a reference:","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"beginalign\ndotv_f = K_v(v_textref - v_h) tag1a\nendalign","category":"page"},{"location":"component_models/avr/#AVR-Type-I-[AVRTypeI]","page":"AVR","title":"AVR Type I [AVRTypeI]","text":"","category":"section"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"This AVR is a simplified version of the IEEE DC1 AVR model:","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"beginalign\ndotv_f = -frac1T_e left V_f(K_e + S_e(v_f))-v_r1 right tag2a \ndotv_r1 = frac1T_a left K_aleft(v_textref - v_m - v_r2 - fracK_fT_fv_fright) - v_r1 right tag2b \ndotv_r2 = -frac1T_f left fracK_fT_fv_f + v_r2 right tag2c \ndotv_m = frac1T_r (v_h - v_m) tag2d\nendalign","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"with the ceiling function:","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"beginalign*\nS_e(v_f) = A_e exp(B_ev_f)\nendalign*","category":"page"},{"location":"component_models/avr/#AVR-Type-II-[AVRTypeII]","page":"AVR","title":"AVR Type II [AVRTypeII]","text":"","category":"section"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"This model represents a static exciter with higher gains and faster response than the Type I:","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"beginalign\ndotv_f = -frac1T_e left V_f(1 + S_e(v_f))-v_r right tag3a \ndotv_r1 = frac1T_1 left K_0left(1 - fracT_2T_1 right)(v_textref - v_m) - v_r1 right tag3b \ndotv_r2 = frac1K_0 T_3 left left( 1 - fracT_4T_3 right) left( v_r1 + K_0fracT_2T_1(v_textref - v_m)right) - K_0 v_r2 right tag3c \ndotv_m = frac1T_r (v_h - v_m) tag3d\nendalign","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"with","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"beginalign*\nv_r = K_0v_r2 + fracT_4T_3 left( v_r1 + K_0fracT_2T_1(v_textref - v_m)right) \nS_e(v_f) = A_e exp(B_ev_f)\nendalign*","category":"page"},{"location":"component_models/avr/#Excitation-System-AC1A-[ESAC1A]","page":"AVR","title":"Excitation System AC1A [ESAC1A]","text":"","category":"section"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"The model represents the 5-states IEEE Type AC1A Excitation System Model:","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"beginalign\ndotV_m = frac1T_r (V_h - V_m) tag4a \ndotV_r1 = frac1T_b left(V_in left(1 - fracT_cT_bright) - V_r1right) tag4b \ndotV_r2 = frac1T_a (K_a V_out - V_r2) tag4c \ndotV_e = frac1T_e (V_r - V_FE) tag4d \ndotV_r3 = frac1T_f left( - fracK_fT_fV_FE - V_r3 right) tag4e \nendalign","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"with","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"beginalign*\nI_N = fracK_cV_e X_adI_fd \nV_FE = K_d X_adI_fd + K_e V_e + S_e V_e \nS_e = Bfrac(V_e-A)^2V_e \nV_F1 = V_r3 + fracK_fT_f V_FE \nV_in = V_ref - V_m - V_F1 \nV_out = V_r1 + fracT_cT_b V_in \nV_f = V_e f(I_N) \nf(I_N) = leftbeginarraycl\n 1 text if I_N le 0 \n 1 - 0577 I_N text if 0 I_N le 0433 \n sqrt075 - I_N^2 text if 0433 I_N le 075 \n 1732(1-I_N) text if 075 I_N le 1 \n 0 text if I_N 1 endarray right\nendalign*","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"on which X_adI_fd is the field current coming from the generator and V_h is the terminal voltage, and AB are the saturation coefficients computed using the E_1 E_2 S_e(E_1) S_e(E_2) data.","category":"page"},{"location":"component_models/avr/#Simplified-Excitation-System-[SEXS]","page":"AVR","title":"Simplified Excitation System [SEXS]","text":"","category":"section"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"The model for the 2 states excitation system SEXS:","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"beginalign\ndotV_f = frac1T_e (V_LL - V_f) tag5a \ndotV_r = frac1T_b leftleft(1 - fracT_aT_bright) V_in - V_r right tag5b\nendalign","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"with","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"beginalign*\nV_in = V_ref + V_s - V_h \nV_LL = V_r + fracT_aT_bV_in \nendalign*","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"on which V_h is the terminal voltage and V_s is the PSS output signal.","category":"page"},{"location":"component_models/avr/#Excitation-System-ST1-[EXST1]","page":"AVR","title":"Excitation System ST1 [EXST1]","text":"","category":"section"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"The model represents the 4-states IEEE Type ST1 Excitation System Model:","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"beginalign\ndotV_m = frac1T_r (V_h - V_m) tag6a \ndotV_rll = frac1T_b left(V_in left(1 - fracT_cT_bright) - V_rllright) tag6b \ndotV_r = frac1T_a (V_LL - V_r) tag6c \ndotV_fb = frac1T_f left( - fracK_fT_fV_r - V_fb right) tag6d \nendalign","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"with ","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"beginalign*\nV_in = V_ref - V_m - y_hp \nV_LL = V_r + fracT_cT_b V_in \ny_hp = V_fb + fracK_fT_f V_r \nV_f = V_r \nendalign*","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"on which V_h is the terminal voltage.","category":"page"},{"location":"component_models/avr/#Excitation-System-EXAC1-[EXAC1]","page":"AVR","title":"Excitation System EXAC1 [EXAC1]","text":"","category":"section"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"The model represents the 5-states IEEE Type EXAC1 Excitation System Model:","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"beginalign\ndotV_m = frac1T_r (V_h - V_m) tag7a \ndotV_r1 = frac1T_b left(V_in left(1 - fracT_cT_bright) - V_r1right) tag7b \ndotV_r2 = frac1T_a (K_a V_out - V_r2) tag7c \ndotV_e = frac1T_e (V_r - V_FE) tag7d \ndotV_r3 = frac1T_f left( - fracK_fT_fV_FE - V_r3 right) tag7e \nendalign","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"with","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"beginalign*\nI_N = fracK_cV_e X_adI_fd \nV_FE = K_d X_adI_fd + K_e V_e + S_e V_e \nS_e = Bfrac(V_e-A)^2V_e \nV_F1 = V_r3 + fracK_fT_f V_FE \nV_in = V_ref - V_m - V_F1 \nV_out = V_r1 + fracT_cT_b V_in \nV_f = V_e f(I_N) \nf(I_N) = leftbeginarraycl\n 1 text if I_N le 0 \n 1 - 0577 I_N text if 0 I_N le 0433 \n sqrt075 - I_N^2 text if 0433 I_N le 075 \n 1732(1-I_N) text if 075 I_N le 1 \n 0 text if I_N 1 endarray right\nendalign*","category":"page"},{"location":"component_models/avr/","page":"AVR","title":"AVR","text":"on which X_adI_fd is the field current coming from the generator and V_h is the terminal voltage, and AB are the saturation coefficients computed using the E_1 E_2 S_e(E_1) S_e(E_2) data.","category":"page"},{"location":"component_models/outer_control/#Outer-Loop-Controls","page":"Outer Control","title":"Outer Loop Controls","text":"","category":"section"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"This component defines controllers for both active and reactive power. The joint design is based on the fact that many novel control techniques can be based on joint control of active and reactive power.","category":"page"},{"location":"component_models/outer_control/#Virtual-Inertia-and-Q-droop-[OuterControl]","page":"Outer Control","title":"Virtual Inertia and Q-droop [OuterControl]","text":"","category":"section"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"The following model represent a virtual synchronous machine model to represent how active power is going to be deployed. The constructor is OuterControl{VirtualInertia, ReactivePowerDroop}. It defines a new SRF denoted as theta_textolc for the active power controller and uses a simple voltage droop for dispatching reactive power:","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"beginalign\n dotomega_textolc = fracp_textrefT_a - fracp_eT_a - frack_d(omega_textolc - omega_textpll)T_a - frack_omega(omega_textolc - omega_textref)T_a tag1a \n dottheta_textolc = Omega_b (omega_textolc - omega_textsys) tag1b \n dotq_m = omega_f (q_e - q_m) tag1c\nendalign","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"with","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"beginalign\n p_e = v_ri_r + v_ii_i tag1d \n q_e = v_ii_r - v_ri_i tag1e \n v_textolc^textref = v_textref + k_q(q_textref - q_m) tag1f\nendalign","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"In this case, the measurement of power are being done in the capacitor of the LCL filter. However, depending on the model, this measurements could be different depending on where is the point of common coupling.","category":"page"},{"location":"component_models/outer_control/#Active-Power-Droop-(P-droop)-and-Q-droop-[OuterControl]","page":"Outer Control","title":"Active Power Droop (P-droop) and Q-droop [OuterControl]","text":"","category":"section"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"The following model represent a Ptext-f droop model to represent how active power is going to be deployed. The constructor is OuterControl{ActivePowerDroop, ReactivePowerDroop}. It defines a new SRF denoted as theta_textolc for the active power controller and uses a simple voltage droop for dispatching reactive power. Both active and reactive power are measured via a low-pass filter:","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"beginalign\n dottheta_textolc = Omega_b (omega_textolc - omega_textsys) tag2a \n dotp_m = omega_z (p_e - p_m) tag2b \n dotq_m = omega_f (q_e - q_m) tag2c\nendalign","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"with","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"beginalign\n p_e = v_ri_r + v_ii_i tag2d \n q_e = v_ii_r - v_ri_i tag2e \n omega_textolc = omega_textref + R_p (p_textref - p_m) tag2f \n v_textolc^textref = v_textref + k_q(q_textref - q_m) tag2g\nendalign","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"In this case, the measurement of power are being done in the capacitor of the LCL filter. However, depending on the model, this measurements could be different depending on where is the point of common coupling.","category":"page"},{"location":"component_models/outer_control/#Active-and-Reactive-Virtual-Oscillator-Controllers-[OuterControl]","page":"Outer Control","title":"Active and Reactive Virtual Oscillator Controllers [OuterControl]","text":"","category":"section"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"The following model represents a Virtual Oscillator Controller for both active and reactive power to generate the voltage references that will be used in the Voltage Controller. The contructor is OuterControl{ActiveVirtualOscillator, ReactiveVirtualOscillator} It defines a new SRF denoted as theta_textolc and a voltage reference E_textolc. The equations are:","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"beginalign\n dottheta_textolc = Omega_b (omega_textolc - omega_textsys) tag3a \n dotE_olc = Omega_b left(frack_1E_oc (-sin(gamma) (p_textref - p_e) + cos(gamma)(q_textref - q_e)) + k_2 (V_textref - E_oc^2)E_oc right) tag3b \nendalign","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"with","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"beginalign\n gamma = psi - fracpi2 tag3c \n omega_textolc = omega_textsys + frack_1E_oc^2 left(cos(gamma) (p_textref - p_e) + sin(gamma)(q_textref - q_e) right) tag3d \n p_e = v_ri_r + v_ii_i tag3e \n q_e = v_ii_r - v_ri_i tag3f \nendalign","category":"page"},{"location":"component_models/outer_control/#Active-and-Reactive-Power-PI-Controllers-(Grid-Following)-[OuterControl]","page":"Outer Control","title":"Active and Reactive Power PI Controllers (Grid Following) [OuterControl]","text":"","category":"section"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"The following model represents a PI controller for both active and reactive power to generate the current references that will be used in the Current Controller of the inner control CurrentModeControl. The constructor is OuterControl{ActivePowerPI, ReactivePowerPI}. The equations are:","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"beginalign\n dotsigma_p = p_textref - p_m tag4a \n dotp_m = omega_z (p_e - p_m) tag4b \n dotsigma_q = q_textref - q_m tag4c \n dotq_m = omega_f (q_e - p_m) tag4d \nendalign","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"with","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"beginalign\n p_e = v_ri_r + v_ii_i tag4e \n q_e = v_ii_r - v_ri_i tag4f \n omega_textolc = omega_textpll tag4g \n theta_textolc = theta_textpll tag4h \n i_textdcv^textref = k_p^q (q_textref - q_m) + k_i^q sigma_q tag4i \n i_textqcv^textref = k_p^p (p_textref - p_m) + k_i^p sigma_p tag4j \nendalign","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"This models requires a PLL to have a SRF for an internal dq reference frame. Contrary to the Grid-Forming model, it cannot work without a PLL. Since this Outer Control outputs a current reference, it can only be used with a current mode inner control (i.e. that receives a current reference instead of a voltage reference).","category":"page"},{"location":"component_models/outer_control/#Active-and-Reactive-Generic-Renewable-Controller-Type-AB-[OuterControl]","page":"Outer Control","title":"Active and Reactive Generic Renewable Controller Type AB [OuterControl]","text":"","category":"section"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"The following model represents an outer controller for both active and reactive power from generic industrial models REPCA and REECB to generate the current references that will be used in the Current Controller of the inner control RECurrentControlB. The constructor is OuterControl{ActiveRenewableControllerAB, ReactiveRenewableControllerAB}. The equations will depend on the flags used.","category":"page"},{"location":"component_models/outer_control/#Active-part","page":"Outer Control","title":"Active part","text":"","category":"section"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"In the case of F_Flag = 1 the equations (without limits and freezing) are:","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"beginalign\n dotp_textflt = frac1T_p (p_e - p_textflt) tag5a \n dotxi_P = p_texterr tag5b \n dotp_textext = frac1T_g (K_pg p_texterr + K_ig xi_P) tag5c \n dotp_textord = frac1T_textpord (p_textext - p_textord) tag5d\nendalign","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"with","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"beginalign\n p_e = v_ri_r + v_ii_i tag5e \n p_texterr = p_textref + p_textdroop - p_textflt tag5f \nendalign","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"In the case of F_Flag = 0 the equations (without limits) are simply","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"beginalign\n dotp_textord = frac1T_textpord (p_textref - p_textord) tag5g\nendalign","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"The current command going to the Inner Loop is computed as:","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"beginalign\n I_textocpcmd = fracp_textordV_texttflt tag5h\nendalign","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"on which V_texttflt is the filtered terminal bus voltage coming from the inner controller.","category":"page"},{"location":"component_models/outer_control/#Reactive-part","page":"Outer Control","title":"Reactive part","text":"","category":"section"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"In the case of VC_Flag = 0, Ref_Flag = 0, PF_Flag = 0, V_Flag = 1 the equations (without limits and freezing) are:","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"beginalign\n dotq_textflt = frac1T_textfltr (q_e - q_textflt) tag5i \n dotxi_textqoc = q_texterr tag5j \n dotq_LL = frac1T_fv(Q_textpi ( 1 - T_ftT_fv) - q_LL) tag5k \n dotxi_Q = V_textpiin tag5l \nendalign","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"with","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"beginalign\n q_e = v_ii_r - v_ri_i tag5m \n q_texterr = q_textref - q_flt tag5n \n Q_textpi = K_p q_texterr + K_i xi_textqoc tag5o \n Q_textext = q_LL + fracT_ftT_fv Q_textpi tag5p \n V_textpiin = Q_textext - q_e tag5q \nendalign","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"The output to the inner controller are V_textocqcmd if the Q_Flag = 1 on the Inner Controller, or I_textocqcmd if Q_Flag = 0:","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"beginalign\n V_textocqcmd = (K_qp V_textpiin + K_qi xi_Q) - V_texttflt tag5r \n I_textocqmcd = fracQ_textextmax(V_texttflt 001) tag5s\nendalign","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"In the case of VC_Flag = 0, Ref_Flag = 0, PF_Flag = 0, V_Flag = 1 the equations (without limits and freezing) are:","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"beginalign\n dotq_textflt = frac1T_textfltr (q_e - q_textflt) tag5t \n dotxi_textqoc = q_texterr tag5u \n dotq_LL = frac1T_fv(Q_textpi ( 1 - T_ftT_fv) - q_LL) tag5v \nendalign","category":"page"},{"location":"component_models/outer_control/","page":"Outer Control","title":"Outer Control","text":"The remaining models for other flags will be included when implemented in PowerSimulationsDynamics.jl.","category":"page"},{"location":"perturbations/#Perturbations","page":"Perturbations","title":"Perturbations","text":"","category":"section"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"Perturbations are used to alter the system from its steady state operation. If a Simulation is properly initialized, all states will remain fixed in their initial condition if no perturbation is applied to the system.","category":"page"},{"location":"perturbations/#List-of-perturbations","page":"Perturbations","title":"List of perturbations","text":"","category":"section"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"NetworkSwitch: allows to modify directly the admittance matrix, Ybus, used in the Simulation.\nBranchTrip: completely disconnects a branch from the system.\nBranchImpedanceChange: change the impedance of a branch by a user defined multiplier. \nGeneratorTrip: allows to disconnect a Dynamic Generation unit from the system.\nControlReferenceChange: allows to change the reference setpoint provided by a generator/inverter.\nLoadChange: allows to change the active or reactive power setpoint from a load.\nLoadTrip: allows the user to disconnect a load from the system.\nSourceBusVoltageChange: allows to change the reference setpoint provided by a voltage source.","category":"page"},{"location":"perturbations/#Examples","page":"Perturbations","title":"Examples","text":"","category":"section"},{"location":"perturbations/#Example-1:-Circuit-Disconnection-using-NetworkSwitch","page":"Perturbations","title":"Example 1: Circuit Disconnection using NetworkSwitch","text":"","category":"section"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"Consider a two bus system connected via a double circuit line, on which each circuit has parameters, r = 0.0, x = 0.1, b = 0.0 per unit, then the admittance matrix of the original system is given by:","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"yb = [0.0 - 20.0im 0.0 + 20.0im\n 0.0 + 20.0im 0.0 - 20.0im]","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"Triping one circuit can be modeled by doubling the impedance, i.e., dividing by 2 the admittance:","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"new_yb = [0.0 - 10.0im 0.0 + 10.0im\n 0.0 + 10.0im 0.0 - 10.0im]","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"To apply a Network Switch, we require to use a sparse matrix, so we can do this by simply:","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"using SparseArrays\nnew_yb = sparse(new_yb)","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"Then, this perturbation ocurring at t = 10 seconds can be included as:","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"ns1 = NetworkSwitch(1.0, new_yb)","category":"page"},{"location":"perturbations/#Example-2:-Three-Phase-Fault-using-NetworkSwitch","page":"Perturbations","title":"Example 2: Three Phase Fault using NetworkSwitch","text":"","category":"section"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"Another perturbation that can be modeled is a three phase fault at Bus 1 with impedance r_f = 0.0001, x_f = 0.0 per unit, then the admittance of this new system is:","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"new_yb2 = [10000.0 - 20.0im 0.0 + 20.0im\n 0.0 + 20.0im 0.0 - 20.0im]","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"Then, this perturbation ocurring at t = 10 seconds can be included as:","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"new_yb2 = sparse(new_yb2)\nns2 = NetworkSwitch(1.0, new_yb2)","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"Now, consider that the fault is cleared at t = 105 seconds by disconnecting the Circuit 2 of the line. This can be modeled with the single circuit admittance matrix:","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"new_yb3 = [0.0 - 10.0im 0.0 + 10.0im\n 0.0 + 10.0im 0.0 - 10.0im]","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"and the perturbation as:","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"new_yb3 = sparse(new_yb3)\nns3 = NetworkSwitch(1.05, new_yb3)","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"Then, the entire perturbation for the Simulation can be included in a vector of perturbations as:","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"three_fault = [ns2, ns3]","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"that can be passed as a perturbation argument in the Simulation construction.","category":"page"},{"location":"perturbations/#Example-3:-BranchTrip","page":"Perturbations","title":"Example 3: BranchTrip","text":"","category":"section"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"Consider the following 2 bus system defined by:","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"buses = [\n Bus(1, \"nodeA\", \"REF\", 0, 1.0, (min = 0.9, max = 1.05), 230, nothing, nothing),\n Bus(2, \"nodeB\", \"PV\", 0, 1.0, (min = 0.9, max = 1.05), 230, nothing, nothing),\n]\n\nline1 = Line(\n \"Circuit1\",\n true,\n 0.0,\n 0.0,\n Arc(from = buses[1], to = buses[2]),\n 0.00,\n 0.1,\n (from = 0.0, to = 0.0),\n 2.0,\n (min = -0.7, max = 0.7),\n )\nline2 = Line(\n \"Circuit2\",\n true,\n 0.0,\n 0.0,\n Arc(from = buses[1], to = buses[2]),\n 0.0,\n 0.1,\n (from = 0.0, to = 0.0),\n 2.0,\n (min = -0.7, max = 0.7),\n )\n\nsys = System(100.0, buses, [], [], [line1, line2])","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"A Branch Trip of Circuit 2 at time t = 10 seconds, can be implemented as:","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"b_trip = BranchTrip(1.0, Line, \"Circuit2\")","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"Note: Islanding is currently not supported in PowerSimulationsDynamics.jl. If a BranchTrip isolates a generation unit, the system may diverge due to the isolated generator.","category":"page"},{"location":"perturbations/#Example-4:-BranchImpedanceChange","page":"Perturbations","title":"Example 4: BranchImpedanceChange","text":"","category":"section"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"Following the same example as before, it is possible to amplify the impedance of a single circuit by 2.0 (that would represent that this Circuit is actually composed by 2 circuits) using the following perturbation:","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"b_change = BranchImpedanceChange(1.0, Line, \"Circuit2\", 2.0)","category":"page"},{"location":"perturbations/#Example-5:-GeneratorTrip","page":"Perturbations","title":"Example 5: GeneratorTrip","text":"","category":"section"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"Consider that you have a generator at bus 102, named \"generator-102-1\" in your system called sys. The constructor to trip it from the system is:","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"g = get_component(DynamicGenerator, sys, \"generator-102-1\")\ng_trip = GeneratorTrip(1.0, g)","category":"page"},{"location":"perturbations/#Example-6:-ControlReferenceChange","page":"Perturbations","title":"Example 6: ControlReferenceChange","text":"","category":"section"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"Consider that you have a generator at bus 102, named \"generator-102-1\" in your system called sys. The constructor to change is active power reference to 0.5 is:","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"g = get_component(DynamicGenerator, sys, \"generator-102-1\")\ncrc = ControlReferenceChange(1.0, g, :P_ref, 0.5)","category":"page"},{"location":"perturbations/#Example-7:-LoadChange","page":"Perturbations","title":"Example 7: LoadChange","text":"","category":"section"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"Consider that you have a load at bus 103, named \"load-103-1\" in your system called sys. The constructor to change is active power reference to 0.8 per unit at t = 10 seconds is:","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"l_device = get_component(ElectricLoad, sys, \"load-103-1\")\nl_change = LoadChange(1.0, l_device, :P_ref, 0.8)","category":"page"},{"location":"perturbations/#Example-8:-LoadTrip","page":"Perturbations","title":"Example 8: LoadTrip","text":"","category":"section"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"Consider that you have a load at bus 103, named \"load-103-1\" in your system called sys. The constructor to disconnect such load at t = 10 seconds is:","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"l_device = get_component(ElectricLoad, sys, \"load-103-1\")\nl_trip = LoadTrip(1.0, l_device)","category":"page"},{"location":"perturbations/#Example-9:-SourceBusVoltageChange","page":"Perturbations","title":"Example 9: SourceBusVoltageChange","text":"","category":"section"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"Consider that you have a voltage source at bus 101, named \"source-101-1\" in your system called sys. The constructor to change is voltage magnitude reference to 1.02 per unit at t = 10 seconds is:","category":"page"},{"location":"perturbations/","page":"Perturbations","title":"Perturbations","text":"s_device = get_component(Source, sys, \"source-101-1\")\ns_change = SourceBusVoltageChange(1.0, s_device, 1, 1.02)","category":"page"},{"location":"component_models/machines/#Machines","page":"Machine","title":"Machines","text":"","category":"section"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"The machine component describes the stator-rotor electromagnetic dynamics.","category":"page"},{"location":"component_models/machines/#Classical-Model-(Zero-Order)-[BaseMachine]","page":"Machine","title":"Classical Model (Zero Order) [BaseMachine]","text":"","category":"section"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"This is the classical order model that does not have differential equations in its machine model (delta and omega are defined in the shaft):","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"beginalign\n left beginarrayc i_d i_q endarray right = left beginarraycc r_a -x_d x_d r_a endarray right^-1 left beginarrayc -v_d e_q - v_q endarray right tag1a\np_e approx tau_e = (v_q + r_a i_q)i_q + (v_d + r_ai_d)i_d tag1b\nendalign","category":"page"},{"location":"component_models/machines/#One-d-One-q-Model-(2nd-Order)-[OneDOneQMachine]","page":"Machine","title":"One d- One q- Model (2nd Order) [OneDOneQMachine]","text":"","category":"section"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"This model includes two transient emf with their respective differential equations:","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"beginalign\ndote_q = frac1T_d0 left-e_q + (x_d-x_d)i_d + v_fright tag2a\ndote_d = frac1T_q0 left-e_d + (x_q-x_q)i_q right tag2b\n left beginarrayc i_d i_q endarray right = left beginarraycc r_a -x_q x_d r_a endarray right^-1 left beginarrayc e_d-v_d e_q - v_q endarray right tag2c\np_e approx tau_e = (v_q + r_a i_q)i_q + (v_d + r_ai_d)i_d tag2d\nendalign","category":"page"},{"location":"component_models/machines/#Marconato-Machine-(6th-Order)-[MarconatoMachine]","page":"Machine","title":"Marconato Machine (6th Order) [MarconatoMachine]","text":"","category":"section"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"The Marconato model defines 6 differential equations, two for stator fluxes and 4 for transient and subtransient emfs:","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"beginalign\ndotpsi_d = Omega_b(r_ai_d + omega psi_q + v_d) tag3a \ndotpsi_q = Omega_b(r_ai_q - omega psi_d + v_q) tag3b \ndote_q = frac1T_d0 left-e_q - (x_d-x_d-gamma_d)i_d + left(1- fracT_AAT_d0 right) v_fright tag3c\ndote_d = frac1T_q0 left-e_d + (x_q-x_q-gamma_q)i_q right tag3d\ndote_q = frac1T_d0 left-e_q + e_q - (x_d-x_d+gamma_d)i_d + fracT_AAT_d0v_f right tag3e \ndote_d = frac1T_q0 left-e_d + e_d + (x_q-x_q+gamma_q)i_q right tag3f \ni_d = frac1x_d (e_q - psi_d) tag3g \ni_q = frac1x_q (-e_d - psi_q) tag3h \ntau_e = psi_d i_q - psi_q i_d tag3i\nendalign","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"with","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"beginalign*\n gamma_d = fracT_d0 x_dT_d0 x_d (x_d - x_d) \n gamma_q = fracT_q0 x_qT_q0 x_q (x_q - x_q)\nendalign*","category":"page"},{"location":"component_models/machines/#Simplified-Marconato-Machine-(4th-Order)-[SimpleMarconatoMachine]","page":"Machine","title":"Simplified Marconato Machine (4th Order) [SimpleMarconatoMachine]","text":"","category":"section"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"This model neglects the derivative of stator fluxes (dotpsi_d and dotpsi_q) and assume that the rotor speed stays close to 1 pu (omegapsi_d=psi_d and omegapsi_q=psi_q) that allows to remove the stator fluxes variables from the Marconato model.","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"beginalign\ndote_q = frac1T_d0 left-e_q - (x_d-x_d-gamma_d)i_d + left(1- fracT_AAT_d0 right) v_fright tag4a\ndote_d = frac1T_q0 left-e_d + (x_q-x_q-gamma_q)i_q right tag4b\ndote_q = frac1T_d0 left-e_q + e_q - (x_d-x_d+gamma_d)i_d + fracT_AAT_d0v_f right tag4c \ndote_d = frac1T_q0 left-e_d + e_d + (x_q-x_q+gamma_q)i_q right tag4d \nleft beginarrayc i_d i_q endarray right = left beginarraycc r_a -x_q x_d r_a endarray right^-1 left beginarrayc e_d-v_d e_q - v_q endarray right tag4e\np_e approx tau_e = (v_q + r_a i_q)i_q + (v_d + r_ai_d)i_d tag4f\nendalign","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"with","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"beginalign*\n gamma_d = fracT_d0 x_dT_d0 x_d (x_d - x_d) \n gamma_q = fracT_q0 x_qT_q0 x_q (x_q - x_q)\nendalign*","category":"page"},{"location":"component_models/machines/#Anderson-Fouad-Machine-(6th-Order)-[AndersonFouadMachine]","page":"Machine","title":"Anderson-Fouad Machine (6th Order) [AndersonFouadMachine]","text":"","category":"section"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"The Anderson-Fouad model also defines 6 differential equations, two for stator fluxes and 4 for transient and subtransient emfs and is derived from the Marconato model by defining gamma_d approx gamma_q approx T_AA approx 0:","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"beginalign\ndotpsi_d = Omega_b(r_ai_d + omega psi_q + v_d) tag5a \ndotpsi_q = Omega_b(r_ai_q - omega psi_d + v_q) tag5b \ndote_q = frac1T_d0 left-e_q - (x_d-x_d)i_d + v_fright tag5c\ndote_d = frac1T_q0 left-e_d + (x_q-x_q)i_q right tag5d\ndote_q = frac1T_d0 left-e_q + e_q - (x_d-x_d)i_d right tag5e \ndote_d = frac1T_q0 left-e_d + e_d + (x_q-x_q)i_q right tag5f \ni_d = frac1x_d (e_q - psi_d) tag5g \ni_q = frac1x_q (-e_d - psi_q) tag5h \ntau_e = psi_d i_q - psi_q i_d tag5i\nendalign","category":"page"},{"location":"component_models/machines/#Simplified-Anderson-Fouad-Machine-(4th-Order)-[SimpleAFMachine]","page":"Machine","title":"Simplified Anderson-Fouad Machine (4th Order) [SimpleAFMachine]","text":"","category":"section"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"Similar to the Simplified Marconato Model, this model neglects the derivative of stator fluxes (dotpsi_d and dotpsi_q) and assume that the rotor speed stays close to 1 pu (omega psi_d = psi_d and omega psi_q = psi_q) that allows to remove the stator fluxes variables from the model:","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"beginalign\ndote_q = frac1T_d0 left-e_q - (x_d-x_d)i_d + v_fright tag6a\ndote_d = frac1T_q0 left-e_d + (x_q-x_q)i_q right tag6b\ndote_q = frac1T_d0 left-e_q + e_q - (x_d-x_d)i_d right tag6c \ndote_d = frac1T_q0 left-e_d + e_d + (x_q-x_q)i_q right tag6d \nleft beginarrayc i_d i_q endarray right = left beginarraycc r_a -x_q x_d r_a endarray right^-1 left beginarrayc e_d-v_d e_q - v_q endarray right tag6e\np_e approx tau_e = (v_q + r_a i_q)i_q + (v_d + r_ai_d)i_d tag6f\nendalign","category":"page"},{"location":"component_models/machines/#Round-Rotor-Machine-(4th-Order)-[RoundRotorQuadratic,-RoundRotorExponential]","page":"Machine","title":"Round Rotor Machine (4th Order) [RoundRotorQuadratic, RoundRotorExponential]","text":"","category":"section"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"This model represents the traditional round rotor models GENROU/GENROE models implemented in PSLF/PSSE/PowerWorld. Similar to the Simplified Marconato Model, this model neglects the derivative of stator fluxes (dotpsi_d and dotpsi_q). Round rotor machines must satisfy x_d = x_q.","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"beginalign\ndote_q = frac1T_d0 leftv_f - X_adI_fdright tag7a\ndote_d = frac1T_q0 left-X_aqI_1q right tag7b\ndotpsi_kd = frac1T_d0 left-psi_kd + e_q - (x_d-x_l)i_d right tag7c \ndotpsi_kq = frac1T_q0 left-psi_kq + e_d + (x_q-x_l)i_q right tag7d \nendalign","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"with:","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"beginalign\ngamma_d1 = fracx_d - x_lx_d - x_l tag7e\ngamma_q1 = fracx_q - x_lx_q - x_l tag7f\ngamma_d2 = fracx_d - x_d(x_d-x_l)^2 tag7g\ngamma_q2 = fracx_q - x_q(x_q - x_l)^2 tag7h\ngamma_qd = fracx_q - x_lx_d - x_l tag7i\npsi_q = gamma_q1 e_d + psi_kq (1 - gamma_q1) tag7j\npsi_d = gamma_d1 e_q + gamma_d2 (x_d - x_l) psi_kd tag7k\npsi = sqrt(psi_d)^2 + (psi_q)^2 tag7l\nleft beginarrayc i_d i_q endarray right = left beginarraycc -r_a x_q -x_d r_a endarray right^-1 left beginarrayc v_d - psi_q -v_q + psi_d endarray right tag7m\nX_adI_fd = e_q + (x_d - x_d) (gamma_d1 i_d - gamma_d2 psi_kd + gamma_d2 + e_q) + textSe(psi) psi_d tag7n\nX_aqI_1q = e_d + (x_q - x_q) (gamma_q2 e_d - gamma_q2psi_kq - gamma_q1 i_q) + textSe(psi) psi_q gamma_qd tag7o \ntau_e = i_d (r_a i_d + v_d) + i_q(r_a i_q + v_q) tag7p\nendalign","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"The difference between GENROU and GENROE occurs in which additive saturation function textSe(psi) is used. Input data is provided by the saturation values at psi = 10 and psi = 12 p.u. For the GENROU model, the function used is:","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"beginalign\ntextSe(psi) = fracB(psi - A)^2 psi tag7q\nendalign","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"and for the GENROE model the function used is:","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"beginalign\ntextSe(psi) = B(psi)^A tag7r\nendalign","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"The parameters A and B for each function are computed using the two points given (10 textSe(10)) and (12 textSe(12)).","category":"page"},{"location":"component_models/machines/#Salient-Pole-Machine-(3rd-Order)-[SalientPoleQuadratic,-SalientPoleExponential]","page":"Machine","title":"Salient Pole Machine (3rd Order) [SalientPoleQuadratic, SalientPoleExponential]","text":"","category":"section"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"This model represents the traditional round rotor models GENSAL/GENSAE models implemented in PSLF/PSSE/PowerWorld. Similar to the GENROU Model, this model neglects the derivative of stator fluxes (dotpsi_d and dotpsi_q).","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"beginalign\ndote_q = frac1T_d0 leftv_f - X_adI_fdright tag8a\ndotpsi_kd = frac1T_d0 left-psi_kd + e_q - (x_d-x_l)i_d right tag8b \ndotpsi_q = frac1T_q0 left-psi_q - (x_q-x_q)i_q right tag8c \nendalign","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"with:","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"beginalign\ngamma_d1 = fracx_d - x_lx_d - x_l tag8d\ngamma_q1 = fracx_q - x_lx_q - x_l tag8e\ngamma_d2 = fracx_d - x_d(x_d-x_l)^2 tag8f\npsi_d = gamma_d1 e_q + gamma_q1 psi_kd tag8g\nleft beginarrayc i_d i_q endarray right = left beginarraycc -r_a x_q -x_d r_a endarray right^-1 left beginarrayc v_d - psi_q -v_q + psi_d endarray right tag8h\nX_adI_fd = e_q + textSe(e_q) e_q + (x_d - x_d) (i_d + gamma_d2 (e_q - psi_kd - (x_d - x_l)i_d) tag8i\ntau_e = i_d (r_a i_d + v_d) + i_q(r_a i_q + v_q) tag8j\nendalign","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"The difference between GENSAL and GENSAE occurs in which additive saturation function textSe(e_q) is used. Input data is provided by the saturation values at e_q = 10 and e_q = 12 p.u. For the GENSAL model, the function used is:","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"beginalign\ntextSe(e_q) = fracB(e_q - A)^2 e_q tag8k\nendalign","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"and for the GENSAE model the function used is:","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"beginalign\ntextSe(e_q) = B(e_q)^A tag8l\nendalign","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"The parameters A and B for each function are computed using the two points given (10 textSe(10)) and (12 textSe(12)).","category":"page"},{"location":"component_models/machines/#SauerPai-Machine-(6th-Order)-[SauerPaiMachine]","page":"Machine","title":"SauerPai Machine (6th Order) [SauerPaiMachine]","text":"","category":"section"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"The Sauer Pai model defines 6 differential equations as follows:","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"beginalign\ndotpsi_d = Omega_b(r_ai_d + omega psi_q + v_d) tag9a \ndotpsi_q = Omega_b(r_ai_q - omega psi_d + v_q) tag9b \ndote_q = frac1T_d0 left(-e_q - (x_d - x_d)(i_d + gamma_d2 cdot dotpsi_d) + v_f)right tag9c\ndote_q = frac1T_q0 left(-e_d + (x_q - x_q)(i_q + gamma_q2 cdot dotpsi_q))right tag9d\ndotpsi_d = frac1T_d0 left(-psi_d + e_q - (x_d - x_l)cdot i_d)right tag9e \ndotpsi_q = frac1T_q0 left(-psi_q - e_d - (x_q - x_l)cdot i_q)right tag9f \ni_d = frac1x_d (gamma_d1 cdot e_q - psi_d + (1 - gamma_d1) * psi_d) tag9g \ni_q = frac1x_q ((-gamma_q1 cdot e_d - psi_q + (1 - gamma_q1) cdot psi_q) tag9h \ntau_e = psi_d i_q - psi_q i_d tag9i\nendalign","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"with","category":"page"},{"location":"component_models/machines/","page":"Machine","title":"Machine","text":"beginalign*\n gamma_d1 = fracx_d - x_lx_d - x_l \n gamma_q1 = fracx_q - x_lx_q - x_l \n gamma_d2 = frac1 - gamma_d1x_d - x_l \n gamma_q2 = frac1 - gamma_q1x_q - x_l\nendalign*","category":"page"},{"location":"component_models/shafts/#Shafts","page":"Shaft","title":"Shafts","text":"","category":"section"},{"location":"component_models/shafts/","page":"Shaft","title":"Shaft","text":"The shaft component defines the rotating mass of the synchronous generator.","category":"page"},{"location":"component_models/shafts/#Rotor-Mass-Shaft-[SingleMass]","page":"Shaft","title":"Rotor Mass Shaft [SingleMass]","text":"","category":"section"},{"location":"component_models/shafts/","page":"Shaft","title":"Shaft","text":"This is the standard model, on which one single mass (typically the rotor) is used to model the entire inertia of the synchronous generator. Each generator's rotating frame use a reference frequency omega_s, that typically is the synchronous one (i.e. omega_s = 10). The model defines two differential equations for the rotor angle delta and the rotor speed omega:","category":"page"},{"location":"component_models/shafts/","page":"Shaft","title":"Shaft","text":"beginalign\ndotdelta = Omega_b(omega - omega_s) tag1a \ndotomega = frac12H(tau_m - tau_e - D(omega-omega_s)) tag1b\nendalign","category":"page"},{"location":"component_models/shafts/#Five-Mass-Shaft-[FiveMassShaft]","page":"Shaft","title":"Five-Mass Shaft [FiveMassShaft]","text":"","category":"section"},{"location":"component_models/shafts/","page":"Shaft","title":"Shaft","text":"This model describes model connecting a high-pressure (hp) steam turbine, intermediate-pressure (ip) steam turbine, low-pressure (lp) steam pressure, rotor and exciter (ex) connected in series (in that order) in the same shaft using a spring-mass model:","category":"page"},{"location":"component_models/shafts/","page":"Shaft","title":"Shaft","text":"beginalign\ndotdelta = Omega_b(omega - omega_s) tag2a \ndotomega = frac12H left- tau_e - D(omega-omega_s)) - D_34 (omega-omega_lp) - D_45(omega-omega_ex) + K_lp(delta_lp-delta) +K_ex(delta_ex-delta) right tag2b \ndotdelta_hp = Omega_b(omega_hp - omega_s) tag2c \ndotomega_hp = frac12H_hp left tau_m - D_hp(omega_hp-omega_s) - D_12(omega_hp - omega_ip) + K_hp(delta_ip - delta_hp) right tag2d \ndotdelta_ip = Omega_b(omega_ip - omega_s) tag2e \ndotomega_ip = frac12H_ip left- D_ip(omega_ip-omega_s) - D_12(omega_ip - omega_hp) -D_23(omega_ip - omega_lp ) + K_hp(delta_hp - delta_ip) + K_ip(delta_lp-delta_ip) right tag2f \ndotdelta_lp = Omega_b(omega_lp-omega_s) tag2g \ndotomega_lp = frac12H_lp left - D_lp(omega_lp-omega_s) - D_23(omega_lp - omega_ip) -D_34(omega_lp - omega ) + K_ip(delta_ip - delta_lp) + K_lp(delta-delta_lp) right tag2h \ndotdelta_ex = Omega_b(omega_ex-omega_s) tag2i \ndotomega_ex = frac12H_ex left - D_ex(omega_ex-omega_s) - D_45(omega_ex - omega) + K_ex(delta - delta_ex) right tag2j\nendalign","category":"page"},{"location":"api/public/#PowerSimulationsDynamics","page":"Public API Reference","title":"PowerSimulationsDynamics","text":"","category":"section"},{"location":"api/public/","page":"Public API Reference","title":"Public API Reference","text":"CurrentModule = PowerSimulationsDynamics\nDocTestSetup = quote\n using PowerSimulationsDynamics\nend","category":"page"},{"location":"api/public/","page":"Public API Reference","title":"Public API Reference","text":"Modules = [PowerSimulationsDynamics]\nPublic = true\nPrivate = false","category":"page"},{"location":"api/public/#PowerSimulationsDynamics.BranchImpedanceChange","page":"Public API Reference","title":"PowerSimulationsDynamics.BranchImpedanceChange","text":"mutable struct BranchImpedanceChange <: Perturbation\n time::Float64\n branch_type::Type{<:PSY.ACBranch}\n branch_name::String\n multiplier::Float64\nend\n\nA BranchImpedanceChange change the impedance of a branch by a user defined multiplier. Currently there is only support for static branches disconnection, PowerSystems.Line and PowerSystems.Transformer2W. Future releases will provide support for a Dynamic Line disconnection.\n\nArguments:\n\ntime::Float64 : Defines when the Branch Impedance Change will happen. This time should be inside the time span considered in the Simulation\nbranch_tipe::Type{<:PowerSystems.ACBranch} : Type of branch modified\nbranch_name::String : User defined name for identifying the branch\nmultiplier::Float64 : User defined value for impedance multiplier.\n\n\n\n\n\n","category":"type"},{"location":"api/public/#PowerSimulationsDynamics.BranchTrip","page":"Public API Reference","title":"PowerSimulationsDynamics.BranchTrip","text":"mutable struct BranchTrip <: Perturbation\n time::Float64\n branch_type::Type{<:PowerSystems.ACBranch}\n branch_name::String\nend\n\nA BranchTrip completely disconnects a branch from the system. Currently there is only support for static branches disconnection, PowerSystems.Line and PowerSystems.Transformer2W. Future releases will provide support for a Dynamic Line disconnection. Note: Islanding is currently not supported in PowerSimulationsDynamics.jl. If a BranchTrip isolates a generation unit, the system may diverge due to the isolated generator.\n\nArguments:\n\ntime::Float64 : Defines when the Branch Trip will happen. This time should be inside the time span considered in the Simulation\nbranch_tipe::Type{<:PowerSystems.ACBranch} : Type of branch disconnected\nbranch_name::String : User defined name for identifying the branch\n\n\n\n\n\n","category":"type"},{"location":"api/public/#PowerSimulationsDynamics.ControlReferenceChange","page":"Public API Reference","title":"PowerSimulationsDynamics.ControlReferenceChange","text":"mutable struct ControlReferenceChange <: Perturbation\n time::Float64\n device::PowerSystems.DynamicInjection\n signal::Symbol\n ref_value::Float64\nend\n\nA ControlReferenceChange allows to change the reference setpoint provided by a generator/inverter.\n\nArguments:\n\ntime::Float64 : Defines when the Control Reference Change will happen. This time should be inside the time span considered in the Simulation\ndevice::Type{<:PowerSystems.DynamicInjection} : Dynamic device modified\nsignal::Symbol : determines which reference setpoint will be modified. The accepted signals are:\n:P_ref: Modifies the active power reference setpoint.\n:V_ref: Modifies the voltage magnitude reference setpoint (if used).\n:Q_ref: Modifies the reactive power reference setpoint (if used).\n:ω_ref: Modifies the frequency setpoint.\nref_value::Float64 : User defined value for setpoint reference.\n\n\n\n\n\n","category":"type"},{"location":"api/public/#PowerSimulationsDynamics.GeneratorTrip","page":"Public API Reference","title":"PowerSimulationsDynamics.GeneratorTrip","text":"mutable struct GeneratorTrip <: Perturbation\n time::Float64\n device::PowerSystems.DynamicInjection\nend\n\nA GeneratorTrip allows to disconnect a Dynamic Generation unit from the system at a specified time.\n\nArguments:\n\ntime::Float64 : Defines when the Generator Trip will happen. This time should be inside the time span considered in the Simulation\ndevice::Type{<:PowerSystems.DynamicInjection} : Device to be disconnected\n\n\n\n\n\n","category":"type"},{"location":"api/public/#PowerSimulationsDynamics.LoadChange","page":"Public API Reference","title":"PowerSimulationsDynamics.LoadChange","text":"mutable struct LoadChange <: Perturbation\n time::Float64\n device::PowerSystems.ElectricLoad\n signal::Symbol\n ref_value::Float64\nend\n\nA LoadChange allows to change the active or reactive power setpoint from a load.\n\nArguments:\n\ntime::Float64 : Defines when the Load Change will happen. This time should be inside the time span considered in the Simulation\ndevice::Type{<:PowerSystems.ElectricLoad} : Dynamic device modified\nsignal::Symbol : determines which reference setpoint will be modified. The accepted signals are:\n:P_ref: Modifies the active power reference setpoint.\n:Q_ref: Modifies the reactive power reference setpoint.\nref_value::Float64 : User defined value for setpoint reference.\n\n\n\n\n\n","category":"type"},{"location":"api/public/#PowerSimulationsDynamics.LoadTrip","page":"Public API Reference","title":"PowerSimulationsDynamics.LoadTrip","text":"mutable struct LoadTrip <: Perturbation\n time::Float64\n device::PowerSystems.ElectricLoad\nend\n\nA LoadTrip allows the user to disconnect a load from the system.\n\nArguments:\n\ntime::Float64 : Defines when the Generator Trip will happen. This time should be inside the time span considered in the Simulation\ndevice::Type{<:PowerSystems.ElectricLoad} : Device to be disconnected\n\n\n\n\n\n","category":"type"},{"location":"api/public/#PowerSimulationsDynamics.MassMatrixModel-Union{Tuple{Ctype}, Tuple{Any, Vector{Float64}, Type{Ctype}}} where Ctype<:PowerSimulationsDynamics.SimCache","page":"Public API Reference","title":"PowerSimulationsDynamics.MassMatrixModel","text":"Instantiate a MassMatrixModel for ODE inputs.\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.MassMatrixModel-Union{Tuple{Ctype}, Tuple{T}, Tuple{PowerSimulationsDynamics.SimulationInputs, Vector{T}, Type{Ctype}}} where {T<:Float64, Ctype<:PowerSimulationsDynamics.JacobianCache}","page":"Public API Reference","title":"PowerSimulationsDynamics.MassMatrixModel","text":"Instantiate a MassMatrixModel for ForwardDiff calculations\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.NetworkSwitch","page":"Public API Reference","title":"PowerSimulationsDynamics.NetworkSwitch","text":"function NetworkSwitch(\n time::Float64,\n ybus::SparseArrays.SparseMatrixCSC{Complex{Float64}, Int},\n)\n\nAllows to modify directly the admittance matrix, Ybus, used in the Simulation. This allows the user to perform branch modifications, three phase faults (with impedance larger than zero) or branch trips, as long as the new Ybus provided captures that perturbation.\n\nArguments:\n\ntime::Float64 : Defines when the Network Switch will happen. This time should be inside the time span considered in the Simulation\nybus::SparseArrays.SparseMatrixCSC{Complex{Float64}, Int} : Complex admittance matrix\n\n\n\n\n\n","category":"type"},{"location":"api/public/#PowerSimulationsDynamics.PerturbState","page":"Public API Reference","title":"PowerSimulationsDynamics.PerturbState","text":"function PerturbState(\n time::Float64,\n index::Int,\n value::Float64,\n)\n\nAllows the user to modify the state index by adding value. The user should modify dynamic states only, since algebraic state may require to do a reinitialization.\n\nArguments:\n\ntime::Float64 : Defines when the modification of the state will happen. This time should be inside the time span considered in the Simulation.\nindex::Int : Defines which state index you want to modify\nvalue::Float64 : Defines how much the state will increase in value\n\n\n\n\n\n","category":"type"},{"location":"api/public/#PowerSimulationsDynamics.ResidualModel-Union{Tuple{Ctype}, Tuple{Any, Vector{Float64}, Type{Ctype}}} where Ctype<:PowerSimulationsDynamics.SimCache","page":"Public API Reference","title":"PowerSimulationsDynamics.ResidualModel","text":"Instantiate an ResidualModel for ODE inputs.\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.ResidualModel-Union{Tuple{Ctype}, Tuple{T}, Tuple{PowerSimulationsDynamics.SimulationInputs, Vector{T}, Type{Ctype}}} where {T<:Float64, Ctype<:PowerSimulationsDynamics.JacobianCache}","page":"Public API Reference","title":"PowerSimulationsDynamics.ResidualModel","text":"Instantiate an ResidualModel for ForwardDiff calculations\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.Simulation-Union{Tuple{T}, Tuple{Type{T}, System, String, Tuple{Float64, Float64}}, Tuple{Type{T}, System, String, Tuple{Float64, Float64}, Vector{<:PowerSimulationsDynamics.Perturbation}}} where T<:PowerSimulationsDynamics.SimulationModel","page":"Public API Reference","title":"PowerSimulationsDynamics.Simulation","text":"function Simulation\n ::SimulationModel\n system::PowerSystems.System\n simulation_folder::String\n tspan::NTuple{2, Float64},\n perturbations::Vector{<:Perturbation} = Vector{Perturbation}();\n kwargs...,\nend\n\nBuilds the simulation object and conducts the indexing process. The original system is not modified and a copy its created and stored in the Simulation.\n\nArguments:\n\n::SimulationModel : Type of Simulation Model. ResidualModel or MassMatrixModel. See Models Section for more details\nsystem::PowerSystems.System : System data\nsimulation_folder::String : Folder directory\ntspan::NTuple{2, Float64} : Time span for simulation\nperturbations::Vector{<:Perturbation} : Vector of Perturbations for the Simulation. Default: No Perturbations\ninitialize_simulation::Bool : Runs the initialization routine. If false, simulation runs based on the operation point stored in System\ninitial_conditions::Vector{Float64} : Allows the user to pass a vector with the initial condition values desired in the simulation. If initialize_simulation = true, these values are used as a first guess and overwritten.\nfrequency_reference : Default ReferenceBus. Determines which frequency model is used for the network. Currently there are two options available:\nConstantFrequency assumes that the network frequency is 1.0 per unit at all times.\nReferenceBus will use the frequency state of a Dynamic Generator (rotor speed) or Dynamic Inverter (virtual speed) connected to the Reference Bus (defined in the Power Flow data) as the network frequency. If multiple devices are connected to such bus, the device with larger base power will be used as a reference. If a Voltage Source is connected to the Reference Bus, then a ConstantFrequency model will be used.\nsystem_to_file::Bool : Default false. Serializes the initialized system\nconsole_level::Logging : Default Logging.Warn. Sets the level of logging output to the console. Can be set to Logging.Error, Logging.Warn, Logging.Info or Logging.Debug\nfile_level::Logging : Default Logging.Info. Sets the level of logging output to file. Can be set to Logging.Error, Logging.Warn, Logging.Info or Logging.Debug\ndisable_timer_outputs::Bool : Default false. Allows the user to display timer information about the construction and initilization of the Simulation.\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.SourceBusVoltageChange","page":"Public API Reference","title":"PowerSimulationsDynamics.SourceBusVoltageChange","text":"mutable struct SourceBusVoltageChange <: Perturbation\n time::Float64\n device::PSY.Source\n signal::Symbol\n ref_value::Float64\nend\n\nA SourceBusVoltageChange allows to change the reference setpoint provided by a voltage source.\n\nArguments:\n\ntime::Float64 : Defines when the Control Reference Change will happen. This time should be inside the time span considered in the Simulation\ndevice::Type{<:PowerSystems.Source} : Device modified\nsignal::Symbol : determines which reference setpoint will be modified. The accepted signals are:\n:V_ref Modifies the internal voltage magnitude reference setpoint.\n:θ_ref Modifies the internal voltage angle reference setpoint.\nref_value::Float64 : User defined value for setpoint reference.\n\n\n\n\n\n","category":"type"},{"location":"api/public/#PowerSimulationsDynamics.Simulation!-Union{Tuple{T}, Tuple{Type{T}, System, String, Tuple{Float64, Float64}}, Tuple{Type{T}, System, String, Tuple{Float64, Float64}, Vector{<:PowerSimulationsDynamics.Perturbation}}} where T<:PowerSimulationsDynamics.SimulationModel","page":"Public API Reference","title":"PowerSimulationsDynamics.Simulation!","text":"function Simulation!\n ::SimulationModel\n system::PowerSystems.System\n simulation_folder::String\n tspan::NTuple{2, Float64},\n perturbations::Vector{<:Perturbation} = Vector{Perturbation}();\n kwargs...,\nend\n\nBuilds the simulation object and conducts the indexing process. The initial conditions are stored in the system.\n\nArguments:\n\n::SimulationModel : Type of Simulation Model. ResidualModel or MassMatrixModel. See Models Section for more details\nsystem::PowerSystems.System : System data\nsimulation_folder::String : Folder directory\ntspan::NTuple{2, Float64} : Time span for simulation\nperturbations::Vector{<:Perturbation} : Vector of Perturbations for the Simulation. Default: No Perturbations\ninitialize_simulation::Bool : Runs the initialization routine. If false, simulation runs based on the operation point stored in System\ninitial_conditions::Vector{Float64} : Allows the user to pass a vector with the initial condition values desired in the simulation. If initialize_simulation = true, these values are used as a first guess and overwritten.\nfrequency_reference : Default ReferenceBus. Determines which frequency model is used for the network. Currently there are two options available:\nConstantFrequency assumes that the network frequency is 1.0 per unit at all times.\nReferenceBus will use the frequency state of a Dynamic Generator (rotor speed) or Dynamic Inverter (virtual speed) connected to the Reference Bus (defined in the Power Flow data) as the network frequency. If multiple devices are connected to such bus, the device with larger base power will be used as a reference. If a Voltage Source is connected to the Reference Bus, then a ConstantFrequency model will be used.\nsystem_to_file::Bool : Default false. Serializes the initialized system\nconsole_level::Logging : Default Logging.Warn. Sets the level of logging output to the console. Can be set to Logging.Error, Logging.Warn, Logging.Info or Logging.Debug\nfile_level::Logging : Default Logging.Info. Sets the level of logging output to file. Can be set to Logging.Error, Logging.Warn, Logging.Info or Logging.Debug\ndisable_timer_outputs::Bool : Default false. Allows the user to display timer information about the construction and initilization of the Simulation.\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.execute!-Tuple{Simulation, Any}","page":"Public API Reference","title":"PowerSimulationsDynamics.execute!","text":"execute!(\n sim::Simulation,\n solver;\n kwargs...\n)\n\nSolves the time-domain dynamic simulation model.\n\nArguments\n\nsim::Simulation : Initialized simulation object\nsolver : Solver used for numerical integration. Must be passed correctly depending on the Type of Simulation Model\nenable_progress_bar::Bool : Default: true. Enables progress bar for the integration routine.\nAdditional solver keyword arguments can be included. See Common Solver Options in the DifferentialEquations.jl documentation for more details.\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.get_activepower_branch_flow-Tuple{SimulationResults, String, Symbol}","page":"Public API Reference","title":"PowerSimulationsDynamics.get_activepower_branch_flow","text":"get_activepower_branch_flow(\n res::SimulationResults,\n name::String,\n location::Symbol,\n)\n\nFunction to obtain the active power flowing through the series element of a Branch. The user must specified is the power should be computed in the :from or to :bus, by specifying a symbol.\n\nIf :from is specified, the power is computed flowing outwards the :from bus. If :to is specified, the power is computed flowing into the :to bus.\n\nArguments\n\nres::SimulationResults : Simulation Results object that contains the solution\nname::String : Name to identify the specified line\nlocation::Symbol : :from or :to to specify a bus\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.get_activepower_series-Tuple{SimulationResults, String}","page":"Public API Reference","title":"PowerSimulationsDynamics.get_activepower_series","text":"get_activepower_series(\n res::SimulationResults,\n name::String,\n)\n\nFunction to obtain the active power output time series of a Dynamic Injection series out of the DAE Solution.\n\nArguments\n\nres::SimulationResults : Simulation Results object that contains the solution\nname::String : Name to identify the specified device\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.get_field_current_series-Tuple{SimulationResults, String}","page":"Public API Reference","title":"PowerSimulationsDynamics.get_field_current_series","text":"get_field_current_series(\n res::SimulationResults,\n name::String,\n)\n\nFunction to obtain the field current time series of a Dynamic Generator out of the DAE Solution.\n\nArguments\n\nres::SimulationResults : Simulation Results object that contains the solution\nname::String : Name to identify the specified device\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.get_field_voltage_series-Tuple{SimulationResults, String}","page":"Public API Reference","title":"PowerSimulationsDynamics.get_field_voltage_series","text":"get_field_voltage_series(\n res::SimulationResults,\n name::String,\n)\n\nFunction to obtain the field voltage time series of a Dynamic Generator out of the DAE Solution.\n\nArguments\n\nres::SimulationResults : Simulation Results object that contains the solution\nname::String : Name to identify the specified device\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.get_frequency_series-Tuple{SimulationResults, String}","page":"Public API Reference","title":"PowerSimulationsDynamics.get_frequency_series","text":"get_frequency_series(\n res::SimulationResults,\n name::String,\n)\n\nFunction to obtain the frequency time series of a Dynamic Injection out of the DAE Solution.\n\nArguments\n\nres::SimulationResults : Simulation Results object that contains the solution\nname::String : Name to identify the specified device\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.get_imaginary_current_branch_flow-Tuple{SimulationResults, String}","page":"Public API Reference","title":"PowerSimulationsDynamics.get_imaginary_current_branch_flow","text":"get_imaginary_current_branch_flow(\n res::SimulationResults,\n name::String,\n)\n\nFunction to obtain the imaginary current flowing through the series element of a Branch\n\nArguments\n\nres::SimulationResults : Simulation Results object that contains the solution\nname::String : Name to identify the specified line\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.get_imaginary_current_series-Tuple{SimulationResults, String}","page":"Public API Reference","title":"PowerSimulationsDynamics.get_imaginary_current_series","text":"get_imaginary_current_series(\n res::SimulationResults,\n name::String,\n)\n\nFunction to obtain the imaginary current time series of a Dynamic Injection series out of the DAE Solution.\n\nArguments\n\nres::SimulationResults : Simulation Results object that contains the solution\nname::String : Name to identify the specified device\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.get_jacobian-Union{Tuple{T}, Tuple{Type{T}, System}, Tuple{Type{T}, System, Int64}} where T<:PowerSimulationsDynamics.SimulationModel","page":"Public API Reference","title":"PowerSimulationsDynamics.get_jacobian","text":"function get_jacobian(\n::Type{T},\nsystem::PSY.System,\nsparse_retrieve_loop::Int = 3,\n) where {T <: SimulationModel}\n\nReturns the jacobian function of the system model resulting from the system data.\n\nArguments:\n\n::SimulationModel : Type of Simulation Model. ResidualModel or MassMatrixModel. See Models Section for more details\nsystem::PowerSystems.System : System data\nsparse_retrieve_loop::Int : Number of loops for sparsity detection. If 0, builds the Jacobian with a DenseMatrix\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.get_mechanical_torque_series-Tuple{SimulationResults, String}","page":"Public API Reference","title":"PowerSimulationsDynamics.get_mechanical_torque_series","text":"get_mechanical_torque_series(\n res::SimulationResults,\n name::String,\n)\n\nFunction to obtain the mechanical torque time series of the mechanical torque out of the DAE Solution.\n\nArguments\n\nres::SimulationResults : Simulation Results object that contains the solution\nname::String : Name to identify the specified device\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.get_pss_output_series-Tuple{SimulationResults, String}","page":"Public API Reference","title":"PowerSimulationsDynamics.get_pss_output_series","text":"get_pss_output_series(\n res::SimulationResults,\n name::String,\n)\n\nFunction to obtain the pss output time series of a Dynamic Generator out of the DAE Solution.\n\nArguments\n\nres::SimulationResults : Simulation Results object that contains the solution\nname::String : Name to identify the specified device\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.get_reactivepower_branch_flow-Tuple{SimulationResults, String, Symbol}","page":"Public API Reference","title":"PowerSimulationsDynamics.get_reactivepower_branch_flow","text":"get_reactivepower_branch_flow(\n res::SimulationResults,\n name::String,\n location::Symbol,\n)\n\nFunction to obtain the reactive power flowing through the series element of a Branch. The user must specified is the power should be computed in the :from or to :bus, by specifying a symbol.\n\nIf :from is specified, the power is computed flowing outwards the :from bus. If :to is specified, the power is computed flowing into the :to bus.\n\nArguments\n\nres::SimulationResults : Simulation Results object that contains the solution\nname::String : Name to identify the specified line\nlocation::Symbol : :from or :to to specify a bus\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.get_reactivepower_series-Tuple{SimulationResults, String}","page":"Public API Reference","title":"PowerSimulationsDynamics.get_reactivepower_series","text":"get_reactivepower_series(\n res::SimulationResults,\n name::String,\n)\n\nFunction to obtain the reactive power output time series of a Dynamic Injection series out of the DAE Solution.\n\nArguments\n\nres::SimulationResults : Simulation Results object that contains the solution\nname::String : Name to identify the specified device\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.get_real_current_branch_flow-Tuple{SimulationResults, String}","page":"Public API Reference","title":"PowerSimulationsDynamics.get_real_current_branch_flow","text":"get_real_current_branch_flow(\n res::SimulationResults,\n name::String,\n)\n\nFunction to obtain the real current flowing through the series element of a Branch\n\nArguments\n\nres::SimulationResults : Simulation Results object that contains the solution\nname::String : Name to identify the specified line\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.get_real_current_series-Tuple{SimulationResults, String}","page":"Public API Reference","title":"PowerSimulationsDynamics.get_real_current_series","text":"get_real_current_series(\n res::SimulationResults,\n name::String,\n)\n\nFunction to obtain the real current time series of a Dynamic Injection series out of the DAE Solution.\n\nArguments\n\nres::SimulationResults : Simulation Results object that contains the solution\nname::String : Name to identify the specified device\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.get_setpoints-Tuple{Simulation}","page":"Public API Reference","title":"PowerSimulationsDynamics.get_setpoints","text":"get_setpoints(sim::Simulation)\n\nFunction that returns the reference setpoints for all the dynamic devices.\n\nArguments\n\nsim::Simulation : Simulation object that contains the initial condition and setpoints.\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.get_source_imaginary_current_series","page":"Public API Reference","title":"PowerSimulationsDynamics.get_source_imaginary_current_series","text":"Function to obtain output imaginary current for a source. It receives the simulation results, the Source name and an optional argument of the time step of the results.\n\n\n\n\n\n","category":"function"},{"location":"api/public/#PowerSimulationsDynamics.get_source_real_current_series","page":"Public API Reference","title":"PowerSimulationsDynamics.get_source_real_current_series","text":"Function to obtain output real current for a source. It receives the simulation results, the Source name and an optional argument of the time step of the results.\n\n\n\n\n\n","category":"function"},{"location":"api/public/#PowerSimulationsDynamics.get_state_series-Tuple{SimulationResults, Tuple{String, Symbol}}","page":"Public API Reference","title":"PowerSimulationsDynamics.get_state_series","text":"get_state_series(\n res::SimulationResults,\n ref::Tuple{String, Symbol};\n dt::Union{Nothing, Float64, Vector{Float64}} = nothing\n)\nend\n\nFunction to obtain series of states out of DAE Solution.\n\nArguments\n\nres::SimulationResults : Simulation Results object that contains the solution\nref:Tuple{String, Symbol} : Tuple used to identify the dynamic device, via its name, as a String, and the associated state as a Symbol.\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.get_voltage_angle_series-Tuple{SimulationResults, Int64}","page":"Public API Reference","title":"PowerSimulationsDynamics.get_voltage_angle_series","text":"get_voltage_angle_series(\n res::SimulationResults,\n bus_number::Int\n)\n\nFunction to obtain the voltage angle series out of the DAE Solution.\n\nArguments\n\nres::SimulationResults : Simulation Results object that contains the solution\nbus_number::Int : Bus number identifier\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.get_voltage_magnitude_series-Tuple{SimulationResults, Int64}","page":"Public API Reference","title":"PowerSimulationsDynamics.get_voltage_magnitude_series","text":"get_voltage_magnitude_series(\n res::SimulationResults,\n bus_number::Int\n)\n\nFunction to obtain the voltage magnitude series out of the DAE Solution.\n\nArguments:\n\nres::SimulationResults : Simulation Results object that contains the solution\nbus_number::Int : Bus number identifier\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.read_initial_conditions-Tuple{Simulation}","page":"Public API Reference","title":"PowerSimulationsDynamics.read_initial_conditions","text":"Returns a Dictionary with the resulting initial conditions of the simulation\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.show_states_initial_value-Tuple{SimulationResults}","page":"Public API Reference","title":"PowerSimulationsDynamics.show_states_initial_value","text":"show_states_initial_value(res::SimulationResults)\n\nFunction to print initial states.\n\nArguments\n\nres::SimulationResults : Simulation Results object that contains the solution\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.show_states_initial_value-Tuple{Simulation}","page":"Public API Reference","title":"PowerSimulationsDynamics.show_states_initial_value","text":"show_states_initial_value(sim::Simulation)\n\nFunction to print initial states.\n\nArguments\n\nsim::Simulation : Simulation object that contains the initial condition\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.small_signal_analysis-Union{Tuple{Simulation{T}}, Tuple{T}} where T<:PowerSimulationsDynamics.SimulationModel","page":"Public API Reference","title":"PowerSimulationsDynamics.small_signal_analysis","text":"small_signal_analysis(\n sim::Simulation,\n)\n\nReturns the Small Signal Output object that contains the eigenvalues and participation factors.\n\nArguments\n\nsim::Simulation : Small Signal Output object that contains the eigenvalues and participation factors\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.summary_eigenvalues-Tuple{PowerSimulationsDynamics.SmallSignalOutput}","page":"Public API Reference","title":"PowerSimulationsDynamics.summary_eigenvalues","text":"summary_eigenvalues(\n sm::SmallSignalOutput,\n)\n\nFunction to obtain a summary of the eigenvalues of the Jacobian at the operating point. It returns a DataFrame with the most associated state for each eigenvalue, its real and imaginary part, damping and frequency.\n\nArguments\n\nsm::SmallSignalOutput : Small Signal Output object that contains the eigenvalues and participation factors\n\n\n\n\n\n","category":"method"},{"location":"api/public/#PowerSimulationsDynamics.summary_participation_factors-Tuple{PowerSimulationsDynamics.SmallSignalOutput}","page":"Public API Reference","title":"PowerSimulationsDynamics.summary_participation_factors","text":"summary_participation_factors(\n sm::SmallSignalOutput,\n)\n\nFunction to obtain the participation factor of each state to each eigenvalue. It returns a DataFrame with the participation factors of each state to all eigenvalues.\n\nArguments\n\nsm::SmallSignalOutput : Small Signal Output object that contains the eigenvalues and participation factors\n\n\n\n\n\n","category":"method"},{"location":"component_models/network/#Network-model","page":"Network","title":"Network model","text":"","category":"section"},{"location":"component_models/network/","page":"Network","title":"Network","text":"Here we discuss the models used to describe the network in PowerSimulationsDynamics.jl. This is based on a standard current injection model as defined in Power System Modelling and Scripting. The numerical advantages of current injection models outweigh the complexities of implementing constant power loads for longer-term transient stability analysis. The network is defined in a synchronous reference frame (SRF), named the RI (real-imaginary) reference frame, rotating at the constant base frequency Omega_b.","category":"page"},{"location":"component_models/network/","page":"Network","title":"Network","text":"In simple terms, PowerSimulationsDynamics.jl internally tracks the current-injection balances at the nodal level from all the devices on the system. Based on the buses and branches information, the system constructor computes the admittance matrix boldsymbolY assuming nominal frequency and this is used for static branch modeling. The algebraic equations for the static portions of the network are as follows:","category":"page"},{"location":"component_models/network/","page":"Network","title":"Network","text":" beginalign\n 0 = boldsymboli(boldsymbolx boldsymbolv) - boldsymbolYboldsymbolv\n endalign","category":"page"},{"location":"component_models/network/","page":"Network","title":"Network","text":"where boldsymboli = i_r + ji_i is the vector of the sum of complex current injections from devices , boldsymbolx is the vector of states and boldsymbolv = v_r + jv_i is the vector of complex bus voltages. Equations (1) connect all the port variables, i.e., currents, defined for each injection device. Components that contribute to (1) by modifying the current boldsymboli are (i) static injection devices, (ii) dynamic injection devices, and (iii) dynamic network branches. Components that contribute to modify the admittance matrix boldsymbolY are static branches.","category":"page"},{"location":"component_models/network/#Static-Branches-(or-Algebraic-Branches)","page":"Network","title":"Static Branches (or Algebraic Branches)","text":"","category":"section"},{"location":"component_models/network/#Lines","page":"Network","title":"Lines","text":"","category":"section"},{"location":"component_models/network/","page":"Network","title":"Network","text":"Each line is defined using a pi model connecting two buses (nm), with a series resistance r and reactance x, and a shunt capacitance at both ends (c_n c_m). The values are already in system per unit. Then each branch contributes to the admittance matrix as follows:","category":"page"},{"location":"component_models/network/","page":"Network","title":"Network","text":"beginalign\nY_nn += frac1r+jx + jc_n \nY_nm += frac-1r+jx \nY_mm += frac1r+jx + jc_m \nY_mn += frac-1r+jx \nendalign","category":"page"},{"location":"component_models/network/#Two-Windings-Transformers","page":"Network","title":"Two-Windings Transformers","text":"","category":"section"},{"location":"component_models/network/","page":"Network","title":"Network","text":"Similarly to lines these are defined by a series reactance and impedance. The equations are equivalently of the lines without the shunt capacitance.","category":"page"},{"location":"component_models/network/#Dynamic-Branches","page":"Network","title":"Dynamic Branches","text":"","category":"section"},{"location":"component_models/network/","page":"Network","title":"Network","text":"Dynamic network branches contribute directly to (1) by modifying the vector of complex currents. Their parameters are also the series resistance r and reactance x, and a shunt capacitance at both ends (c_n c_m) for a line ell. In addition, they define 3 new additional differential equations per line (6 in total for real and imaginary part):","category":"page"},{"location":"component_models/network/","page":"Network","title":"Network","text":"beginalign\n fraclOmega_b fracdboldsymboli_elldt = (boldsymbolv_n - boldsymbolv_m) - (r+jl) boldsymboli_ell \n fracc_nOmega_b fracdboldsymbolv_ndt = boldsymboli_n^textcap - jc_nboldsymbolv_n \n fracc_mOmega_b fracdboldsymbolv_mdt = boldsymboli_m^textcap - jc_mboldsymbolv_m\nendalign","category":"page"},{"location":"component_models/network/","page":"Network","title":"Network","text":"Since all the values are in per unit, the reactance is equal to the inductance.","category":"page"},{"location":"component_models/network/","page":"Network","title":"Network","text":"A detail discussion about the effects of different line models in the modeling of inverters is presented in Grid Forming Inverter Small Signal Stability: Examining Role of Line and Voltage Dynamics","category":"page"},{"location":"component_models/pss/#Power-System-Stabilizers-(PSS)","page":"PSS","title":"Power System Stabilizers (PSS)","text":"","category":"section"},{"location":"component_models/pss/","page":"PSS","title":"PSS","text":"PSS are used to add an additional signal v_s to the input signal of the AVR: v_textref = v_textref^textavr + v_s.","category":"page"},{"location":"component_models/pss/#Fixed-PSS-[PSSFixed]","page":"PSS","title":"Fixed PSS [PSSFixed]","text":"","category":"section"},{"location":"component_models/pss/","page":"PSS","title":"PSS","text":"This is a simple model that set the stabilization signal to be equal to a desired constant value v_s = v_s^textfix. The absence of PSS can be modelled using this component with v_s^textfix = 0.","category":"page"},{"location":"component_models/pss/#Simple-PSS-[PSSSimple]","page":"PSS","title":"Simple PSS [PSSSimple]","text":"","category":"section"},{"location":"component_models/pss/","page":"PSS","title":"PSS","text":"This is the most basic PSS that can be implemented, on which the stabilization signal is a proportional controller over the frequency and electrical power:","category":"page"},{"location":"component_models/pss/","page":"PSS","title":"PSS","text":"beginalign\nv_s = K_omega(omega - omega_s) + K_p(omega tau_e - P_textref) tag1a\nendalign","category":"page"},{"location":"component_models/pss/#IEEE-Stabilizer-[IEEEST]","page":"PSS","title":"IEEE Stabilizer [IEEEST]","text":"","category":"section"},{"location":"component_models/pss/","page":"PSS","title":"PSS","text":"The 7th-order PSS model is:","category":"page"},{"location":"component_models/pss/","page":"PSS","title":"PSS","text":"beginalign\nA_4 dotx_1 = u - A_3 x_1 - x_2 tag2a \ndotx_2 = x_1 tag2b \nA_2dotx_3 = x_2 - A_1 x_3 - x_4 tag2c\ndotx_4 = x_3 tag2d\nT_2dotx_5 = left(1 - fracT_1T_2right) y_f - x_5 tag2e\nT_4dotx_6 = left(1 - fracT_3T_4right) y_LL1 - x_6 tag2f\nT_6dotx_7 = -left(fracK_s T_5T_6 y_LL2 + x_7 right) tag2g\nendalign","category":"page"},{"location":"component_models/pss/","page":"PSS","title":"PSS","text":"with","category":"page"},{"location":"component_models/pss/","page":"PSS","title":"PSS","text":"beginalign*\ny_f = fracT_4T_2 x_2 + left(T_3 - T_1 fracT_4T_2right) x_3 + left(1 - fracT_4T_2right)x_4 \ny_LL1 = x_5 + fracT_1T_2 y_f \ny_LL2 = x_6 + fracT_3T_4 y_LL1 \ny_out = x_7 + fracK_s T_5T_6 y_LL2 \nV_s = textclamp(y_out textLs_textmin textLs_textmax)\nendalign*","category":"page"},{"location":"component_models/pss/","page":"PSS","title":"PSS","text":"on which u is the input signal to the PSS, that depends on the flag. Currently, rotor speed, electric torque, mechanical torque and voltage magnitude are supported inputs.","category":"page"},{"location":"component_models/pss/#STAB1-PSS-[STAB1]","page":"PSS","title":"STAB1 PSS [STAB1]","text":"","category":"section"},{"location":"component_models/pss/","page":"PSS","title":"PSS","text":"The 3rd-order PSS model is:","category":"page"},{"location":"component_models/pss/","page":"PSS","title":"PSS","text":"beginalign\nT dotx_1 = K omega - x_1 tag3a \nT_3dotx_2 = left(1 - fracT_1T_3right) x_1 - x_2 tag3b \nT_4dotx_3 = left(1 - fracT_2T_4right) y_LL - x_2 tag3c \nendalign","category":"page"},{"location":"component_models/pss/","page":"PSS","title":"PSS","text":"with","category":"page"},{"location":"component_models/pss/","page":"PSS","title":"PSS","text":"beginalign*\ny_LL = x_2 + fracT_1T_3 x_1 \ny_out = x_3 + fracT_2T_4 y_LL \nV_s = textclamp(y_out -H_lim H_lim)\nendalign*","category":"page"},{"location":"initialization/#Initialization-Routine","page":"Initialization","title":"Initialization Routine","text":"","category":"section"},{"location":"initialization/","page":"Initialization","title":"Initialization","text":"Dynamic Simulations require a reasonable initial condition for the system model. In most analysis, power systems models are initialized at a stable equilibrium, which implies that:","category":"page"},{"location":"initialization/","page":"Initialization","title":"Initialization","text":"beginalign\n0 = F(x u eta)\nendalign","category":"page"},{"location":"initialization/","page":"Initialization","title":"Initialization","text":"Finding the solution of a large non-linear system is challenging and requires a reasonable initial guess. In classical power systems literature, the routine to find equilibrium points for the dynamic injection devices' components is well known and used in free and commercial software (see Power System Modelling and Scripting page 224). However, in the case of converter interface dynamic injection models, such routines are not documented.","category":"page"},{"location":"initialization/","page":"Initialization","title":"Initialization","text":"Initializing the system also requires finding valid set-points for the devices in the system. For instance, finding the reference voltage in an AVR to match the voltage magnitude resulting from the power flow solution. PowerSimulationsDynamics.jl prioritizes mathching the dynamic components control references to match the power flow results.","category":"page"},{"location":"initialization/","page":"Initialization","title":"Initialization","text":"Finally, the initialization must instantiate not only the values of the states but also the inner vars. PowerSimulationsDynamics.jl handles all this initializations by default.","category":"page"},{"location":"initialization/#Initialization-interface","page":"Initialization","title":"Initialization interface","text":"","category":"section"},{"location":"initialization/","page":"Initialization","title":"Initialization","text":"By default PowerSimulationsDynamics.jl initializes the system following the steps described below. it is possible to provide an initial guess for the initial conditions to speed up the initialization process.","category":"page"},{"location":"initialization/","page":"Initialization","title":"Initialization","text":"Simulation(\n ResidualModel,\n sys,\n pwd(),\n (0.0, 20.0);\n initial_conditions = x0_init,\n )","category":"page"},{"location":"initialization/","page":"Initialization","title":"Initialization","text":"It is also possible to initialize the simulation using a flat start (V_mag = 1.0, V_angle = 0.0 and x0 = zeros) using initialize_simulation = false. However, for medium or large system this is unlikely to result in a valid initial condition for the simulation.","category":"page"},{"location":"initialization/","page":"Initialization","title":"Initialization","text":"Simulation(\n ResidualModel,\n sys,\n pwd(),\n (0.0, 20.0);\n initialize_simulation = false,\n )","category":"page"},{"location":"initialization/","page":"Initialization","title":"Initialization","text":"If you want to avoid PowerSimulationsDynamics.jl from finding an stable equilibrium automatically and provide the initial condition manually you can use the following flag combination.","category":"page"},{"location":"initialization/","page":"Initialization","title":"Initialization","text":"Simulation(\n ResidualModel,\n sys,\n pwd(),\n (0.0, 20.0);\n initialize_simulation = false,\n initial_conditions = x0_init,\n )","category":"page"},{"location":"initialization/","page":"Initialization","title":"Initialization","text":"WARNING!: when the initialize_simulation is set to false, neither the device set points nor the inner vars are initialized. Use these keywords with care and make sure the values in the system components match the initial conditions provided.","category":"page"},{"location":"initialization/#System-wide-initialization-routine","page":"Initialization","title":"System-wide initialization routine","text":"","category":"section"},{"location":"initialization/","page":"Initialization","title":"Initialization","text":"The initialization routine starts from the solution of the power flow equations. For each dynamic injection device PowerSimulationsDynamics.jl finds the solution of the systems of non-linear equations for each dynamic component following the sequences described in the forthcoming sections.","category":"page"},{"location":"initialization/","page":"Initialization","title":"Initialization","text":"Once each device is individually initialized, the system-wide initial guess is used to solve the system (1). In a first attempt at finding the solution, the tolerance is set to a stringent tolerance. If the non-linear solver is unable to get a solution, it might usually reflect small signal stability problems in the system. In a second attempt, the tolerances are relaxed. If the solver succeeds, the simulation continues, but the user is warned.","category":"page"},{"location":"initialization/","page":"Initialization","title":"Initialization","text":"","category":"page"},{"location":"initialization/#Initialization-of-the-Synchronous-Machines","page":"Initialization","title":"Initialization of the Synchronous Machines","text":"","category":"section"},{"location":"initialization/","page":"Initialization","title":"Initialization","text":"The initialization of Synchronous Machines is standard in power systems and follows the scheme shown in the figure. Other internal variables are calculated recursively from the power flow solution for the node on which the dynamic device isconnected. (Adapted from Power System Modelling and Scripting Figure 9.2)","category":"page"},{"location":"initialization/","page":"Initialization","title":"Initialization","text":"(Image: init_machine)","category":"page"},{"location":"initialization/#Initialization-of-the-Inverters","page":"Initialization","title":"Initialization of the Inverters","text":"","category":"section"},{"location":"initialization/","page":"Initialization","title":"Initialization","text":"Initializing the inverters follows the sequence shown in the figure and has been developed to be compatible with the implementation of custom dynamic components. Given that the process is less studied and standard than the one of the synchronous machine, this page contains more detailed documentation of the process.","category":"page"},{"location":"initialization/","page":"Initialization","title":"Initialization","text":"(Image: init_machine)","category":"page"},{"location":"initialization/","page":"Initialization","title":"Initialization","text":"The first component to be initialized is the filter. Given that the filter is an RLC circuit connected to the grid, its currents and voltages need to match the results of the power flow. The initialization of the filter provides the values for the P and Q used in the outer control and the V and I needed in the inner controls.\nBased on the bus voltage in the system's reference frame V_r and the bus angle theta the PLL's can be initialized to obtain the angle and frequency estimates needed by the outer control.\nThe Outer Control calculates the internal angle delta_olc required by the inner control to estimate the voltage and current phase difference.\nThe DC Source uses the power set-point consistent with the power outputs of the filter to initialize the V_dc set-points. This value is used in the inner control.\nThe inner control takes the phase angle delta_olc and the V_dc to estimate the modulation values of the PWM converter.","category":"page"},{"location":"initialization/","page":"Initialization","title":"Initialization","text":"Note: The initialization of an inverter through the proposed meta-model is actively under development and subject to change. This page will maintain the latest version of the sequence.","category":"page"},{"location":"tutorials_page/#SIIP-Examples","page":"SIIP-Examples","title":"SIIP-Examples","text":"","category":"section"},{"location":"tutorials_page/","page":"SIIP-Examples","title":"SIIP-Examples","text":"All the tutorials for the SIIP project are part of a separate repository SIIP-Examples. You can access the latest PowerSimulationsDynamics.jl tutorial notebooks in this link","category":"page"},{"location":"tutorials_page/","page":"SIIP-Examples","title":"SIIP-Examples","text":"Specific examples of common workflows and models:","category":"page"},{"location":"tutorials_page/","page":"SIIP-Examples","title":"SIIP-Examples","text":"Loading Dynamic Data\nSolving a One Machine against Infinite Bus model\nChanging line modeling assumptions\nUsing an Inverter in a Multi-Machine Model","category":"page"},{"location":"tutorials/tutorial_continuation_pf/#Tutorial-Small-Signal-Analysis-with-Continuation-Power-Flow","page":"Small-Signal Analysis","title":"Tutorial Small Signal Analysis with Continuation Power Flow","text":"","category":"section"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"Originally Contributed by: Rodrigo Henriquez-Auba","category":"page"},{"location":"tutorials/tutorial_continuation_pf/#Introduction","page":"Small-Signal Analysis","title":"Introduction","text":"","category":"section"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"This tutorial will introduce you to the functionality of PowerSimulationsDynamics and PowerFlows for running small signal analysis in a continuation power flow.","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"This tutorial presents a simulation of a two-bus system with a generator (represented with a GENROU + SEXS + TGOV1 model) at bus 1, and a load on bus 2. We will increase the load demand to observe the P-V curve and run a small-signal analysis to check if the system satisfies small-signal stability at different operating points.","category":"page"},{"location":"tutorials/tutorial_continuation_pf/#Dependencies","page":"Small-Signal Analysis","title":"Dependencies","text":"","category":"section"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"using PowerSimulationsDynamics\nPSID = PowerSimulationsDynamics\nusing PowerSystemCaseBuilder\nusing PowerSystems\nusing PowerFlows\nconst PSY = PowerSystems\nusing Plots\ngr()\n\n# Disable Logging to avoid excessive information\nusing Logging\nLogging.disable_logging(Logging.Info); \nLogging.disable_logging(Logging.Warn); ","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"note: Note\nPowerSystemCaseBuilder.jl is a helper library that makes it easier to reproduce examples in the documentation and tutorials. Normally you would pass your local files to create the system data instead of calling the function build_system. For more details visit PowerSystemCaseBuilder Documentation","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"PowerSystems (abbreviated with PSY) is used to properly define the data structure and establish an equilibrium point initial condition with a power flow routine using PowerFlows.","category":"page"},{"location":"tutorials/tutorial_continuation_pf/#Load-the-system","page":"Small-Signal Analysis","title":"Load the system","text":"","category":"section"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"We load the system using PowerSystemCaseBuilder.jl. This system only have a generator without dynamic data on which we can use PowerFlows to generate a P-V (or nose) curve.","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"sys_static = build_system(PSIDSystems, \"2 Bus Load Tutorial\")","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"Note that this system contains an Exponential Load, but the parameters are set up to zero, so it behaves a Constant Power Load:","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"first(get_components(PSY.ExponentialLoad, sys_static))","category":"page"},{"location":"tutorials/tutorial_continuation_pf/#Create-a-P-V-curve","page":"Small-Signal Analysis","title":"Create a P-V curve","text":"","category":"section"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"The next step is to run multiple power flows and store the voltage at the load and the active power. For this example we will set up the power factor to be unitary (i.e. no reactive power at the load). ","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"# Create a Power Range to change the power load active power\nP_range = 0.01:0.01:4.6;\n# Choose the power factor\nload_pf = 1.0;","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"Then create vectors to store the results","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"# PV Curve Results\nP_load_p = Vector{Float64}();\nV_load_p = Vector{Float64}();","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"Then, we run multiple power flows in a for loop by changing the active power of the load:","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"for p in P_range\n # Change the active power and reactive power of the load\n power = p * 1.0\n load = get_component(PSY.ExponentialLoad, sys_static, \"load1021\")\n set_active_power!(load, power)\n q_power = power * tan(acos(load_pf))\n set_reactive_power!(load, q_power)\n # Run Power Flow\n status = solve_ac_powerflow!(sys_static)\n if !status\n # Finish the loop if the power flow fails\n print(\"Power Flow failed at p = $(power)\")\n break\n end\n # Obtain the bus voltage information\n bus = get_component(Bus, sys_static, \"BUS 2\")\n Vm = get_magnitude(bus)\n # Store values in the vectors\n push!(V_load_p, Vm)\n push!(P_load_p, power)\nend","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"The plot can be visualized with:","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"plot(P_load_p,\n V_load_p,\n label = \"PV Curve\",\n xlabel = \"Load Power [pu]\",\n ylabel = \"Load Bus Voltage [pu]\",\n color = :black\n)","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"(Image: plot)","category":"page"},{"location":"tutorials/tutorial_continuation_pf/#Run-Small-Signal-Analysis-besides-the-Continuation-Power-Flow","page":"Small-Signal Analysis","title":"Run Small-Signal Analysis besides the Continuation Power Flow","text":"","category":"section"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"To run a small-signal analysis we require a dynamic model of the machine. We can use PowerSystemCaseBuilder to the load the same system, but with a dynamic model for the generator, including a GENROU + SEXS exciter + TGOV1 governor.","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"sys = build_system(PSIDSystems, \"2 Bus Load Tutorial GENROU\")","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"Here are the components of the generator:","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"first(get_components(DynamicGenerator, sys))","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"Besides the results of the P-V curve, we need to store if the system is small-signal stable or not by looking if there is a positive real part eigenvalue.","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"# Vectors to store stability using a boolean (true for stable).\nstable_vec = Vector{Bool}();\nstatus_vec = Vector{Bool}();\n\n# PV Curve Results\nP_load_p = Vector{Float64}();\nV_load_p = Vector{Float64}();","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"We then run the main for loop by updating the load active power, but in addition we create a PowerSimulationsDynamics simulation on which we can run a small-signal analysis to check stability.","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"for p in P_range\n # Change the active power and reactive power of the load\n power = p * 1.0\n load = get_component(PSY.ExponentialLoad, sys_static, \"load1021\")\n set_active_power!(load, power)\n q_power = power * tan(acos(load_pf))\n set_reactive_power!(load, q_power)\n # Run Power Flow\n status = solve_ac_powerflow!(sys_static)\n if !status\n # Finish the loop if the power flow fails\n print(\"Power Flow failed at p = $(power)\")\n break\n end\n # Obtain the bus voltage information\n bus = get_component(Bus, sys_static, \"BUS 2\")\n Vm = get_magnitude(bus)\n # Store values in the vectors\n push!(V_load_p, Vm)\n push!(P_load_p, power)\n\n # Update Load Power in the GENROU system\n load = get_component(PSY.ExponentialLoad, sys, \"load1021\")\n set_active_power!(load, power)\n q_power = power * tan(acos(load_pf))\n set_reactive_power!(load, q_power)\n # Construct Simulation\n sim = Simulation(ResidualModel, sys, mktempdir(), (0.0, 1.0))\n if sim.status == PSID.BUILT\n # Check small-signal stability\n sm = small_signal_analysis(sim).stable\n # Push results of small-signal stability\n push!(stable_vec, sm)\n # Push results if the simulation was able to be constructed\n push!(status_vec, true)\n else\n # Push results if the simulation was not able to be constructed\n push!(status_vec, false)\n end\nend","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"The following plot showcases the P-V curve, while also showcasing (in red) the regions on which the system is small-signal stable.","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"\n# Find where is stable and unstable\ndict_true_ixs_p = Vector();\ndict_false_ixs_p = Vector();\ndict_true_ixs_p = findall(x->x, stable_vec);\ndict_false_ixs_p = findall(x->!x, stable_vec);\n\n# Create plot\ntrue_ixs = dict_true_ixs_p;\nplot(P_load_p, V_load_p, color = :blue, label = \"PV Curve\", xlabel = \"Load Power [pu]\", ylabel = \"Load Bus Voltage [pu]\")\nplot!(Plots.scatter!(P_load_p[true_ixs] , V_load_p[true_ixs], markerstrokewidth= 0, label = \"GENROU SSA\"))","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"(Image: plot)","category":"page"},{"location":"tutorials/tutorial_continuation_pf/","page":"Small-Signal Analysis","title":"Small-Signal Analysis","text":"This results is consistent with most of the literature for dynamic generator models supplying constant power loads, on which by increasing the active power of the load, produce critical eigenvalues which cross the jomega axis at some point. This is called a Hopf Bifurcation, in this case a subcritical one since the limit cycles are unstable.","category":"page"},{"location":"reference_frames/#Reference-Frames","page":"Reference Frames","title":"Reference Frames","text":"","category":"section"},{"location":"reference_frames/","page":"Reference Frames","title":"Reference Frames","text":"Each dynamic device is defined in its own dq synchronous reference frame (SRF). It is important to note that there are several conventions to do reference frame transformations.","category":"page"},{"location":"reference_frames/#Synchronous-Machines","page":"Reference Frames","title":"Synchronous Machines","text":"","category":"section"},{"location":"reference_frames/","page":"Reference Frames","title":"Reference Frames","text":"The grid is modeled in its own real-imaginary (RI) reference frame. With such, this follows the standard convention that for a voltage angle theta = 0, there is no imaginary part and hence v_h = v_r + j0. Traditionally, the reference frame dq with rotor angle delta for synchronous machines connected to a bus v_hangle theta = v_r + jv_i follows the following convention for transformation of per-unit RMS phasors:","category":"page"},{"location":"reference_frames/","page":"Reference Frames","title":"Reference Frames","text":"beginalign\nv_d + jv_q = (v_r + jv_i) e^-j(delta- pi2) tag1a \nv_d = v_h sin(delta - theta) tag1b \nv_q = v_h cos(delta - theta) tag1c \nleft beginarrayc v_d v_q endarray right = left beginarraycc sin(delta) -cos(delta) cos(delta) sin(delta) endarray right left beginarrayc v_r v_i endarray right tag1d\nendalign","category":"page"},{"location":"reference_frames/","page":"Reference Frames","title":"Reference Frames","text":"Note that hence in a bus of 10angle 0, a rotor angle of delta = 0 implies that v_q = 10 and v_d = 00. This transformation is the one that can be found in most books of Power Systems, such as Kundur, Sauer Pai and in Milano too, and is the convention used in the software to model dynamic models of synchronous machines in their own reference frame.","category":"page"},{"location":"reference_frames/#Inverters","page":"Reference Frames","title":"Inverters","text":"","category":"section"},{"location":"reference_frames/","page":"Reference Frames","title":"Reference Frames","text":"The previously convention is not the standard one used for modeling inverters. Most of inverter and phase-lock loop (PLL) models follow the next convention:","category":"page"},{"location":"reference_frames/","page":"Reference Frames","title":"Reference Frames","text":"beginalign\nv_d + jv_q = (v_r + jv_i) e^-j delta tag2a \nv_d = v_h cos(delta - theta) tag2b \nv_q = -v_h sin(delta - theta) tag2c\nendalign","category":"page"},{"location":"reference_frames/","page":"Reference Frames","title":"Reference Frames","text":"That, contrary to the previous case, when delta = theta = 0 implies that v_d = 10 and v_q = 00. This yields the typical PLL conditions that steer v_q to 0 when delta locks in theta, or when both SRF lock between each other.","category":"page"},{"location":"reference_frames/#Transformation-used","page":"Reference Frames","title":"Transformation used","text":"","category":"section"},{"location":"reference_frames/","page":"Reference Frames","title":"Reference Frames","text":"Given the predominancy of both convention in current work, the software uses both conventions depending on the device modeled. For synchronous machines we used the standard convention (1a)-(1d), while for inverter models we use the predominant convention used nowadays in such models, i.e. (2a)-(2c).","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/#Inverter-Modeling-simulation","page":"Inverter Modeling","title":"Inverter Modeling simulation","text":"","category":"section"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"Originally Contributed by: José Daniel Lara","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/#Introduction","page":"Inverter Modeling","title":"Introduction","text":"","category":"section"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"This tutorial will introduce the modeling of an inverter with Virtual Inertia in a multi-machine model of the system. We will load the data directly from PSS/e dynamic files.","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"The tutorial uses a modified 14-bus system on which all the synchronous machines have been substituted by generators with ESAC1A AVR's and no Turbine Governors.","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"In the first portion of the tutorial we will simulate the system with the original data and cause a line trip between Buses 2 and 4. In the second part of the simulation, we will switch generator 6 with a battery using an inverter and perform the same fault.","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/#Load-the-packages","page":"Inverter Modeling","title":"Load the packages","text":"","category":"section"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"using PowerSimulationsDynamics\nusing PowerSystemCaseBuilder\nusing PowerSystems\nconst PSY = PowerSystems\nusing PowerFlows\nusing Logging\nusing Sundials\nusing Plots","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"note: Note\nPowerSystemCaseBuilder.jl is a helper library that makes it easier to reproduce examples in the documentation and tutorials. Normally you would pass your local files to create the system data instead of calling the function build_system. For more details visit PowerSystemCaseBuilder Documentation","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"Create the system using PowerSystemCaseBuilder.jl:","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"sys = build_system(PSIDSystems, \"14 Bus Base Case\")","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"PowerSystemCaseBuilder.jl is a helper library that makes it easier to reproduce examples in the documentation and tutorials. Normally you would pass your local files to create the system data.","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"Define Simulation Problem with a 20 second simulation period and the branch trip at t = 1.0:","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"sim = Simulation(\n ResidualModel, #Type of model used\n sys, #system\n mktempdir(), #path for the simulation output\n (0.0, 20.0), #time span\n BranchTrip(1.0, Line, \"BUS 02-BUS 04-i_1\");\n console_level = Logging.Info,\n)","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"Now that the system is initialized, we can verify the system states for potential issues.","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"show_states_initial_value(sim)","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"We execute the simulation with an additional tolerance for the solver set at 1e-8:","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"execute!(sim, IDA(); abstol = 1e-8)","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"Using PowerSimulationsDynamics tools for exploring the results, we can plot all the voltage results for the buses:","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"result = read_results(sim)\np = plot();\nfor b in get_components(ACBus, sys)\n voltage_series = get_voltage_magnitude_series(result, get_number(b))\n plot!(\n p,\n voltage_series;\n xlabel = \"Time\",\n ylabel = \"Voltage Magnitude [pu]\",\n label = \"Bus - $(get_name(b))\",\n );\nend","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"(Image: plot)","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"We can also explore the frequency of the different generators","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"p2 = plot();\nfor g in get_components(ThermalStandard, sys)\n state_series = get_state_series(result, (get_name(g), :ω))\n plot!(\n p2,\n state_series;\n xlabel = \"Time\",\n ylabel = \"Speed [pu]\",\n label = \"$(get_name(g)) - ω\",\n );\nend","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"(Image: plot)","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"It is also possible to explore the small signal stability of this system we created.","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"res = small_signal_analysis(sim)","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/#The-eigenvalues-can-be-explored","page":"Inverter Modeling","title":"The eigenvalues can be explored","text":"","category":"section"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"res.eigenvalues","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/#Modifying-the-system-and-adding-storage","page":"Inverter Modeling","title":"Modifying the system and adding storage","text":"","category":"section"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"Reload the system for this example:","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"sys = build_system(PSIDSystems, \"14 Bus Base Case\")\n\n# We want to remove the generator 6 and the dynamic component attached to it.\nthermal_gen = get_component(ThermalStandard, sys, \"generator-6-1\")\nremove_component!(sys, get_dynamic_injector(thermal_gen))\nremove_component!(sys, thermal_gen)\n\n# We can now define our storage device and add it to the system\nstorage = GenericBattery(\n name = \"Battery\",\n bus = get_component(Bus, sys, \"BUS 06\"),\n available = true,\n prime_mover = PrimeMovers.BA,\n active_power = 0.6,\n reactive_power = 0.16,\n rating = 1.1,\n base_power = 25.0,\n initial_energy = 50.0,\n state_of_charge_limits = (min = 5.0, max = 100.0),\n input_active_power_limits = (min = 0.0, max = 1.0),\n output_active_power_limits = (min = 0.0, max = 1.0),\n reactive_power_limits = (min = -1.0, max = 1.0),\n efficiency = (in = 0.80, out = 0.90),\n)\n\nadd_component!(sys, storage)","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"A good sanity check it running a power flow on the system to make sure all the components are properly scaled and that the system is properly balanced. We can use PowerSystems to perform this check. We can get the results back and perform a sanity check.","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"res = solve_powerflow(ACPowerFlow(), sys)\nres[\"bus_results\"]","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"After verifying that the system works, we can define our inverter dynamics and add it to the battery that has already been stored in the system.","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"inverter = DynamicInverter(\n name = get_name(storage),\n ω_ref = 1.0, # ω_ref,\n converter = AverageConverter(rated_voltage = 138.0, rated_current = 100.0),\n outer_control = OuterControl(\n VirtualInertia(Ta = 2.0, kd = 400.0, kω = 20.0),\n ReactivePowerDroop(kq = 0.2, ωf = 1000.0),\n ),\n inner_control = VoltageModeControl(\n kpv = 0.59, #Voltage controller proportional gain\n kiv = 736.0, #Voltage controller integral gain\n kffv = 0.0, #Binary variable enabling the voltage feed-forward in output of current controllers\n rv = 0.0, #Virtual resistance in pu\n lv = 0.2, #Virtual inductance in pu\n kpc = 1.27, #Current controller proportional gain\n kic = 14.3, #Current controller integral gain\n kffi = 0.0, #Binary variable enabling the current feed-forward in output of current controllers\n ωad = 50.0, #Active damping low pass filter cut-off frequency\n kad = 0.2,\n ),\n dc_source = FixedDCSource(voltage = 600.0),\n freq_estimator = KauraPLL(\n ω_lp = 500.0, #Cut-off frequency for LowPass filter of PLL filter.\n kp_pll = 0.084, #PLL proportional gain\n ki_pll = 4.69, #PLL integral gain\n ),\n filter = LCLFilter(lf = 0.08, rf = 0.003, cf = 0.074, lg = 0.2, rg = 0.01),\n)\nadd_component!(sys, inverter, storage)","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"These are the current system components:","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"sys","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"Define Simulation problem using the same parameters:","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"sim = Simulation(\n ResidualModel, #Type of model used\n sys, #system\n mktempdir(), #path for the simulation output\n (0.0, 20.0), #time span\n BranchTrip(1.0, Line, \"BUS 02-BUS 04-i_1\");\n console_level = Logging.Info,\n)","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"We can verify the small signal stability of the system before running the simulation:","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"res = small_signal_analysis(sim)","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"Exploring the eigenvalues:","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"res.eigenvalues","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"We execute the simulation","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"execute!(sim, IDA(); abstol = 1e-8)","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"Using PowerSimulationsDynamics tools for exploring the results, we can plot all the voltage results for the buses","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"result = read_results(sim)\np = plot();\nfor b in get_components(ACBus, sys)\n voltage_series = get_voltage_magnitude_series(result, get_number(b))\n plot!(\n p,\n voltage_series;\n xlabel = \"Time\",\n ylabel = \"Voltage Magnitude [pu]\",\n label = \"Bus - $(get_name(b))\",\n );\nend","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"(Image: plot)","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"We can also explore the frequency of the different static generators and storage","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"p2 = plot();\nfor g in get_components(ThermalStandard, sys)\n state_series = get_state_series(result, (get_name(g), :ω))\n plot!(\n p2,\n state_series;\n xlabel = \"Time\",\n ylabel = \"Speed [pu]\",\n label = \"$(get_name(g)) - ω\",\n );\nend\nstate_series = get_state_series(result, (\"Battery\", :ω_oc))\nplot!(p2, state_series; xlabel = \"Time\", ylabel = \"Speed [pu]\", label = \"Battery - ω\");","category":"page"},{"location":"tutorials/tutorial_inverter_modeling/","page":"Inverter Modeling","title":"Inverter Modeling","text":"(Image: plot)","category":"page"},{"location":"time_delays/#Delays","page":"Time Delays","title":"Delays","text":"","category":"section"},{"location":"time_delays/","page":"Time Delays","title":"Time Delays","text":"PowerSimulationsDynamics supports models with constant delays in a mass matrix formulation:","category":"page"},{"location":"time_delays/","page":"Time Delays","title":"Time Delays","text":"beginalign\nMfracdx(t)dt = f(x(t) x(t-tau_1) x(t-tau_N)) \nendalign","category":"page"},{"location":"time_delays/","page":"Time Delays","title":"Time Delays","text":"For more information on solving such models, refer to the documentation for DelayDiffEq.jl package.","category":"page"},{"location":"time_delays/","page":"Time Delays","title":"Time Delays","text":"The following models include time delays:","category":"page"},{"location":"time_delays/","page":"Time Delays","title":"Time Delays","text":"DEGOV","category":"page"},{"location":"time_delays/","page":"Time Delays","title":"Time Delays","text":"There is currently limited support for including models with time delays. The following limitations apply:","category":"page"},{"location":"time_delays/","page":"Time Delays","title":"Time Delays","text":"Only constant delays are supported (state dependent delays are not).\nSystem models with delays must use MassMatrixModel formulation (ResidualModel is not currently compatible).\nSystem models with delays are not compatible with small signal analysis tools.\nThe system formulation with delays is not compatible with automatic differentiation for calculating the gradient with respect to time. The setting autodiff=false should be set when passing the solver (e.g. MethodofSteps(Rodas5(autodiff=false))).","category":"page"},{"location":"component_models/dc_source/#DC-Source","page":"DC Sources","title":"DC Source","text":"","category":"section"},{"location":"component_models/dc_source/","page":"DC Sources","title":"DC Sources","text":"This component can be used to model the dynamics of the DC side of the converter.","category":"page"},{"location":"component_models/dc_source/#Fixed-DC-Source-[FixedDCSource]","page":"DC Sources","title":"Fixed DC Source [FixedDCSource]","text":"","category":"section"},{"location":"component_models/dc_source/","page":"DC Sources","title":"DC Sources","text":"This is a model that set the DC voltage to a fixed value v_textdc = v_textdc^textfix.","category":"page"},{"location":"tutorials/tutorial_omib/#One-Machine-against-Infinite-Bus-(OMIB)-Simulation","page":"OMIB","title":"One Machine against Infinite Bus (OMIB) Simulation","text":"","category":"section"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"Originally Contributed by: Rodrigo Henriquez-Auba and José Daniel Lara","category":"page"},{"location":"tutorials/tutorial_omib/#Introduction","page":"OMIB","title":"Introduction","text":"","category":"section"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"This tutorial will introduce you to the functionality of PowerSimulationsDynamics for running power system dynamic simulations.","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"This tutorial presents a simulation of a two-bus system with an infinite bus (represented as a voltage source behind an impedance) at bus 1, and a classic machine on bus 2. The perturbation will be the trip of one of the two circuits (doubling its resistance and impedance) of the line that connects both buses.","category":"page"},{"location":"tutorials/tutorial_omib/#Dependencies","page":"OMIB","title":"Dependencies","text":"","category":"section"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"using PowerSimulationsDynamics\nPSID = PowerSimulationsDynamics\nusing PowerSystemCaseBuilder\nusing PowerSystems\nconst PSY = PowerSystems\nusing Sundials\nusing Plots\ngr()","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"note: Note\nPowerSystemCaseBuilder.jl is a helper library that makes it easier to reproduce examples in the documentation and tutorials. Normally you would pass your local files to create the system data instead of calling the function build_system. For more details visit PowerSystemCaseBuilder Documentation","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"PowerSystems (abbreviated with PSY) is used to properly define the data structure and establish an equilibrium point initial condition with a power flow routine, while Sundials is used to solve the problem defined in PowerSimulationsDynamics.","category":"page"},{"location":"tutorials/tutorial_omib/#Load-the-system","page":"OMIB","title":"Load the system","text":"","category":"section"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"We load the system using PowerSystemCaseBuilder.jl:","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"omib_sys = build_system(PSIDSystems, \"OMIB System\")","category":"page"},{"location":"tutorials/tutorial_omib/#Build-the-simulation-and-initialize-the-problem","page":"OMIB","title":"Build the simulation and initialize the problem","text":"","category":"section"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"The next step is to create the simulation structure. This will create the indexing of our system that will be used to formulate the differential-algebraic system of equations. To do so, it is required to specify the perturbation that will occur in the system. PowerSimulationsDynamics supports multiple types of perturbations. See Perturbations","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"Here, we will use a Branch Trip perturbation, that is modeled by modifying the specifying which line we want to trip. In this case we disconnect one of the lines that connects BUS 1 and BUS 2, named \"BUS 1-BUS 2-i_1\".","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"With this, we are ready to create our simulation structure:","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"time_span = (0.0, 30.0)\nperturbation_trip = BranchTrip(1.0, Line, \"BUS 1-BUS 2-i_1\")\nsim = PSID.Simulation(\n ResidualModel, # Type of formulation\n omib_sys, # System\n mktempdir(), # Output directory\n time_span,\n perturbation_trip)","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"This will automatically initialize the system by running a power flow and update V_ref, P_ref and hence eq_p (the internal voltage) to match the solution of the power flow. It will also initialize the states in the equilibrium, which can be printed with:","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"show_states_initial_value(sim)","category":"page"},{"location":"tutorials/tutorial_omib/#Run-the-Simulation","page":"OMIB","title":"Run the Simulation","text":"","category":"section"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"Finally, to run the simulation we simply use:","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"execute!(\n sim, #simulation structure\n IDA(), #Sundials DAE Solver\n dtmax = 0.02, #Arguments: Maximum timestep allowed\n);","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"In some cases, the dynamic time step used for the simulation may fail. In such case, the keyword argument dtmax can be used to limit the maximum time step allowed for the simulation.","category":"page"},{"location":"tutorials/tutorial_omib/#Exploring-the-solution","page":"OMIB","title":"Exploring the solution","text":"","category":"section"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"First, we need to load the simulation results into memory:","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"results = read_results(sim)","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"PowerSimulationsDynamics has two functions to obtain different states of the solution:","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"get_state_series(results, (\"generator-102-1\", :δ)): can be used to obtain the solution as a tuple of time and the required state. In this case, we are obtaining the rotor angle :δ of the generator named \"generator-102-1\"`.","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"angle = get_state_series(results, (\"generator-102-1\", :δ));\nplot(angle, xlabel = \"time\", ylabel = \"rotor angle [rad]\", label = \"rotor angle\")","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"(Image: plot)","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"get_voltage_magnitude_series(results, 102): can be used to obtain the voltage magnitude as a tuple of time and voltage. In this case, we are obtaining the voltage magnitude at bus 102 (where the generator is located).","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"volt = get_voltage_magnitude_series(results, 102);\nplot(volt, xlabel = \"time\", ylabel = \"Voltage [pu]\", label = \"V_2\")","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"(Image: plot)","category":"page"},{"location":"tutorials/tutorial_omib/#Optional:-Small-Signal-Analysis","page":"OMIB","title":"Optional: Small Signal Analysis","text":"","category":"section"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"PowerSimulationsDynamics uses automatic differentiation to compute the reduced Jacobian of the system for the differential states. This can be used to analyze the local stability of the linearized system. We need to re-initialize our simulation:","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"sim2 = Simulation(ResidualModel, omib_sys, mktempdir(), time_span)\nsmall_sig = small_signal_analysis(sim2)","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"The small_sig result can report the reduced jacobian for delta and omega,","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"small_sig.reduced_jacobian","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"and can also be used to report the eigenvalues of the reduced linearized system:","category":"page"},{"location":"tutorials/tutorial_omib/","page":"OMIB","title":"OMIB","text":"small_sig.eigenvalues","category":"page"},{"location":"api/internal/#Internal","page":"Internal API Reference","title":"Internal","text":"","category":"section"},{"location":"api/internal/","page":"Internal API Reference","title":"Internal API Reference","text":"CurrentModule = PowerSimulationsDynamics\nDocTestSetup = quote\n using PowerSimulationsDynamics\nend","category":"page"},{"location":"api/internal/","page":"Internal API Reference","title":"Internal API Reference","text":"Modules = [PowerSimulationsDynamics]\nPublic = false\nPrivate = true","category":"page"},{"location":"api/internal/#PowerSimulationsDynamics.BUILD_STATUS","page":"Internal API Reference","title":"PowerSimulationsDynamics.BUILD_STATUS","text":"Defines the status of the simulation object\n\n\n\n\n\n","category":"type"},{"location":"api/internal/#PowerSimulationsDynamics.BranchWrapper","page":"Internal API Reference","title":"PowerSimulationsDynamics.BranchWrapper","text":"Wraps DynamicBranch devices from PowerSystems to handle changes in controls and connection status, and allocate the required indexes of the state space.\n\n\n\n\n\n","category":"type"},{"location":"api/internal/#PowerSimulationsDynamics.DynamicWrapper","page":"Internal API Reference","title":"PowerSimulationsDynamics.DynamicWrapper","text":"Wraps DynamicInjection devices from PowerSystems to handle changes in controls and connection status, and allocate the required indexes of the state space.\n\n\n\n\n\n","category":"type"},{"location":"api/internal/#PowerSimulationsDynamics.SimulationInputs-Tuple{Type{MassMatrixModel}, System, Union{ConstantFrequency, ReferenceBus}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.SimulationInputs","text":"SimulationInputs build function for MassMatrixModels\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.SimulationInputs-Tuple{Type{ResidualModel}, System, Union{ConstantFrequency, ReferenceBus}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.SimulationInputs","text":"SimulationInputs build function for ResidualModels\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.generator_inner_vars","page":"Internal API Reference","title":"PowerSimulationsDynamics.generator_inner_vars","text":"Generator Inner Vars:\n\nτe_var :: Electric torque\nτm_var :: Mechanical torque\nVf_var :: Field voltage\nV_pss_var :: Additional PSS voltage\nVR_gen_var :: Real part of the terminal voltage\nVI_gen_var :: Imaginary part of the terminal voltage\nψd_var :: Stator Flux (if defined) in the d-axis\nψq_var :: Stator Flux (if defined) in the q-axis\n\n\n\n\n\n","category":"type"},{"location":"api/internal/#PowerSimulationsDynamics.inverter_inner_vars","page":"Internal API Reference","title":"PowerSimulationsDynamics.inverter_inner_vars","text":"Inverter Inner Vars:\n\nmd_var :: Modulation signal on the d-component\nmq_var :: Modulation signal on the q-component\nVdc_var :: DC voltage supplied by the DC source\nVr_filter_var :: Voltage seen in the capacitor of the filter in the R-component\nVi_filter_var :: Voltage seen in the capacitor of the filter in the I-component\nθ_freq_estimator_var :: Angle estimated by the frequency estimator.\nω_freq_estimator_var :: Frequency estimated by the frequency estimator.\nV_oc_var :: Control voltage reference in the d-axis supplied from the outer loop control to the inner loop (for Voltage Mode Control)\nId_oc_var :: Control current reference in the d-axis supplied from the outer loop control to the inner loop (for Current Mode Control)\nIq_oc_var :: Control current reference in the q-axis supplied from the outer loop control to the inner loop (for Current Mode Control)\nId_ic_var :: Control current reference in the d-axis supplied from the inner loop control to the converter (for Generic Models)\nIq_ic_var :: Control current reference in the q-axis supplied from the inner loop control to the converter (for Generic Models)\nIr_cnv_var :: Control current reference in the R-axis supplied from the converter to the filter (for Generic Models)\nIi_cnv_var :: Control current reference in the I-axis supplied from the converter to the filter (for Generic Models)\nω_oc_var :: Control frequency supplied from the outer loop control the inner loop\nθ_oc_var :: Variation of the angle (PLL or VSM) of the inverter\nVr_inv_var :: Real terminal voltage on the inverter\nVi_inv_var :: Imaginary terminal voltage on the inverter\nVr_cnv_var :: Voltage supplied from the converter in the R-component\nVi_cnv_var :: Voltage supplied from the converter in the I-component\nP_ES_var :: Power supplied from the Energy Source side\n\n\n\n\n\n","category":"type"},{"location":"api/internal/#PowerSimulationsDynamics._field_current-Tuple{SalientPoleExponential, String, Vector{Float64}, Vector{Float64}, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics._field_current","text":"Function to obtain the field current time series of a Dynamic Generator with machine type GENSAE.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._field_current-Tuple{SalientPoleQuadratic, String, Vector{Float64}, Vector{Float64}, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics._field_current","text":"Function to obtain the field current time series of a Dynamic Generator with machine type GENSAL.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._field_current-Union{Tuple{M}, Tuple{M, String, Vector{Float64}, Vector{Float64}, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}} where M<:Machine","page":"Internal API Reference","title":"PowerSimulationsDynamics._field_current","text":"Function to obtain the field current time series of a Dynamic Generator. It is dispatched via the machine type. By default, machine does not have support for field current\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._field_current-Union{Tuple{M}, Tuple{M, String, Vector{Float64}, Vector{Float64}, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}} where M<:Union{RoundRotorExponential, RoundRotorQuadratic}","page":"Internal API Reference","title":"PowerSimulationsDynamics._field_current","text":"Function to obtain the field current time series of a Dynamic Generator with machine type GENROU/GENROE.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._field_voltage-Tuple{AVRFixed, String, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics._field_voltage","text":"Function to obtain the field voltage time series of a Dynamic Generator with avr AVRFixed.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._field_voltage-Tuple{ESST1A, String, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics._field_voltage","text":"Function to obtain the field voltage time series of a Dynamic Generator with avr ESST1A.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._field_voltage-Tuple{SCRX, String, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics._field_voltage","text":"Function to obtain the field voltage time series of a Dynamic Generator with avr SCRX.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._field_voltage-Tuple{Union{ESAC1A, EXAC1}, String, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics._field_voltage","text":"Function to obtain the field voltage time series of a Dynamic Generator with avr ESAC1A and EXAC1.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._field_voltage-Union{Tuple{A}, Tuple{A, String, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}} where A<:AVR","page":"Internal API Reference","title":"PowerSimulationsDynamics._field_voltage","text":"Function to obtain the field voltage time series of a Dynamic Generator with avrs that have the field voltage as a state. By default it is assumed that the models have that state.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._frequency-Union{Tuple{G}, Tuple{F}, Tuple{OuterControl{ActivePowerDroop, ReactivePowerDroop}, F, String, SimulationResults, G, Union{Nothing, Float64, Vector{Float64}}}} where {F<:FrequencyEstimator, G<:DynamicInverter}","page":"Internal API Reference","title":"PowerSimulationsDynamics._frequency","text":"Function to obtain the frequency time series of a droop grid forming inverter out of the DAE Solution. It is dispatched via the OuterControl type.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._frequency-Union{Tuple{G}, Tuple{F}, Tuple{OuterControl{ActiveVirtualOscillator, ReactiveVirtualOscillator}, F, String, SimulationResults, G, Union{Nothing, Float64, Vector{Float64}}}} where {F<:FrequencyEstimator, G<:DynamicInverter}","page":"Internal API Reference","title":"PowerSimulationsDynamics._frequency","text":"Function to obtain the frequency time series of a VOC grid forming inverter out of the DAE Solution. It is dispatched via the OuterControl type.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._frequency-Union{Tuple{G}, Tuple{F}, Tuple{OuterControl{VirtualInertia, ReactivePowerDroop}, F, String, SimulationResults, G, Union{Nothing, Float64, Vector{Float64}}}} where {F<:FrequencyEstimator, G<:DynamicInverter}","page":"Internal API Reference","title":"PowerSimulationsDynamics._frequency","text":"Function to obtain the frequency time series of a virtual inertia grid forming inverter out of the DAE Solution. It is dispatched via the OuterControl type.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._frequency-Union{Tuple{G}, Tuple{OuterControl{ActivePowerPI, ReactivePowerPI}, KauraPLL, String, SimulationResults, G, Union{Nothing, Float64, Vector{Float64}}}} where G<:DynamicInverter","page":"Internal API Reference","title":"PowerSimulationsDynamics._frequency","text":"Function to obtain the frequency time series of a grid-following inverter with KauraPLL out of the DAE Solution. It is dispatched via the OuterControl and FrequencyEstimator type.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._frequency-Union{Tuple{G}, Tuple{OuterControl{ActivePowerPI, ReactivePowerPI}, ReducedOrderPLL, String, SimulationResults, G, Union{Nothing, Float64, Vector{Float64}}}} where G<:DynamicInverter","page":"Internal API Reference","title":"PowerSimulationsDynamics._frequency","text":"Function to obtain the frequency time series of a grid-following inverter with ReducedOrderPLL out of the DAE Solution. It is dispatched via the OuterControl and FrequencyEstimator type.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._machine_current-Tuple{BaseMachine, String, Vector{Float64}, Vector{Float64}, Float64, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics._machine_current","text":"Function to obtain the output current time series of a Classic Machine model out of the DAE Solution. It is dispatched via the machine type.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._machine_current-Tuple{OneDOneQMachine, String, Vector{Float64}, Vector{Float64}, Float64, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics._machine_current","text":"Function to obtain the output current time series of a One-D-One-Q model out of the DAE Solution. It is dispatched via the machine type.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._machine_current-Tuple{SauerPaiMachine, String, Vector{Float64}, Vector{Float64}, Float64, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics._machine_current","text":"Function to obtain the output current time series of a SauerPaiMachine model out of the DAE Solution. It is dispatched via the machine type.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._machine_current-Tuple{Union{AndersonFouadMachine, MarconatoMachine}, String, Vector{Float64}, Vector{Float64}, Float64, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics._machine_current","text":"Function to obtain the output current time series of a Marconato or AndersonFouad model out of the DAE Solution. It is dispatched via the machine type.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._machine_current-Tuple{Union{RoundRotorExponential, RoundRotorQuadratic}, String, Vector{Float64}, Vector{Float64}, Float64, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics._machine_current","text":"Function to obtain the output current time series of a GENROU/GENROE model out of the DAE Solution. It is dispatched via the machine type.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._machine_current-Tuple{Union{SalientPoleExponential, SalientPoleQuadratic}, String, Vector{Float64}, Vector{Float64}, Float64, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics._machine_current","text":"Function to obtain the output current time series of a GENSAL/GENSAE model out of the DAE Solution. It is dispatched via the machine type.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._machine_current-Tuple{Union{SimpleAFMachine, SimpleMarconatoMachine}, String, Vector{Float64}, Vector{Float64}, Float64, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics._machine_current","text":"Function to obtain the output current time series of a SimpleMarconato or SimpleAndersonFouad model out of the DAE Solution. It is dispatched via the machine type.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._make_reduced_jacobian_index-Tuple{Any, Any}","page":"Internal API Reference","title":"PowerSimulationsDynamics._make_reduced_jacobian_index","text":"Finds the location of the differential states in the reduced Jacobian\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._mechanical_torque-Tuple{DEGOV, String, SimulationResults, Union{Nothing, Float64}}","page":"Internal API Reference","title":"PowerSimulationsDynamics._mechanical_torque","text":"Function to obtain the mechanical torque time series of a Dynamic Generator with DEGOV Turbine Governor.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._mechanical_torque-Tuple{GasTG, String, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics._mechanical_torque","text":"Function to obtain the mechanical torque time series of a Dynamic Generator with GasTG (GAST) Turbine Governor.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._mechanical_torque-Tuple{HydroTurbineGov, String, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics._mechanical_torque","text":"Function to obtain the mechanical torque time series of a Dynamic Generator with HydroTurbineGov (HYGOV) Turbine Governor.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._mechanical_torque-Tuple{SteamTurbineGov1, String, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics._mechanical_torque","text":"Function to obtain the mechanical torque time series of a Dynamic Generator with SteamTurbineGov1 (TGOV1) Turbine Governor.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._mechanical_torque-Tuple{TGFixed, String, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics._mechanical_torque","text":"Function to obtain the mechanical torque time series of a Dynamic Generator with TGFixed Turbine Governor.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._mechanical_torque-Tuple{TGTypeI, String, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics._mechanical_torque","text":"Function to obtain the mechanical torque time series of a Dynamic Generator with TGTypeI Turbine Governor.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._mechanical_torque-Tuple{TGTypeII, String, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics._mechanical_torque","text":"Function to obtain the mechanical torque time series of a Dynamic Generator with TGTypeII Turbine Governor.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._output_current-Union{Tuple{G}, Tuple{C}, Tuple{LCLFilter, C, String, Vector{Float64}, Vector{Float64}, Float64, SimulationResults, G, Union{Nothing, Float64, Vector{Float64}}}} where {C<:Converter, G<:DynamicInverter}","page":"Internal API Reference","title":"PowerSimulationsDynamics._output_current","text":"Function to obtain the output current time series of a LCL Filter model out of the DAE Solution. It is dispatched via the Filter type.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._output_current-Union{Tuple{G}, Tuple{RLFilter, RenewableEnergyConverterTypeA, String, Vector{Float64}, Vector{Float64}, Float64, SimulationResults, G, Union{Nothing, Float64, Vector{Float64}}}} where G<:DynamicInverter","page":"Internal API Reference","title":"PowerSimulationsDynamics._output_current","text":"Function to obtain the output current time series of a REGCA converter model out of the DAE Solution. It is dispatched via the Converter type.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._post_proc_state_series-Tuple{Any, Int64, Nothing}","page":"Internal API Reference","title":"PowerSimulationsDynamics._post_proc_state_series","text":"Internal function to obtain as a Vector of Float64 of a specific state. It receives the solution and the global index for a state.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._pss_output-Tuple{IEEEST, String, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics._pss_output","text":"Function to obtain the pss output time series of a Dynamic Generator with pss IEEEST.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics._pss_output-Tuple{PSSFixed, String, SimulationResults, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics._pss_output","text":"Function to obtain the pss output time series of a Dynamic Generator with pss PSSFixed.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.compute_field_current-Union{Tuple{G}, Tuple{SimulationResults, G, Vector{Float64}, Vector{Float64}, Union{Nothing, Float64, Vector{Float64}}}} where G<:DynamicGenerator","page":"Internal API Reference","title":"PowerSimulationsDynamics.compute_field_current","text":"Function to obtain the field current time series of a Dynamic Generator model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage. It is dispatched for device type to compute the specific current.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.compute_field_current-Union{Tuple{G}, Tuple{SimulationResults, G, Vector{Float64}, Vector{Float64}, Union{Nothing, Float64, Vector{Float64}}}} where G<:DynamicInverter","page":"Internal API Reference","title":"PowerSimulationsDynamics.compute_field_current","text":"Function to obtain the field current time series of a Dynamic Inverter model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage. It must return nothing since field current does not exists in inverters.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.compute_field_voltage-Union{Tuple{G}, Tuple{SimulationResults, G, Union{Nothing, Float64, Vector{Float64}}}} where G<:DynamicGenerator","page":"Internal API Reference","title":"PowerSimulationsDynamics.compute_field_voltage","text":"Function to obtain the field voltage time series of a Dynamic Generator model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage. It is dispatched for device type to compute the specific voltage.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.compute_field_voltage-Union{Tuple{G}, Tuple{SimulationResults, G, Union{Nothing, Float64, Vector{Float64}}}} where G<:DynamicInverter","page":"Internal API Reference","title":"PowerSimulationsDynamics.compute_field_voltage","text":"Function to obtain the field current time series of a Dynamic Inverter model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage. It must return nothing since field voltage does not exists in inverters.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.compute_frequency-Union{Tuple{G}, Tuple{SimulationResults, G, Union{Nothing, Float64, Vector{Float64}}}} where G<:DynamicGenerator","page":"Internal API Reference","title":"PowerSimulationsDynamics.compute_frequency","text":"Function to obtain the output frequency time series of a DynamicGenerator\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.compute_mechanical_torque-Union{Tuple{G}, Tuple{SimulationResults, G, Union{Nothing, Float64, Vector{Float64}}}} where G<:DynamicGenerator","page":"Internal API Reference","title":"PowerSimulationsDynamics.compute_mechanical_torque","text":"Function to obtain the mechanical torque time series of a Dynamic Generator model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage. It is dispatched for device type to compute the specific torque.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.compute_mechanical_torque-Union{Tuple{G}, Tuple{SimulationResults, G, Union{Nothing, Float64, Vector{Float64}}}} where G<:DynamicInverter","page":"Internal API Reference","title":"PowerSimulationsDynamics.compute_mechanical_torque","text":"Function to obtain the mechanical torque time series of a Dynamic Inverter model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage. It must return nothing since mechanical torque is not used in inverters.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.compute_output_current-Tuple{SimulationResults, AggregateDistributedGenerationA, Vector{Float64}, Vector{Float64}, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.compute_output_current","text":"Function to obtain the output current time series of a AggregateDistributedGenerationA (DERA) model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.compute_output_current-Tuple{SimulationResults, ExponentialLoad, Vector{Float64}, Vector{Float64}, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.compute_output_current","text":"Function to obtain the output current time series of a ExponentialLoad model. \n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.compute_output_current-Tuple{SimulationResults, PeriodicVariableSource, Vector{Float64}, Vector{Float64}, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.compute_output_current","text":"Function to obtain the output current time series of a PeriodicVariableSource model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage. It is dispatched for device type to compute the specific current. computeoutputcurrent(::SimulationResults, ::PeriodicVariableSource, ::Vector{Float64}, ::Vector{Float64}, ::Nothing)\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.compute_output_current-Tuple{SimulationResults, PowerLoad, Vector{Float64}, Vector{Float64}, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.compute_output_current","text":"Function to obtain the output current time series of a PowerLoad model. \n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.compute_output_current-Tuple{SimulationResults, SimplifiedSingleCageInductionMachine, Vector{Float64}, Vector{Float64}, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.compute_output_current","text":"Function to obtain the output current time series of a 3th Order Induction Machine model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage. \n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.compute_output_current-Tuple{SimulationResults, SingleCageInductionMachine, Vector{Float64}, Vector{Float64}, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.compute_output_current","text":"Function to obtain the output current time series of a 5th Order Induction Machine model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage. \n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.compute_output_current-Tuple{SimulationResults, StandardLoad, Vector{Float64}, Vector{Float64}, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.compute_output_current","text":"Function to obtain the output current time series of a PowerLoad model. \n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.compute_output_current-Union{Tuple{G}, Tuple{SimulationResults, G, Vector{Float64}, Vector{Float64}, Union{Nothing, Float64, Vector{Float64}}}} where G<:DynamicGenerator","page":"Internal API Reference","title":"PowerSimulationsDynamics.compute_output_current","text":"Function to obtain the output current time series of a Dynamic Generator model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage. It is dispatched for device type to compute the specific current.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.compute_output_current-Union{Tuple{G}, Tuple{SimulationResults, G, Vector{Float64}, Vector{Float64}, Union{Nothing, Float64, Vector{Float64}}}} where G<:DynamicInverter","page":"Internal API Reference","title":"PowerSimulationsDynamics.compute_output_current","text":"Function to obtain the output current time series of a Dynamic Inverter model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage. It is dispatched for device type to compute the specific current.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.compute_output_current-Union{Tuple{I}, Tuple{SimulationResults, I, Vector{Float64}, Vector{Float64}, Union{Nothing, Float64, Vector{Float64}}}} where I<:DynamicInjection","page":"Internal API Reference","title":"PowerSimulationsDynamics.compute_output_current","text":"Default function to compute output current. Returns an error\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.compute_pss_output-Union{Tuple{G}, Tuple{SimulationResults, G, Union{Nothing, Float64, Vector{Float64}}}} where G<:DynamicGenerator","page":"Internal API Reference","title":"PowerSimulationsDynamics.compute_pss_output","text":"Function to obtain the pss output time series of a Dynamic Generator model out of the DAE Solution. It receives the simulation inputs, the dynamic device and bus voltage. It is dispatched for device type to compute the specific output.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.configure_logging-Tuple{}","page":"Internal API Reference","title":"PowerSimulationsDynamics.configure_logging","text":"configure_logging(;\n console_level = Logging.Error,\n file_level = Logging.Info,\n filename = \"power-simulations.log\",\n)\n\nCreates console and file loggers.\n\nNote: Log messages may not be written to the file until flush() or close() is called on the returned logger.\n\nArguments\n\nconsole_level = Logging.Error: level for console messages\nfile_level = Logging.Info: level for file messages\nfilename::String = power-simulations.log: log file\n\nExample\n\nlogger = configure_logging(console_level = Logging.Info)\n@info \"log message\"\nclose(logger)\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.device!-Union{Tuple{T}, Tuple{AbstractArray{T}, AbstractArray{T}, T, T, AbstractArray{T}, AbstractArray{T}, AbstractArray{T}, AbstractArray{T}, PowerSimulationsDynamics.DynamicWrapper{ActiveConstantPowerLoad}, Any, Any}} where T<:Union{Float64, ForwardDiff.Dual}","page":"Internal API Reference","title":"PowerSimulationsDynamics.device!","text":"Model of 12-state Active Constant Power Load in Julia. Based on the paper Malicious Control of an Active Load in an Islanded Mixed-Source Microgrid by C. Roberts, U. Markovic, D. Arnold and D. Callaway.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.device!-Union{Tuple{T}, Tuple{AbstractArray{T}, AbstractArray{T}, T, T, AbstractArray{T}, AbstractArray{T}, AbstractArray{T}, AbstractArray{T}, PowerSimulationsDynamics.DynamicWrapper{CSVGN1}, Any, Any}} where T<:Union{Float64, ForwardDiff.Dual}","page":"Internal API Reference","title":"PowerSimulationsDynamics.device!","text":"Model of Static Shunt Compensator: CSVGN1.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.device!-Union{Tuple{T}, Tuple{AbstractArray{T}, AbstractArray{T}, T, T, AbstractArray{T}, AbstractArray{T}, AbstractArray{T}, AbstractArray{T}, PowerSimulationsDynamics.DynamicWrapper{SimplifiedSingleCageInductionMachine}, Any, Any}} where T<:Union{Float64, ForwardDiff.Dual}","page":"Internal API Reference","title":"PowerSimulationsDynamics.device!","text":"Model of 3-state (SimplifiedSingleCageInductionMachine) induction motor in Julia. Based on the 3rd order model derived in Prabha Kundur's Book and the equations in \"Analysis of Electric Machinery and Drive Systems\" by Paul Krause, Oleg Wasynczuk and Scott Sudhoff.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.device!-Union{Tuple{T}, Tuple{AbstractArray{T}, AbstractArray{T}, T, T, AbstractArray{T}, AbstractArray{T}, AbstractArray{T}, AbstractArray{T}, PowerSimulationsDynamics.DynamicWrapper{SingleCageInductionMachine}, Any, Any}} where T<:Union{Float64, ForwardDiff.Dual}","page":"Internal API Reference","title":"PowerSimulationsDynamics.device!","text":"Model of 5-state (SingleCageInductionMachine) induction motor in Julia. Refer to \"Analysis of Electric Machinery and Drive Systems\" by Paul Krause, Oleg Wasynczuk and Scott Sudhoff for the equations\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.initialize_mach_shaft!-Union{Tuple{P}, Tuple{TG}, Tuple{A}, Tuple{S}, Tuple{Any, StaticInjection, PowerSimulationsDynamics.DynamicWrapper{DynamicGenerator{AndersonFouadMachine, S, A, TG, P}}, AbstractVector}} where {S<:Shaft, A<:AVR, TG<:TurbineGov, P<:PSS}","page":"Internal API Reference","title":"PowerSimulationsDynamics.initialize_mach_shaft!","text":"Initialitation of model of 6-state (Anderson-Fouad) synchronous machine in Julia. Refer to Power System Modelling and Scripting by F. Milano for the equations\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.initialize_mach_shaft!-Union{Tuple{P}, Tuple{TG}, Tuple{A}, Tuple{S}, Tuple{Any, StaticInjection, PowerSimulationsDynamics.DynamicWrapper{DynamicGenerator{BaseMachine, S, A, TG, P}}, AbstractVector}} where {S<:Shaft, A<:AVR, TG<:TurbineGov, P<:PSS}","page":"Internal API Reference","title":"PowerSimulationsDynamics.initialize_mach_shaft!","text":"Initialitation of model of 0-state synchronous (classic model) machine in Julia. Refer to Power System Modelling and Scripting by F. Milano for the equations\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.initialize_mach_shaft!-Union{Tuple{P}, Tuple{TG}, Tuple{A}, Tuple{S}, Tuple{Any, StaticInjection, PowerSimulationsDynamics.DynamicWrapper{DynamicGenerator{MarconatoMachine, S, A, TG, P}}, AbstractVector}} where {S<:Shaft, A<:AVR, TG<:TurbineGov, P<:PSS}","page":"Internal API Reference","title":"PowerSimulationsDynamics.initialize_mach_shaft!","text":"Initialitation of model of 6-state (Marconato) synchronous machine in Julia. Refer to Power System Modelling and Scripting by F. Milano for the equations\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.initialize_mach_shaft!-Union{Tuple{P}, Tuple{TG}, Tuple{A}, Tuple{S}, Tuple{Any, StaticInjection, PowerSimulationsDynamics.DynamicWrapper{DynamicGenerator{OneDOneQMachine, S, A, TG, P}}, AbstractVector}} where {S<:Shaft, A<:AVR, TG<:TurbineGov, P<:PSS}","page":"Internal API Reference","title":"PowerSimulationsDynamics.initialize_mach_shaft!","text":"Initialitation of model of 2-state (One d- and One q-) synchronous machine in Julia. Refer to Power System Modelling and Scripting by F. Milano for the equations\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.initialize_mach_shaft!-Union{Tuple{P}, Tuple{TG}, Tuple{A}, Tuple{S}, Tuple{Any, StaticInjection, PowerSimulationsDynamics.DynamicWrapper{DynamicGenerator{SauerPaiMachine, S, A, TG, P}}, AbstractVector}} where {S<:Shaft, A<:AVR, TG<:TurbineGov, P<:PSS}","page":"Internal API Reference","title":"PowerSimulationsDynamics.initialize_mach_shaft!","text":"Initialitation of model of 6-state (SauerPai) synchronous machine in Julia. Refer to Power System Modelling and Scripting by F. Milano for the equations\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.initialize_mach_shaft!-Union{Tuple{P}, Tuple{TG}, Tuple{A}, Tuple{S}, Tuple{Any, StaticInjection, PowerSimulationsDynamics.DynamicWrapper{DynamicGenerator{SimpleAFMachine, S, A, TG, P}}, AbstractVector}} where {S<:Shaft, A<:AVR, TG<:TurbineGov, P<:PSS}","page":"Internal API Reference","title":"PowerSimulationsDynamics.initialize_mach_shaft!","text":"Initialitation of model of 4-state (Simple Anderson-Fouad) synchronous machine in Julia. Refer to Power System Modelling and Scripting by F. Milano for the equations\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.initialize_mach_shaft!-Union{Tuple{P}, Tuple{TG}, Tuple{A}, Tuple{S}, Tuple{Any, StaticInjection, PowerSimulationsDynamics.DynamicWrapper{DynamicGenerator{SimpleMarconatoMachine, S, A, TG, P}}, AbstractVector}} where {S<:Shaft, A<:AVR, TG<:TurbineGov, P<:PSS}","page":"Internal API Reference","title":"PowerSimulationsDynamics.initialize_mach_shaft!","text":"Initialitation of model of 4-state (Simple Marconato) synchronous machine in Julia. Refer to Power System Modelling and Scripting by F. Milano for the equations\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.low_pass_modified_mass_matrix-Union{Tuple{Z}, Tuple{W}, Tuple{V}, Tuple{Z, V, Float64, W, Float64}} where {V<:Union{Float64, ForwardDiff.Dual}, W<:Union{Float64, ForwardDiff.Dual}, Z<:Union{Float64, ForwardDiff.Dual}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.low_pass_modified_mass_matrix","text":"Low Pass Filter Modified ┌─────────────┐ │ K │ u -> │ ────────────│ -> y │ K_den + sT │ └─────────────┘\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.mass_matrix_entries-Tuple{DynamicInjection}","page":"Internal API Reference","title":"PowerSimulationsDynamics.mass_matrix_entries","text":"Default implementation of mass matrix entries. Keeps the default values in the identity matrix\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.mdl_machine_ode!-Union{Tuple{P}, Tuple{TG}, Tuple{A}, Tuple{S}, Tuple{AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, PowerSimulationsDynamics.DynamicWrapper{DynamicGenerator{AndersonFouadMachine, S, A, TG, P}}, Any, Any}} where {S<:Shaft, A<:AVR, TG<:TurbineGov, P<:PSS}","page":"Internal API Reference","title":"PowerSimulationsDynamics.mdl_machine_ode!","text":"Model of 6-state (AndersonFouadMachine) synchronous machine in Julia. Refer to Power System Modelling and Scripting by F. Milano for the equations\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.mdl_machine_ode!-Union{Tuple{P}, Tuple{TG}, Tuple{A}, Tuple{S}, Tuple{AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, PowerSimulationsDynamics.DynamicWrapper{DynamicGenerator{BaseMachine, S, A, TG, P}}, Any, Any}} where {S<:Shaft, A<:AVR, TG<:TurbineGov, P<:PSS}","page":"Internal API Reference","title":"PowerSimulationsDynamics.mdl_machine_ode!","text":"Model of 0-state synchronous machine in Julia. Refer to Power System Modelling and Scripting by F. Milano for the equations\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.mdl_machine_ode!-Union{Tuple{P}, Tuple{TG}, Tuple{A}, Tuple{S}, Tuple{AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, PowerSimulationsDynamics.DynamicWrapper{DynamicGenerator{MarconatoMachine, S, A, TG, P}}, Any, Any}} where {S<:Shaft, A<:AVR, TG<:TurbineGov, P<:PSS}","page":"Internal API Reference","title":"PowerSimulationsDynamics.mdl_machine_ode!","text":"Model of 6-state (MarconatoMachine) synchronous machine in Julia. Refer to Power System Modelling and Scripting by F. Milano for the equations\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.mdl_machine_ode!-Union{Tuple{P}, Tuple{TG}, Tuple{A}, Tuple{S}, Tuple{AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, PowerSimulationsDynamics.DynamicWrapper{DynamicGenerator{OneDOneQMachine, S, A, TG, P}}, Any, Any}} where {S<:Shaft, A<:AVR, TG<:TurbineGov, P<:PSS}","page":"Internal API Reference","title":"PowerSimulationsDynamics.mdl_machine_ode!","text":"Model of 2-state (One d- and One q-) synchronous machine in Julia. Refer to Power System Modelling and Scripting by F. Milano for the equations\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.mdl_machine_ode!-Union{Tuple{P}, Tuple{TG}, Tuple{A}, Tuple{S}, Tuple{AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, PowerSimulationsDynamics.DynamicWrapper{DynamicGenerator{SauerPaiMachine, S, A, TG, P}}, Any, Any}} where {S<:Shaft, A<:AVR, TG<:TurbineGov, P<:PSS}","page":"Internal API Reference","title":"PowerSimulationsDynamics.mdl_machine_ode!","text":"Model of 6-state (SauerPaiMachine) synchronous machine in Julia. Refer to Power System Modelling and Scripting by F. Milano for the equations\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.mdl_machine_ode!-Union{Tuple{P}, Tuple{TG}, Tuple{A}, Tuple{S}, Tuple{AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, PowerSimulationsDynamics.DynamicWrapper{DynamicGenerator{SimpleAFMachine, S, A, TG, P}}, Any, Any}} where {S<:Shaft, A<:AVR, TG<:TurbineGov, P<:PSS}","page":"Internal API Reference","title":"PowerSimulationsDynamics.mdl_machine_ode!","text":"Model of 4-state (SimpleAFMachine) synchronous machine in Julia. Refer to Power System Modelling and Scripting by F. Milano for the equations\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.mdl_machine_ode!-Union{Tuple{P}, Tuple{TG}, Tuple{A}, Tuple{S}, Tuple{AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, AbstractArray{<:Union{Float64, ForwardDiff.Dual}}, PowerSimulationsDynamics.DynamicWrapper{DynamicGenerator{SimpleMarconatoMachine, S, A, TG, P}}, Any, Any}} where {S<:Shaft, A<:AVR, TG<:TurbineGov, P<:PSS}","page":"Internal API Reference","title":"PowerSimulationsDynamics.mdl_machine_ode!","text":"Model of 4-state (SimpleMarconatoMachine) synchronous machine in Julia. Refer to Power System Modelling and Scripting by F. Milano for the equations\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.mdl_zip_load!-Union{Tuple{T}, Tuple{T, T, AbstractArray{T}, AbstractArray{T}, PowerSimulationsDynamics.StaticLoadWrapper}} where T<:Union{Float64, ForwardDiff.Dual}","page":"Internal API Reference","title":"PowerSimulationsDynamics.mdl_zip_load!","text":"Model for ZIP Load model given by:\n\nPzip = Ppower + Pcurrent * (V / V0) + Pimpedance * (V / V0)^2 Qzip = Qpower + Qcurrent * (V / V0) + Qimpedance * (V / V0)^2\n\nwith V = sqrt(Vr^2 + Vi^2) and V0 the voltage magnitude from the power flow solution\n\nThe current taken for the load is computed as: Izip = (Pzip + j Qzip)^* / (Vr + j Vi)^* Izip = (Pzip - j Qzip) / (Vr - j Vi)\n\nFor constant impedance it is obtained: Izre = (1 / V0)^2 * (Vr * Pimpedance + Vi * Qimpedance) Izim = (1 / V0)^2 * (Vi * Pimpedance - Vr * Qimpedance)\n\nFor constant current it is obtained: Iire = (1 / V0) * ( (Vr * Pcurrent + Vi * Qcurrent) / V ) Iiim = (1 / V0) * ( (Vi * Pcurrent - Vr * Qcurrent) / V )\n\nFor constant power it is obtained: Ipre = (Vr * Ppower + Vi * Qpower) / V^2 Ipim = (Vi * Ppower - Vr * Qpower) / V^2\n\nModel for Exponential Load model given by:\n\nPexp = P0 * (V / V0)^α Qexp = Q0 * (V / V0)^β\n\nThe current taken for the load is computed as: Iexp = (Pexp + j Qexp)^* / (Vr + j Vi)^* Iexp = (Pexp - j Qexp) / (Vr - j Vi)\n\nIt results: Irexp = Vr * P0 * (V^(α - 2) / V0^α) + Vi * Q0 * (V^(β - 2)/ V0^β) Iiim = Vi * P0 * (V^(α - 2) / V0^α) - Vr * Q0 * (V^(β - 2)/ V0^β)\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.post_proc_activepower_series-Tuple{SimulationResults, String, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.post_proc_activepower_series","text":"Function to compute the active power output time series of a Dynamic Injection series out of the DAE Solution. It receives the solution and the string name of the Dynamic Injection device.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.post_proc_branch_series-Tuple{SimulationResults, String, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.post_proc_branch_series","text":"Function to compute the current flowing through an AC branch through their series element. The current is computed through the from bus into the to bus.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.post_proc_field_current_series-Tuple{SimulationResults, String, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.post_proc_field_current_series","text":"Function to compute the field current output time series of a Dynamic Injection series out of the DAE Solution. It receives the solution and the string name of the Dynamic Injection device.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.post_proc_field_voltage_series-Tuple{SimulationResults, String, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.post_proc_field_voltage_series","text":"Function to compute the field voltage output time series of a Dynamic Injection series out of the DAE Solution. It receives the solution and the string name of the Dynamic Injection device.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.post_proc_frequency_series-Tuple{SimulationResults, String, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.post_proc_frequency_series","text":"Function to compute the frequency of a Dynamic Injection component.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.post_proc_imaginary_current_series-Tuple{SimulationResults, String, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.post_proc_imaginary_current_series","text":"Function to compute the imaginary current output time series of a Dynamic Injection series out of the DAE Solution. It receives the solution and the string name of the Dynamic Injection device.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.post_proc_mechanical_torque_series-Tuple{SimulationResults, String, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.post_proc_mechanical_torque_series","text":"Function to compute the mechanical torque output time series of a Dynamic Injection series out of the DAE Solution. It receives the solution and the string name of the Dynamic Injection device.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.post_proc_pss_output_series-Tuple{SimulationResults, String, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.post_proc_pss_output_series","text":"Function to compute the pss output time series of a Dynamic Injection series out of the DAE Solution. It receives the solution and the string name of the Dynamic Injection device.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.post_proc_reactivepower_series-Tuple{SimulationResults, String, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.post_proc_reactivepower_series","text":"Function to compute the active power output time series of a Dynamic Injection series out of the DAE Solution. It receives the solution and the string name of the Dynamic Injection device.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.post_proc_real_current_series-Tuple{SimulationResults, String, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.post_proc_real_current_series","text":"Function to compute the real current output time series of a Dynamic Injection series out of the DAE Solution. It receives the solution and the string name of the Dynamic Injection device.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.post_proc_source_voltage_current_series","page":"Internal API Reference","title":"PowerSimulationsDynamics.post_proc_source_voltage_current_series","text":"Function to obtain voltage and output currents for a source. It receives the simulation resutls and an optional argument of the time step of the results.\n\n\n\n\n\n","category":"function"},{"location":"api/internal/#PowerSimulationsDynamics.post_proc_state_series-Tuple{SimulationResults, Tuple{String, Symbol}, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.post_proc_state_series","text":"Function to obtain the state time series of a specific state. It receives the simulation, and a tuple containing the name of the Dynamic Device and the symbol of the state.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.post_proc_voltage_current_series-Tuple{SimulationResults, String, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.post_proc_voltage_current_series","text":"Function to obtain voltage and output currents for a dynamic device. It receives the simulation, and the name of the Dynamic Device.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.post_proc_voltage_series-Tuple{Any, Int64, Int64, Union{Nothing, Float64, Vector{Float64}}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.post_proc_voltage_series","text":"Function to obtain voltage using the bus index (and not the bus number). It receives the solution, the bus index and the total number of buses.\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.saturation_function-Tuple{Union{RoundRotorExponential, SalientPoleExponential}, Union{Float64, ForwardDiff.Dual}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.saturation_function","text":"Saturation function for exponential saturation models for machines\n Se(x) = B * x^A\n\n\n\n\n\n","category":"method"},{"location":"api/internal/#PowerSimulationsDynamics.saturation_function-Tuple{Union{RoundRotorQuadratic, SalientPoleQuadratic}, Union{Float64, ForwardDiff.Dual}}","page":"Internal API Reference","title":"PowerSimulationsDynamics.saturation_function","text":"Saturation function for quadratic saturation models for machines\n Se(x) = B * (x - A)^2 / x\n\n\n\n\n\n","category":"method"},{"location":"component_models/converter/#Converter","page":"Converter","title":"Converter","text":"","category":"section"},{"location":"component_models/converter/","page":"Converter","title":"Converter","text":"This component can be used to model the dynamics of the switching process.","category":"page"},{"location":"component_models/converter/#Average-Model-[AverageConverter]","page":"Converter","title":"Average Model [AverageConverter]","text":"","category":"section"},{"location":"component_models/converter/","page":"Converter","title":"Converter","text":"The average model outputs the desired reference signal since:","category":"page"},{"location":"component_models/converter/","page":"Converter","title":"Converter","text":"beginalign\nv_d^textcv approx m_d v_textdc approx fracv_d^textref-signalv_textdc v_textdc approx v_d^textref-signal tag1a \nv_q^textcv approx m_q v_textdc approx fracv_q^textref-signalv_textdc v_textdc approx v_q^textref-signal tag1b\nendalign","category":"page"},{"location":"component_models/converter/","page":"Converter","title":"Converter","text":"where m_dq is the modulation signal, and v_dq^textref-signal is the voltage reference signal from the inner loop control.","category":"page"},{"location":"component_models/converter/#Generic-Renewable-Converter-Type-A-[RenewableEnergyConverterTypeA]","page":"Converter","title":"Generic Renewable Converter Type A ```[RenewableEnergyConverterTypeA]","text":"","category":"section"},{"location":"component_models/converter/","page":"Converter","title":"Converter","text":"This block represents the REGCA model. The equations (without the limiters) are:","category":"page"},{"location":"component_models/converter/","page":"Converter","title":"Converter","text":"beginalign\n dotI_p = frac1T_g (I_textpcmd - I_p) tag2a \n dotI_q = frac1T_g (I_textqcmd - I_q) tag2b \n dotV_textmeas = frac1T_fltr (V_t - V_textmeas tag2c)\nendalign","category":"page"},{"location":"component_models/converter/","page":"Converter","title":"Converter","text":"on which I_textpcmd and I_textqcmd are the current commands from the inner control and V_t is the bus voltage magnitude. The additional terms and output current are computed as:","category":"page"},{"location":"component_models/converter/","page":"Converter","title":"Converter","text":"beginalign\n I_q^textcv = -I_q - I_textqextra tag2d \n I_textqextra = max(K_hv (V_t - V_textolim)) tag2e \n I_p^textcv = G_lv I_p tag2f \nendalign","category":"page"},{"location":"component_models/converter/","page":"Converter","title":"Converter","text":"on which G_lv is the gain used for Low Voltage Active Current Management and I_textqextra is the additional current for High Voltage Reactive Current Management.","category":"page"},{"location":"component_models/converter/","page":"Converter","title":"Converter","text":"It is important to note that both current commands coming from the inner control were obtained by dividing the active (or reactive) power by the magnitude voltage instead of using the correct phasor formula I = (SV)^*. For that purpose, a correction factor must be applied to obtain the correct output currents in the network reference frame:","category":"page"},{"location":"component_models/converter/","page":"Converter","title":"Converter","text":"beginalign*\n I_r + jI_i = (I_p + jI_q) cdot V_t cdot frac1V_r + jV_i \n = (I_p + jI_q) cdot fracV_tV_t e^jtheta \n = (I_p + jI_q) cdot e^-jtheta\nendalign*","category":"page"},{"location":"component_models/converter/","page":"Converter","title":"Converter","text":"This correction factor looks like a reference transformation that must be used to properly inject current into the grid. With that the output current is computed as:","category":"page"},{"location":"component_models/converter/","page":"Converter","title":"Converter","text":"beginalign\n I_r = I_p^textcv cos(theta) - I_q^textcv sin(theta) tag2g \n I_i = I_p^textcv sin(theta) + I_q^textcv cos(theta) tag2h\nendalign","category":"page"},{"location":"component_models/converter/","page":"Converter","title":"Converter","text":"This current source is usually modeled as a Norton equivalent using a parallel impedance with values R_sorce and X_sorce provided in the .raw file. If an RL filter is used, a Voltage Source behind that RL filter (i.e. the converter output voltage) can be computed as:","category":"page"},{"location":"component_models/converter/","page":"Converter","title":"Converter","text":"beginalign*\n Z_f = r_f + jl_f \n Z_sorce = R_sorce + jX_sorce \n I_cv = I_r + jI_i \n v_r^textcv + jv_i^textcv = fracI_cv + fracv^textgridZ_ffrac1Z_sorce + frac1Z_f tag2i\nendalign*","category":"page"},{"location":"#PowerSimulationsDynamics.jl","page":"Welcome Page","title":"PowerSimulationsDynamics.jl","text":"","category":"section"},{"location":"","page":"Welcome Page","title":"Welcome Page","text":"CurrentModule = PowerSimulationsDynamics","category":"page"},{"location":"#Overview","page":"Welcome Page","title":"Overview","text":"","category":"section"},{"location":"","page":"Welcome Page","title":"Welcome Page","text":"PowerSimulationsDynamics.jl is a Julia package for doing Power Systems Dynamic Modeling with Low Inertia Energy Sources.","category":"page"},{"location":"","page":"Welcome Page","title":"Welcome Page","text":"The synchronous machine components supported here are based on commercial models and the academic components are derived from Power System Modelling and Scripting.","category":"page"},{"location":"","page":"Welcome Page","title":"Welcome Page","text":"Inverter models support both commercial models, such as REPC, REEC and REGC type of models; and academic models obtained from grid-following and grid-forming literature such as in \"A Virtual Synchronous Machine implementation for distributed control of power converters in SmartGrids\"","category":"page"},{"location":"","page":"Welcome Page","title":"Welcome Page","text":"The background work on PowerSimulationsDynamics.jl is explained in Revisiting Power Systems Time-domain Simulation Methods and Models","category":"page"},{"location":"","page":"Welcome Page","title":"Welcome Page","text":"@article{lara2023revisiting,\ntitle={Revisiting Power Systems Time-domain Simulation Methods and Models},\nauthor={Lara, Jose Daniel and Henriquez-Auba, Rodrigo and Ramasubramanian, Deepak and Dhople, Sairaj and Callaway, Duncan S and Sanders, Seth},\njournal={arXiv preprint arXiv:2301.10043},\nyear={2023}\n}","category":"page"},{"location":"#Installation","page":"Welcome Page","title":"Installation","text":"","category":"section"},{"location":"","page":"Welcome Page","title":"Welcome Page","text":"The latest stable release of PowerSimulationsDynamics.jl can be installed using the Julia package manager with","category":"page"},{"location":"","page":"Welcome Page","title":"Welcome Page","text":"] add PowerSimulationsDynamics","category":"page"},{"location":"","page":"Welcome Page","title":"Welcome Page","text":"For the current development version, \"checkout\" this package with","category":"page"},{"location":"","page":"Welcome Page","title":"Welcome Page","text":"] add PowerSimulationsDynamics#master","category":"page"},{"location":"#Structure","page":"Welcome Page","title":"Structure","text":"","category":"section"},{"location":"","page":"Welcome Page","title":"Welcome Page","text":"The following figure shows the interactions between PowerSimulationsDynamics.jl, PowerSystems.jl, ForwardDiff.jl, DiffEqBase.jl and the integrators. The architecture of PowerSimulationsDynamics.jl is such that the power system models are all self-contained and return the model function evaluations. The Jacobian is calculated using automatic differentiation through ForwardDiff.jl, that is used for both numerical integration and small signal analysis. Considering that the resulting models are differential-algebraic equations (DAE), the implementation focuses on the use of implicit solvers, in particular BDF and Rosenbrock methods.","category":"page"},{"location":"","page":"Welcome Page","title":"Welcome Page","text":"","category":"page"},{"location":"","page":"Welcome Page","title":"Welcome Page","text":"⠀","category":"page"},{"location":"","page":"Welcome Page","title":"Welcome Page","text":"","category":"page"},{"location":"","page":"Welcome Page","title":"Welcome Page","text":"PowerSimulationsDynamics.jl has been developed as part of the Scalable Integrated Infrastructure Planning (SIIP) initiative at the U.S. Department of Energy's National Renewable Energy Laboratory (NREL)","category":"page"},{"location":"generic/#Industrial-(Generic)-Renewable-Models","page":"Industrial Renewable Models","title":"Industrial (Generic) Renewable Models","text":"","category":"section"},{"location":"generic/#Connection-with-the-Inverter-Metamodel","page":"Industrial Renewable Models","title":"Connection with the Inverter Metamodel","text":"","category":"section"},{"location":"generic/","page":"Industrial Renewable Models","title":"Industrial Renewable Models","text":"Generic Renewable Models for PV solar or battery devices used in industrial tools, such as PSS/E or PowerWorld, does not necessary resemble the proposed structure of our proposed metamodel. ","category":"page"},{"location":"generic/","page":"Industrial Renewable Models","title":"Industrial Renewable Models","text":"In general terms, a generic renewable model (for PV plant or battery) is typically a Grid Following inverter that uses a Renewable Energy Plant Controller (REPC), a Renewable Energy Electrical Controller (REEC) and a Renewable Energy Generic Converter (REGC) model. The following figure is useful to understand the general structure of such models:","category":"page"},{"location":"generic/","page":"Industrial Renewable Models","title":"Industrial Renewable Models","text":"","category":"page"},{"location":"generic/","page":"Industrial Renewable Models","title":"Industrial Renewable Models","text":"In comparison to the proposed inverter metamodel it is clear that the REPC resembles the Outer Control. However, the REEC has a purpose of both Outer Control and Inner Control and the REGC has a similar purpose of the Converter and Filter in the proposed structure. For such purpose, it was necessary to split the REEC and part of its model was included in both Outer Control and Inner Control.","category":"page"},{"location":"generic/#Example-of-implementation-of-generic-models","page":"Industrial Renewable Models","title":"Example of implementation of generic models","text":"","category":"section"},{"location":"generic/","page":"Industrial Renewable Models","title":"Industrial Renewable Models","text":"The following includes examples of the implementation of the proposed model in the inverter metamodel.","category":"page"},{"location":"generic/#Active-Renewable-Outer-Control","page":"Industrial Renewable Models","title":"Active Renewable Outer Control","text":"","category":"section"},{"location":"generic/","page":"Industrial Renewable Models","title":"Industrial Renewable Models","text":"The following example join the active power controllers from REPCA and REECB as ActiveRenewableControllerAB in PowerSimulationsDynamics.jl","category":"page"},{"location":"generic/","page":"Industrial Renewable Models","title":"Industrial Renewable Models","text":"","category":"page"},{"location":"generic/","page":"Industrial Renewable Models","title":"Industrial Renewable Models","text":"⠀","category":"page"},{"location":"generic/","page":"Industrial Renewable Models","title":"Industrial Renewable Models","text":"An important thing to consider with the industrial models, is that the change of Flags can significantly vary the model and purpose of the controller.","category":"page"},{"location":"generic/#Reactive-Renewable-Outer-Control","page":"Industrial Renewable Models","title":"Reactive Renewable Outer Control","text":"","category":"section"},{"location":"generic/","page":"Industrial Renewable Models","title":"Industrial Renewable Models","text":"Similar to the active controller, the following figure presents the reactive controller part from REPCA and REECB as ReactiveRenewableControllerAB in PowerSimulationsDynamics.jl","category":"page"},{"location":"generic/","page":"Industrial Renewable Models","title":"Industrial Renewable Models","text":"","category":"page"},{"location":"generic/","page":"Industrial Renewable Models","title":"Industrial Renewable Models","text":"⠀","category":"page"},{"location":"generic/#Inner-Controller","page":"Industrial Renewable Models","title":"Inner Controller","text":"","category":"section"},{"location":"generic/","page":"Industrial Renewable Models","title":"Industrial Renewable Models","text":"Finally, the remaining part from REECB was included RECurrentControllerB","category":"page"},{"location":"generic/","page":"Industrial Renewable Models","title":"Industrial Renewable Models","text":"","category":"page"},{"location":"generic/","page":"Industrial Renewable Models","title":"Industrial Renewable Models","text":"⠀","category":"page"},{"location":"generic/","page":"Industrial Renewable Models","title":"Industrial Renewable Models","text":"The REGCAmodel was directly included in a Converter Block, and the filter can be bypassed using an RLFilter block with rf = lf = 0.","category":"page"},{"location":"generic/#Current-availability-of-model-flags-in-PSID","page":"Industrial Renewable Models","title":"Current availability of model flags in PSID","text":"","category":"section"},{"location":"generic/#Active-Controller","page":"Industrial Renewable Models","title":"Active Controller","text":"","category":"section"},{"location":"generic/","page":"Industrial Renewable Models","title":"Industrial Renewable Models","text":"For the active controller, both Freq_Flag = 0 (ignoring frequency regulation) and Freq_Flag = 1 (considering frequency regulation) are available.","category":"page"},{"location":"generic/#Reactive-Controller","page":"Industrial Renewable Models","title":"Reactive Controller","text":"","category":"section"},{"location":"generic/","page":"Industrial Renewable Models","title":"Industrial Renewable Models","text":"The following table describes the current available combination of flags in PSID:","category":"page"},{"location":"generic/","page":"Industrial Renewable Models","title":"Industrial Renewable Models","text":"REF_Flag PF_Flag V_Flag Q_Flag\n0 0 0 0\n0 0 1 0\n1 0 1 1\n1 0 0 0","category":"page"},{"location":"generic/","page":"Industrial Renewable Models","title":"Industrial Renewable Models","text":"Any combination outside of these cases may not converge to a feasible operating point. Check the following CAISO report for the description and compliance of each flag combination.","category":"page"}] } diff --git a/dev/small/index.html b/dev/small/index.html index 924d7670a..4c0875186 100644 --- a/dev/small/index.html +++ b/dev/small/index.html @@ -29,4 +29,4 @@ \Delta \dot{x} = J_{\text{red}} \Delta x \end{align}\]

      on which we can compute its eigenvalues to analyze local stability.

      Accessing the Jacobian function

      You can retrieve the Jacobian function for a simulation using the get_jacobian function as follows:

      jacobian = function get_jacobian(ResidualModel, system)

      optionally you can pass the number of iterations to check for sparsity as follows:

      jacobian = function get_jacobian(ResidualModel, system, 0)

      if you specify 0, the jacobian function will use a full matrix.

      The return of get_jacobian is known as a functor in Julia and can be used to make evaluations. Currently, any function can be evaluated with the following inputs:

      jacobian(x)

      This version of the function is type unstable should only be used for non-critial ops. It works to get the eigenvalues given an operating point x

      jacobian(JM, x)

      This version evaluates in place the value of the jacobian for an operating point x and writes to the matrix JM

      jacobian(JM, x, p, t)

      This version complied with the requirements to be used in DiffEq for ODE solvers. p and t aren't used they just mean to match the interfaces. See DiffEqDocs

      jacobian(JM, dx, x, p, gamma, t)

      This version complied with the requirements to be used in DiffEq for DAE solvers. p and t aren't used they just mean to match the interfaces. It assumes that the jacobian has the form:

      \[\begin{align} JM = \gamma * I + J(x) -\end{align}\]

      See DiffEqDocs for additional details.

      +\end{align}\]

      See DiffEqDocs for additional details.

      diff --git a/dev/time_delays/index.html b/dev/time_delays/index.html index 40d8c7332..33e482aa1 100644 --- a/dev/time_delays/index.html +++ b/dev/time_delays/index.html @@ -1,4 +1,4 @@ Time Delays · PowerSimulationsDynamics.jl

      Delays

      PowerSimulationsDynamics supports models with constant delays in a mass matrix formulation:

      \[\begin{align} M\frac{dx(t)}{dt} = f(x(t), x(t-\tau_1), ... , x(t-\tau_N)) -\end{align}\]

      For more information on solving such models, refer to the documentation for DelayDiffEq.jl package.

      The following models include time delays:

      • DEGOV

      There is currently limited support for including models with time delays. The following limitations apply:

      • Only constant delays are supported (state dependent delays are not).
      • System models with delays must use MassMatrixModel formulation (ResidualModel is not currently compatible).
      • System models with delays are not compatible with small signal analysis tools.
      • The system formulation with delays is not compatible with automatic differentiation for calculating the gradient with respect to time. The setting autodiff=false should be set when passing the solver (e.g. MethodofSteps(Rodas5(autodiff=false))).
      +\end{align}\]

      For more information on solving such models, refer to the documentation for DelayDiffEq.jl package.

      The following models include time delays:

      There is currently limited support for including models with time delays. The following limitations apply:

      diff --git a/dev/tutorials/modified_sys.json b/dev/tutorials/modified_sys.json index cc1b28118..6e5a24013 100644 --- a/dev/tutorials/modified_sys.json +++ b/dev/tutorials/modified_sys.json @@ -1 +1 @@ -{"internal":{"uuid":{"value":"0ad55e5b-7db8-4c24-a6ed-08eb6db1365c"},"ext":{},"units_info":null},"data":{"time_series_in_memory":false,"masked_components":[],"version_info":{"julia_version":"1.10.4","package_info":"Status `~/work/PowerSimulationsDynamics.jl/PowerSimulationsDynamics.jl/docs/Manifest.toml`\n [47edcb42] ADTypes v1.5.3\n [a4c015fc] ANSIColoredPrinters v0.0.1\n [1520ce14] AbstractTrees v0.4.5\n [7d9f7c33] Accessors v0.1.36\n [79e6a3ab] Adapt v4.0.4\n [ec485272] ArnoldiMethod v0.4.0\n [4fba245c] ArrayInterface v7.11.0\n [4c555306] ArrayLayouts v1.10.0\n [d1d4a3ce] BitFlags v0.1.9\n [62783981] BitTwiddlingConvenienceFunctions v0.1.6\n [a74b3585] Blosc v0.7.3\n [fa961155] CEnum v0.5.0\n [2a0fbf3d] CPUSummary v0.2.6\n [336ed68f] CSV v0.10.14\n [d360d2e6] ChainRulesCore v1.24.0\n [fb6a15b2] CloseOpenIntervals v0.1.13\n [944b1d66] CodecZlib v0.7.4\n [35d6a980] ColorSchemes v3.25.0\n [3da002f7] ColorTypes v0.11.5\n [c3611d14] ColorVectorSpace v0.10.0\n [5ae59095] Colors v0.12.11\n [38540f10] CommonSolve v0.2.4\n [bbf7d656] CommonSubexpressions v0.3.0\n [f70d9fcc] CommonWorldInvalidations v1.0.0\n [34da2185] Compat v4.15.0\n [a33af91c] CompositionsBase v0.1.2\n [2569d6c7] ConcreteStructs v0.2.3\n [f0e56b4a] ConcurrentUtilities v2.4.1\n [187b0558] ConstructionBase v1.5.5\n [d38c429a] Contour v0.6.3\n [adafc99b] CpuId v0.3.1\n [a8cc5b0e] Crayons v4.1.1\n [9a962f9c] DataAPI v1.16.0\n [a93c6f00] DataFrames v1.6.1\n [864edb3b] DataStructures v0.18.20\n [e2d170a0] DataValueInterfaces v1.0.0\n [8bb1440f] DelimitedFiles v1.9.1\n [2b5f629d] DiffEqBase v6.151.5\n [163ba53b] DiffResults v1.1.0\n [b552c78f] DiffRules v1.15.1\n [a0c0ee7d] DifferentiationInterface v0.5.7\n [b4f34e82] Distances v0.10.11\n [ffbed154] DocStringExtensions v0.9.3\n⌅ [e30172f5] Documenter v0.27.25\n [35a29f4d] DocumenterTools v0.1.19\n [4e289a0a] EnumX v1.0.4\n [f151be2c] EnzymeCore v0.7.6\n [460bff9d] ExceptionUnwrapping v0.1.10\n [d4d017d3] ExponentialUtilities v1.26.1\n [e2ba6199] ExprTools v0.1.10\n [c87230d0] FFMPEG v0.4.1\n [7034ab61] FastBroadcast v0.3.4\n [9aa1b823] FastClosures v0.3.2\n [29a986be] FastLapackInterface v2.0.4\n [48062228] FilePathsBase v0.9.21\n [1a297f60] FillArrays v1.11.0\n [6a86dc24] FiniteDiff v2.23.1\n [53c48c17] FixedPointNumbers v0.8.5\n [1fa38f19] Format v1.3.7\n [f6369f11] ForwardDiff v0.10.36\n [069b7b12] FunctionWrappers v1.1.3\n [77dc65aa] FunctionWrappersWrappers v0.1.3\n [46192b85] GPUArraysCore v0.1.6\n⌃ [28b8d3ca] GR v0.73.5\n [c145ed77] GenericSchur v0.5.4\n [86223c79] Graphs v1.11.2\n [42e2da0e] Grisu v1.0.2\n [708ec375] Gumbo v0.8.2\n [c8ec2601] H5Zblosc v0.1.2\n [f67ccb44] HDF5 v0.17.2\n [cd3eb016] HTTP v1.10.8\n [3e5b6fbb] HostCPUFeatures v0.1.17\n [b5f81e59] IOCapture v0.2.5\n [615f187c] IfElse v0.1.1\n [d25df0c9] Inflate v0.1.5\n⌅ [2cd47ed4] InfrastructureSystems v1.22.2\n [842dd82b] InlineStrings v1.4.1\n [3587e190] InverseFunctions v0.1.14\n [41ab1584] InvertedIndices v1.3.0\n [92d709cd] IrrationalConstants v0.2.2\n [82899510] IteratorInterfaceExtensions v1.0.0\n [1019f520] JLFzf v0.1.7\n [692b3bcd] JLLWrappers v1.5.0\n [682c06a0] JSON v0.21.4\n [0f8b85d8] JSON3 v1.14.0\n [ef3ab10e] KLU v0.6.0\n [ba0b0d4f] Krylov v0.9.6\n [b964fa9f] LaTeXStrings v1.3.1\n [23fbe1c1] Latexify v0.16.3\n [10f19ff3] LayoutPointers v0.1.17\n [5078a376] LazyArrays v2.1.1\n [1d6d02ad] LeftChildRightSiblingTrees v0.2.0\n [d3d80556] LineSearches v7.2.0\n [7ed4a6bd] LinearSolve v2.30.2\n [2ab3a3ac] LogExpFunctions v0.3.28\n [e6f89c97] LoggingExtras v1.0.3\n [bdcacae8] LoopVectorization v0.12.171\n⌅ [33e6dc65] MKL v0.6.3\n [3da0fdf6] MPIPreferences v0.1.11\n [1914dd2f] MacroTools v0.5.13\n [d125e4d3] ManualMemory v0.1.8\n [299715c1] MarchingCubes v0.1.9\n [bb5d69b7] MaybeInplace v0.1.3\n [739be429] MbedTLS v1.1.9\n [442fdcdd] Measures v0.3.2\n [e1d29d7a] Missings v1.2.0\n [46d2c3a1] MuladdMacro v0.2.4\n [ffc61752] Mustache v1.0.19\n [d41bc354] NLSolversBase v7.8.3\n [2774e3e8] NLsolve v4.5.1\n [77ba4419] NaNMath v1.0.2\n [8913a72c] NonlinearSolve v3.13.1\n [6fe1bfb0] OffsetArrays v1.14.0\n [4d8831e6] OpenSSL v1.4.3\n [bac558e1] OrderedCollections v1.6.3\n [1dea7af3] OrdinaryDiffEq v6.85.0\n [65ce6f38] PackageExtensionCompat v1.0.2\n [d96e819e] Parameters v0.12.3\n [46dd5b70] Pardiso v0.5.7\n [69de0a69] Parsers v2.8.1\n [b98c9c47] Pipe v1.3.0\n [ccf2f8ad] PlotThemes v3.2.0\n [995b91a9] PlotUtils v1.4.1\n [91a5bcdd] Plots v1.40.4\n [f517fe37] Polyester v0.7.15\n [1d0040c9] PolyesterWeave v0.2.2\n [2dfb63ee] PooledArrays v1.4.3\n [dd99e9e3] PowerFlowData v1.5.0\n [94fada2c] PowerFlows v0.6.2\n⌅ [bed98974] PowerNetworkMatrices v0.10.3\n [398b2ede] PowerSimulationsDynamics v0.14.2 `~/work/PowerSimulationsDynamics.jl/PowerSimulationsDynamics.jl`\n⌃ [f00506e0] PowerSystemCaseBuilder v1.2.5\n⌅ [bcd98974] PowerSystems v3.3.0\n [d236fae5] PreallocationTools v0.4.22\n [aea7be01] PrecompileTools v1.2.1\n [21216c6a] Preferences v1.4.3\n [08abe8d2] PrettyTables v2.3.2\n [33c8b6b6] ProgressLogging v0.1.4\n [3cdcf5f2] RecipesBase v1.3.4\n [01d81517] RecipesPipeline v0.6.12\n [731186ca] RecursiveArrayTools v3.23.1\n [f2c3362d] RecursiveFactorization v0.2.23\n [189a3867] Reexport v1.2.2\n [05181044] RelocatableFolders v1.0.1\n [ae029012] Requires v1.3.0\n [7e49a35a] RuntimeGeneratedFunctions v0.5.13\n [94e857df] SIMDTypes v0.1.0\n [476501e8] SLEEFPirates v0.6.43\n [322a6be2] Sass v0.2.0\n [0bca4576] SciMLBase v2.42.0\n [c0aeaf25] SciMLOperators v0.3.8\n [53ae85a6] SciMLStructures v1.4.1\n [6c6a2e73] Scratch v1.2.1\n [91c51154] SentinelArrays v1.4.3\n [efcf1570] Setfield v1.1.1\n [992d4aef] Showoff v1.0.3\n [777ac1f9] SimpleBufferStream v1.1.0\n [727e6d20] SimpleNonlinearSolve v1.10.1\n [699a6c99] SimpleTraits v0.9.4\n [ce78b400] SimpleUnPack v1.1.0\n [a2af1166] SortingAlgorithms v1.2.1\n [47a9eef4] SparseDiffTools v2.19.0\n [0a514795] SparseMatrixColorings v0.3.3\n [e56a9233] Sparspak v0.3.9\n [276daf66] SpecialFunctions v2.4.0\n [aedffcd0] Static v1.1.0\n [0d7ed370] StaticArrayInterface v1.5.1\n [90137ffa] StaticArrays v1.9.6\n [1e83bf80] StaticArraysCore v1.4.3\n [82ae8749] StatsAPI v1.7.0\n [2913bbd2] StatsBase v0.34.3\n [7792a7ef] StrideArraysCore v0.5.7\n [69024149] StringEncodings v0.3.7\n [892a3eda] StringManipulation v0.3.4\n [856f2bd8] StructTypes v1.10.0\n [c3572dad] Sundials v4.24.0\n [2efcf032] SymbolicIndexingInterface v0.3.22\n [3783bdb8] TableTraits v1.0.1\n [bd369af6] Tables v1.11.1\n [62fd8b95] TensorCore v0.1.1\n [5d786b92] TerminalLoggers v0.1.7\n [8290d209] ThreadingUtilities v0.5.2\n⌅ [9e3dc215] TimeSeries v0.23.2\n [a759f4b9] TimerOutputs v0.5.24\n⌅ [3bb67fe8] TranscodingStreams v0.10.10\n [d5829a12] TriangularSolve v0.2.1\n [410a4b4d] Tricks v0.1.8\n [781d530d] TruncatedStacktraces v1.4.0\n [5c2747f8] URIs v1.5.1\n [3a884ed6] UnPack v1.0.2\n [1cfade01] UnicodeFun v0.4.1\n [b8865327] UnicodePlots v3.6.4\n [1986cc42] Unitful v1.20.0\n [45397f5d] UnitfulLatexify v1.6.3\n [41fe7b60] Unzip v0.2.0\n [3d5dd08c] VectorizationBase v0.21.70\n [19fa3120] VertexSafeGraphs v0.2.0\n [ea10d353] WeakRefStrings v1.4.2\n [76eceee3] WorkerUtilities v1.6.1\n [ddb6d928] YAML v0.4.11\n [0b7ba130] Blosc_jll v1.21.5+0\n [6e34b625] Bzip2_jll v1.0.8+1\n [83423d85] Cairo_jll v1.18.0+2\n [2702e6a9] EpollShim_jll v0.0.20230411+0\n [2e619515] Expat_jll v2.6.2+0\n⌅ [b22a6f82] FFMPEG_jll v4.4.2+2\n [a3f928ae] Fontconfig_jll v2.13.96+0\n [d7e528f0] FreeType2_jll v2.13.2+0\n [559328eb] FriBidi_jll v1.0.14+0\n [0656b61e] GLFW_jll v3.4.0+0\n⌅ [d2c73de3] GR_jll v0.73.5+0\n [78b55507] Gettext_jll v0.21.0+0\n [7746bdde] Glib_jll v2.80.2+0\n [3b182d85] Graphite2_jll v1.3.14+0\n [528830af] Gumbo_jll v0.10.2+0\n⌃ [0234f1f7] HDF5_jll v1.12.2+2\n [2e76f6c2] HarfBuzz_jll v2.8.1+1\n [1d5cc7b8] IntelOpenMP_jll v2024.1.0+0\n [aacddb02] JpegTurbo_jll v3.0.3+0\n [c1c5ebd0] LAME_jll v3.100.2+0\n⌅ [88015f11] LERC_jll v3.0.0+1\n [1d63c593] LLVMOpenMP_jll v15.0.7+0\n [dd4b983a] LZO_jll v2.10.2+0\n⌅ [e9f186c6] Libffi_jll v3.2.2+1\n [d4300ac3] Libgcrypt_jll v1.8.11+0\n [7e76a0d4] Libglvnd_jll v1.6.0+0\n [7add5ba3] Libgpg_error_jll v1.49.0+0\n [94ce4f54] Libiconv_jll v1.17.0+0\n [4b2f31a3] Libmount_jll v2.40.1+0\n⌅ [89763e89] Libtiff_jll v4.5.1+1\n [38a345b3] Libuuid_jll v2.40.1+0\n [5ced341a] Lz4_jll v1.9.4+0\n [856f044c] MKL_jll v2024.1.0+0\n [e7412a2a] Ogg_jll v1.3.5+1\n⌅ [9bd350c2] OpenSSH_jll v8.9.0+1\n⌅ [458c3c95] OpenSSL_jll v1.1.23+0\n [efe28fd5] OpenSpecFun_jll v0.5.5+0\n [91d4177d] Opus_jll v1.3.2+0\n [30392449] Pixman_jll v0.43.4+0\n⌅ [c0090381] Qt6Base_jll v6.5.2+2\n⌅ [fb77eaff] Sundials_jll v5.2.2+0\n [a44049a8] Vulkan_Loader_jll v1.3.243+0\n [a2964d1f] Wayland_jll v1.21.0+1\n [2381bf8a] Wayland_protocols_jll v1.31.0+0\n [02c8fc9c] XML2_jll v2.13.1+0\n [aed1982a] XSLT_jll v1.1.41+0\n [ffd25f8a] XZ_jll v5.4.6+0\n [f67eecfb] Xorg_libICE_jll v1.1.1+0\n [c834827a] Xorg_libSM_jll v1.2.4+0\n [4f6342f7] Xorg_libX11_jll v1.8.6+0\n [0c0b7dd1] Xorg_libXau_jll v1.0.11+0\n [935fb764] Xorg_libXcursor_jll v1.2.0+4\n [a3789734] Xorg_libXdmcp_jll v1.1.4+0\n [1082639a] Xorg_libXext_jll v1.3.6+0\n [d091e8ba] Xorg_libXfixes_jll v5.0.3+4\n [a51aa0fd] Xorg_libXi_jll v1.7.10+4\n [d1454406] Xorg_libXinerama_jll v1.1.4+4\n [ec84b674] Xorg_libXrandr_jll v1.5.2+4\n [ea2f1a96] Xorg_libXrender_jll v0.9.11+0\n [14d82f49] Xorg_libpthread_stubs_jll v0.1.1+0\n [c7cfdc94] Xorg_libxcb_jll v1.17.0+0\n [cc61e674] Xorg_libxkbfile_jll v1.1.2+0\n [e920d4aa] Xorg_xcb_util_cursor_jll v0.1.4+0\n [12413925] Xorg_xcb_util_image_jll v0.4.0+1\n [2def613f] Xorg_xcb_util_jll v0.4.0+1\n [975044d2] Xorg_xcb_util_keysyms_jll v0.4.0+1\n [0d47668e] Xorg_xcb_util_renderutil_jll v0.3.9+1\n [c22f9ab0] Xorg_xcb_util_wm_jll v0.4.1+1\n [35661453] Xorg_xkbcomp_jll v1.4.6+0\n [33bec58e] Xorg_xkeyboard_config_jll v2.39.0+0\n [c5fb5394] Xorg_xtrans_jll v1.5.0+0\n [3161d3a3] Zstd_jll v1.5.6+0\n [35ca27e7] eudev_jll v3.2.9+0\n⌅ [214eeab7] fzf_jll v0.43.0+0\n [1a1c6b14] gperf_jll v3.1.1+0\n [a4ae2306] libaom_jll v3.9.0+0\n [0ac62f75] libass_jll v0.15.1+0\n [2db6ffa8] libevdev_jll v1.11.0+0\n [f638f0a6] libfdk_aac_jll v2.0.2+0\n [36db933b] libinput_jll v1.18.0+0\n [b53b4c65] libpng_jll v1.6.43+1\n [47bcb7c8] libsass_jll v3.6.6+0\n [f27f6e37] libvorbis_jll v1.3.7+1\n [009596ad] mtdev_jll v1.1.6+0\n [1317d2d5] oneTBB_jll v2021.12.0+0\n [1270edf5] x264_jll v2021.5.5+0\n [dfaa095f] x265_jll v3.5.0+0\n [d8fb68d0] xkbcommon_jll v1.4.1+1\n [0dad84c5] ArgTools v1.1.1\n [56f22d72] Artifacts\n [2a0f44e3] Base64\n [ade2ca70] Dates\n [8ba89e20] Distributed\n [f43a241f] Downloads v1.6.0\n [7b1f6079] FileWatching\n [9fa8497b] Future\n [b77e0a4c] InteractiveUtils\n [4af54fe1] LazyArtifacts\n [b27032c2] LibCURL v0.6.4\n [76f85450] LibGit2\n [8f399da3] Libdl\n [37e2e46d] LinearAlgebra\n [56ddb016] Logging\n [d6f4376e] Markdown\n [a63ad114] Mmap\n [ca575930] NetworkOptions v1.2.0\n [44cfe95a] Pkg v1.10.0\n [de0858da] Printf\n [3fa0cd96] REPL\n [9a3f8284] Random\n [ea8e919c] SHA v0.7.0\n [9e88b42a] Serialization\n [1a1011a3] SharedArrays\n [6462fe0b] Sockets\n [2f01184e] SparseArrays v1.10.0\n [10745b16] Statistics v1.10.0\n [4607b0f0] SuiteSparse\n [fa267f1f] TOML v1.0.3\n [a4e569a6] Tar v1.10.0\n [8dfed614] Test\n [cf7118a7] UUIDs\n [4ec0a83e] Unicode\n [e66e0078] CompilerSupportLibraries_jll v1.1.1+0\n [deac9b47] LibCURL_jll v8.4.0+0\n [e37daf67] LibGit2_jll v1.6.4+0\n [29816b5a] LibSSH2_jll v1.11.0+1\n [c8ffd9c3] MbedTLS_jll v2.28.2+1\n [14a3606d] MozillaCACerts_jll v2023.1.10\n [4536629a] OpenBLAS_jll v0.3.23+4\n [05823500] OpenLibm_jll v0.8.1+2\n [efcefdf7] PCRE2_jll v10.42.0+1\n [bea87d4a] SuiteSparse_jll v7.2.1+1\n [83775a58] Zlib_jll v1.2.13+1\n [8e850b90] libblastrampoline_jll v5.8.0+1\n [8e850ede] nghttp2_jll v1.52.0+1\n [3f19e933] p7zip_jll v17.4.0+2\nInfo Packages marked with ⌃ and ⌅ have new versions available. Those with ⌃ may be upgradable, but those with ⌅ are restricted by compatibility constraints from upgrading. To see why use `status --outdated -m`\n"},"internal":{"uuid":{"value":"20814d40-f8d1-448f-b8d2-8192586ef21f"},"ext":{},"units_info":null},"time_series_compression_enabled":false,"components":[{"number":103,"base_voltage":138.0,"bustype":"PV","angle":0.0,"name":"BUS 3","magnitude":1.0059,"__metadata__":{"module":"PowerSystems","type":"ACBus"},"internal":{"uuid":{"value":"d19e65fe-4954-4357-b4cc-e22ac169c9da"},"ext":null,"units_info":null},"area":{"value":"3c78f447-91db-444a-bc30-a87b814619e2"},"ext":{},"voltage_limits":{"min":0.9,"max":1.1},"load_zone":{"value":"94bda3f8-51ea-4ff6-b208-16cc4e3bf43c"}},{"number":101,"base_voltage":138.0,"bustype":"REF","angle":0.0,"name":"BUS 1","magnitude":1.02,"__metadata__":{"module":"PowerSystems","type":"ACBus"},"internal":{"uuid":{"value":"d2754af5-8685-45c7-a870-863a0d2e47d6"},"ext":null,"units_info":null},"area":{"value":"3c78f447-91db-444a-bc30-a87b814619e2"},"ext":{},"voltage_limits":{"min":0.9,"max":1.1},"load_zone":{"value":"94bda3f8-51ea-4ff6-b208-16cc4e3bf43c"}},{"number":102,"base_voltage":138.0,"bustype":"PV","angle":0.0,"name":"BUS 2","magnitude":1.0142,"__metadata__":{"module":"PowerSystems","type":"ACBus"},"internal":{"uuid":{"value":"f4815c12-ef20-431a-a61f-c68205cba717"},"ext":null,"units_info":null},"area":{"value":"3c78f447-91db-444a-bc30-a87b814619e2"},"ext":{},"voltage_limits":{"min":0.9,"max":1.1},"load_zone":{"value":"94bda3f8-51ea-4ff6-b208-16cc4e3bf43c"}},{"load_response":0.0,"name":"1","__metadata__":{"module":"PowerSystems","type":"Area"},"internal":{"uuid":{"value":"3c78f447-91db-444a-bc30-a87b814619e2"},"ext":null,"units_info":null},"peak_active_power":0.0,"peak_reactive_power":0.0,"time_series_container":[]},{"__metadata__":{"module":"PowerSystems","type":"LoadZone"},"name":"1","internal":{"uuid":{"value":"94bda3f8-51ea-4ff6-b208-16cc4e3bf43c"},"ext":null,"units_info":null},"peak_active_power":1.8,"peak_reactive_power":0.5,"time_series_container":[]},{"internal_voltage":1.0,"services":[],"bus":{"value":"d2754af5-8685-45c7-a870-863a0d2e47d6"},"available":true,"name":"InfBus","internal_angle":0.0,"active_power":0.0,"dynamic_injector":null,"__metadata__":{"module":"PowerSystems","type":"Source"},"internal":{"uuid":{"value":"63154fdc-a3d7-4a26-b4ea-4d2ceb8dc973"},"ext":null,"units_info":null},"ext":{},"X_th":5.0e-6,"R_th":0.0,"reactive_power":0.0},{"internal":{"uuid":{"value":"57e6c8b4-2152-458a-9be9-972621d30f80"},"ext":null,"units_info":null},"to":{"value":"d19e65fe-4954-4357-b4cc-e22ac169c9da"},"from":{"value":"d2754af5-8685-45c7-a870-863a0d2e47d6"},"__metadata__":{"module":"PowerSystems","type":"Arc"}},{"internal":{"uuid":{"value":"633e9f98-a1ef-46fd-9483-7724617df6a9"},"ext":null,"units_info":null},"to":{"value":"f4815c12-ef20-431a-a61f-c68205cba717"},"from":{"value":"d2754af5-8685-45c7-a870-863a0d2e47d6"},"__metadata__":{"module":"PowerSystems","type":"Arc"}},{"internal":{"uuid":{"value":"8bb42c3c-5b12-4aca-951c-fa10d459a4ce"},"ext":null,"units_info":null},"to":{"value":"d19e65fe-4954-4357-b4cc-e22ac169c9da"},"from":{"value":"f4815c12-ef20-431a-a61f-c68205cba717"},"__metadata__":{"module":"PowerSystems","type":"Arc"}},{"base_power":100.0,"shaft":{"internal":{"uuid":{"value":"21d08938-b74f-48cd-924b-838050ca61aa"},"ext":null,"units_info":null},"n_states":2,"ext":{},"D":2.0,"states":["δ","ω"],"H":3.148,"__metadata__":{"module":"PowerSystems","type":"SingleMass"}},"states":["δ","ω"],"name":"generator-102-1","n_states":2,"ω_ref":1.0,"__metadata__":{"parameters":["BaseMachine","SingleMass","AVRFixed","TGFixed","PSSFixed"],"module":"PowerSystems","type":"DynamicGenerator"},"avr":{"states_types":[],"internal":{"uuid":{"value":"a225363d-fe26-45d8-86cd-8348b02e1943"},"ext":null,"units_info":null},"n_states":0,"ext":{},"V_ref":1.0,"states":[],"Vf":0.0,"__metadata__":{"module":"PowerSystems","type":"AVRFixed"}},"internal":{"uuid":{"value":"dfd2d167-a346-4cf4-b5fa-fea3b77f3980"},"ext":null,"units_info":null},"ext":{},"machine":{"internal":{"uuid":{"value":"be34bce1-ea8e-4b5f-8a2a-6cd420bbdc63"},"ext":null,"units_info":null},"n_states":0,"ext":{},"Xd_p":0.2995,"eq_p":0.7087,"R":0.0,"states":[],"__metadata__":{"module":"PowerSystems","type":"BaseMachine"}},"pss":{"V_pss":0.0,"internal":{"uuid":{"value":"948324ec-7ff8-4558-95c8-0ed95fca55f2"},"ext":null,"units_info":null},"n_states":0,"ext":{},"states":[],"__metadata__":{"module":"PowerSystems","type":"PSSFixed"}},"prime_mover":{"P_ref":1.0,"internal":{"uuid":{"value":"169eda0e-447a-42ee-9e97-bdc51ca5f840"},"ext":null,"units_info":null},"efficiency":1.0,"n_states":0,"ext":{},"states":[],"__metadata__":{"module":"PowerSystems","type":"TGFixed"}}},{"base_power":100.0,"services":[],"bus":{"value":"d2754af5-8685-45c7-a870-863a0d2e47d6"},"max_constant_active_power":0.5,"available":true,"time_series_container":[],"name":"load1011","max_current_active_power":0.0,"constant_active_power":0.5,"dynamic_injector":null,"__metadata__":{"module":"PowerSystems","type":"StandardLoad"},"current_active_power":0.0,"current_reactive_power":0.0,"internal":{"uuid":{"value":"035c8f8f-e530-4cc4-85a1-c1b2e05ad5ee"},"ext":null,"units_info":null},"ext":{},"max_constant_reactive_power":0.1,"max_current_reactive_power":0.0,"impedance_reactive_power":0.0,"impedance_active_power":0.0,"max_impedance_active_power":0.0,"constant_reactive_power":0.1,"max_impedance_reactive_power":0.0},{"base_power":100.0,"services":[],"bus":{"value":"d19e65fe-4954-4357-b4cc-e22ac169c9da"},"max_constant_active_power":0.3,"available":true,"time_series_container":[],"name":"load1031","max_current_active_power":0.0,"constant_active_power":0.3,"dynamic_injector":null,"__metadata__":{"module":"PowerSystems","type":"StandardLoad"},"current_active_power":0.0,"current_reactive_power":0.0,"internal":{"uuid":{"value":"609fb425-f51d-4aec-b344-032ce0f1c0f5"},"ext":null,"units_info":null},"ext":{},"max_constant_reactive_power":0.1,"max_current_reactive_power":0.0,"impedance_reactive_power":0.0,"impedance_active_power":0.0,"max_impedance_active_power":0.0,"constant_reactive_power":0.1,"max_impedance_reactive_power":0.0},{"base_power":100.0,"services":[],"bus":{"value":"f4815c12-ef20-431a-a61f-c68205cba717"},"max_constant_active_power":1.0,"available":true,"time_series_container":[],"name":"load1021","max_current_active_power":0.0,"constant_active_power":1.0,"dynamic_injector":null,"__metadata__":{"module":"PowerSystems","type":"StandardLoad"},"current_active_power":0.0,"current_reactive_power":0.0,"internal":{"uuid":{"value":"72719c1c-704f-4eb6-9a82-dc17fddfd359"},"ext":null,"units_info":null},"ext":{},"max_constant_reactive_power":0.3,"max_current_reactive_power":0.0,"impedance_reactive_power":0.0,"impedance_active_power":0.0,"max_impedance_active_power":0.0,"constant_reactive_power":0.3,"max_impedance_reactive_power":0.0},{"services":[],"x":0.12,"b":{"from":0.1,"to":0.1},"r":0.01,"rate":2.5,"available":true,"time_series_container":[],"name":"BUS 1-BUS 3-i_1","reactive_power_flow":0.0,"arc":{"value":"57e6c8b4-2152-458a-9be9-972621d30f80"},"__metadata__":{"module":"PowerSystems","type":"Line"},"internal":{"uuid":{"value":"a2709ac3-f9d2-46c8-97a3-909a0badb41c"},"ext":null,"units_info":null},"ext":{},"active_power_flow":0.0,"angle_limits":{"min":-1.0472,"max":1.0472}},{"services":[],"x":0.12,"b":{"from":0.1,"to":0.1},"r":0.01,"rate":2.5,"available":true,"time_series_container":[],"name":"BUS 1-BUS 2-i_1","reactive_power_flow":0.0,"arc":{"value":"633e9f98-a1ef-46fd-9483-7724617df6a9"},"__metadata__":{"module":"PowerSystems","type":"Line"},"internal":{"uuid":{"value":"db188cba-32f0-464a-b1e8-f24b15c7da95"},"ext":null,"units_info":null},"ext":{},"active_power_flow":0.0,"angle_limits":{"min":-1.0472,"max":1.0472}},{"services":[],"x":0.9,"b":{"from":0.5,"to":0.5},"r":0.02,"rate":2.5,"available":true,"time_series_container":[],"name":"BUS 2-BUS 3-i_1","reactive_power_flow":0.0,"arc":{"value":"8bb42c3c-5b12-4aca-951c-fa10d459a4ce"},"__metadata__":{"module":"PowerSystems","type":"Line"},"internal":{"uuid":{"value":"d92d51f7-2309-4e21-ae28-ee3bdcdeca78"},"ext":null,"units_info":null},"ext":{},"active_power_flow":0.0,"angle_limits":{"min":-1.0472,"max":1.0472}},{"base_power":100.0,"prime_mover_type":"OT","rating":3.333526661060325,"services":[],"bus":{"value":"f4815c12-ef20-431a-a61f-c68205cba717"},"available":true,"time_series_container":[],"name":"generator-102-1","status":true,"active_power":0.7,"dynamic_injector":{"value":"dfd2d167-a346-4cf4-b5fa-fea3b77f3980"},"__metadata__":{"module":"PowerSystems","type":"ThermalStandard"},"fuel":"OTHER","internal":{"uuid":{"value":"864b8fc6-91c1-4718-8379-9d4269c08903"},"ext":null,"units_info":null},"reactive_power_limits":{"min":-1.0,"max":1.0},"ext":{"z_source":{"r":0.0,"x":1.0}},"operation_cost":{"start_up":0.0,"fixed":0.0,"shut_down":0.0,"variable":{"cost":[0.0,1.0]},"__metadata__":{"module":"PowerSystems","type":"ThreePartCost"}},"time_limits":null,"must_run":false,"ramp_limits":{"up":3.18,"down":3.18},"time_at_status":10000.0,"active_power_limits":{"min":0.0,"max":3.18},"reactive_power":0.0},{"base_power":100.0,"prime_mover_type":"OT","rating":3.333526661060325,"services":[],"bus":{"value":"d19e65fe-4954-4357-b4cc-e22ac169c9da"},"available":true,"time_series_container":[],"name":"generator-103-1","status":true,"active_power":0.8,"dynamic_injector":null,"__metadata__":{"module":"PowerSystems","type":"ThermalStandard"},"fuel":"OTHER","internal":{"uuid":{"value":"42ffa9d0-6793-4c31-a4a8-fbd3a6eacdfb"},"ext":null,"units_info":null},"reactive_power_limits":{"min":-1.0,"max":1.0},"ext":{"z_source":{"r":0.0,"x":1.0}},"operation_cost":{"start_up":0.0,"fixed":0.0,"shut_down":0.0,"variable":{"cost":[0.0,1.0]},"__metadata__":{"module":"PowerSystems","type":"ThreePartCost"}},"time_limits":null,"must_run":false,"ramp_limits":{"up":3.18,"down":3.18},"time_at_status":10000.0,"active_power_limits":{"min":0.0,"max":3.18},"reactive_power":0.0}],"validation_descriptor_file":"modified_sys_validation_descriptors.json","time_series_params":{"__metadata__":{"module":"InfrastructureSystems","type":"TimeSeriesParameters"},"resolution":{"value":0,"type":"Minute"},"forecast_params":{"initial_timestamp":"0001-01-01T00:00:00.0","interval":{"value":0,"type":"Minute"},"horizon":0,"count":0,"__metadata__":{"module":"InfrastructureSystems","type":"ForecastParameters"}}}},"units_settings":{"base_value":100.0,"unit_system":"SYSTEM_BASE"},"frequency":60.0,"runchecks":true,"metadata":{"name":null,"description":null,"__metadata__":{"module":"PowerSystems","type":"SystemMetadata"}},"data_format_version":"3.0.0"} \ No newline at end of file +{"internal":{"uuid":{"value":"b5becb8b-f141-4365-8577-36a74ba0cf16"},"ext":{},"units_info":null},"data":{"masked_components":[],"supplemental_attribute_manager":{"attributes":[],"associations":[]},"internal":{"uuid":{"value":"32988bf8-3cd7-4276-8e30-6747604bec65"},"ext":{},"units_info":null},"time_series_compression_enabled":false,"components":[{"base_power":100.0,"shaft":{"internal":{"uuid":{"value":"5fcd6bf7-f618-4c75-9e6d-b35583b08aa8"},"ext":null,"units_info":null},"n_states":2,"ext":{},"D":2.0,"states":["δ","ω"],"H":3.148,"__metadata__":{"module":"PowerSystems","type":"SingleMass"}},"states":["δ","ω"],"name":"generator-102-1","n_states":2,"ω_ref":1.0,"__metadata__":{"parameters":["BaseMachine","SingleMass","AVRFixed","TGFixed","PSSFixed"],"module":"PowerSystems","type":"DynamicGenerator"},"avr":{"states_types":[],"internal":{"uuid":{"value":"7765b510-bd82-4cb4-b505-c9125dc5f786"},"ext":null,"units_info":null},"n_states":0,"ext":{},"V_ref":1.0,"states":[],"Vf":0.0,"__metadata__":{"module":"PowerSystems","type":"AVRFixed"}},"internal":{"uuid":{"value":"1056fc74-58b4-4676-b11e-700b6367786a"},"ext":null,"units_info":null},"ext":{},"machine":{"internal":{"uuid":{"value":"0ae2297c-2406-4be6-912a-1d082b9b66f3"},"ext":null,"units_info":null},"n_states":0,"ext":{},"Xd_p":0.2995,"eq_p":0.7087,"R":0.0,"states":[],"__metadata__":{"module":"PowerSystems","type":"BaseMachine"}},"pss":{"V_pss":0.0,"internal":{"uuid":{"value":"01dac009-7e40-486e-8070-4da996925a28"},"ext":null,"units_info":null},"n_states":0,"ext":{},"states":[],"__metadata__":{"module":"PowerSystems","type":"PSSFixed"}},"prime_mover":{"P_ref":1.0,"internal":{"uuid":{"value":"0532ded7-23c2-4ff4-811a-d75a96007760"},"ext":null,"units_info":null},"efficiency":1.0,"n_states":0,"ext":{},"states":[],"__metadata__":{"module":"PowerSystems","type":"TGFixed"}}},{"number":103,"base_voltage":138.0,"bustype":"PV","angle":0.0,"name":"BUS 3","magnitude":1.0059,"__metadata__":{"module":"PowerSystems","type":"ACBus"},"internal":{"uuid":{"value":"6f84f8dd-e5c5-4656-9f22-8547c8e5b693"},"ext":null,"units_info":null},"area":{"value":"cd599955-2721-4133-8edb-eea3b9593b6c"},"ext":{},"voltage_limits":{"min":0.9,"max":1.1},"load_zone":{"value":"62d8ad01-23fd-4b98-82cf-4d1b5667bf80"}},{"number":101,"base_voltage":138.0,"bustype":"REF","angle":0.0,"name":"BUS 1","magnitude":1.02,"__metadata__":{"module":"PowerSystems","type":"ACBus"},"internal":{"uuid":{"value":"54a60455-d7e2-4030-9d95-e72fbb443eb0"},"ext":null,"units_info":null},"area":{"value":"cd599955-2721-4133-8edb-eea3b9593b6c"},"ext":{},"voltage_limits":{"min":0.9,"max":1.1},"load_zone":{"value":"62d8ad01-23fd-4b98-82cf-4d1b5667bf80"}},{"number":102,"base_voltage":138.0,"bustype":"PV","angle":0.0,"name":"BUS 2","magnitude":1.0142,"__metadata__":{"module":"PowerSystems","type":"ACBus"},"internal":{"uuid":{"value":"bc008aa5-ef59-4703-8034-213237eb7632"},"ext":null,"units_info":null},"area":{"value":"cd599955-2721-4133-8edb-eea3b9593b6c"},"ext":{},"voltage_limits":{"min":0.9,"max":1.1},"load_zone":{"value":"62d8ad01-23fd-4b98-82cf-4d1b5667bf80"}},{"name":"1","internal":{"uuid":{"value":"62d8ad01-23fd-4b98-82cf-4d1b5667bf80"},"ext":null,"units_info":null},"ext":{},"peak_active_power":1.8,"peak_reactive_power":0.5,"__metadata__":{"module":"PowerSystems","type":"LoadZone"}},{"load_response":0.0,"name":"1","internal":{"uuid":{"value":"cd599955-2721-4133-8edb-eea3b9593b6c"},"ext":null,"units_info":null},"ext":{},"peak_active_power":0.0,"peak_reactive_power":0.0,"__metadata__":{"module":"PowerSystems","type":"Area"}},{"base_power":100.0,"services":[],"bus":{"value":"54a60455-d7e2-4030-9d95-e72fbb443eb0"},"max_constant_active_power":0.5,"available":true,"name":"load1011","max_current_active_power":0.0,"constant_active_power":0.5,"dynamic_injector":null,"__metadata__":{"module":"PowerSystems","type":"StandardLoad"},"current_active_power":0.0,"current_reactive_power":0.0,"internal":{"uuid":{"value":"e7dc1e2a-db59-4966-b831-3975c85eaa03"},"ext":null,"units_info":null},"ext":{},"max_constant_reactive_power":0.1,"max_current_reactive_power":0.0,"impedance_reactive_power":0.0,"impedance_active_power":0.0,"max_impedance_active_power":0.0,"constant_reactive_power":0.1,"max_impedance_reactive_power":0.0},{"base_power":100.0,"services":[],"bus":{"value":"6f84f8dd-e5c5-4656-9f22-8547c8e5b693"},"max_constant_active_power":0.3,"available":true,"name":"load1031","max_current_active_power":0.0,"constant_active_power":0.3,"dynamic_injector":null,"__metadata__":{"module":"PowerSystems","type":"StandardLoad"},"current_active_power":0.0,"current_reactive_power":0.0,"internal":{"uuid":{"value":"5a9d43c7-d6d1-4bbd-9846-f05460c4a1cb"},"ext":null,"units_info":null},"ext":{},"max_constant_reactive_power":0.1,"max_current_reactive_power":0.0,"impedance_reactive_power":0.0,"impedance_active_power":0.0,"max_impedance_active_power":0.0,"constant_reactive_power":0.1,"max_impedance_reactive_power":0.0},{"base_power":100.0,"services":[],"bus":{"value":"bc008aa5-ef59-4703-8034-213237eb7632"},"max_constant_active_power":1.0,"available":true,"name":"load1021","max_current_active_power":0.0,"constant_active_power":1.0,"dynamic_injector":null,"__metadata__":{"module":"PowerSystems","type":"StandardLoad"},"current_active_power":0.0,"current_reactive_power":0.0,"internal":{"uuid":{"value":"1b483ed8-cc05-429b-80ba-1b54836e7d2d"},"ext":null,"units_info":null},"ext":{},"max_constant_reactive_power":0.3,"max_current_reactive_power":0.0,"impedance_reactive_power":0.0,"impedance_active_power":0.0,"max_impedance_active_power":0.0,"constant_reactive_power":0.3,"max_impedance_reactive_power":0.0},{"internal":{"uuid":{"value":"9fd44ef6-4867-479f-ba08-06ef61e3446d"},"ext":null,"units_info":null},"to":{"value":"6f84f8dd-e5c5-4656-9f22-8547c8e5b693"},"from":{"value":"54a60455-d7e2-4030-9d95-e72fbb443eb0"},"__metadata__":{"module":"PowerSystems","type":"Arc"}},{"internal":{"uuid":{"value":"c55189e0-2cbe-4664-ab9e-b5ad24addc7b"},"ext":null,"units_info":null},"to":{"value":"bc008aa5-ef59-4703-8034-213237eb7632"},"from":{"value":"54a60455-d7e2-4030-9d95-e72fbb443eb0"},"__metadata__":{"module":"PowerSystems","type":"Arc"}},{"internal":{"uuid":{"value":"3e7c8d36-85cd-49b7-82df-26b20c64df03"},"ext":null,"units_info":null},"to":{"value":"6f84f8dd-e5c5-4656-9f22-8547c8e5b693"},"from":{"value":"bc008aa5-ef59-4703-8034-213237eb7632"},"__metadata__":{"module":"PowerSystems","type":"Arc"}},{"base_power":100.0,"prime_mover_type":"OT","rating":3.333526661060325,"services":[],"bus":{"value":"bc008aa5-ef59-4703-8034-213237eb7632"},"available":true,"name":"generator-102-1","status":true,"active_power":0.7,"dynamic_injector":{"value":"1056fc74-58b4-4676-b11e-700b6367786a"},"__metadata__":{"module":"PowerSystems","type":"ThermalStandard"},"fuel":"OTHER","internal":{"uuid":{"value":"5b7e1497-1bfc-40b7-acb5-e3b39d5325fb"},"ext":null,"units_info":null},"reactive_power_limits":{"min":-1.0,"max":1.0},"ext":{"z_source":{"r":0.0,"x":1.0}},"operation_cost":{"start_up":0.0,"fixed":0.0,"shut_down":0.0,"variable":{"__metadata__":{"parameters":["InputOutputCurve"],"module":"PowerSystems","type":"CostCurve"},"value_curve":{"input_at_zero":null,"function_data":{"__metadata__":{"module":"InfrastructureSystems","type":"QuadraticFunctionData"},"quadratic_term":0.0,"constant_term":0.0,"proportional_term":1.0},"__metadata__":{"parameters":["QuadraticFunctionData"],"module":"PowerSystems","type":"InputOutputCurve"}},"power_units":"DEVICE_BASE","vom_cost":{"input_at_zero":null,"function_data":{"__metadata__":{"module":"InfrastructureSystems","type":"LinearFunctionData"},"constant_term":0.0,"proportional_term":0.0},"__metadata__":{"parameters":["LinearFunctionData"],"module":"PowerSystems","type":"InputOutputCurve"}}},"__metadata__":{"module":"PowerSystems","type":"ThermalGenerationCost"}},"time_limits":null,"must_run":false,"ramp_limits":{"up":3.18,"down":3.18},"time_at_status":10000.0,"active_power_limits":{"min":0.0,"max":3.18},"reactive_power":0.0},{"base_power":100.0,"prime_mover_type":"OT","rating":3.333526661060325,"services":[],"bus":{"value":"6f84f8dd-e5c5-4656-9f22-8547c8e5b693"},"available":true,"name":"generator-103-1","status":true,"active_power":0.8,"dynamic_injector":null,"__metadata__":{"module":"PowerSystems","type":"ThermalStandard"},"fuel":"OTHER","internal":{"uuid":{"value":"4618df43-eaed-42e1-8bf1-5cef75049c4b"},"ext":null,"units_info":null},"reactive_power_limits":{"min":-1.0,"max":1.0},"ext":{"z_source":{"r":0.0,"x":1.0}},"operation_cost":{"start_up":0.0,"fixed":0.0,"shut_down":0.0,"variable":{"__metadata__":{"parameters":["InputOutputCurve"],"module":"PowerSystems","type":"CostCurve"},"value_curve":{"input_at_zero":null,"function_data":{"__metadata__":{"module":"InfrastructureSystems","type":"QuadraticFunctionData"},"quadratic_term":0.0,"constant_term":0.0,"proportional_term":1.0},"__metadata__":{"parameters":["QuadraticFunctionData"],"module":"PowerSystems","type":"InputOutputCurve"}},"power_units":"DEVICE_BASE","vom_cost":{"input_at_zero":null,"function_data":{"__metadata__":{"module":"InfrastructureSystems","type":"LinearFunctionData"},"constant_term":0.0,"proportional_term":0.0},"__metadata__":{"parameters":["LinearFunctionData"],"module":"PowerSystems","type":"InputOutputCurve"}}},"__metadata__":{"module":"PowerSystems","type":"ThermalGenerationCost"}},"time_limits":null,"must_run":false,"ramp_limits":{"up":3.18,"down":3.18},"time_at_status":10000.0,"active_power_limits":{"min":0.0,"max":3.18},"reactive_power":0.0},{"rating":2.5,"services":[],"x":0.12,"b":{"from":0.1,"to":0.1},"r":0.01,"available":true,"name":"BUS 1-BUS 3-i_1","reactive_power_flow":0.0,"arc":{"value":"9fd44ef6-4867-479f-ba08-06ef61e3446d"},"__metadata__":{"module":"PowerSystems","type":"Line"},"internal":{"uuid":{"value":"3725c589-acf4-4d6d-91f3-3639a5c64924"},"ext":null,"units_info":null},"ext":{},"active_power_flow":0.0,"angle_limits":{"min":-1.0472,"max":1.0472}},{"rating":2.5,"services":[],"x":0.12,"b":{"from":0.1,"to":0.1},"r":0.01,"available":true,"name":"BUS 1-BUS 2-i_1","reactive_power_flow":0.0,"arc":{"value":"c55189e0-2cbe-4664-ab9e-b5ad24addc7b"},"__metadata__":{"module":"PowerSystems","type":"Line"},"internal":{"uuid":{"value":"014f84f0-2952-4c1d-b7e7-77feceaa5d6b"},"ext":null,"units_info":null},"ext":{},"active_power_flow":0.0,"angle_limits":{"min":-1.0472,"max":1.0472}},{"rating":2.5,"services":[],"x":0.9,"b":{"from":0.5,"to":0.5},"r":0.02,"available":true,"name":"BUS 2-BUS 3-i_1","reactive_power_flow":0.0,"arc":{"value":"3e7c8d36-85cd-49b7-82df-26b20c64df03"},"__metadata__":{"module":"PowerSystems","type":"Line"},"internal":{"uuid":{"value":"1f407832-418a-4a2f-9dc8-ab22ed42743d"},"ext":null,"units_info":null},"ext":{},"active_power_flow":0.0,"angle_limits":{"min":-1.0472,"max":1.0472}},{"internal_voltage":1.0,"services":[],"bus":{"value":"54a60455-d7e2-4030-9d95-e72fbb443eb0"},"available":true,"name":"InfBus","internal_angle":0.0,"active_power":0.0,"dynamic_injector":null,"__metadata__":{"module":"PowerSystems","type":"Source"},"internal":{"uuid":{"value":"bfaf23c4-1e82-4d0a-9670-d301102bf87a"},"ext":null,"units_info":null},"ext":{},"X_th":5.0e-6,"R_th":0.0,"reactive_power":0.0}],"subsystems":{},"version_info":{"julia_version":"1.10.4","package_info":"Status `~/work/PowerSimulationsDynamics.jl/PowerSimulationsDynamics.jl/docs/Manifest.toml`\n [47edcb42] ADTypes v1.5.3\n [a4c015fc] ANSIColoredPrinters v0.0.1\n [1520ce14] AbstractTrees v0.4.5\n [7d9f7c33] Accessors v0.1.36\n [79e6a3ab] Adapt v4.0.4\n [ec485272] ArnoldiMethod v0.4.0\n [4fba245c] ArrayInterface v7.12.0\n [4c555306] ArrayLayouts v1.10.2\n [d1d4a3ce] BitFlags v0.1.9\n [62783981] BitTwiddlingConvenienceFunctions v0.1.6\n [a74b3585] Blosc v0.7.3\n [fa961155] CEnum v0.5.0\n [2a0fbf3d] CPUSummary v0.2.6\n [336ed68f] CSV v0.10.14\n [d360d2e6] ChainRulesCore v1.24.0\n [fb6a15b2] CloseOpenIntervals v0.1.13\n [944b1d66] CodecZlib v0.7.5\n [35d6a980] ColorSchemes v3.25.0\n [3da002f7] ColorTypes v0.11.5\n [c3611d14] ColorVectorSpace v0.10.0\n [5ae59095] Colors v0.12.11\n [38540f10] CommonSolve v0.2.4\n [bbf7d656] CommonSubexpressions v0.3.0\n [f70d9fcc] CommonWorldInvalidations v1.0.0\n [34da2185] Compat v4.15.0\n [a33af91c] CompositionsBase v0.1.2\n [2569d6c7] ConcreteStructs v0.2.3\n [f0e56b4a] ConcurrentUtilities v2.4.2\n [187b0558] ConstructionBase v1.5.5\n [d38c429a] Contour v0.6.3\n [adafc99b] CpuId v0.3.1\n [a8cc5b0e] Crayons v4.1.1\n [a10d1c49] DBInterface v2.6.1\n [9a962f9c] DataAPI v1.16.0\n [a93c6f00] DataFrames v1.6.1\n [864edb3b] DataStructures v0.18.20\n [e2d170a0] DataValueInterfaces v1.0.0\n [8bb1440f] DelimitedFiles v1.9.1\n [2b5f629d] DiffEqBase v6.151.5\n [163ba53b] DiffResults v1.1.0\n [b552c78f] DiffRules v1.15.1\n [a0c0ee7d] DifferentiationInterface v0.5.7\n [b4f34e82] Distances v0.10.11\n [ffbed154] DocStringExtensions v0.9.3\n⌅ [e30172f5] Documenter v0.27.25\n [35a29f4d] DocumenterTools v0.1.19\n [4e289a0a] EnumX v1.0.4\n [f151be2c] EnzymeCore v0.7.6\n [460bff9d] ExceptionUnwrapping v0.1.10\n [d4d017d3] ExponentialUtilities v1.26.1\n [e2ba6199] ExprTools v0.1.10\n [c87230d0] FFMPEG v0.4.1\n [7034ab61] FastBroadcast v0.3.4\n [9aa1b823] FastClosures v0.3.2\n [29a986be] FastLapackInterface v2.0.4\n [48062228] FilePathsBase v0.9.21\n [1a297f60] FillArrays v1.11.0\n [6a86dc24] FiniteDiff v2.23.1\n [53c48c17] FixedPointNumbers v0.8.5\n [1fa38f19] Format v1.3.7\n [f6369f11] ForwardDiff v0.10.36\n [069b7b12] FunctionWrappers v1.1.3\n [77dc65aa] FunctionWrappersWrappers v0.1.3\n [46192b85] GPUArraysCore v0.1.6\n⌃ [28b8d3ca] GR v0.73.5\n [c145ed77] GenericSchur v0.5.4\n [86223c79] Graphs v1.11.2\n [42e2da0e] Grisu v1.0.2\n [708ec375] Gumbo v0.8.2\n [c8ec2601] H5Zblosc v0.1.2\n [f67ccb44] HDF5 v0.17.2\n [cd3eb016] HTTP v1.10.8\n [3e5b6fbb] HostCPUFeatures v0.1.17\n [b5f81e59] IOCapture v0.2.5\n [615f187c] IfElse v0.1.1\n [d25df0c9] Inflate v0.1.5\n [2cd47ed4] InfrastructureSystems v2.0.1\n [842dd82b] InlineStrings v1.4.1\n [3587e190] InverseFunctions v0.1.14\n [41ab1584] InvertedIndices v1.3.0\n [92d709cd] IrrationalConstants v0.2.2\n [82899510] IteratorInterfaceExtensions v1.0.0\n [1019f520] JLFzf v0.1.7\n [692b3bcd] JLLWrappers v1.5.0\n [682c06a0] JSON v0.21.4\n [0f8b85d8] JSON3 v1.14.0\n [ef3ab10e] KLU v0.6.0\n [ba0b0d4f] Krylov v0.9.6\n [b964fa9f] LaTeXStrings v1.3.1\n [23fbe1c1] Latexify v0.16.4\n [10f19ff3] LayoutPointers v0.1.17\n [5078a376] LazyArrays v2.1.5\n [1d6d02ad] LeftChildRightSiblingTrees v0.2.0\n [d3d80556] LineSearches v7.2.0\n [7ed4a6bd] LinearSolve v2.30.2\n [2ab3a3ac] LogExpFunctions v0.3.28\n [e6f89c97] LoggingExtras v1.0.3\n [bdcacae8] LoopVectorization v0.12.171\n⌅ [33e6dc65] MKL v0.6.3\n [3da0fdf6] MPIPreferences v0.1.11\n [1914dd2f] MacroTools v0.5.13\n [d125e4d3] ManualMemory v0.1.8\n [299715c1] MarchingCubes v0.1.9\n [bb5d69b7] MaybeInplace v0.1.3\n [739be429] MbedTLS v1.1.9\n [442fdcdd] Measures v0.3.2\n [e1d29d7a] Missings v1.2.0\n [46d2c3a1] MuladdMacro v0.2.4\n [ffc61752] Mustache v1.0.19\n [d41bc354] NLSolversBase v7.8.3\n [2774e3e8] NLsolve v4.5.1\n [77ba4419] NaNMath v1.0.2\n [8913a72c] NonlinearSolve v3.13.1\n [6fe1bfb0] OffsetArrays v1.14.1\n [4d8831e6] OpenSSL v1.4.3\n [bac558e1] OrderedCollections v1.6.3\n [1dea7af3] OrdinaryDiffEq v6.85.0\n [65ce6f38] PackageExtensionCompat v1.0.2\n [d96e819e] Parameters v0.12.3\n [46dd5b70] Pardiso v0.5.7\n [69de0a69] Parsers v2.8.1\n [b98c9c47] Pipe v1.3.0\n [ccf2f8ad] PlotThemes v3.2.0\n [995b91a9] PlotUtils v1.4.1\n [91a5bcdd] Plots v1.40.5\n [f517fe37] Polyester v0.7.15\n [1d0040c9] PolyesterWeave v0.2.2\n [2dfb63ee] PooledArrays v1.4.3\n [dd99e9e3] PowerFlowData v1.5.0\n [94fada2c] PowerFlows v0.7.0\n [bed98974] PowerNetworkMatrices v0.11.0\n [398b2ede] PowerSimulationsDynamics v0.15.0 `~/work/PowerSimulationsDynamics.jl/PowerSimulationsDynamics.jl`\n [f00506e0] PowerSystemCaseBuilder v1.3.3\n [bcd98974] PowerSystems v4.1.1\n [d236fae5] PreallocationTools v0.4.22\n [aea7be01] PrecompileTools v1.2.1\n [21216c6a] Preferences v1.4.3\n [08abe8d2] PrettyTables v2.3.2\n [33c8b6b6] ProgressLogging v0.1.4\n [3cdcf5f2] RecipesBase v1.3.4\n [01d81517] RecipesPipeline v0.6.12\n [731186ca] RecursiveArrayTools v3.26.0\n [f2c3362d] RecursiveFactorization v0.2.23\n [189a3867] Reexport v1.2.2\n [05181044] RelocatableFolders v1.0.1\n [ae029012] Requires v1.3.0\n [7e49a35a] RuntimeGeneratedFunctions v0.5.13\n [94e857df] SIMDTypes v0.1.0\n [476501e8] SLEEFPirates v0.6.43\n [0aa819cd] SQLite v1.6.1\n [322a6be2] Sass v0.2.0\n [0bca4576] SciMLBase v2.42.0\n [c0aeaf25] SciMLOperators v0.3.8\n [53ae85a6] SciMLStructures v1.4.1\n [6c6a2e73] Scratch v1.2.1\n [91c51154] SentinelArrays v1.4.5\n [efcf1570] Setfield v1.1.1\n [992d4aef] Showoff v1.0.3\n [777ac1f9] SimpleBufferStream v1.1.0\n [727e6d20] SimpleNonlinearSolve v1.10.1\n [699a6c99] SimpleTraits v0.9.4\n [ce78b400] SimpleUnPack v1.1.0\n [a2af1166] SortingAlgorithms v1.2.1\n [47a9eef4] SparseDiffTools v2.19.0\n [0a514795] SparseMatrixColorings v0.3.3\n [e56a9233] Sparspak v0.3.9\n [276daf66] SpecialFunctions v2.4.0\n [aedffcd0] Static v1.1.0\n [0d7ed370] StaticArrayInterface v1.5.1\n [90137ffa] StaticArrays v1.9.7\n [1e83bf80] StaticArraysCore v1.4.3\n [82ae8749] StatsAPI v1.7.0\n [2913bbd2] StatsBase v0.34.3\n [7792a7ef] StrideArraysCore v0.5.7\n [69024149] StringEncodings v0.3.7\n [892a3eda] StringManipulation v0.3.4\n [856f2bd8] StructTypes v1.10.0\n [c3572dad] Sundials v4.24.0\n [2efcf032] SymbolicIndexingInterface v0.3.26\n [3783bdb8] TableTraits v1.0.1\n [bd369af6] Tables v1.11.1\n [62fd8b95] TensorCore v0.1.1\n [5d786b92] TerminalLoggers v0.1.7\n [8290d209] ThreadingUtilities v0.5.2\n [9e3dc215] TimeSeries v0.24.2\n [a759f4b9] TimerOutputs v0.5.24\n [3bb67fe8] TranscodingStreams v0.11.0\n [d5829a12] TriangularSolve v0.2.1\n [410a4b4d] Tricks v0.1.8\n [781d530d] TruncatedStacktraces v1.4.0\n [5c2747f8] URIs v1.5.1\n [3a884ed6] UnPack v1.0.2\n [1cfade01] UnicodeFun v0.4.1\n [b8865327] UnicodePlots v3.6.4\n [1986cc42] Unitful v1.20.0\n [45397f5d] UnitfulLatexify v1.6.4\n [41fe7b60] Unzip v0.2.0\n [3d5dd08c] VectorizationBase v0.21.70\n [19fa3120] VertexSafeGraphs v0.2.0\n [ea10d353] WeakRefStrings v1.4.2\n [76eceee3] WorkerUtilities v1.6.1\n [ddb6d928] YAML v0.4.11\n [0b7ba130] Blosc_jll v1.21.5+0\n [6e34b625] Bzip2_jll v1.0.8+1\n [83423d85] Cairo_jll v1.18.0+2\n [2702e6a9] EpollShim_jll v0.0.20230411+0\n [2e619515] Expat_jll v2.6.2+0\n⌅ [b22a6f82] FFMPEG_jll v4.4.2+2\n [a3f928ae] Fontconfig_jll v2.13.96+0\n [d7e528f0] FreeType2_jll v2.13.2+0\n [559328eb] FriBidi_jll v1.0.14+0\n [0656b61e] GLFW_jll v3.4.0+0\n⌅ [d2c73de3] GR_jll v0.73.5+0\n [78b55507] Gettext_jll v0.21.0+0\n [7746bdde] Glib_jll v2.80.2+0\n [3b182d85] Graphite2_jll v1.3.14+0\n [528830af] Gumbo_jll v0.10.2+0\n⌃ [0234f1f7] HDF5_jll v1.12.2+2\n [2e76f6c2] HarfBuzz_jll v2.8.1+1\n [1d5cc7b8] IntelOpenMP_jll v2024.2.0+0\n [aacddb02] JpegTurbo_jll v3.0.3+0\n [c1c5ebd0] LAME_jll v3.100.2+0\n⌅ [88015f11] LERC_jll v3.0.0+1\n [1d63c593] LLVMOpenMP_jll v15.0.7+0\n [dd4b983a] LZO_jll v2.10.2+0\n⌅ [e9f186c6] Libffi_jll v3.2.2+1\n [d4300ac3] Libgcrypt_jll v1.8.11+0\n [7e76a0d4] Libglvnd_jll v1.6.0+0\n [7add5ba3] Libgpg_error_jll v1.49.0+0\n [94ce4f54] Libiconv_jll v1.17.0+0\n [4b2f31a3] Libmount_jll v2.40.1+0\n⌅ [89763e89] Libtiff_jll v4.5.1+1\n [38a345b3] Libuuid_jll v2.40.1+0\n [5ced341a] Lz4_jll v1.9.4+0\n [856f044c] MKL_jll v2024.2.0+0\n [e7412a2a] Ogg_jll v1.3.5+1\n⌅ [9bd350c2] OpenSSH_jll v8.9.0+1\n⌅ [458c3c95] OpenSSL_jll v1.1.23+0\n [efe28fd5] OpenSpecFun_jll v0.5.5+0\n [91d4177d] Opus_jll v1.3.2+0\n [30392449] Pixman_jll v0.43.4+0\n⌅ [c0090381] Qt6Base_jll v6.5.2+2\n [76ed43ae] SQLite_jll v3.45.3+0\n⌅ [fb77eaff] Sundials_jll v5.2.2+0\n [a44049a8] Vulkan_Loader_jll v1.3.243+0\n [a2964d1f] Wayland_jll v1.21.0+1\n [2381bf8a] Wayland_protocols_jll v1.31.0+0\n [02c8fc9c] XML2_jll v2.13.1+0\n [aed1982a] XSLT_jll v1.1.41+0\n [ffd25f8a] XZ_jll v5.4.6+0\n [f67eecfb] Xorg_libICE_jll v1.1.1+0\n [c834827a] Xorg_libSM_jll v1.2.4+0\n [4f6342f7] Xorg_libX11_jll v1.8.6+0\n [0c0b7dd1] Xorg_libXau_jll v1.0.11+0\n [935fb764] Xorg_libXcursor_jll v1.2.0+4\n [a3789734] Xorg_libXdmcp_jll v1.1.4+0\n [1082639a] Xorg_libXext_jll v1.3.6+0\n [d091e8ba] Xorg_libXfixes_jll v5.0.3+4\n [a51aa0fd] Xorg_libXi_jll v1.7.10+4\n [d1454406] Xorg_libXinerama_jll v1.1.4+4\n [ec84b674] Xorg_libXrandr_jll v1.5.2+4\n [ea2f1a96] Xorg_libXrender_jll v0.9.11+0\n [14d82f49] Xorg_libpthread_stubs_jll v0.1.1+0\n [c7cfdc94] Xorg_libxcb_jll v1.17.0+0\n [cc61e674] Xorg_libxkbfile_jll v1.1.2+0\n [e920d4aa] Xorg_xcb_util_cursor_jll v0.1.4+0\n [12413925] Xorg_xcb_util_image_jll v0.4.0+1\n [2def613f] Xorg_xcb_util_jll v0.4.0+1\n [975044d2] Xorg_xcb_util_keysyms_jll v0.4.0+1\n [0d47668e] Xorg_xcb_util_renderutil_jll v0.3.9+1\n [c22f9ab0] Xorg_xcb_util_wm_jll v0.4.1+1\n [35661453] Xorg_xkbcomp_jll v1.4.6+0\n [33bec58e] Xorg_xkeyboard_config_jll v2.39.0+0\n [c5fb5394] Xorg_xtrans_jll v1.5.0+0\n [3161d3a3] Zstd_jll v1.5.6+0\n [35ca27e7] eudev_jll v3.2.9+0\n⌅ [214eeab7] fzf_jll v0.43.0+0\n [1a1c6b14] gperf_jll v3.1.1+0\n [a4ae2306] libaom_jll v3.9.0+0\n [0ac62f75] libass_jll v0.15.1+0\n [2db6ffa8] libevdev_jll v1.11.0+0\n [f638f0a6] libfdk_aac_jll v2.0.2+0\n [36db933b] libinput_jll v1.18.0+0\n [b53b4c65] libpng_jll v1.6.43+1\n [47bcb7c8] libsass_jll v3.6.6+0\n [f27f6e37] libvorbis_jll v1.3.7+1\n [009596ad] mtdev_jll v1.1.6+0\n [1317d2d5] oneTBB_jll v2021.12.0+0\n [1270edf5] x264_jll v2021.5.5+0\n [dfaa095f] x265_jll v3.5.0+0\n [d8fb68d0] xkbcommon_jll v1.4.1+1\n [0dad84c5] ArgTools v1.1.1\n [56f22d72] Artifacts\n [2a0f44e3] Base64\n [ade2ca70] Dates\n [8ba89e20] Distributed\n [f43a241f] Downloads v1.6.0\n [7b1f6079] FileWatching\n [9fa8497b] Future\n [b77e0a4c] InteractiveUtils\n [4af54fe1] LazyArtifacts\n [b27032c2] LibCURL v0.6.4\n [76f85450] LibGit2\n [8f399da3] Libdl\n [37e2e46d] LinearAlgebra\n [56ddb016] Logging\n [d6f4376e] Markdown\n [a63ad114] Mmap\n [ca575930] NetworkOptions v1.2.0\n [44cfe95a] Pkg v1.10.0\n [de0858da] Printf\n [3fa0cd96] REPL\n [9a3f8284] Random\n [ea8e919c] SHA v0.7.0\n [9e88b42a] Serialization\n [1a1011a3] SharedArrays\n [6462fe0b] Sockets\n [2f01184e] SparseArrays v1.10.0\n [10745b16] Statistics v1.10.0\n [4607b0f0] SuiteSparse\n [fa267f1f] TOML v1.0.3\n [a4e569a6] Tar v1.10.0\n [8dfed614] Test\n [cf7118a7] UUIDs\n [4ec0a83e] Unicode\n [e66e0078] CompilerSupportLibraries_jll v1.1.1+0\n [deac9b47] LibCURL_jll v8.4.0+0\n [e37daf67] LibGit2_jll v1.6.4+0\n [29816b5a] LibSSH2_jll v1.11.0+1\n [c8ffd9c3] MbedTLS_jll v2.28.2+1\n [14a3606d] MozillaCACerts_jll v2023.1.10\n [4536629a] OpenBLAS_jll v0.3.23+4\n [05823500] OpenLibm_jll v0.8.1+2\n [efcefdf7] PCRE2_jll v10.42.0+1\n [bea87d4a] SuiteSparse_jll v7.2.1+1\n [83775a58] Zlib_jll v1.2.13+1\n [8e850b90] libblastrampoline_jll v5.8.0+1\n [8e850ede] nghttp2_jll v1.52.0+1\n [3f19e933] p7zip_jll v17.4.0+2\nInfo Packages marked with ⌃ and ⌅ have new versions available. Those with ⌃ may be upgradable, but those with ⌅ are restricted by compatibility constraints from upgrading. To see why use `status --outdated -m`\n"},"time_series_in_memory":false},"units_settings":{"base_value":100.0,"unit_system":"SYSTEM_BASE","__metadata__":{"module":"InfrastructureSystems","type":"SystemUnitsSettings"}},"frequency":60.0,"runchecks":true,"metadata":{"name":null,"description":null,"__metadata__":{"module":"PowerSystems","type":"SystemMetadata"}},"data_format_version":"4.0.0"} \ No newline at end of file diff --git a/dev/tutorials/modified_sys_metadata.json b/dev/tutorials/modified_sys_metadata.json index edfb83aaf..31ccce301 100644 --- a/dev/tutorials/modified_sys_metadata.json +++ b/dev/tutorials/modified_sys_metadata.json @@ -2,7 +2,8 @@ "name": "", "description": "", "frequency": 60, - "time_series_resolution_milliseconds": 0, + "time_series_resolutions_milliseconds": [ + ], "component_counts": [ { "type": "ACBus", @@ -17,7 +18,7 @@ "count": 1 }, { - "type": "DynamicGenerator", + "type": "DynamicGenerator{BaseMachine, SingleMass, AVRFixed, TGFixed, PSSFixed}", "count": 1 }, { diff --git a/dev/tutorials/modified_sys_validation_descriptors.json b/dev/tutorials/modified_sys_validation_descriptors.json deleted file mode 100644 index ba401f09a..000000000 --- a/dev/tutorials/modified_sys_validation_descriptors.json +++ /dev/null @@ -1 +0,0 @@ -{"struct_validation_descriptors":[{"fields":[{"name":"variable","data_type":"VariableCost","null_value":"VariableCost((0.0, 0.0))","comment":"variable cost"},{"name":"fixed","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"fixed cost","valid_range":{"max":null,"min":0}}],"docstring":"Data Structure Operational Cost Data in two parts: fixed and variable cost.","struct_name":"TwoPartCost","supertype":"OperationalCost"},{"fields":[{"name":"variable","data_type":"VariableCost","null_value":"VariableCost((0.0, 0.0))","comment":"variable cost"},{"name":"fixed","data_type":"Float64","null_value":"0.0","comment":"fixed cost"},{"name":"start_up","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"start-up cost","valid_range":{"max":null,"min":0}},{"name":"shut_down","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"shut-down cost","valid_range":{"max":null,"min":0}}],"docstring":"Data Structure Operational Cost Data in Three parts fixed, variable cost and start - stop costs.","struct_name":"ThreePartCost","supertype":"OperationalCost"},{"fields":[{"name":"variable","default":"VariableCost((0.0, 0.0))","data_type":"VariableCost","null_value":"VariableCost((0.0, 0.0))","comment":"variable cost"},{"name":"fixed","default":"0.0","data_type":"Float64","null_value":"0.0","comment":"fixed cost"},{"name":"start_up","default":"0.0","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"start-up cost","valid_range":{"max":null,"min":0}},{"name":"shut_down","default":"0.0","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"shut-down cost","valid_range":{"max":null,"min":0}},{"name":"energy_shortage_cost","default":"0.0","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"Cost incurred by the model for being short of the energy target.","valid_range":{"max":null,"min":0}},{"name":"energy_surplus_cost","default":"0.0","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"Cost incurred by the model for surplus energy stored.","valid_range":{"max":null,"min":0}}],"docstring":"Data Structure for Operational Cost Data like variable cost and start - stop costs and energy storage cost.","struct_name":"StorageManagementCost","supertype":"OperationalCost"},{"fields":[{"name":"no_load","data_type":"Float64","null_value":"0.0","comment":"no load cost"},{"name":"start_up","data_type":"NamedTuple{(:hot, :warm, :cold), NTuple{3, Float64}}","null_value":"(hot = START_COST, warm = START_COST, cold = START_COST)","comment":"start-up cost at different stages of the thermal cycle. Warm is also refered as intermediate in some markets"},{"name":"shut_down","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"shut-down cost","valid_range":{"max":null,"min":0}},{"name":"variable","default":"nothing","data_type":"Union{Nothing, IS.TimeSeriesKey}","null_value":"nothing","comment":"Variable Cost TimeSeriesKey"},{"name":"ancillary_services","default":"Vector{Service}()","data_type":"Vector{Service}","null_value":"Vector{Service}()","comment":"Bids for the ancillary services"}],"docstring":"Data Structure Operational Cost to reflect market bids of energy and ancilliary services.\nCompatible with most US Market bidding mechanisms","struct_name":"MarketBidCost","supertype":"OperationalCost"},{"fields":[{"name":"variable","data_type":"VariableCost","null_value":"VariableCost((0.0, 0.0))","comment":"variable cost"},{"name":"no_load","data_type":"Float64","null_value":"0.0","comment":"no load cost"},{"name":"fixed","data_type":"Float64","null_value":"0.0","comment":"fixed cost"},{"name":"start_up","data_type":"NamedTuple{(:hot, :warm, :cold), NTuple{3, Float64}}","null_value":"(hot = START_COST, warm = START_COST, cold = START_COST)","comment":"start-up cost"},{"name":"shut_down","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"shut-down cost","valid_range":{"max":null,"min":0}}],"docstring":"Data Structure Operational Cost Data which includes fixed, variable cost, multiple start up cost and stop costs.","struct_name":"MultiStartCost","supertype":"OperationalCost"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"peak_active_power","needs_conversion":true,"default":"0.0","data_type":"Float64","null_value":"0.0"},{"name":"peak_reactive_power","needs_conversion":true,"default":"0.0","data_type":"Float64","null_value":"0.0"},{"name":"load_response","default":"0.0","data_type":"Float64","null_value":"0.0"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"A collection of buses for control purposes.","struct_name":"Area","supertype":"AggregationTopology"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"peak_active_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"peak_reactive_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"A collection of buses for electricity price analysis.","struct_name":"LoadZone","supertype":"AggregationTopology"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"active_power_flow_limits","needs_conversion":true,"data_type":"MinMax","null_value":"(min=0.0, max=0.0)"},{"name":"violation_penalty","default":"INFINITE_COST","data_type":"Float64","null_value":"0.0","comment":"Penalty for violating the flow limits in the interface"},{"name":"direction_mapping","default":"Dict{String, Int}()","data_type":"Dict{String, Int}","null_value":"Dict{String, Int}()","comment":"Map to set of multiplier to the flow in the line for cases when the line has a reverse direction with respect to the interface"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"A collection of branches that make up an interface or corridor for the transfer of power.","struct_name":"TransmissionInterface","supertype":"Service"},{"inner_constructor_check":"check_bus_params","fields":[{"name":"number","data_type":"Int","null_value":"0","comment":"number associated with the bus"},{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init","comment":"the name of the bus"},{"name":"bustype","data_type":"Union{Nothing, ACBusTypes}","null_value":"nothing","comment":"bus type"},{"name":"angle","data_type":"Union{Nothing, Float64}","null_value":"0.0","validation_action":"error","comment":"angle of the bus in radians","valid_range":{"max":1.571,"min":-1.571}},{"name":"magnitude","data_type":"Union{Nothing, Float64}","null_value":"0.0","validation_action":"warn","comment":"voltage as a multiple of basevoltage","valid_range":"voltage_limits"},{"name":"voltage_limits","data_type":"Union{Nothing, MinMax}","null_value":"(min=0.0, max=0.0)","comment":"limits on the voltage variation as multiples of basevoltage"},{"name":"base_voltage","data_type":"Union{Nothing, Float64}","null_value":"nothing","validation_action":"error","comment":"the base voltage in kV","valid_range":{"max":null,"min":0}},{"name":"area","default":"nothing","data_type":"Union{Nothing, Area}","null_value":"nothing","comment":"the area containing the bus"},{"name":"load_zone","default":"nothing","data_type":"Union{Nothing, LoadZone}","null_value":"nothing","comment":"the load zone containing the bus"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"A power-system bus.","struct_name":"ACBus","supertype":"Bus"},{"fields":[{"name":"number","data_type":"Int","null_value":"0","comment":"number associated with the DC bus"},{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init","comment":"the name of the DC bus"},{"name":"magnitude","data_type":"Union{Nothing, Float64}","null_value":"0.0","validation_action":"warn","comment":"voltage as a multiple of basevoltage","valid_range":"voltage_limits"},{"name":"voltage_limits","data_type":"Union{Nothing, MinMax}","null_value":"(min=0.0, max=0.0)","comment":"limits on the voltage variation as multiples of basevoltage"},{"name":"base_voltage","data_type":"Union{Nothing, Float64}","null_value":"nothing","validation_action":"error","comment":"the base voltage in kV","valid_range":{"max":null,"min":0}},{"name":"area","default":"nothing","data_type":"Union{Nothing, Area}","null_value":"nothing","comment":"the area containing the DC bus"},{"name":"load_zone","default":"nothing","data_type":"Union{Nothing, LoadZone}","null_value":"nothing","comment":"the load zone containing the DC bus"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"A power-system DC bus.","struct_name":"DCBus","supertype":"Bus"},{"fields":[{"name":"from","data_type":"Bus","null_value":"ACBus(nothing)","comment":"The initial bus"},{"name":"to","data_type":"Bus","null_value":"ACBus(nothing)","comment":"The terminal bus"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"A topological Arc.","struct_name":"Arc","supertype":"Topology","custom_code":"get_name(arc::Arc) = (get_name ∘ get_from)(arc) * \" -> \" * (get_name ∘ get_to)(arc)"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"active_power_flow","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"reactive_power_flow","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"arc","data_type":"Arc","null_value":"Arc(ACBus(nothing), ACBus(nothing))"},{"name":"r","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"System per-unit value","valid_range":{"max":4,"min":0}},{"name":"x","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"System per-unit value","valid_range":{"max":4,"min":0}},{"name":"b","data_type":"FromTo","null_value":"(from=0.0, to=0.0)","validation_action":"warn","comment":"System per-unit value","valid_range":{"max":100,"min":0}},{"name":"rate","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"angle_limits","data_type":"MinMax","null_value":"(min=-1.571, max=1.571)","validation_action":"error","valid_range":{"max":1.571,"min":-1.571}},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"struct_name":"Line","supertype":"ACBranch"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"active_power_flow","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"reactive_power_flow","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"arc","data_type":"Arc","null_value":"Arc(ACBus(nothing), ACBus(nothing))"},{"name":"r","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"System per-unit value","valid_range":{"max":4,"min":0}},{"name":"x","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"System per-unit value","valid_range":{"max":4,"min":0}},{"name":"b","data_type":"FromTo","null_value":"(from=0.0, to=0.0)","validation_action":"warn","comment":"System per-unit value","valid_range":{"max":2,"min":0}},{"name":"flow_limits","needs_conversion":true,"data_type":"FromTo_ToFrom","null_value":"(from_to=0.0, to_from=0.0)","comment":"throw warning above max SIL"},{"name":"rate","needs_conversion":true,"data_type":"Float64","null_value":"0.0","comment":"compare to SIL (warn) (theoretical limit)"},{"name":"angle_limits","data_type":"MinMax","null_value":"(min=-1.571, max=1.571)","validation_action":"error","valid_range":{"max":1.571,"min":-1.571}},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"struct_name":"MonitoredLine","supertype":"ACBranch"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"active_power_flow","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"reactive_power_flow","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"arc","data_type":"Arc","null_value":"Arc(ACBus(nothing), ACBus(nothing))"},{"name":"r","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"System per-unit value","valid_range":{"max":4,"min":0}},{"name":"x","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"System per-unit value","valid_range":{"max":4,"min":-2}},{"name":"primary_shunt","Comment":"System per-unit value","data_type":"Float64","null_value":"0.0","validation_action":"warn","valid_range":{"max":2,"min":0}},{"name":"tap","data_type":"Float64","null_value":"1.0","validation_action":"error","valid_range":{"max":2,"min":0}},{"name":"α","data_type":"Float64","null_value":"0.0","validation_action":"warn","valid_range":{"max":1.571,"min":-1.571}},{"name":"rate","needs_conversion":true,"data_type":"Union{Nothing, Float64}","null_value":"0.0","validation_action":"error","valid_range":{"max":null,"min":0}},{"name":"phase_angle_limits","default":"(min=-1.571, max=1.571)","data_type":"MinMax","null_value":"(min=-1.571, max=1.571)","validation_action":"error","valid_range":{"max":1.571,"min":-1.571}},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"struct_name":"PhaseShiftingTransformer","supertype":"ACBranch"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"active_power_flow","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"reactive_power_flow","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"arc","data_type":"Arc","null_value":"Arc(ACBus(nothing), ACBus(nothing))"},{"name":"r","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"System per-unit value","valid_range":{"max":2,"min":-2}},{"name":"x","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"System per-unit value","valid_range":{"max":4,"min":-2}},{"name":"primary_shunt","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"System per-unit value","valid_range":{"max":2,"min":0}},{"name":"tap","data_type":"Float64","null_value":"1.0","validation_action":"error","valid_range":{"max":2,"min":0}},{"name":"rate","needs_conversion":true,"data_type":"Union{Nothing, Float64}","null_value":"0.0","validation_action":"error","valid_range":{"max":null,"min":0}},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"struct_name":"TapTransformer","supertype":"ACBranch"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"active_power_flow","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"reactive_power_flow","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"arc","data_type":"Arc","null_value":"Arc(ACBus(nothing), ACBus(nothing))"},{"name":"r","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"System per-unit value","valid_range":{"max":4,"min":-2}},{"name":"x","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"System per-unit value","valid_range":{"max":4,"min":-2}},{"name":"primary_shunt","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"System per-unit value","valid_range":{"max":2,"min":0}},{"name":"rate","needs_conversion":true,"data_type":"Union{Nothing, Float64}","null_value":"nothing","validation_action":"error","valid_range":{"max":null,"min":0}},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"The 2-W transformer model uses an equivalent circuit assuming the impedance is on the High Voltage Side of the transformer. The model allocates the iron losses and magnetizing susceptance to the primary side.","struct_name":"Transformer2W","supertype":"ACBranch"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"active_power_flow","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"arc","data_type":"Arc","null_value":"Arc(ACBus(nothing), ACBus(nothing))"},{"name":"active_power_limits_from","needs_conversion":true,"data_type":"MinMax","null_value":"(min=0.0, max=0.0)"},{"name":"active_power_limits_to","needs_conversion":true,"data_type":"MinMax","null_value":"(min=0.0, max=0.0)"},{"name":"reactive_power_limits_from","needs_conversion":true,"data_type":"MinMax","null_value":"(min=0.0, max=0.0)"},{"name":"reactive_power_limits_to","needs_conversion":true,"data_type":"MinMax","null_value":"(min=0.0, max=0.0)"},{"name":"loss","data_type":"NamedTuple{(:l0, :l1), Tuple{Float64, Float64}}","null_value":"(l0=0.0, l1=0.0)"},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"a High voltage DC line.","struct_name":"TwoTerminalHVDCLine","supertype":"ACBranch"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"active_power_flow","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"arc","data_type":"Arc","null_value":"Arc(ACBus(nothing), ACBus(nothing))"},{"name":"rectifier_tap_limits","data_type":"MinMax","null_value":"(min=0.0, max=0.0)"},{"name":"rectifier_xrc","data_type":"Float64","null_value":"0.0"},{"name":"rectifier_firing_angle","data_type":"MinMax","null_value":"(min=0.0, max=0.0)"},{"name":"inverter_tap_limits","data_type":"MinMax","null_value":"(min=0.0, max=0.0)"},{"name":"inverter_xrc","data_type":"Float64","null_value":"0.0"},{"name":"inverter_firing_angle","data_type":"MinMax","null_value":"(min=0.0, max=0.0)"},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"As implemented in Milano's Book, Page 397.","struct_name":"TwoTerminalVSCDCLine","supertype":"ACBranch"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"active_power_flow","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"arc","data_type":"Arc","null_value":"Arc(DCBus(nothing), DCBus(nothing))"},{"name":"r","data_type":"Float64","null_value":"0.0","comment":"Series Resistance system per-unit value"},{"name":"l","data_type":"Float64","null_value":"0.0","comment":"Series Inductance system per-unit value"},{"name":"c","data_type":"Float64","null_value":"0.0","comment":"Shunt capacitance system per-unit value"},{"name":"active_power_limits_from","needs_conversion":true,"data_type":"MinMax","null_value":"(min=0.0, max=0.0)"},{"name":"active_power_limits_to","needs_conversion":true,"data_type":"MinMax","null_value":"(min=0.0, max=0.0)"},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"a HVDC T-Model DC line.","struct_name":"TModelHVDCLine","supertype":"DCBranch"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"bus","data_type":"ACBus","null_value":"ACBus(nothing)"},{"name":"active_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"reactive_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"max_active_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"max_reactive_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"base_power","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"Base power of the unit in MVA","valid_range":{"max":null,"min":0}},{"name":"operation_cost","data_type":"TwoPartCost","null_value":"TwoPartCost(nothing)","comment":"Operation Cost of Generation [`TwoPartCost`](@ref)"},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"dynamic_injector","default":"nothing","data_type":"Union{Nothing, DynamicInjection}","exclude_setter":true,"null_value":"nothing","comment":"corresponding dynamic injection device"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"struct_name":"InterruptiblePowerLoad","supertype":"ControllableLoad"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"bus","data_type":"ACBus","null_value":"ACBus(nothing)"},{"name":"Y","data_type":"Complex{Float64}","null_value":"0.0","comment":"System per-unit value"},{"name":"dynamic_injector","default":"nothing","data_type":"Union{Nothing, DynamicInjection}","exclude_setter":true,"null_value":"nothing","comment":"corresponding dynamic injection model for admittance"},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"struct_name":"FixedAdmittance","supertype":"ElectricLoad"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"bus","data_type":"ACBus","null_value":"ACBus(nothing)"},{"name":"Y","data_type":"Complex{Float64}","null_value":"0.0","comment":"Initial impedance at N = 0"},{"name":"number_of_steps","default":"0","data_type":"Int","null_value":"0","comment":"Number of steps for adjustable shunt"},{"name":"Y_increase","default":"0","data_type":"Complex{Float64}","null_value":"0","comment":"Admittance increment for each of step increase"},{"name":"dynamic_injector","default":"nothing","data_type":"Union{Nothing, DynamicInjection}","exclude_setter":true,"null_value":"nothing","comment":"corresponding dynamic injection model for admittance"},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"struct_name":"SwitchedAdmittance","supertype":"ElectricLoad"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"bus","data_type":"ACBus","null_value":"ACBus(nothing)"},{"name":"active_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"reactive_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"base_power","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"Base power of the unit in MVA","valid_range":{"max":null,"min":0}},{"name":"max_active_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"max_reactive_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"dynamic_injector","default":"nothing","data_type":"Union{Nothing, DynamicInjection}","exclude_setter":true,"null_value":"nothing","comment":"corresponding dynamic injection device"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Data structure for a static power load.","struct_name":"PowerLoad","supertype":"StaticLoad"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"bus","data_type":"ACBus","null_value":"ACBus(nothing)"},{"name":"base_power","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"Base power of the unit in MVA","valid_range":{"max":null,"min":0}},{"name":"constant_active_power","needs_conversion":true,"default":"0.0","data_type":"Float64","null_value":"0.0"},{"name":"constant_reactive_power","needs_conversion":true,"default":"0.0","data_type":"Float64","null_value":"0.0"},{"name":"impedance_active_power","needs_conversion":true,"default":"0.0","data_type":"Float64","null_value":"0.0"},{"name":"impedance_reactive_power","needs_conversion":true,"default":"0.0","data_type":"Float64","null_value":"0.0"},{"name":"current_active_power","needs_conversion":true,"default":"0.0","data_type":"Float64","null_value":"0.0"},{"name":"current_reactive_power","needs_conversion":true,"default":"0.0","data_type":"Float64","null_value":"0.0"},{"name":"max_constant_active_power","needs_conversion":true,"default":"0.0","data_type":"Float64","null_value":"0.0"},{"name":"max_constant_reactive_power","needs_conversion":true,"default":"0.0","data_type":"Float64","null_value":"0.0"},{"name":"max_impedance_active_power","needs_conversion":true,"default":"0.0","data_type":"Float64","null_value":"0.0"},{"name":"max_impedance_reactive_power","needs_conversion":true,"default":"0.0","data_type":"Float64","null_value":"0.0"},{"name":"max_current_active_power","needs_conversion":true,"default":"0.0","data_type":"Float64","null_value":"0.0"},{"name":"max_current_reactive_power","needs_conversion":true,"default":"0.0","data_type":"Float64","null_value":"0.0"},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"dynamic_injector","default":"nothing","data_type":"Union{Nothing, DynamicInjection}","exclude_setter":true,"null_value":"nothing","comment":"corresponding dynamic injection device"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Data structure for a standard load.","struct_name":"StandardLoad","supertype":"StaticLoad"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"bus","data_type":"ACBus","null_value":"ACBus(nothing)"},{"name":"active_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"reactive_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"active_power_coefficient","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"Coefficient relating voltage dependence for power P = P0 * V^α","valid_range":{"max":null,"min":0}},{"name":"reactive_power_coefficient","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"Coefficient relating voltage dependence for power Q = Q0 * V^β","valid_range":{"max":null,"min":0}},{"name":"base_power","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"Base power of the unit in MVA","valid_range":{"max":null,"min":0}},{"name":"max_active_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"max_reactive_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"dynamic_injector","default":"nothing","data_type":"Union{Nothing, DynamicInjection}","exclude_setter":true,"null_value":"nothing","comment":"corresponding dynamic injection device"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Data structure for a static exponential load.","struct_name":"ExponentialLoad","supertype":"StaticLoad"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"R_s","data_type":"Float64","null_value":0,"comment":"Armature stator resistance","valid_range":{"max":null,"min":0}},{"name":"R_r","data_type":"Float64","null_value":0,"comment":"Rotor resistance","valid_range":{"max":null,"min":0}},{"name":"X_ls","data_type":"Float64","null_value":0,"comment":"Stator Leakage Reactance","valid_range":{"max":null,"min":0}},{"name":"X_lr","data_type":"Float64","null_value":0,"comment":"Rotor Leakage Reactance","valid_range":{"max":null,"min":0}},{"name":"X_m","data_type":"Float64","null_value":0,"comment":"Stator-Rotor Mutual Reactance","valid_range":{"max":null,"min":0}},{"name":"H","data_type":"Float64","null_value":0,"comment":"Motor Inertia Constant [s]","valid_range":{"max":null,"min":0}},{"name":"A","data_type":"Float64","null_value":"0.0","comment":"Torque-Speed Quadratic Term","valid_range":{"max":1,"min":0}},{"name":"B","data_type":"Float64","null_value":"0.0","comment":"Torque-Speed Linear Term","valid_range":{"max":1,"min":0}},{"name":"base_power","data_type":"Float64","null_value":0,"comment":"Base power","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"C","data_type":"Float64","comment":"Torque-Speed Constant Term","internal_default":"PowerSystems.calculate_IM_torque_params(A, B)"},{"name":"τ_ref","data_type":"Float64","comment":"Reference torque parameter","internal_default":"1.0"},{"name":"B_shunt","data_type":"Float64","comment":"Susceptance Initialization Corrector Term","internal_default":"0.0"},{"name":"X_ad","data_type":"Float64","comment":"Equivalent d-axis reactance","internal_default":"(1.0 / X_m + 1.0 / X_ls + 1.0 / X_lr)^(-1)"},{"name":"X_aq","data_type":"Float64","comment":"Equivalent q-axis reactance","internal_default":"X_ad"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tψ_qs: stator flux in the q-axis,\n\tψ_ds: stator flux in the d-axis,\n\tψ_qr: rotor flux in the q-axis,\n\tψ_dr: rotor flux in the d-axis, \n\tωr: Rotor speed [pu],","internal_default":"[:ψ_qs, :ψ_ds, :ψ_qr, :ψ_dr, :ωr]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"SingleCageInductionMachine has 5 states","internal_default":5},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of 5-states three-phase single cage induction machine with quadratic torque-speed relationship.","struct_name":"SingleCageInductionMachine","supertype":"DynamicInjection"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"R_s","data_type":"Float64","null_value":0,"comment":"Armature stator resistance","valid_range":{"max":null,"min":0}},{"name":"R_r","data_type":"Float64","null_value":0,"comment":"Rotor resistance","valid_range":{"max":null,"min":0}},{"name":"X_ls","data_type":"Float64","null_value":0,"comment":"Stator Leakage Reactance","valid_range":{"max":null,"min":0}},{"name":"X_lr","data_type":"Float64","null_value":0,"comment":"Rotor Leakage Reactance","valid_range":{"max":null,"min":0}},{"name":"X_m","data_type":"Float64","null_value":0,"comment":"Stator-Rotor Mutual Reactance","valid_range":{"max":null,"min":0}},{"name":"H","data_type":"Float64","null_value":0,"comment":"Motor Inertia Constant [s]","valid_range":{"max":null,"min":0}},{"name":"A","data_type":"Float64","null_value":"0.0","comment":"Torque-Speed Quadratic Term","valid_range":{"max":1,"min":0}},{"name":"B","data_type":"Float64","null_value":"0.0","comment":"Torque-Speed Linear Term","valid_range":{"max":1,"min":0}},{"name":"base_power","data_type":"Float64","null_value":0,"comment":"Base power","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"C","data_type":"Float64","comment":"Torque-Speed Constant Term","internal_default":"PowerSystems.calculate_IM_torque_params(A, B)"},{"name":"τ_ref","data_type":"Float64","comment":"Reference torque parameter","internal_default":"1.0"},{"name":"B_shunt","data_type":"Float64","comment":"Susceptance Initialization Corrector Term","internal_default":"0.0"},{"name":"X_ss","data_type":"Float64","comment":"Stator self reactance","internal_default":"X_ls + X_m"},{"name":"X_rr","data_type":"Float64","comment":"Rotor self reactance","internal_default":"X_lr + X_m"},{"name":"X_p","data_type":"Float64","comment":"Transient reactance","internal_default":"X_ss - X_m^2 / X_rr"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tψ_qr: rotor flux in the q-axis,\n\tψ_dr: rotor flux in the d-axis, \n\tωr: Rotor speed [pu],","internal_default":"[:ψ_qr, :ψ_dr, :ωr]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"SimplifiedSingleCageInductionMachine has 3 states","internal_default":3},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of 3-states three-phase single cage induction machine with quadratic torque-speed relationship.","struct_name":"SimplifiedSingleCageInductionMachine","supertype":"DynamicInjection"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"a","data_type":"Float64","null_value":0,"comment":"Active power static exponential coefficient","valid_range":{"max":null,"min":0}},{"name":"b","data_type":"Float64","null_value":0,"comment":"Reactive power static exponential coefficient","valid_range":{"max":null,"min":0}},{"name":"α","data_type":"Float64","null_value":0,"comment":"Active power transient exponential coefficient","valid_range":{"max":null,"min":0}},{"name":"β","data_type":"Float64","null_value":0,"comment":"Reactive power transient exponential coefficient","valid_range":{"max":null,"min":0}},{"name":"T_p","data_type":"Float64","null_value":0,"comment":"Active Power Time Constant","valid_range":{"max":null,"min":0}},{"name":"T_q","data_type":"Float64","null_value":0,"comment":"Reactive Power Time Constant","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"base_power","data_type":"Float64","comment":"Base Power","internal_default":"100.0"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tx_p: Integrator state of the active power,\n\tx_q: Integrator state of the reactive power,","internal_default":"[:x_p, :x_q]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"DynamicExponentialLoad has 2 states","internal_default":2},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of 2-states of a generic dynamic load model based on VOLTAGE STABILITY ANALYSIS USING GENERIC DYNAMIC LOAD MODELS by W. Xu and Y. Mansour, IEEE Transactions on Power Systems, 1994.","struct_name":"DynamicExponentialLoad","supertype":"DynamicInjection"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"r_load","data_type":"Float64","null_value":0,"comment":"DC-side resistor","valid_range":{"max":null,"min":0}},{"name":"c_dc","data_type":"Float64","null_value":0,"comment":"DC-side capacitor","valid_range":{"max":null,"min":0}},{"name":"rf","data_type":"Float64","null_value":0,"comment":"Converter side filter resistance","valid_range":{"max":null,"min":0}},{"name":"lf","data_type":"Float64","null_value":0,"comment":"Converter side filter inductance","valid_range":{"max":null,"min":0}},{"name":"cf","data_type":"Float64","null_value":0,"comment":"AC Converter filter capacitance","valid_range":{"max":null,"min":0}},{"name":"rg","data_type":"Float64","null_value":0,"comment":"Network side filter resistance","valid_range":{"max":null,"min":0}},{"name":"lg","data_type":"Float64","null_value":0,"comment":"Network side filter inductance","valid_range":{"max":null,"min":0}},{"name":"kp_pll","data_type":"Float64","null_value":0,"comment":"Proportional constant for PI-PLL block","valid_range":{"max":null,"min":0}},{"name":"ki_pll","data_type":"Float64","null_value":0,"comment":"Integral constant for PI-PLL block","valid_range":{"max":null,"min":0}},{"name":"kpv","data_type":"Float64","null_value":0,"comment":"Proportional constant for Voltage Control block","valid_range":{"max":null,"min":0}},{"name":"kiv","data_type":"Float64","null_value":0,"comment":"Integral constant for Voltage Control block","valid_range":{"max":null,"min":0}},{"name":"kpc","data_type":"Float64","null_value":0,"comment":"Proportional constant for Current Control block","valid_range":{"max":null,"min":0}},{"name":"kic","data_type":"Float64","null_value":0,"comment":"Integral constant for Current Control block","valid_range":{"max":null,"min":0}},{"name":"base_power","data_type":"Float64","null_value":0,"comment":"Base power","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"P_ref","data_type":"Float64","comment":"Reference active power parameter","internal_default":"1.0"},{"name":"Q_ref","data_type":"Float64","comment":"Reference reactive power parameter","internal_default":"1.0"},{"name":"V_ref","data_type":"Float64","comment":"Reference voltage parameter","internal_default":"1.0"},{"name":"ω_ref","data_type":"Float64","comment":"Reference frequency parameter","internal_default":"1.0"},{"name":"is_filter_differential","data_type":"Int","comment":"Boolean to decide if filter states are differential or algebraic","internal_default":"1"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tθ_pll: PLL deviation angle, \n\tϵ_pll: PLL integrator state, \n\tη: DC-voltage controller integrator state, \n\tv_dc: DC voltage at the capacitor, \n\tγd: d-axis Current controller integrator state, \n\tγq: q-axis Current controller integrator state, \n\tir_cnv: Real current out of the converter,\n\tii_cnv: Imaginary current out of the converter,\n\tvr_filter: Real voltage at the filter's capacitor,\n\tvi_filter: Imaginary voltage at the filter's capacitor,\n\tir_filter: Real current out of the filter,\n\tii_filter: Imaginary current out of the filter","internal_default":"[:θ_pll, :ϵ_pll, :η, :v_dc, :γd, :γq, :ir_cnv, :ii_cnv, :vr_filter, :vi_filter, :ir_filter, :ii_filter]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"ActiveConstantPowerLoad has 12 states","internal_default":12},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of 12-states active power load based on the paper Dynamic Stability of a Microgrid With an Active Load from N. Bottrell, M. Prodanovic and T. Green in IEEE Transactions on Power Electronics, 2013.","struct_name":"ActiveConstantPowerLoad","supertype":"DynamicInjection"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"bus","data_type":"ACBus","null_value":"ACBus(nothing)"},{"name":"dc_bus","data_type":"DCBus","null_value":"DCBus(nothing)"},{"name":"active_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"Active Power on the DCSide","valid_range":"active_power_limits"},{"name":"rating","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"Thermal limited MVA Power Output of the converter. <= Capacity","valid_range":{"max":null,"min":0}},{"name":"active_power_limits","needs_conversion":true,"data_type":"MinMax","null_value":"(min=0.0, max=0.0)"},{"name":"base_power","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"Base power of the converter in MVA","valid_range":{"max":null,"min":0}},{"name":"operation_cost","default":"TwoPartCost(0.0, 0.0)","data_type":"OperationalCost","null_value":"TwoPartCost(nothing)","comment":"Operation Cost of Generation [`OperationalCost`](@ref)"},{"name":"efficiency","default":"1.0","data_type":"Float64","null_value":"0.0","comment":"Conversion efficiency from AC Power to DC Power"},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"dynamic_injector","default":"nothing","data_type":"Union{Nothing, DynamicInjection}","exclude_setter":true,"null_value":"nothing","comment":"corresponding dynamic injection device"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Interconnecting Power Converter (IPC) for transforming power from an ACBus to a DCBus","struct_name":"InterconnectingConverter","supertype":"StaticInjection"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"K","data_type":"Float64","null_value":0,"comment":"Gain in pu","valid_range":{"max":null,"min":0}},{"name":"T1","data_type":"Float64","null_value":0,"comment":"Time constant in s","valid_range":{"max":null,"min":0}},{"name":"T2","data_type":"Float64","null_value":0,"comment":"Time constant in s","valid_range":{"max":null,"min":0}},{"name":"T3","data_type":"Float64","null_value":0,"comment":"Time constant in s","valid_range":{"max":null,"min":"eps()"}},{"name":"T4","data_type":"Float64","null_value":0,"comment":"Time constant in s","valid_range":{"max":null,"min":0}},{"name":"T5","data_type":"Float64","null_value":0,"comment":"Time constant in s","valid_range":{"max":null,"min":0}},{"name":"Rmin","data_type":"Float64","null_value":0,"comment":"Reactor minimum Mvar","valid_range":{"max":null,"min":0}},{"name":"Vmax","data_type":"Float64","null_value":0,"comment":"Maximum voltage in pu","valid_range":{"max":null,"min":0}},{"name":"Vmin","data_type":"Float64","null_value":0,"comment":"Minimum voltage in pu","valid_range":{"max":null,"min":0}},{"name":"CBase","data_type":"Float64","null_value":0,"comment":"Capacitor Mvar","valid_range":{"max":null,"min":0}},{"name":"base_power","data_type":"Float64","null_value":0,"comment":"Base power","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"R_th","data_type":"Float64","comment":"Source Thevenin resistance","internal_default":"0.0"},{"name":"X_th","data_type":"Float64","comment":"Source Thevenin reactance","internal_default":"0.0"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tthy: thyristor,\n\tvr1: regulator output 1,\n\tvr2: regulator output 2","internal_default":"[:thy, :vr1, :vr2]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"CSVGN1 has 3 states","internal_default":3},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of static shunt compensator: CSVGN1 in PSSE","struct_name":"CSVGN1","supertype":"DynamicInjection"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"bus","data_type":"ACBus","null_value":"ACBus(nothing)"},{"name":"active_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"reactive_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"warn","valid_range":"reactive_power_limits"},{"name":"rating","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"Thermal limited MVA Power Output of the unit. <= Capacity","valid_range":{"max":null,"min":0}},{"name":"prime_mover_type","data_type":"PrimeMovers","null_value":"PrimeMovers.HY","comment":"Prime mover technology according to EIA 923"},{"name":"active_power_limits","needs_conversion":true,"data_type":"MinMax","null_value":"(min=0.0, max=0.0)"},{"name":"reactive_power_limits","needs_conversion":true,"data_type":"Union{Nothing, MinMax}","null_value":"nothing","validation_action":"warn"},{"name":"ramp_limits","needs_conversion":true,"data_type":"Union{Nothing, UpDown}","null_value":"nothing","validation_action":"error","comment":"ramp up and ramp down limits in MW (in component base per unit) per minute","valid_range":{"max":null,"min":0}},{"name":"time_limits","data_type":"Union{Nothing, UpDown}","null_value":"nothing","validation_action":"error","comment":"Minimum up and Minimum down time limits in hours","valid_range":{"max":null,"min":0}},{"name":"base_power","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"Base power of the unit in MVA","valid_range":{"max":null,"min":0}},{"name":"storage_capacity","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"Maximum storage capacity in the reservoir (units can be p.u-hr or m^3).","valid_range":{"max":null,"min":0}},{"name":"inflow","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"Baseline inflow into the reservoir (units can be p.u. or m^3/hr)","valid_range":{"max":null,"min":0}},{"name":"initial_storage","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"Initial storage capacity in the reservoir (units can be p.u-hr or m^3).","valid_range":{"max":null,"min":0}},{"name":"operation_cost","default":"TwoPartCost(0.0, 0.0)","data_type":"OperationalCost","null_value":"TwoPartCost(nothing)","comment":"Operation Cost of Generation [`OperationalCost`](@ref)"},{"name":"storage_target","default":"1.0","data_type":"Float64","null_value":"0.0","comment":"Storage target at the end of simulation as ratio of storage capacity."},{"name":"conversion_factor","default":"1.0","data_type":"Float64","null_value":"0.0","comment":"Conversion factor from flow/volume to energy: m^3 -> p.u-hr."},{"name":"time_at_status","default":"INFINITE_TIME","data_type":"Float64","null_value":"INFINITE_TIME"},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"dynamic_injector","default":"nothing","data_type":"Union{Nothing, DynamicInjection}","exclude_setter":true,"null_value":"nothing","comment":"corresponding dynamic injection device"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"struct_name":"HydroEnergyReservoir","supertype":"HydroGen"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"bus","data_type":"ACBus","null_value":"ACBus(nothing)"},{"name":"active_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"reactive_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"warn","valid_range":"reactive_power_limits"},{"name":"rating","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"Thermal limited MVA Power Output of the unit. <= Capacity","valid_range":{"max":null,"min":0}},{"name":"prime_mover_type","data_type":"PrimeMovers","null_value":"PrimeMovers.HY","comment":"Prime mover technology according to EIA 923"},{"name":"active_power_limits","needs_conversion":true,"data_type":"MinMax","null_value":"(min=0.0, max=0.0)","validation_action":"warn","valid_range":{"max":null,"min":0}},{"name":"reactive_power_limits","needs_conversion":true,"data_type":"Union{Nothing, MinMax}","null_value":"nothing","validation_action":"warn"},{"name":"ramp_limits","needs_conversion":true,"data_type":"Union{Nothing, UpDown}","null_value":"nothing","validation_action":"error","comment":"ramp up and ramp down limits in MW (in component base per unit) per minute","valid_range":{"max":null,"min":0}},{"name":"time_limits","data_type":"Union{Nothing, UpDown}","null_value":"nothing","validation_action":"error","comment":"Minimum up and Minimum down time limits in hours","valid_range":{"max":null,"min":0}},{"name":"base_power","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"Base power of the unit in MVA","valid_range":{"max":null,"min":0}},{"name":"operation_cost","default":"TwoPartCost(0.0, 0.0)","data_type":"OperationalCost","null_value":"TwoPartCost(nothing)","comment":"Operation Cost of Generation [`OperationalCost`](@ref)"},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"dynamic_injector","default":"nothing","data_type":"Union{Nothing, DynamicInjection}","exclude_setter":true,"null_value":"nothing","comment":"corresponding dynamic injection device"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"struct_name":"HydroDispatch","supertype":"HydroGen"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"bus","data_type":"ACBus","null_value":"ACBus(nothing)"},{"name":"active_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"reactive_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"rating","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"Thermal limited MVA Power Output of the unit. <= Capacity","valid_range":{"max":null,"min":0}},{"name":"base_power","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"Base power of the unit in MVA","valid_range":{"max":null,"min":0}},{"name":"prime_mover_type","data_type":"PrimeMovers","null_value":"PrimeMovers.HY","comment":"Prime mover technology according to EIA 923"},{"name":"active_power_limits","needs_conversion":true,"data_type":"MinMax","null_value":"(min=0.0, max=0.0)","validation_action":"warn","valid_range":{"max":null,"min":0}},{"name":"reactive_power_limits","needs_conversion":true,"data_type":"Union{Nothing, MinMax}","null_value":"nothing","validation_action":"warn"},{"name":"ramp_limits","needs_conversion":true,"data_type":"Union{Nothing, UpDown}","null_value":"nothing","validation_action":"error","comment":"ramp up and ramp down limits in MW (in component base per unit) per minute","valid_range":{"max":null,"min":0}},{"name":"time_limits","data_type":"Union{Nothing, UpDown}","null_value":"nothing","validation_action":"error","comment":"Minimum up and Minimum down time limits in hours","valid_range":{"max":null,"min":0}},{"name":"rating_pump","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"Thermal limited MVA Power Withdrawl of the pump. <= Capacity","valid_range":{"max":null,"min":0}},{"name":"active_power_limits_pump","needs_conversion":true,"data_type":"MinMax","null_value":"(min=0.0, max=0.0)"},{"name":"reactive_power_limits_pump","needs_conversion":true,"data_type":"Union{Nothing, MinMax}","null_value":"nothing","validation_action":"warn"},{"name":"ramp_limits_pump","needs_conversion":true,"data_type":"Union{Nothing, UpDown}","null_value":"nothing","validation_action":"error","comment":"ramp up and ramp down limits in MW (in component base per unit) per minute of pump","valid_range":{"max":null,"min":0}},{"name":"time_limits_pump","data_type":"Union{Nothing, UpDown}","null_value":"nothing","validation_action":"error","comment":"Minimum up and Minimum down time limits of pump in hours","valid_range":{"max":null,"min":0}},{"name":"storage_capacity","needs_conversion":true,"data_type":"UpDown","null_value":"(up=0.0, down=0.0)","validation_action":"error","comment":"Maximum storage capacity in the upper and lower reservoirs (units can be p.u-hr or m^3).","valid_range":{"max":null,"min":0}},{"name":"inflow","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"Baseline inflow into the upper reservoir (units can be p.u. or m^3/hr)","valid_range":{"max":null,"min":0}},{"name":"outflow","data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"Baseline outflow from the lower reservoir (units can be p.u. or m^3/hr)","valid_range":{"max":null,"min":0}},{"name":"initial_storage","needs_conversion":true,"data_type":"UpDown","null_value":"(up=0.0, down=0.0)","validation_action":"error","comment":"Initial storage capacity in the upper and lower reservoir (units can be p.u-hr or m^3).","valid_range":{"max":null,"min":0}},{"name":"storage_target","default":"(up=1.0, down=1.0)","data_type":"UpDown","null_value":"(up=0.0, down=0.0)","comment":"Storage target of upper reservoir at the end of simulation as ratio of storage capacity."},{"name":"operation_cost","default":"TwoPartCost(0.0, 0.0)","data_type":"OperationalCost","null_value":"TwoPartCost(nothing)","comment":"Operation Cost of Generation [`OperationalCost`](@ref)"},{"name":"pump_efficiency","default":"1.0","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"Efficiency of pump","valid_range":{"max":1,"min":0}},{"name":"conversion_factor","default":"1.0","data_type":"Float64","null_value":"0.0","comment":"Conversion factor from flow/volume to energy: m^3 -> p.u-hr."},{"name":"time_at_status","default":"INFINITE_TIME","data_type":"Float64","null_value":"INFINITE_TIME"},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"dynamic_injector","default":"nothing","data_type":"Union{Nothing, DynamicInjection}","exclude_setter":true,"null_value":"nothing","comment":"corresponding dynamic injection device"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"struct_name":"HydroPumpedStorage","supertype":"HydroGen"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"bus","data_type":"ACBus","null_value":"ACBus(nothing)"},{"name":"active_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"reactive_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"rating","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"Thermal limited MVA Power Output of the unit. <= Capacity","valid_range":{"max":null,"min":0}},{"name":"prime_mover_type","data_type":"PrimeMovers","null_value":"PrimeMovers.OT","comment":"Prime mover technology according to EIA 923"},{"name":"reactive_power_limits","needs_conversion":true,"data_type":"Union{Nothing, MinMax}","null_value":"nothing"},{"name":"power_factor","data_type":"Float64","null_value":"1.0","validation_action":"error","valid_range":{"max":1,"min":0}},{"name":"operation_cost","data_type":"TwoPartCost","null_value":"TwoPartCost(nothing)","comment":"Operation Cost of Generation [`TwoPartCost`](@ref)"},{"name":"base_power","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"Base power of the unit in MVA","valid_range":{"max":null,"min":0}},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"dynamic_injector","default":"nothing","data_type":"Union{Nothing, DynamicInjection}","exclude_setter":true,"null_value":"nothing","comment":"corresponding dynamic injection device"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"struct_name":"RenewableDispatch","supertype":"RenewableGen"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"bus","data_type":"ACBus","null_value":"ACBus(nothing)"},{"name":"active_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"reactive_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"rating","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"Thermal limited MVA Power Output of the unit. <= Capacity","valid_range":{"max":null,"min":0}},{"name":"prime_mover_type","data_type":"PrimeMovers","null_value":"PrimeMovers.OT","comment":"Prime mover technology according to EIA 923"},{"name":"power_factor","data_type":"Float64","null_value":"1.0","validation_action":"error","valid_range":{"max":1,"min":0}},{"name":"base_power","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"Base power of the unit in MVA","valid_range":{"max":null,"min":0}},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"dynamic_injector","default":"nothing","data_type":"Union{Nothing, DynamicInjection}","exclude_setter":true,"null_value":"nothing","comment":"corresponding dynamic injection device"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Data Structure for fixed renewable generation technologies.","struct_name":"RenewableFix","supertype":"RenewableGen"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"status","data_type":"Bool","null_value":"false"},{"name":"bus","data_type":"ACBus","null_value":"ACBus(nothing)"},{"name":"active_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"warn","valid_range":"active_power_limits"},{"name":"reactive_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"warn","valid_range":"reactive_power_limits"},{"name":"rating","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"Thermal limited MVA Power Output of the unit. <= Capacity","valid_range":{"max":null,"min":0}},{"name":"active_power_limits","needs_conversion":true,"data_type":"MinMax","null_value":"(min=0.0, max=0.0)","validation_action":"warn","valid_range":{"max":null,"min":0}},{"name":"reactive_power_limits","needs_conversion":true,"data_type":"Union{Nothing, MinMax}","null_value":"nothing"},{"name":"ramp_limits","needs_conversion":true,"data_type":"Union{Nothing, UpDown}","null_value":"nothing","validation_action":"error","comment":"ramp up and ramp down limits in MW (in component base per unit) per minute","valid_range":{"max":null,"min":0}},{"name":"operation_cost","data_type":"OperationalCost","null_value":"ThreePartCost(nothing)"},{"name":"base_power","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"Base power of the unit in MVA","valid_range":{"max":null,"min":0}},{"name":"time_limits","default":"nothing","data_type":"Union{Nothing, UpDown}","null_value":"nothing","validation_action":"error","comment":"Minimum up and Minimum down time limits in hours","valid_range":{"max":null,"min":0}},{"name":"must_run","default":"false","data_type":"Bool","null_value":"false"},{"name":"prime_mover_type","default":"PrimeMovers.OT","data_type":"PrimeMovers","null_value":"PrimeMovers.OT","comment":"Prime mover technology according to EIA 923"},{"name":"fuel","default":"ThermalFuels.OTHER","data_type":"ThermalFuels","null_value":"ThermalFuels.OTHER","comment":"Prime mover fuel according to EIA 923"},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"time_at_status","default":"INFINITE_TIME","data_type":"Float64","null_value":"INFINITE_TIME"},{"name":"dynamic_injector","default":"nothing","data_type":"Union{Nothing, DynamicInjection}","exclude_setter":true,"null_value":"nothing","comment":"corresponding dynamic injection device"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Data Structure for thermal generation technologies.","struct_name":"ThermalStandard","supertype":"ThermalGen"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"status","data_type":"Bool","null_value":"false"},{"name":"bus","data_type":"ACBus","null_value":"ACBus(nothing)"},{"name":"active_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"warn","valid_range":"active_power_limits"},{"name":"reactive_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"warn","valid_range":"reactive_power_limits"},{"name":"rating","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"Thermal limited MVA Power Output of the unit. <= Capacity","valid_range":{"max":null,"min":0}},{"name":"prime_mover_type","data_type":"PrimeMovers","null_value":"PrimeMovers.OT","comment":"Prime mover technology according to EIA 923"},{"name":"fuel","data_type":"ThermalFuels","null_value":"ThermalFuels.OTHER","comment":"Prime mover fuel according to EIA 923"},{"name":"active_power_limits","needs_conversion":true,"data_type":"MinMax","null_value":"(min=0.0, max=0.0)"},{"name":"reactive_power_limits","needs_conversion":true,"data_type":"Union{Nothing, MinMax}","null_value":"nothing"},{"name":"ramp_limits","needs_conversion":true,"data_type":"Union{Nothing, UpDown}","null_value":"nothing","validation_action":"error","valid_range":{"max":null,"min":0}},{"name":"power_trajectory","needs_conversion":true,"data_type":"Union{Nothing, StartUpShutDown}","null_value":"nothing","validation_action":"error","comment":"Power trajectory the unit will take during the start-up and shut-down ramp process","valid_range":{"max":null,"min":0}},{"name":"time_limits","data_type":"Union{Nothing, UpDown}","null_value":"nothing","validation_action":"error","comment":"Minimum up and Minimum down time limits in hours","valid_range":{"max":null,"min":0}},{"name":"start_time_limits","data_type":"Union{Nothing, NamedTuple{(:hot, :warm, :cold), Tuple{Float64, Float64, Float64}}}","null_value":"nothing","comment":" Time limits for start-up based on turbine temperature in hours"},{"name":"start_types","data_type":"Int","null_value":"1","validation_action":"error","comment":" Number of start-up based on turbine temperature","valid_range":{"max":3,"min":1}},{"name":"operation_cost","data_type":"OperationalCost","null_value":"MultiStartCost(nothing)"},{"name":"base_power","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"Base power of the unit in MVA","valid_range":{"max":null,"min":0}},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"time_at_status","default":"INFINITE_TIME","data_type":"Float64","null_value":"INFINITE_TIME"},{"name":"must_run","default":"false","data_type":"Bool","null_value":"false"},{"name":"dynamic_injector","default":"nothing","data_type":"Union{Nothing, DynamicInjection}","exclude_setter":true,"null_value":"nothing","comment":"corresponding dynamic injection device"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Data Structure for thermal generation technologies.","struct_name":"ThermalMultiStart","supertype":"ThermalGen"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"bus","data_type":"ACBus","null_value":"ACBus(nothing)"},{"name":"prime_mover_type","data_type":"PrimeMovers","null_value":"PrimeMovers.BA","comment":"Prime mover technology according to EIA 923"},{"name":"initial_energy","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"State of Charge of the Battery p.u.-hr","valid_range":{"max":null,"min":0}},{"name":"state_of_charge_limits","needs_conversion":true,"data_type":"MinMax","null_value":"(min=0.0, max=0.0)","validation_action":"error","comment":"Maximum and Minimum storage capacity in p.u.-hr","valid_range":{"max":null,"min":0}},{"name":"rating","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"active_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"input_active_power_limits","needs_conversion":true,"data_type":"MinMax","null_value":"(min=0.0, max=0.0)","validation_action":"error","valid_range":{"max":null,"min":0}},{"name":"output_active_power_limits","needs_conversion":true,"data_type":"MinMax","null_value":"(min=0.0, max=0.0)","validation_action":"error","valid_range":{"max":null,"min":0}},{"name":"efficiency","data_type":"NamedTuple{(:in, :out), Tuple{Float64, Float64}}","null_value":"(in=0.0, out=0.0)","validation_action":"warn","valid_range":{"max":1,"min":0}},{"name":"reactive_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"warn","valid_range":"reactive_power_limits"},{"name":"reactive_power_limits","needs_conversion":true,"data_type":"Union{Nothing, MinMax}","null_value":"(min=0.0, max=0.0)"},{"name":"base_power","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"Base power of the unit in MVA","valid_range":{"max":null,"min":0}},{"name":"operation_cost","default":"StorageManagementCost()","data_type":"Union{StorageManagementCost, MarketBidCost}","null_value":"StorageManagementCost()"},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"dynamic_injector","default":"nothing","data_type":"Union{Nothing, DynamicInjection}","exclude_setter":true,"null_value":"nothing","comment":"corresponding dynamic injection device"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Data structure for a generic battery","struct_name":"GenericBattery","supertype":"Storage"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"bus","data_type":"ACBus","null_value":"ACBus(nothing)"},{"name":"prime_mover_type","data_type":"PrimeMovers","null_value":"PrimeMovers.BA","comment":"Prime mover technology according to EIA 923"},{"name":"initial_energy","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"State of Charge of the Battery p.u.-hr","valid_range":{"max":null,"min":0}},{"name":"state_of_charge_limits","needs_conversion":true,"data_type":"MinMax","null_value":"(min=0.0, max=0.0)","validation_action":"error","comment":"Maximum and Minimum storage capacity in p.u.-hr","valid_range":{"max":null,"min":0}},{"name":"rating","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"active_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"input_active_power_limits","needs_conversion":true,"data_type":"MinMax","null_value":"(min=0.0, max=0.0)","validation_action":"error","valid_range":{"max":null,"min":0}},{"name":"output_active_power_limits","needs_conversion":true,"data_type":"MinMax","null_value":"(min=0.0, max=0.0)","validation_action":"error","valid_range":{"max":null,"min":0}},{"name":"efficiency","data_type":"NamedTuple{(:in, :out), Tuple{Float64, Float64}}","null_value":"(in=0.0, out=0.0)","validation_action":"warn","valid_range":{"max":1,"min":0}},{"name":"reactive_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"warn","valid_range":"reactive_power_limits"},{"name":"reactive_power_limits","needs_conversion":true,"data_type":"Union{Nothing, MinMax}","null_value":"(min=0.0, max=0.0)"},{"name":"base_power","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"Base power of the unit in MVA","valid_range":{"max":null,"min":0}},{"name":"operation_cost","default":"Union{StorageManagementCost, MarketBidCost}","data_type":"StorageManagementCost","null_value":"StorageManagementCost()"},{"name":"storage_target","default":"0.0","data_type":"Float64","null_value":"0.0","comment":"Storage target at the end of simulation as ratio of storage capacity."},{"name":"cycle_limits","default":"1e4","data_type":"Int","null_value":"0","comment":"Storage Maximum number of cycles per year"},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"dynamic_injector","default":"nothing","data_type":"Union{Nothing, DynamicInjection}","exclude_setter":true,"null_value":"nothing","comment":"corresponding dynamic injection device"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Data structure for a battery compatible with energy management formulations.","struct_name":"BatteryEMS","supertype":"Storage"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"time_frame","data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"the saturation time_frame in minutes to provide reserve contribution","valid_range":{"max":null,"min":0}},{"name":"requirement","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"the static value of required reserves in system p.u.","valid_range":{"max":null,"min":0}},{"name":"sustained_time","default":"3600.0","data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"the time in secounds reserve contribution must sustained at a specified level","valid_range":{"max":null,"min":0}},{"name":"max_output_fraction","default":"1.0","data_type":"Float64","null_value":"1.0","validation_action":"error","comment":"the maximum fraction of the device's output that can be assigned to the service","valid_range":{"max":1,"min":0}},{"name":"max_participation_factor","default":"1.0","data_type":"Float64","null_value":"1.0","validation_action":"error","comment":"the maximum limit of reserve contribution per device","valid_range":{"max":1,"min":0}},{"name":"deployed_fraction","default":"0.0","data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"Fraction of ancillary services participation deployed from the assignment","valid_range":{"max":1,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Data Structure for a proportional reserve product for system simulations.","parametric":"ReserveDirection","struct_name":"StaticReserve","supertype":"Reserve{T}"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"time_frame","data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"the saturation time_frame in minutes to provide reserve contribution","valid_range":{"max":null,"min":0}},{"name":"requirement","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"the static value of required reserves in system p.u.","valid_range":{"max":null,"min":0}},{"name":"sustained_time","default":"3600.0","data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"the time in secounds reserve contribution must sustained at a specified level","valid_range":{"max":null,"min":0}},{"name":"max_output_fraction","default":"1.0","data_type":"Float64","null_value":"1.0","validation_action":"error","comment":"the maximum fraction of the device's output that can be assigned to the service","valid_range":{"max":1,"min":0}},{"name":"max_participation_factor","default":"1.0","data_type":"Float64","null_value":"1.0","validation_action":"error","comment":"the maximum limit of reserve contribution per device","valid_range":{"max":1,"min":0}},{"name":"deployed_fraction","default":"0.0","data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"Fraction of ancillary services participation deployed from the assignment","valid_range":{"max":1,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Data Structure for a non-spinning reserve product for system simulations.","struct_name":"StaticReserveNonSpinning","supertype":"ReserveNonSpinning"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"requirement","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"the static value of required reserves in system p.u.","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"contributing_services","default":"Vector{Service}()","data_type":"Vector{Service}","exclude_setter":true,"null_value":"Vector{Service}()","comment":"Services that contribute for this requirement constraint"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Data Structure for a group reserve product for system simulations.","parametric":"ReserveDirection","struct_name":"StaticReserveGroup","supertype":"Service"},{"fields":[{"name":"variable","data_type":"Union{Nothing, IS.TimeSeriesKey}","null_value":"nothing","comment":"Variable Cost TimeSeriesKey"},{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"time_frame","data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"the saturation time_frame in minutes to provide reserve contribution","valid_range":{"max":null,"min":0}},{"name":"sustained_time","default":"3600.0","data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"the time in secounds reserve contribution must sustained at a specified level","valid_range":{"max":null,"min":0}},{"name":"max_participation_factor","default":"1.0","data_type":"Float64","null_value":"1.0","validation_action":"error","comment":"the maximum limit of reserve contribution per device","valid_range":{"max":1,"min":0}},{"name":"deployed_fraction","default":"0.0","data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"Fraction of ancillary services participation deployed from the assignment","valid_range":{"max":1,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Data Structure for a operating reserve with demand curve product for system simulations.","parametric":"ReserveDirection","struct_name":"ReserveDemandCurve","supertype":"Reserve{T}"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"time_frame","data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"the saturation time_frame in minutes to provide reserve contribution","valid_range":{"max":null,"min":0}},{"name":"requirement","data_type":"Float64","null_value":"0.0","comment":"the required quantity of the product should be scaled by a TimeSeriesData"},{"name":"sustained_time","default":"3600.0","data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"the time in secounds reserve contribution must sustained at a specified level","valid_range":{"max":null,"min":0}},{"name":"max_output_fraction","default":"1.0","data_type":"Float64","null_value":"1.0","validation_action":"error","comment":"the maximum fraction of the device's output that can be assigned to the service","valid_range":{"max":1,"min":0}},{"name":"max_participation_factor","default":"1.0","data_type":"Float64","null_value":"1.0","validation_action":"error","comment":"the maximum limit of reserve contribution per device","valid_range":{"max":1,"min":0}},{"name":"deployed_fraction","default":"0.0","data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"Fraction of ancillary services participation deployed from the assignment","valid_range":{"max":1,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Data Structure for the procurement products for system simulations.","parametric":"ReserveDirection","struct_name":"VariableReserve","supertype":"Reserve{T}"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"time_frame","data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"the saturation time_frame in minutes to provide reserve contribution","valid_range":{"max":null,"min":0}},{"name":"requirement","needs_conversion":true,"data_type":"Float64","null_value":"0.0","comment":"the required quantity of the product should be scaled by a TimeSeriesData"},{"name":"sustained_time","default":"14400.0","data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"the time in secounds reserve contribution must sustained at a specified level","valid_range":{"max":null,"min":0}},{"name":"max_output_fraction","default":"1.0","data_type":"Float64","null_value":"1.0","validation_action":"error","comment":"the maximum fraction of the device's output that can be assigned to the service","valid_range":{"max":1,"min":0}},{"name":"max_participation_factor","default":"1.0","data_type":"Float64","null_value":"1.0","validation_action":"error","comment":"the maximum limit of reserve contribution per device","valid_range":{"max":1,"min":0}},{"name":"deployed_fraction","default":"0.0","data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"Fraction of ancillary services participation deployed from the assignment","valid_range":{"max":1,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Data Structure for the procurement products for system simulations.","struct_name":"VariableReserveNonSpinning","supertype":"ReserveNonSpinning"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"bias","data_type":"Float64","null_value":"0.0"},{"name":"K_p","data_type":"Float64","null_value":"0.0","comment":"PID Proportional Constant"},{"name":"K_i","data_type":"Float64","null_value":"0.0","comment":"PID Integral Constant"},{"name":"K_d","data_type":"Float64","null_value":"0.0","comment":"PID Derrivative Constant"},{"name":"delta_t","data_type":"Float64","null_value":"0.0","comment":"PID Discretization period [Seconds]"},{"name":"area","default":"nothing","data_type":"Union{Nothing, Area}","null_value":"Area(nothing)","comment":"the area controlled by the AGC"},{"name":"initial_ace","default":"0.0","data_type":"Float64","null_value":"0.0","comment":"PID Discretization period [Seconds]"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"struct_name":"AGC","supertype":"Service"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"requirement","data_type":"Float64","null_value":"0.0"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"struct_name":"Transfer","supertype":"Service"},{"fields":[{"name":"Vf","data_type":"Float64","null_value":0,"comment":"Fixed voltage field applied to the rotor winding","valid_range":{"max":null,"min":0}},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"Fixed AVR has no states","internal_default":"Vector{Symbol}()"},{"name":"n_states","data_type":"Int","exclude_setter":true,"null_value":0,"comment":"Fixed AVR has no states","internal_default":0},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"Fixed AVR has no states","internal_default":"Vector{StateTypes}()"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of a AVR that returns a fixed voltage to the rotor winding","struct_name":"AVRFixed","supertype":"AVR"},{"fields":[{"name":"Kv","data_type":"Float64","null_value":0,"comment":"Proportional Gain","valid_range":{"max":null,"min":0}},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tVf: field voltage","internal_default":"[:Vf]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"Fixed AVR has 1 states","internal_default":1},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"Simple AVR has 1 differential states","internal_default":"[StateTypes.Differential]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of a simple proportional AVR in the derivative of EMF\ni.e. an integrator controller on EMF","struct_name":"AVRSimple","supertype":"AVR"},{"fields":[{"name":"Ta_Tb","data_type":"Float64","null_value":0,"comment":"Ratio of lead and lag time constants","valid_range":{"max":null,"min":0}},{"name":"Tb","data_type":"Float64","null_value":0,"comment":"Lag time constant","valid_range":{"max":null,"min":"eps()"}},{"name":"K","data_type":"Float64","null_value":0,"comment":"Gain","valid_range":{"max":null,"min":0}},{"name":"Te","data_type":"Float64","null_value":0,"comment":"Field circuit time constant in s","valid_range":{"max":null,"min":0}},{"name":"V_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Field voltage limits"},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\tVf: Voltage field,\tVr: Lead-lag state","internal_default":"[:Vf, :Vr]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"SEXS has 2 states","internal_default":2},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"SEXS has 2 differential states","internal_default":"[StateTypes.Differential, StateTypes.Differential]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of Simplified Excitation System Model - SEXS in PSSE","struct_name":"SEXS","supertype":"AVR"},{"fields":[{"name":"Tr","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Voltage Measurement Time Constant in s","valid_range":{"max":0.5,"min":0}},{"name":"Ka","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Amplifier Gain","valid_range":{"max":500,"min":10}},{"name":"Ta","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Amplifier Time Constant in s","valid_range":{"max":1,"min":0}},{"name":"Tb","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator input Time Constant in s","valid_range":{"max":null,"min":0}},{"name":"Tc","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator input Time Constant in s","valid_range":{"max":null,"min":0}},{"name":"Vr_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Voltage regulator limits (regulator output) (Vi_min, Vi_max)"},{"name":"Ke","data_type":"Float64","null_value":0,"comment":"Exciter constant related to self-excited field","valid_range":{"max":null,"min":0}},{"name":"Te","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Exciter time constant, integration rate associated with exciter control","valid_range":{"max":1,"min":"eps()"}},{"name":"Kf","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Excitation control system stabilizer gain","valid_range":{"max":0.3,"min":"eps()"}},{"name":"Tf","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Excitation control system stabilizer time constant","valid_range":{"max":null,"min":"eps()"}},{"name":"switch","data_type":"Int","null_value":0,"validation_action":"error","comment":"Switch","valid_range":{"max":1,"min":0}},{"name":"E_sat","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Exciter output voltage for saturation factor: (E1, E2)"},{"name":"Se","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Exciter saturation factor at exciter output voltage: (Se(E1), Se(E2))"},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"saturation_coeffs","default":"PowerSystems.get_avr_saturation(E_sat, Se)","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Coefficients (A,B) of the function: Se(V) = B(V - A)^2/V"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tVt: Terminal Voltage,\n\tVr1: input lead lag,\n\tVr2: Regulator Output,\n\tVf: Exciter Output, \n\tVr3: Rate feedback integrator","internal_default":"[:Vt, :Vr1, :Vr2, :Vf, :Vr3]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"The ESDC1A has 5 states","internal_default":5},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"ESDC1A has 5 differential states","internal_default":"[StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Differential, StateTypes.Differential]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Self-excited shunt fields with the voltage regulator operating in a mode commonly termed buck-boost. \nParameters of IEEE Std 421.5 Type DC1A Excitacion System. This model corresponds to ESDC1A in PSSE and PSLF","struct_name":"ESDC1A","supertype":"AVR"},{"fields":[{"name":"Tr","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Voltage Measurement Time Constant in s","valid_range":{"max":0.5,"min":0}},{"name":"Ka","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Amplifier Gain","valid_range":{"max":500,"min":10}},{"name":"Ta","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Amplifier Time Constant in s","valid_range":{"max":1,"min":0}},{"name":"Tb","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator input Time Constant in s","valid_range":{"max":null,"min":0}},{"name":"Tc","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator input Time Constant in s","valid_range":{"max":null,"min":0}},{"name":"Vr_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Voltage regulator limits (regulator output) (Vi_min, Vi_max)"},{"name":"Ke","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Exciter constant related to self-excited field","valid_range":{"max":1,"min":-1}},{"name":"Te","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Exciter time constant, integration rate associated with exciter control","valid_range":{"max":2,"min":"eps()"}},{"name":"Kf","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Excitation control system stabilizer gain","valid_range":{"max":0.3,"min":0}},{"name":"Tf","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Excitation control system stabilizer time constant. Appropiate Data: 5.0 <= Tf/Kf <= 15.0","valid_range":{"max":1.5,"min":"eps()"}},{"name":"switch","data_type":"Int","null_value":0,"validation_action":"error","comment":"Switch","valid_range":{"max":1,"min":0}},{"name":"E_sat","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Exciter output voltage for saturation factor: (E1, E2)"},{"name":"Se","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Exciter saturation factor at exciter output voltage: (Se(E1), Se(E2))"},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"saturation_coeffs","default":"PowerSystems.get_avr_saturation(E_sat, Se)","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Coefficients (A,B) of the function: Se(V) = B(V - A)^2/V"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tVt: Terminal Voltage,\n\tVr1: input lead lag,\n\tVr2: Regulator Output,\n\tVf: Exciter Output, \n\tVr3: Rate feedback integrator","internal_default":"[:Vt, :Vr1, :Vr2, :Vf, :Vr3]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"The ESDC2A has 5 states","internal_default":5},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"ESDC2A has 5 differential states","internal_default":"[StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Differential, StateTypes.Differential]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Is used to represent field-controlled dc commutator exciters with continuously acting voltage regulators having power supplies derived from the generator or auxiliaries bus.\nParameters of IEEE Std 421.5 Type DC2A Excitacion System. This model corresponds to ESDC2A in PSSE and PSLF","struct_name":"ESDC2A","supertype":"AVR"},{"fields":[{"name":"Tr","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Voltage Measurement Time Constant in s","valid_range":{"max":0.5,"min":0}},{"name":"Ka","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Amplifier Gain","valid_range":{"max":500,"min":10}},{"name":"Ta","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Amplifier Time Constant in s","valid_range":{"max":1,"min":0}},{"name":"Vr_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Voltage regulator limits (regulator output) (Vi_min, Vi_max)"},{"name":"Ke","data_type":"Float64","null_value":0,"comment":"Exciter constant related to self-excited field","valid_range":{"max":1,"min":-1}},{"name":"Te","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Exciter time constant, integration rate associated with exciter control","valid_range":{"max":1,"min":"eps()"}},{"name":"Kf","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Excitation control system stabilizer gain","valid_range":{"max":0.3,"min":"eps()"}},{"name":"Tf","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Excitation control system stabilizer time constant. Appropiate Data: 5 <= Tf/Kf <= 15","valid_range":{"max":null,"min":"eps()"}},{"name":"switch","data_type":"Int","null_value":0,"validation_action":"error","comment":"Switch","valid_range":{"max":1,"min":0}},{"name":"E_sat","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Exciter output voltage for saturation factor: (E1, E2)"},{"name":"Se","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Exciter saturation factor at exciter output voltage: (Se(E1), Se(E2))"},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"saturation_coeffs","default":"PowerSystems.get_avr_saturation(E_sat, Se)","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Coefficients (A,B) of the function: Se(V) = B(V - A)^2/V"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tVt: Terminal Voltage,\n\tVr: Regulator Output,\n\tVf: Exciter Output, \n\tVr3: Rate feedback integrator","internal_default":"[:Vt, :Vr1, :Vf, :Vr2]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"The IEEET1 has 4 states","internal_default":4},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"IEEET1 I has 4 differential states","internal_default":"[StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Differential, StateTypes.Differential]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"1968 IEEE type 1 excitation system model","struct_name":"IEEET1","supertype":"AVR"},{"fields":[{"name":"Ka","data_type":"Float64","null_value":0,"comment":"Amplifier Gain","valid_range":{"max":null,"min":0}},{"name":"Ke","data_type":"Float64","null_value":0,"comment":"Field circuit integral deviation","valid_range":{"max":null,"min":0}},{"name":"Kf","data_type":"Float64","null_value":0,"comment":"Stabilizer Gain in s * pu/pu","valid_range":{"max":null,"min":0}},{"name":"Ta","data_type":"Float64","null_value":0,"comment":"Amplifier Time Constant in s","valid_range":{"max":null,"min":0}},{"name":"Te","data_type":"Float64","null_value":0,"comment":"Field Circuit Time Constant in s","valid_range":{"max":null,"min":0}},{"name":"Tf","data_type":"Float64","null_value":0,"comment":"Stabilizer Time Constant in s","valid_range":{"max":null,"min":0}},{"name":"Tr","data_type":"Float64","null_value":0,"comment":"Voltage Measurement Time Constant in s","valid_range":{"max":null,"min":0}},{"name":"Va_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Limits for pi controler `(Va_min, Va_max)`"},{"name":"Ae","data_type":"Float64","null_value":0,"comment":"1st ceiling coefficient","valid_range":{"max":null,"min":0}},{"name":"Be","data_type":"Float64","null_value":0,"comment":"2nd ceiling coefficient","valid_range":{"max":null,"min":0}},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tVf: Voltage field,\n\tVr1: Amplifier State,\n\tVr2: Stabilizing Feedback State,\n\tVm: Measured voltage","internal_default":"[:Vf, :Vr1, :Vr2, :Vm]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"The AVR Type I has 4 states","internal_default":4},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"AVR Type I has 4 differential states","internal_default":"[StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of an Automatic Voltage Regulator Type I - Resembles IEEE Type DC1","struct_name":"AVRTypeI","supertype":"AVR"},{"fields":[{"name":"K0","data_type":"Float64","null_value":0,"comment":"Regulator Gain","valid_range":{"max":null,"min":0}},{"name":"T1","data_type":"Float64","null_value":0,"comment":"First Pole in s","valid_range":{"max":null,"min":0}},{"name":"T2","data_type":"Float64","null_value":0,"comment":"First zero in s","valid_range":{"max":null,"min":0}},{"name":"T3","data_type":"Float64","null_value":0,"comment":"First Pole in s","valid_range":{"max":null,"min":0}},{"name":"T4","data_type":"Float64","null_value":0,"comment":"First zero in s","valid_range":{"max":null,"min":0}},{"name":"Te","data_type":"Float64","null_value":0,"comment":"Field Circuit Time Constant in s","valid_range":{"max":null,"min":0}},{"name":"Tr","data_type":"Float64","null_value":0,"comment":"Voltage Measurement Time Constant in s","valid_range":{"max":null,"min":0}},{"name":"Va_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Limits for pi controler `(Va_min, Va_max)`"},{"name":"Ae","data_type":"Float64","null_value":0,"comment":"1st ceiling coefficient","valid_range":{"max":null,"min":0}},{"name":"Be","data_type":"Float64","null_value":0,"comment":"2nd ceiling coefficient","valid_range":{"max":null,"min":0}},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tVf: Voltage field,\n\tVr1: First Lead-Lag state,\n\tVr2: Second lead-lag state,\n\tVm: Measured voltage","internal_default":"[:Vf, :Vr1, :Vr2, :Vm]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"AVR Type II has 4 states","internal_default":4},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"AVR Type II has 4 differential states","internal_default":"[StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of an Automatic Voltage Regulator Type II - Typical static exciter model","struct_name":"AVRTypeII","supertype":"AVR"},{"fields":[{"name":"Ta_Tb","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Lead input constant ratio","valid_range":{"max":0.3,"min":0.05}},{"name":"Tb","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Lag input constant in s","valid_range":{"max":20,"min":5}},{"name":"K","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator Gain","valid_range":{"max":100,"min":20}},{"name":"Te","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator Time Constant","valid_range":{"max":1,"min":0}},{"name":"Efd_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Field Voltage regulator limits (regulator output) (Efd_min, Efd_max)"},{"name":"switch","data_type":"Int","null_value":0,"validation_action":"error","comment":"Switch","valid_range":{"max":1,"min":0}},{"name":"rc_rfd","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Field current capability. Set = 0 for negative current capability. Typical value 10","valid_range":{"max":10,"min":0}},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tVr1: First integrator,\n\tVr2: Second integrator","internal_default":"[:Vr1, :Vr2]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"SCRX has 2 states","internal_default":2},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"SCRX has 2 differential states","internal_default":"[StateTypes.Differential, StateTypes.Hybrid]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"This exciter is based on an IEEE type SCRX solid state exciter. The output field voltage is varied by a control system to maintain the system voltage at Vref. Please note that this exciter model has no initialization capabilities - this means that it will respond to whatever inputs it receives regardless of the state of the machine model.","struct_name":"SCRX","supertype":"AVR"},{"fields":[{"name":"Tr","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator input filter time constant in s","valid_range":{"max":0.5,"min":0}},{"name":"Tb","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator denominator (lag) time constant in s","valid_range":{"max":20,"min":0}},{"name":"Tc","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator numerator (lead) time constant in s","valid_range":{"max":20,"min":0}},{"name":"Ka","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator output gain","valid_range":{"max":1000,"min":0}},{"name":"Ta","data_type":"Float64","null_value":0,"comment":"Regulator output time constant in s","valid_range":{"max":10,"min":0}},{"name":"Va_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Limits for regulator output `(Va_min, Va_max)`"},{"name":"Te","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Exciter field time constant in s","valid_range":{"max":2,"min":"eps()"}},{"name":"Kf","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Rate feedback excitation system stabilizer gain","valid_range":{"max":0.3,"min":0}},{"name":"Tf","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Rate feedback time constant","valid_range":{"max":1.5,"min":"eps()"}},{"name":"Kc","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Rectifier loading factor proportional to commutating reactance","valid_range":{"max":1,"min":0}},{"name":"Kd","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Demagnetizing factor, function of exciter alternator reactances","valid_range":{"max":1,"min":0}},{"name":"Ke","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Exciter field proportional constant","valid_range":{"max":1,"min":0}},{"name":"E_sat","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Exciter output voltage for saturation factor: (E1, E2)"},{"name":"Se","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Exciter saturation factor at exciter output voltage: (Se(E1), Se(E2))"},{"name":"Vr_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Limits for exciter field voltage: `(Vr_min, Vr_max)`"},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"saturation_coeffs","default":"PowerSystems.get_avr_saturation(E_sat, Se)","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Coefficients (A,B) of the function: Se(x) = B(x - A)^2/x"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tVm: Sensed terminal voltage,\n\tVr1: Lead-lag state,\n\tVr2: Regulator output state,\n\tVe: Integrator output state,\n\tVr3: Feedback output state","internal_default":"[:Vm, :Vr1, :Vr2, :Ve, :Vr3]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"ESAC1A has 5 states","internal_default":5},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"ESAC1A has 5 states","internal_default":"[StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Differential, StateTypes.Differential]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"This excitation systems consists of an alternator main exciter feeding its output via non-controlled rectifiers.\nThe exciter does not employ self-excitation, and the voltage regulator power is taken from a source that is not affected by external transients.\nParameters of IEEE Std 421.5 Type AC1A Excitacion System. This model corresponds to ESAC1A in PSSE and PSLF","struct_name":"ESAC1A","supertype":"AVR"},{"fields":[{"name":"Tr","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator input filter time constant in s","valid_range":{"max":0.5,"min":0}},{"name":"Tb","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator denominator (lag) time constant in s","valid_range":{"max":20,"min":0}},{"name":"Tc","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator numerator (lead) time constant in s","valid_range":{"max":20,"min":0}},{"name":"Ka","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator output gain","valid_range":{"max":1000,"min":0}},{"name":"Ta","data_type":"Float64","null_value":0,"comment":"Regulator output time constant in s","valid_range":{"max":10,"min":0}},{"name":"Va_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Limits for regulator output `(Va_min, Va_max)`"},{"name":"Te","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Exciter field time constant in s","valid_range":{"max":2,"min":"eps()"}},{"name":"Kf","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Rate feedback excitation system stabilizer gain","valid_range":{"max":0.3,"min":0}},{"name":"Tf","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Rate feedback time constant","valid_range":{"max":1.5,"min":"eps()"}},{"name":"Kc","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Rectifier loading factor proportional to commutating reactance","valid_range":{"max":1,"min":0}},{"name":"Kd","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Demagnetizing factor, function of exciter alternator reactances","valid_range":{"max":1,"min":0}},{"name":"Ke","data_type":"Float64","null_value":0,"comment":"Exciter field proportional constant","valid_range":{"max":1,"min":0}},{"name":"E_sat","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Exciter output voltage for saturation factor: (E1, E2)"},{"name":"Se","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Exciter saturation factor at exciter output voltage: (Se(E1), Se(E2))"},{"name":"Vr_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Limits for exciter field voltage: `(Vr_min, Vr_max)`"},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"saturation_coeffs","default":"PowerSystems.get_avr_saturation(E_sat, Se)","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Coefficients (A,B) of the function: Se(x) = B(x - A)^2/x"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tVm: Sensed terminal voltage,\n\tVr1: Lead-lag state,\n\tVr2: Regulator output state,\n\tVe: Integrator output state,\n\tVr3: Feedback output state","internal_default":"[:Vm, :Vr1, :Vr2, :Ve, :Vr3]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"EXAC1A has 5 states","internal_default":5},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"EXAC1A has 5 states","internal_default":"[StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Differential, StateTypes.Differential]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Modified ESAC1A. This excitation systems consists of an alternator main exciter feeding its output via non-controlled rectifiers.\nThe exciter does not employ self-excitation, and the voltage regulator power is taken from a source that is not affected by external transients.\nParameters of IEEE Std 421.5 Type AC1A Excitacion System. EXAC1A in PSSE and PSLF","struct_name":"EXAC1A","supertype":"AVR"},{"fields":[{"name":"Tr","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator input filter time constant in s","valid_range":{"max":0.5,"min":0}},{"name":"Tb","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator denominator (lag) time constant in s","valid_range":{"max":20,"min":0}},{"name":"Tc","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator numerator (lead) time constant in s","valid_range":{"max":20,"min":0}},{"name":"Ka","data_type":"Float64","null_value":0,"comment":"Regulator output gain","valid_range":{"max":1000,"min":0}},{"name":"Ta","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator output time constant in s","valid_range":{"max":10,"min":0}},{"name":"Vr_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Limits for regulator output `(Vr_min, Vr_max)`"},{"name":"Te","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Exciter field time constant in s","valid_range":{"max":2,"min":"eps()"}},{"name":"Kf","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Rate feedback excitation system stabilizer gain","valid_range":{"max":0.3,"min":0}},{"name":"Tf","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Rate feedback time constant","valid_range":{"max":1.5,"min":"eps()"}},{"name":"Kc","data_type":"Float64","null_value":0,"comment":"Rectifier loading factor proportional to commutating reactance","valid_range":{"max":1,"min":0}},{"name":"Kd","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Demagnetizing factor, function of exciter alternator reactances","valid_range":{"max":1,"min":0}},{"name":"Ke","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Exciter field proportional constant","valid_range":{"max":1,"min":0}},{"name":"E_sat","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Exciter output voltage for saturation factor: (E1, E2)"},{"name":"Se","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Exciter saturation factor at exciter output voltage: (Se(E1), Se(E2))"},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"saturation_coeffs","default":"PowerSystems.get_avr_saturation(E_sat, Se)","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Coefficients (A,B) of the function: Se(V) = B(V - A)^2/V"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tVm: Sensed terminal voltage,\n\tVr1: Lead-lag state,\n\tVr2: Regulator output state,\n\tVe: Integrator output state,\n\tVr3: Feedback output state","internal_default":"[:Vm, :Vr1, :Vr2, :Ve, :Vr3]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"EXAC1 has 5 states","internal_default":5},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"EXAC1 has 5 states","internal_default":"[StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Differential, StateTypes.Differential]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Modified ESAC1A. This excitation systems consists of an alternator main exciter feeding its output via non-controlled rectifiers.\nThe exciter does not employ self-excitation, and the voltage regulator power is taken from a source that is not affected by external transients.\nParameters of IEEE Std 421.5 Type AC1A. EXAC1 in PSSE and PSLF","struct_name":"EXAC1","supertype":"AVR"},{"fields":[{"name":"Tr","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator input filter time constant in s","valid_range":{"max":0.5,"min":0}},{"name":"Tb","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator denominator (lag) time constant in s","valid_range":{"max":20,"min":0}},{"name":"Tc","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator numerator (lead) time constant in s","valid_range":{"max":20,"min":0}},{"name":"Ka","data_type":"Float64","null_value":0,"comment":"Regulator output gain","valid_range":{"max":1000,"min":0}},{"name":"Ta","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator output time constant in s","valid_range":{"max":10,"min":0}},{"name":"Va_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Limits for regulator output `(Va_min, Va_max)`"},{"name":"Kb","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Second Stage regulator gain","valid_range":{"max":500,"min":"eps()"}},{"name":"Vr_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Limits for exciter field voltage `(Vr_min, Vr_max)`"},{"name":"Te","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Exciter field time constant","valid_range":{"max":2,"min":"eps()"}},{"name":"Kl","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Exciter field current limiter gain","valid_range":{"max":1.1,"min":0}},{"name":"Kh","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Exciter field current regulator feedback gain","valid_range":{"max":1.1,"min":0}},{"name":"Kf","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Rate feedback excitation system stabilizer gain","valid_range":{"max":0.3,"min":0}},{"name":"Tf","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Rate feedback time constant","valid_range":{"max":null,"min":"eps()"}},{"name":"Kc","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Rectifier loading factor proportional to commutating reactance","valid_range":{"max":1,"min":0}},{"name":"Kd","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Demagnetizing factor, function of exciter alternator reactances","valid_range":{"max":1,"min":0}},{"name":"Ke","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Exciter field proportional constant","valid_range":{"max":1,"min":0}},{"name":"V_lr","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Maximum exciter field current","valid_range":{"max":null,"min":0}},{"name":"E_sat","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Exciter output voltage for saturation factor: (E1, E2)"},{"name":"Se","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Exciter saturation factor at exciter output voltage: (Se(E1), Se(E2))"},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"saturation_coeffs","default":"PowerSystems.get_avr_saturation(E_sat, Se)","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Coefficients (A,B) of the function: Se(V) = B(V - A)^2/V"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tVm: Sensed terminal voltage,\n\tVr1: Lead-lag state,\n\tVr2: Regulator output state,\n\tVe: Integrator output state,\n\tVr3: Feedback output state","internal_default":"[:Vm, :Vr1, :Vr2, :Ve, :Vr3]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"EXAC2 has 5 states","internal_default":5},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"EXAC2 has 5 states","internal_default":"[StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Differential, StateTypes.Differential]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Modified AC2. This excitation systems consists of an alternator main exciter feeding its output via non-controlled rectifiers.\nThe exciter does not employ self-excitation, and the voltage regulator power is taken from a source that is not affected by external transients.\nParameters of IEEE Std 421.5 Type AC2A Excitacion System. The alternator main exciter is used, feeding its output via non-controlled rectifiers. The Type AC2C model is similar to that of Type AC1C except for the inclusion of exciter time constant compensation and exciter field current limiting elements. EXAC2 in PSSE and PSLF.","struct_name":"EXAC2","supertype":"AVR"},{"fields":[{"name":"Tr","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator input filter time constant in s","valid_range":{"max":0.5,"min":0}},{"name":"Ka","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator output gain","valid_range":{"max":1000,"min":0}},{"name":"Ta","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator output lag time constant in s","valid_range":{"max":10,"min":0}},{"name":"Tk","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Voltage Regulator lead time constant","valid_range":{"max":10,"min":0}},{"name":"Tb","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator denominator (lag) time constant in s","valid_range":{"max":20,"min":0}},{"name":"Tc","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator numerator (lead) time constant in s","valid_range":{"max":20,"min":0}},{"name":"Va_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Limits for regulator output `(Va_min, Va_max)`"},{"name":"Vr_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Limits for exciter field voltage `(Vr_min, Vr_max)`"},{"name":"Te","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Exciter field time constant","valid_range":{"max":2,"min":"eps()"}},{"name":"VFE_lim","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Exciter field current limiter reference","valid_range":{"max":20,"min":-5}},{"name":"Kh","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Exciter field current regulator feedback gain","valid_range":{"max":100,"min":0}},{"name":"VH_max","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Exciter field current limiter maximum output","valid_range":{"max":100,"min":0}},{"name":"Th","data_type":"Float64","null_value":0,"comment":"Exciter field current limiter denominator (lag) time constant","valid_range":{"max":1,"min":0}},{"name":"Tj","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Exciter field current limiter numerator (lead) time constant","valid_range":{"max":1,"min":0}},{"name":"Kc","data_type":"Float64","null_value":0,"comment":"Rectifier loading factor proportional to commutating reactance","valid_range":{"max":1,"min":0}},{"name":"Kd","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Demagnetizing factor, function of exciter alternator reactances","valid_range":{"max":2,"min":0}},{"name":"Ke","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Exciter field proportional constant","valid_range":{"max":2,"min":0}},{"name":"E_sat","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Exciter output voltage for saturation factor: (E1, E2)"},{"name":"Se","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Exciter saturation factor at exciter output voltage: (Se(E1), Se(E2))"},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"saturation_coeffs","default":"PowerSystems.get_avr_saturation(E_sat, Se)","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Coefficients (A,B) of the function: Se(V) = B(V - A)^2/V"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tVm: Sensed terminal voltage,\n\tVr1: Lead-lag state,\n\tVr2: Regulator output state,\n\tVe: Integrator output state,\n\tVr3: Feedback output state","internal_default":"[:Vm, :Vr1, :Vr2, :Ve, :Vr3]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"ESAC6A has 5 states","internal_default":5},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"ESAC6A has 5 states","internal_default":"[StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Differential, StateTypes.Hybrid]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Modified AC6A. Used to represent field-controlled alternator-rectifier excitation systems with system-supplied electronic voltage regulators. \nParameters of IEEE Std 421.5 Type AC6A Excitacion System. ESAC6A in PSSE and PSLF.","struct_name":"ESAC6A","supertype":"AVR"},{"fields":[{"name":"UEL_flags","data_type":"Int","null_value":1,"validation_action":"warn","comment":"Code input for Underexcitization limiter (UEL) entry. Not supported.","valid_range":{"max":3,"min":1}},{"name":"PSS_flags","data_type":"Int","null_value":1,"comment":"Code input for Power System Stabilizer (PSS) or (VOS) entry.","valid_range":{"max":2,"min":1}},{"name":"Tr","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator input filter time constant in s","valid_range":{"max":0.1,"min":0}},{"name":"Vi_lim","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Voltage error limits (regulator input) (Vi_min, Vi_max)"},{"name":"Tc","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"First regulator denominator (lead) time constant in s","valid_range":{"max":10,"min":0}},{"name":"Tb","data_type":"Float64","null_value":0,"comment":"First regulator denominator (lag) time constant in s","valid_range":{"max":20,"min":0}},{"name":"Tc1","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Second regulator denominator (lead) time constant in s","valid_range":{"max":10,"min":0}},{"name":"Tb1","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Second regulator denominator (lead) time constant in s","valid_range":{"max":20,"min":0}},{"name":"Ka","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Voltage regulator gain","valid_range":{"max":1000,"min":50}},{"name":"Ta","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Voltage regulator time constant in s","valid_range":{"max":0.5,"min":0}},{"name":"Va_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Limits for regulator output `(Va_min, Va_max)`"},{"name":"Vr_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Limits for exciter output `(Vr_min, Vr_max)`"},{"name":"Kc","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Rectifier loading factor proportional to commutating reactance","valid_range":{"max":0.3,"min":0}},{"name":"Kf","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Rate feedback gain","valid_range":{"max":0.3,"min":0}},{"name":"Tf","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Rate feedback time constant in s","valid_range":{"max":1.5,"min":"eps()"}},{"name":"K_lr","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Exciter output current limiter gain","valid_range":{"max":5,"min":0}},{"name":"I_lr","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Exciter output current limit reference","valid_range":{"max":5,"min":0}},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tVm: Sensed terminal voltage,\n\tVr1: First Lead-lag state,\n\tVr2: Second lead-lag state,\n\tVa: Regulator output state,\n\tVr3: Feedback output state","internal_default":"[:Vm, :Vr1, :Vr2, :Va, :Vr3]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"ST1A has 5 states","internal_default":5},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"ST1A has 5 states","internal_default":"[StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Differential]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"This excitation system supplies power through a transformer from the generator terminals and its regulated by a controlled rectifier (via thyristors).\nParameters of IEEE Std 421.5 Type ST1A Excitacion System. ESST1A in PSSE and PSLF","struct_name":"ESST1A","supertype":"AVR"},{"fields":[{"name":"Tr","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator input filter time constant in s","valid_range":{"max":0.5,"min":0}},{"name":"Ka","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Voltage regulator gain","valid_range":{"max":500,"min":1}},{"name":"Ta","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Voltage regulator time constant in s","valid_range":{"max":10,"min":0}},{"name":"Va_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Limits for pi controler `(Vr_min, Vr_max)`"},{"name":"Ta_2","data_type":"Float64","null_value":0,"comment":"Voltage regulator time constant in s","valid_range":{"max":null,"min":0}},{"name":"Ta_3","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Voltage regulator time constant in s","valid_range":{"max":null,"min":0}},{"name":"Ta_4","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Voltage regulator time constant in s","valid_range":{"max":null,"min":0}},{"name":"Vr_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Voltage regulator limits (regulator output) (Vi_min, Vi_max)"},{"name":"Kf","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Rate feedback gain","valid_range":{"max":0.3,"min":0}},{"name":"Tf_1","validation_actions":"error","data_type":"Float64","null_value":0,"comment":"Rate Feedback time constant in s","valid_range":{"max":15,"min":"eps()"}},{"name":"Tf_2","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Rate Feedback time constant in s","valid_range":{"max":5,"min":0}},{"name":"Efd_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Field Voltage regulator limits (regulator output) (Efd_min, Efd_max)"},{"name":"Ke","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Exciter constant","valid_range":{"max":1,"min":0}},{"name":"Te","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Exciter time constant","valid_range":{"max":2,"min":0}},{"name":"E_sat","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Exciter output voltage for saturation factor: (E1, E2)"},{"name":"Se","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Exciter saturation factor at exciter output voltage: (Se(E1), Se(E2))"},{"name":"Kp","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Potential source gain","valid_range":{"max":5,"min":0}},{"name":"Ki","data_type":"Float64","null_value":0,"comment":"current source gain","valid_range":{"max":1.1,"min":0}},{"name":"Kc","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Exciter regulation factor","valid_range":{"max":2,"min":0}},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"saturation_coeffs","default":"PowerSystems.get_avr_saturation(E_sat, Se)","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Coefficients (A,B) of the function: Se(V) = B(V - A)^2/V"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tVm: Sensed terminal voltage,\n\tVr1: First Lead-lag state,\n\tVr2: Second regulator lead-lag state,\n\tVr2: Third regulator lead-lag state \n\tVf: Exciter output \n\tVr3: First feedback integrator,\n\tVr4: second feedback integrator","internal_default":"[:Vm, :Vr1, :Vr2, :Vf, :Vr3, :Vr4]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"EXPIC1 has 6 states","internal_default":6},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"EXPIC has 6 states","internal_default":"[StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Differential, StateTypes.Hybrid]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Generic Proportional/Integral Excitation System","struct_name":"EXPIC1","supertype":"AVR"},{"fields":[{"name":"Tr","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator input filter time constant in s","valid_range":{"max":0.5,"min":0}},{"name":"K_pr","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator propotional gain","valid_range":{"max":75,"min":0}},{"name":"K_ir","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator integral gain","valid_range":{"max":75,"min":0}},{"name":"Vr_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Voltage regulator limits (Vi_min, Vi_max)"},{"name":"Ta","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Voltage regulator time constant in s","valid_range":{"max":1,"min":0}},{"name":"K_pm","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Voltage regulator proportional gain output","valid_range":{"max":1.2,"min":0}},{"name":"K_im","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Voltage regulator integral gain output","valid_range":{"max":18,"min":0}},{"name":"Vm_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Limits for inner loop output `(Vm_min, Vm_max)`"},{"name":"Kg","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Feedback gain constant of the inner loop field regulator","valid_range":{"max":1.1,"min":0}},{"name":"Kp","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Potential circuit (voltage) gain coefficient","valid_range":{"max":10,"min":0}},{"name":"Ki","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Compound circuit (current) gain coefficient","valid_range":{"max":1.1,"min":0}},{"name":"VB_max","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Maximum available exciter voltage","valid_range":{"max":20,"min":1}},{"name":"Kc","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Rectifier loading factor proportional to commutating reactance","valid_range":{"max":1,"min":0}},{"name":"Xl","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Reactance associated with potential source","valid_range":{"max":0.5,"min":0}},{"name":"θp","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Potential circuit phase angle (degrees)","valid_range":{"max":90,"min":-90}},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"θp_rad","default":"θp*π*inv(180)","data_type":"Float64","null_value":0,"comment":"Potential circuit phase angle (radians)"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tVm: Sensed terminal voltage,\n\tVt: Sensed Terminal Voltage,\n\tVr1: Regulator Integrator,\n\tVr2: Regulator Output,\n\tVm: Output integrator","internal_default":"[:Vt, :Vr1, :Vr2, :Vm]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"ST4B has 4 states","internal_default":4},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"ST4B has 4 states","internal_default":"[StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"In these excitation systems, voltage (and also current in compounded systems) is transformed to an appropriate level. Rectifiers, either controlled or non-controlled, provide the necessary direct current for the generator field.\nParameters of IEEE Std 421.5 Type ST4B Excitacion System. ESST4B in PSSE and PSLF","struct_name":"ESST4B","supertype":"AVR"},{"fields":[{"name":"Tr","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Voltage Measurement Time Constant in s","valid_range":{"max":null,"min":0}},{"name":"Vi_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Voltage input limits (Vi_min, Vi_max)"},{"name":"Tc","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Numerator lead-lag (lead) time constant in s","valid_range":{"max":null,"min":0}},{"name":"Tb","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Denominator lead-lag (lag) time constant in s","valid_range":{"max":null,"min":0}},{"name":"Ka","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Amplifier Gain","valid_range":{"max":null,"min":0}},{"name":"Ta","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Amplifier Time Constant in s","valid_range":{"max":null,"min":0}},{"name":"Vr_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Voltage regulator limits (regulator output) (Vr_min, Vr_max)"},{"name":"Kc","data_type":"Float64","null_value":0,"comment":"Current field constant limiter multiplier","valid_range":{"max":null,"min":0}},{"name":"Kf","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Excitation control system stabilizer gain","valid_range":{"max":0.3,"min":"eps()"}},{"name":"Tf","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Excitation control system stabilizer time constant","valid_range":{"max":null,"min":"eps()"}},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tVm: Sensed Terminal Voltage,\n\tVrll: Lead-Lag state,\n\tVr: Regulator Output, \n\tVfb: Feedback state","internal_default":"[:Vm, :Vrll, :Vr, :Vfb]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"The EXST1 has 4 states","internal_default":4},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"IEEE Type ST1 Excitation System (PTI version)","struct_name":"EXST1","supertype":"AVR"},{"fields":[{"name":"Iflim","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"OEL Field current limit","valid_range":{"max":null,"min":0}},{"name":"d","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"OEL parameter d","valid_range":{"max":null,"min":0}},{"name":"f","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"OEL parameter f","valid_range":{"max":null,"min":0}},{"name":"Spar","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"OEL parameter Spar","valid_range":{"max":null,"min":0}},{"name":"K1","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"OEL delay time constant","valid_range":{"max":null,"min":0}},{"name":"K2","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"OEL parameter K2","valid_range":{"max":null,"min":0}},{"name":"Oel_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Oel integrator limits (Oel_min, Oel_max)"},{"name":"G","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"AVR Exciter Gain","valid_range":{"max":null,"min":0}},{"name":"Ta","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Numerator lead-lag (lag) time constant in s","valid_range":{"max":null,"min":0}},{"name":"Tb","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Denominator lead-lag (lag) time constant in s","valid_range":{"max":null,"min":0}},{"name":"Te","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Exciter Time Constant in s","valid_range":{"max":null,"min":0}},{"name":"E_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Voltage regulator limits (regulator output) (E_min, E_max)"},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tVll: Lead-lag internal state,\n\tVex: Exciter Output, \n\toel: OEL integrator state","internal_default":"[:Vll, :Vex, :oel]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"The EX4VSA has 3 states","internal_default":3},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"IEEE Excitation System for Voltage Security Assesment","struct_name":"EX4VSA","supertype":"AVR"},{"fields":[{"name":"R","data_type":"Float64","null_value":0,"comment":"Resistance after EMF in machine per unit","valid_range":{"max":null,"min":0}},{"name":"Xd_p","data_type":"Float64","null_value":0,"comment":"Reactance after EMF in machine per unit","valid_range":{"max":null,"min":0}},{"name":"eq_p","data_type":"Float64","null_value":0,"comment":"Fixed EMF behind the impedance","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"BaseMachine has no states","internal_default":"Vector{Symbol}()"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"BaseMachine has no states","internal_default":0},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of a Classic Machine: GENCLS in PSSE and PSLF","struct_name":"BaseMachine","supertype":"Machine"},{"fields":[{"name":"R","data_type":"Float64","null_value":0,"comment":"Armature resistance","valid_range":{"max":null,"min":0}},{"name":"Td0_p","data_type":"Float64","null_value":0,"comment":"Time constant of transient d-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Td0_pp","data_type":"Float64","null_value":0,"comment":"Time constant of sub-transient d-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Tq0_p","data_type":"Float64","null_value":0,"comment":"Time constant of transient q-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Tq0_pp","data_type":"Float64","null_value":0,"comment":"Time constant of sub-transient q-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Xd","data_type":"Float64","null_value":0,"comment":"Reactance after EMF in d-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xq","data_type":"Float64","null_value":0,"comment":"Reactance after EMF in q-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xd_p","data_type":"Float64","null_value":0,"comment":"Transient reactance after EMF in d-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xq_p","data_type":"Float64","null_value":0,"comment":"Transient reactance after EMF in q-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xd_pp","data_type":"Float64","null_value":0,"comment":"Sub-Transient reactance after EMF in d-axis per unit. Note: Xd_pp = Xq_pp","valid_range":{"max":null,"min":0}},{"name":"Xl","data_type":"Float64","null_value":0,"comment":"Stator leakage reactance","valid_range":{"max":null,"min":0}},{"name":"Se","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Saturation factor at 1 and 1.2 pu flux: S(1.0) = B(|ψ_pp|-A)^2"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"γ_d1","data_type":"Float64","comment":"γ_d1 parameter","internal_default":"(Xd_pp - Xl) / (Xd_p - Xl)"},{"name":"γ_q1","data_type":"Float64","comment":"γ_q1 parameter","internal_default":"(Xd_pp - Xl) / (Xq_p - Xl)"},{"name":"γ_d2","data_type":"Float64","comment":"γ_d2 parameter","internal_default":"(Xd_p - Xd_pp) / (Xd_p - Xl)^2"},{"name":"γ_q2","data_type":"Float64","comment":"γ_q2 parameter","internal_default":"(Xq_p - Xd_pp) / (Xq_p - Xl)^2"},{"name":"γ_qd","data_type":"Float64","comment":"γ_qd parameter","internal_default":"(Xq - Xl) / (Xd - Xl)"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\teq_p: q-axis generator voltage behind the transient reactance,\n\ted_p: d-axis generator voltage behind the transient reactance,\n\tψ_kd: flux linkage in the first equivalent damping circuit in the d-axis,\n\tψ_kq: flux linkage in the first equivalent damping circuit in the d-axis","internal_default":"[:eq_p, :ed_p, :ψ_kd, :ψ_kq]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"RoundRotorMachine has 4 states","internal_default":4},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of 4-states round-rotor synchronous machine with quadratic/exponential saturation:\nIEEE Std 1110 §5.3.2 (Model 2.2). GENROU or GENROE model in PSSE and PSLF.","struct_name":"RoundRotorMachine","supertype":"Machine"},{"fields":[{"name":"R","data_type":"Float64","null_value":0,"comment":"Armature resistance","valid_range":{"max":null,"min":0}},{"name":"Td0_p","data_type":"Float64","null_value":0,"comment":"Time constant of transient d-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Td0_pp","data_type":"Float64","null_value":0,"comment":"Time constant of sub-transient d-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Tq0_pp","data_type":"Float64","null_value":0,"comment":"Time constant of sub-transient q-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Xd","data_type":"Float64","null_value":0,"comment":"Reactance after EMF in d-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xq","data_type":"Float64","null_value":0,"comment":"Reactance after EMF in q-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xd_p","data_type":"Float64","null_value":0,"comment":"Transient reactance after EMF in d-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xd_pp","data_type":"Float64","null_value":0,"comment":"Sub-Transient reactance after EMF in d-axis per unit. Note: Xd_pp = Xq_pp","valid_range":{"max":null,"min":0}},{"name":"Xl","data_type":"Float64","null_value":0,"comment":"Stator leakage reactance","valid_range":{"max":null,"min":0}},{"name":"Se","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Saturation factor at 1 and 1.2 pu flux: Se(eq_p) = B(eq_p-A)^2"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"γ_d1","data_type":"Float64","comment":"γ_d1 parameter","internal_default":"(Xd_pp - Xl) / (Xd_p - Xl)"},{"name":"γ_q1","data_type":"Float64","comment":"γ_q1 parameter","internal_default":"(Xd_p - Xd_pp) / (Xd_p - Xl)"},{"name":"γ_d2","data_type":"Float64","comment":"γ_d2 parameter","internal_default":"(Xd_p - Xd_pp) / (Xd_p - Xl)^2"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\teq_p: q-axis generator voltage behind the transient reactance,\n\tψ_kd: flux linkage in the first equivalent damping circuit in the d-axis,\n\tψq_pp: phasonf of the subtransient flux linkage in the q-axis","internal_default":"[:eq_p, :ψ_kd, :ψq_pp]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"SalientPoleMachine has 3 states","internal_default":3},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of 3-states salient-pole synchronous machine with quadratic/exponential saturation:\nIEEE Std 1110 §5.3.1 (Model 2.1). GENSAL or GENSAE model in PSSE and PSLF.","struct_name":"SalientPoleMachine","supertype":"Machine"},{"fields":[{"name":"R","data_type":"Float64","null_value":0,"comment":"Resistance after EMF in machine per unit","valid_range":{"max":null,"min":0}},{"name":"Xd","data_type":"Float64","null_value":0,"comment":"Reactance after EMF in d-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xq","data_type":"Float64","null_value":0,"comment":"Reactance after EMF in q-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xd_p","data_type":"Float64","null_value":0,"comment":"Transient reactance after EMF in d-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xq_p","data_type":"Float64","null_value":0,"comment":"Transient reactance after EMF in q-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xd_pp","data_type":"Float64","null_value":0,"comment":"Sub-Transient reactance after EMF in d-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xq_pp","data_type":"Float64","null_value":0,"comment":"Sub-Transient reactance after EMF in q-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Td0_p","data_type":"Float64","null_value":0,"comment":"Time constant of transient d-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Tq0_p","data_type":"Float64","null_value":0,"comment":"Time constant of transient q-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Td0_pp","data_type":"Float64","null_value":0,"comment":"Time constant of sub-transient d-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Tq0_pp","data_type":"Float64","null_value":0,"comment":"Time constant of sub-transient q-axis voltage","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tψq: q-axis stator flux,\n\tψd: d-axis stator flux,\n\teq_p: q-axis transient voltage,\n\ted_p: d-axis transient voltage,\n\teq_pp: q-axis subtransient voltage,\n\ted_pp: d-axis subtransient voltage","internal_default":"[:ψq, :ψd, :eq_p, :ed_p, :eq_pp, :ed_pp]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"AndersonFouadMachine has 6 states","internal_default":6},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of 6-states synchronous machine: Anderson-Fouad model","struct_name":"AndersonFouadMachine","supertype":"Machine"},{"fields":[{"name":"R","data_type":"Float64","null_value":0,"comment":"Resistance after EMF in machine per unit","valid_range":{"max":null,"min":0}},{"name":"R_f","data_type":"Float64","null_value":0,"comment":"Field rotor winding resistance in per unit","valid_range":{"max":null,"min":0}},{"name":"R_1d","data_type":"Float64","null_value":0,"comment":" Damping rotor winding resistance on d-axis in per unit. This value is denoted as RD in Machowski.","valid_range":{"max":null,"min":0}},{"name":"R_1q","data_type":"Float64","null_value":0,"comment":"Damping rotor winding resistance on q-axis in per unit. This value is denoted as RQ in Machowski.","valid_range":{"max":null,"min":0}},{"name":"L_d","data_type":"Float64","null_value":1,"comment":"Inductance of fictitious damping that represent the effect of the three-phase stator winding in the d-axis of the rotor, in per unit. This value is denoted as L_ad + L_l in Kundur (and Ld in Machowski).","valid_range":{"max":null,"min":0}},{"name":"L_q","data_type":"Float64","null_value":1,"comment":"Inductance of fictitious damping that represent the effect of the three-phase stator winding in the q-axis of the rotor, in per unit. This value is denoted as L_aq + L_l in Kundur.","valid_range":{"max":null,"min":0}},{"name":"L_ad","data_type":"Float64","null_value":2,"comment":"Mutual inductance between stator winding and rotor field (and damping) winding inductance on d-axis, in per unit","valid_range":{"max":null,"min":0}},{"name":"L_aq","data_type":"Float64","null_value":2,"comment":"Mutual inductance between stator winding and rotor damping winding inductance on q-axis, in per unit","valid_range":{"max":null,"min":0}},{"name":"L_f1d","data_type":"Float64","null_value":1,"comment":"Mutual inductance between rotor field winding and rotor damping winding inductance on d-axis, in per unit","valid_range":{"max":null,"min":0}},{"name":"L_ff","data_type":"Float64","null_value":2,"comment":"Field rotor winding inductance, in per unit","valid_range":{"max":null,"min":0}},{"name":"L_1d","data_type":"Float64","null_value":1,"comment":"Inductance of the d-axis rotor damping circuit, in per unit","valid_range":{"max":null,"min":0}},{"name":"L_1q","data_type":"Float64","null_value":1,"comment":"Inductance of the q-axis rotor damping circuit, in per unit","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"inv_d_fluxlink","data_type":"Array{Float64,2}","comment":"Equations 3.127, 3.130, 3.131 From Kundur","internal_default":"inv([[-L_d L_ad L_ad]; [-L_ad L_ff L_f1d]; [-L_ad L_f1d L_1d]])"},{"name":"inv_q_fluxlink","data_type":"Array{Float64,2}","comment":"Equations 3.128, 3.132 From Kundur","internal_default":"inv([[-L_q L_aq]; [-L_aq L_1q]])"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tψd: d-axis stator flux,\n\tψq: q-axis stator flux,\n\tψf: field rotor flux,\n\tψ1d: d-axis rotor damping flux,\n\tψ1q: q-axis rotor damping flux","internal_default":"[:ψd, :ψq, :ψf, :ψ1d, :ψ1q]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"FullMachine has 5 states","internal_default":5},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameter of a full order flux stator-rotor model without zero sequence flux in the stator.\n The derivative of stator fluxes (ψd and ψq) is NOT neglected. Only one q-axis damping circuit is considered. All parameters are in machine per unit.\n Refer to Chapter 3 of Power System Stability and Control by P. Kundur or Chapter 11 of Power System Dynamics: Stability and Control, by J. Machowski, J. Bialek and J. Bumby, for more details.\n Note that the models are somewhat different (but equivalent) due to the different Park Transformation used in both books.","struct_name":"FullMachine","supertype":"Machine"},{"fields":[{"name":"R","data_type":"Float64","null_value":0,"comment":"Resistance after EMF in machine per unit","valid_range":{"max":null,"min":0}},{"name":"Xd","data_type":"Float64","null_value":0,"comment":"Reactance after EMF in d-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xq","data_type":"Float64","null_value":0,"comment":"Reactance after EMF in q-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xd_p","data_type":"Float64","null_value":0,"comment":"Transient reactance after EMF in d-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xq_p","data_type":"Float64","null_value":0,"comment":"Transient reactance after EMF in q-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xd_pp","data_type":"Float64","null_value":0,"comment":"Sub-Transient reactance after EMF in d-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xq_pp","data_type":"Float64","null_value":0,"comment":"Sub-Transient reactance after EMF in q-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xl","data_type":"Float64","null_value":0,"comment":"Stator Leakage Reactance","valid_range":{"max":null,"min":0}},{"name":"Td0_p","data_type":"Float64","null_value":0,"comment":"Time constant of transient d-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Tq0_p","data_type":"Float64","null_value":0,"comment":"Time constant of transient q-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Td0_pp","data_type":"Float64","null_value":0,"comment":"Time constant of sub-transient d-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Tq0_pp","data_type":"Float64","null_value":0,"comment":"Time constant of sub-transient q-axis voltage","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"γ_d1","data_type":"Float64","comment":"","internal_default":"(Xd_pp-Xl)/(Xd_p-Xl)"},{"name":"γ_q1","data_type":"Float64","comment":"","internal_default":"(Xq_pp-Xl)/(Xq_p-Xl)"},{"name":"γ_d2","data_type":"Float64","comment":"","internal_default":"(Xd_p - Xd_pp) / (Xd_p - Xl)^2"},{"name":"γ_q2","data_type":"Float64","comment":"","internal_default":"(Xq_p - Xq_pp) / (Xq_p - Xl)^2"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tψq: q-axis stator flux,\n\tψd: d-axis stator flux,\n\teq_p: q-axis transient voltage,\n\ted_p: d-axis transient voltage\n\tψd_pp: subtransient flux linkage in the d-axis\n\tψq_pp: subtransient flux linkage in the q-axis","internal_default":"[:ψq, :ψd, :eq_p, :ed_p, :ψd_pp, :ψq_pp]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"SauerPaiMachine has 6 states","internal_default":6},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of synchronous machine: Sauer Pai model","struct_name":"SauerPaiMachine","supertype":"Machine"},{"fields":[{"name":"R","data_type":"Float64","null_value":0,"comment":"Resistance after EMF in machine per unit","valid_range":{"max":null,"min":0}},{"name":"Xd","data_type":"Float64","null_value":0,"comment":"Reactance after EMF in d-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xq","data_type":"Float64","null_value":0,"comment":"Reactance after EMF in q-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xd_p","data_type":"Float64","null_value":0,"comment":"Transient reactance after EMF in d-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xq_p","data_type":"Float64","null_value":0,"comment":"Transient reactance after EMF in q-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xd_pp","data_type":"Float64","null_value":0,"comment":"Sub-Transient reactance after EMF in d-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xq_pp","data_type":"Float64","null_value":0,"comment":"Sub-Transient reactance after EMF in q-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Td0_p","data_type":"Float64","null_value":0,"comment":"Time constant of transient d-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Tq0_p","data_type":"Float64","null_value":0,"comment":"Time constant of transient q-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Td0_pp","data_type":"Float64","null_value":0,"comment":"Time constant of sub-transient d-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Tq0_pp","data_type":"Float64","null_value":0,"comment":"Time constant of sub-transient q-axis voltage","valid_range":{"max":null,"min":0}},{"name":"T_AA","data_type":"Float64","null_value":0,"comment":"Time constant of d-axis additional leakage","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"γd","data_type":"Float64","comment":"","internal_default":"((Td0_pp*Xd_pp)/(Td0_p*Xd_p) )*(Xd-Xd_p)"},{"name":"γq","data_type":"Float64","comment":"","internal_default":"((Tq0_pp*Xq_pp)/(Tq0_p*Xq_p) )*(Xq-Xq_p)"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tψq: q-axis stator flux,\n\tψd: d-axis stator flux,\n\teq_p: q-axis transient voltage,\n\ted_p: d-axis transient voltage,\n\teq_pp: q-axis subtransient voltage,\n\ted_pp: d-axis subtransient voltage","internal_default":"[:ψq, :ψd, :eq_p, :ed_p, :eq_pp, :ed_pp]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"MarconatoMachine has 6 states","internal_default":6},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of 6-states synchronous machine: Marconato model","struct_name":"MarconatoMachine","supertype":"Machine"},{"fields":[{"name":"R","data_type":"Float64","null_value":0,"comment":"Resistance after EMF in machine per unit","valid_range":{"max":null,"min":0}},{"name":"Xd","data_type":"Float64","null_value":0,"comment":"Reactance after EMF in d-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xq","data_type":"Float64","null_value":0,"comment":"Reactance after EMF in q-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xd_p","data_type":"Float64","null_value":0,"comment":"Transient reactance after EMF in d-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xq_p","data_type":"Float64","null_value":0,"comment":"Transient reactance after EMF in q-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Td0_p","data_type":"Float64","null_value":0,"comment":"Time constant of transient d-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Tq0_p","data_type":"Float64","null_value":0,"comment":"Time constant of transient q-axis voltage","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\teq_p: q-axis transient voltage,\n\ted_p: d-axis transient voltage","internal_default":"[:eq_p, :ed_p]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"OneDOneQMachine has 2 states","internal_default":2},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of 4-states synchronous machine: Simplified Marconato model\n The derivative of stator fluxes (ψd and ψq) is neglected and ωψd = ψd and\n ωψq = ψq is assumed (i.e. ω=1.0). This is standard when\n transmission network dynamics is neglected.","struct_name":"OneDOneQMachine","supertype":"Machine"},{"fields":[{"name":"R","data_type":"Float64","null_value":0,"comment":"Resistance after EMF in machine per unit","valid_range":{"max":null,"min":0}},{"name":"Xd","data_type":"Float64","null_value":0,"comment":"Reactance after EMF in d-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xq","data_type":"Float64","null_value":0,"comment":"Reactance after EMF in q-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xd_p","data_type":"Float64","null_value":0,"comment":"Transient reactance after EMF in d-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xq_p","data_type":"Float64","null_value":0,"comment":"Transient reactance after EMF in q-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xd_pp","data_type":"Float64","null_value":0,"comment":"Sub-Transient reactance after EMF in d-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xq_pp","data_type":"Float64","null_value":0,"comment":"Sub-Transient reactance after EMF in q-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Td0_p","data_type":"Float64","null_value":0,"comment":"Time constant of transient d-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Tq0_p","data_type":"Float64","null_value":0,"comment":"Time constant of transient q-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Td0_pp","data_type":"Float64","null_value":0,"comment":"Time constant of sub-transient d-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Tq0_pp","data_type":"Float64","null_value":0,"comment":"Time constant of sub-transient q-axis voltage","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\teq_p: q-axis transient voltage,\n\ted_p: d-axis transient voltage,\n\teq_pp: q-axis subtransient voltage,\n\ted_pp: d-axis subtransient voltage","internal_default":"[:eq_p, :ed_p, :eq_pp, :ed_pp]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"SimpleAFMachine has 4 states","internal_default":4},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of 4-states simplified Anderson-Fouad (SimpleAFMachine) model.\n The derivative of stator fluxes (ψd and ψq) is neglected and ωψd = ψd and\n ωψq = ψq is assumed (i.e. ω=1.0). This is standard when transmission network\n dynamics is neglected.\n If transmission dynamics is considered use the full order Anderson Fouad model.","struct_name":"SimpleAFMachine","supertype":"Machine"},{"fields":[{"name":"R","data_type":"Float64","null_value":0,"comment":"Resistance after EMF in machine per unit","valid_range":{"max":null,"min":0}},{"name":"R_f","data_type":"Float64","null_value":0,"comment":"Field rotor winding resistance in per unit","valid_range":{"max":null,"min":0}},{"name":"R_1d","data_type":"Float64","null_value":0,"comment":" Damping rotor winding resistance on d-axis in per unit. This value is denoted as RD in Machowski.","valid_range":{"max":null,"min":0}},{"name":"R_1q","data_type":"Float64","null_value":0,"comment":"Damping rotor winding resistance on q-axis in per unit. This value is denoted as RQ in Machowski.","valid_range":{"max":null,"min":0}},{"name":"L_d","data_type":"Float64","null_value":1,"comment":"Inductance of fictitious damping that represent the effect of the three-phase stator winding in the d-axis of the rotor, in per unit. This value is denoted as L_ad + L_l in Kundur (and Ld in Machowski).","valid_range":{"max":null,"min":0}},{"name":"L_q","data_type":"Float64","null_value":1,"comment":"Inductance of fictitious damping that represent the effect of the three-phase stator winding in the q-axis of the rotor, in per unit. This value is denoted as L_aq + L_l in Kundur.","valid_range":{"max":null,"min":0}},{"name":"L_ad","data_type":"Float64","null_value":2,"comment":"Mutual inductance between stator winding and rotor field (and damping) winding inductance on d-axis, in per unit","valid_range":{"max":null,"min":0}},{"name":"L_aq","data_type":"Float64","null_value":1,"comment":"Mutual inductance between stator winding and rotor damping winding inductance on q-axis, in per unit","valid_range":{"max":null,"min":0}},{"name":"L_f1d","data_type":"Float64","null_value":1,"comment":"Mutual inductance between rotor field winding and rotor damping winding inductance on d-axis, in per unit","valid_range":{"max":null,"min":0}},{"name":"L_ff","data_type":"Float64","null_value":2,"comment":"Field rotor winding inductance, in per unit","valid_range":{"max":null,"min":0}},{"name":"L_1d","data_type":"Float64","null_value":1,"comment":"Inductance of the d-axis rotor damping circuit, in per unit","valid_range":{"max":null,"min":0}},{"name":"L_1q","data_type":"Float64","null_value":2,"comment":"Inductance of the q-axis rotor damping circuit, in per unit","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"inv_d_fluxlink","data_type":"Array{Float64,2}","comment":"Equations 3.127, 3.130, 3.131 From Kundur","internal_default":"inv([[-L_d L_ad L_ad]; [-L_ad L_ff L_f1d]; [-L_ad L_f1d L_1d]])"},{"name":"inv_q_fluxlink","data_type":"Array{Float64,2}","comment":"Equations 3.128, 3.132 From Kundur","internal_default":"inv([[-L_q L_aq]; [-L_aq L_1q]])"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tψf: field rotor flux,\n\tψ1d: d-axis rotor damping flux,\n\tψ1q: q-axis rotor damping flux","internal_default":"[:ψf, :ψ1d, :ψ1q]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"SimpleFullMachine has 3 states","internal_default":3},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameter of a full order flux stator-rotor model without zero sequence flux in the stator.\n The derivative of stator fluxes (ψd and ψq) is neglected. This is standard when\n transmission network dynamics is neglected. Only one q-axis damping circuit\n is considered. All per unit are in machine per unit.\n Refer to Chapter 3 of Power System Stability and Control by P. Kundur or Chapter 11 of Power System Dynamics: Stability and Control, by J. Machowski, J. Bialek and J. Bumby, for more details.\n Note that the models are somewhat different (but equivalent) due to the different Park Transformation used in both books.","struct_name":"SimpleFullMachine","supertype":"Machine"},{"fields":[{"name":"R","data_type":"Float64","null_value":0,"comment":"Resistance after EMF in machine per unit","valid_range":{"max":null,"min":0}},{"name":"Xd","data_type":"Float64","null_value":0,"comment":"Reactance after EMF in d-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xq","data_type":"Float64","null_value":0,"comment":"Reactance after EMF in q-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xd_p","data_type":"Float64","null_value":0,"comment":"Transient reactance after EMF in d-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xq_p","data_type":"Float64","null_value":0,"comment":"Transient reactance after EMF in q-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xd_pp","data_type":"Float64","null_value":0,"comment":"Sub-Transient reactance after EMF in d-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xq_pp","data_type":"Float64","null_value":0,"comment":"Sub-Transient reactance after EMF in q-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Td0_p","data_type":"Float64","null_value":0,"comment":"Time constant of transient d-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Tq0_p","data_type":"Float64","null_value":0,"comment":"Time constant of transient q-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Td0_pp","data_type":"Float64","null_value":0,"comment":"Time constant of sub-transient d-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Tq0_pp","data_type":"Float64","null_value":0,"comment":"Time constant of sub-transient q-axis voltage","valid_range":{"max":null,"min":0}},{"name":"T_AA","data_type":"Float64","null_value":0,"comment":"Time constant of d-axis additional leakage","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"γd","data_type":"Float64","comment":"","internal_default":"((Td0_pp*Xd_pp)/(Td0_p*Xd_p) )*(Xd-Xd_p)"},{"name":"γq","data_type":"Float64","comment":"","internal_default":"((Tq0_pp*Xq_pp)/(Tq0_p*Xq_p) )*(Xq-Xq_p)"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\teq_p: q-axis transient voltage,\n\ted_p: d-axis transient voltage,\n\teq_pp: q-axis subtransient voltage,\n\ted_pp: d-axis subtransient voltage","internal_default":"[:eq_p, :ed_p, :eq_pp, :ed_pp]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"SimpleMarconatoMachine has 4 states","internal_default":4},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of 4-states synchronous machine: Simplified Marconato model\n The derivative of stator fluxes (ψd and ψq) is neglected and ωψd = ψd and\n ωψq = ψq is assumed (i.e. ω=1.0). This is standard when transmission network\n dynamics is neglected.","struct_name":"SimpleMarconatoMachine","supertype":"Machine"},{"fields":[{"name":"V_pss","data_type":"Float64","null_value":0,"comment":"Fixed voltage stabilization signal","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"","internal_default":"Vector{Symbol}()"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"PSSFixed has no states","internal_default":0},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of a PSS that returns a fixed voltage to add to the reference for the AVR","struct_name":"PSSFixed","supertype":"PSS"},{"fields":[{"name":"K_ω","data_type":"Float64","null_value":0,"comment":"Proportional gain for frequency","valid_range":{"max":null,"min":0}},{"name":"K_p","data_type":"Float64","null_value":0,"comment":"Proportional gain for active power","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"","internal_default":"Vector{Symbol}()"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"PSSSimple has no states","internal_default":0},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of a PSS that returns a proportional droop voltage to add to the reference for the AVR","struct_name":"PSSSimple","supertype":"PSS"},{"fields":[{"name":"input_code","data_type":"Int","null_value":1,"validation_action":"error","comment":"Code input for stabilizer","valid_range":{"max":6,"min":1}},{"name":"remote_bus_control","data_type":"Int","null_value":0,"comment":"Remote Bus number for control."},{"name":"A1","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Filter coefficient","valid_range":{"max":null,"min":0}},{"name":"A2","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Filter coefficient","valid_range":{"max":null,"min":0}},{"name":"A3","data_type":"Float64","null_value":0,"comment":"Filter coefficient","valid_range":{"max":null,"min":0}},{"name":"A4","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Filter coefficient","valid_range":{"max":null,"min":0}},{"name":"A5","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Filter coefficient","valid_range":{"max":null,"min":0}},{"name":"A6","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Filter coefficient","valid_range":{"max":null,"min":0}},{"name":"T1","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant","valid_range":{"max":10,"min":0}},{"name":"T2","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant","valid_range":{"max":10,"min":0}},{"name":"T3","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant","valid_range":{"max":10,"min":0}},{"name":"T4","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant","valid_range":{"max":10,"min":0}},{"name":"T5","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant","valid_range":{"max":10,"min":0}},{"name":"T6","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Time constant","valid_range":{"max":"2.0","min":"eps()"}},{"name":"Ks","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Proportional gain","valid_range":{"max":null,"min":0}},{"name":"Ls_lim","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"PSS output limits for regulator output `(Ls_min, Ls_max)`"},{"name":"Vcu","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Cutoff limiter upper bound","valid_range":{"max":"1.25","min":0}},{"name":"Vcl","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Cutoff limiter lower bound","valid_range":{"max":"1.0","min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tx_p1: 1st filter integration,\n\tx_p2: 2nd filter integration, \n\tx_p3: 3rd filter integration, \n\tx_p4: 4rd filter integration, \n\tx_p5: T1/T2 lead-lag integrator, \n\tx_p6: T3/T4 lead-lag integrator, \n\t:x_p7 last integer,","internal_default":"[:x_p1, :x_p2, :x_p3, :x_p4, :x_p5, :x_p6, :x_p7]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"IEEEST has 7 states","internal_default":7},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"IEEEST has 7 differential states","internal_default":"[StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Differential]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"IEEE Stabilizing Model PSS. ","struct_name":"IEEEST","supertype":"PSS"},{"fields":[{"name":"KT","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"K/T for washout filter","valid_range":{"max":null,"min":0}},{"name":"T","data_type":"Float64","null_value":0.01,"validation_action":"warn","comment":"Time constant for washout filter","valid_range":{"max":null,"min":0.01}},{"name":"T1T3","data_type":"Float64","null_value":0,"comment":"Time constant division T1/T3","valid_range":{"max":null,"min":0}},{"name":"T3","data_type":"Float64","null_value":0.01,"validation_action":"warn","comment":"Time constant","valid_range":{"max":null,"min":0.01}},{"name":"T2T4","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant division T2/T4","valid_range":{"max":null,"min":0}},{"name":"T4","data_type":"Float64","null_value":0.01,"validation_action":"warn","comment":"Time constant","valid_range":{"max":null,"min":0.01}},{"name":"H_lim","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"PSS output limit","valid_range":{"max":0.5,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tx_p1: washout filter,\n\tx_p2: T1/T3 lead-lag block, \n\tx_p3: T2/T4 lead-lag block,","internal_default":"[:x_p1, :x_p2, :x_p3]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"STAB1 has 3 states","internal_default":3},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"STAB1 has 3 differential states","internal_default":"[StateTypes.Differential, StateTypes.Differential, StateTypes.Differential]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Speed-Sensitive Stabilizing Model","struct_name":"STAB1","supertype":"PSS"},{"fields":[{"name":"input_code_1","data_type":"Int","null_value":1,"validation_action":"error","comment":"First Input Code for stabilizer","valid_range":{"max":6,"min":1}},{"name":"remote_bus_control_1","data_type":"Int","null_value":0,"comment":"First Input Remote Bus number for control."},{"name":"input_code_2","data_type":"Int","null_value":1,"validation_action":"error","comment":"Second Input Code for stabilizer","valid_range":{"max":6,"min":1}},{"name":"remote_bus_control_2","data_type":"Int","null_value":0,"comment":"Second Input Remote Bus number for control."},{"name":"M_rtf","data_type":"Int","null_value":0,"validation_action":"error","comment":"M parameter for ramp tracking filter","valid_range":{"max":8,"min":0}},{"name":"N_rtf","data_type":"Int","null_value":0,"validation_action":"error","comment":"N parameter for ramp tracking filter","valid_range":{"max":8,"min":0}},{"name":"Tw1","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for first washout filter for first input","valid_range":{"max":null,"min":"eps()"}},{"name":"Tw2","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for second washout filter for first input","valid_range":{"max":null,"min":0}},{"name":"T6","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for low-pass filter for first input","valid_range":{"max":null,"min":0}},{"name":"Tw3","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for first washout filter for second input","valid_range":{"max":null,"min":"eps()"}},{"name":"Tw4","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for second washout filter for second input","valid_range":{"max":null,"min":0}},{"name":"T7","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for low-pass filter for second input","valid_range":{"max":null,"min":0}},{"name":"Ks2","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Gain for low-pass filter for second input","valid_range":{"max":null,"min":0}},{"name":"Ks3","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Gain for second input","valid_range":{"max":null,"min":0}},{"name":"T8","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for ramp tracking filter","valid_range":{"max":null,"min":0}},{"name":"T9","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for ramp tracking filter","valid_range":{"max":null,"min":"eps()"}},{"name":"Ks1","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Gain before lead-lag blocks","valid_range":{"max":null,"min":0}},{"name":"T1","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for first lead-lag block","valid_range":{"max":null,"min":0}},{"name":"T2","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for first lead-lag block","valid_range":{"max":null,"min":0}},{"name":"T3","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for second lead-lag block","valid_range":{"max":null,"min":0}},{"name":"T4","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for second lead-lag block","valid_range":{"max":null,"min":0}},{"name":"Vst_lim","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"PSS output limits `(Vst_min, Vst_max)`"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tx_p1: 1st washout 1st input, \n\tx_p2: 2nd washout 1st input, \n\tx_p3: transducer 1st input, \n\tx_p4: 1st washout 2nd input, \n\tx_p5: 2nd washout 2nd input, \n\tx_p6: transducer 2nd input, \n\tx_p7: ramp tracking filter state 1, \n\tx_p8: ramp tracking filter state 2, \n\tx_p9: ramp tracking filter state 3, \n\tx_p10: ramp tracking filter state 4, \n\tx_p11: ramp tracking filter state 5, \n\tx_p12: ramp tracking filter state 6, \n\tx_p13: ramp tracking filter state 7, \n\tx_p14: ramp tracking filter state 8, \n\tx_p15: 1st lead-lag, \n\tx_p16: 2nd lead-lag,","internal_default":"[:x_p1, :x_p2, :x_p3, :x_p4, :x_p5, :x_p6, :x_p7, :x_p8, :x_p9, :x_p10, :x_p11, :x_p12, :x_p13, :x_p14, :x_p15, :x_p16]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"IEEEST has 16 states","internal_default":16},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"IEEEST has 16 differential states","internal_default":"[StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"IEEE Dual-Input Stabilizer Model","struct_name":"PSS2A","supertype":"PSS"},{"fields":[{"name":"input_code_1","data_type":"Int","null_value":1,"validation_action":"error","comment":"First Input Code for stabilizer","valid_range":{"max":6,"min":1}},{"name":"remote_bus_control_1","data_type":"Int","null_value":0,"comment":"First Input Remote Bus number for control."},{"name":"input_code_2","data_type":"Int","null_value":1,"validation_action":"error","comment":"Second Input Code for stabilizer","valid_range":{"max":6,"min":1}},{"name":"remote_bus_control_2","data_type":"Int","null_value":0,"comment":"Second Input Remote Bus number for control."},{"name":"M_rtf","data_type":"Int","null_value":0,"validation_action":"error","comment":"M parameter for ramp tracking filter","valid_range":{"max":8,"min":0}},{"name":"N_rtf","data_type":"Int","null_value":0,"validation_action":"error","comment":"N parameter for ramp tracking filter","valid_range":{"max":8,"min":0}},{"name":"Tw1","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for first washout filter for first input","valid_range":{"max":null,"min":"eps()"}},{"name":"Tw2","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for second washout filter for first input","valid_range":{"max":null,"min":0}},{"name":"T6","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for low-pass filter for first input","valid_range":{"max":null,"min":0}},{"name":"Tw3","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for first washout filter for second input","valid_range":{"max":null,"min":"eps()"}},{"name":"Tw4","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for second washout filter for second input","valid_range":{"max":null,"min":0}},{"name":"T7","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for low-pass filter for second input","valid_range":{"max":null,"min":0}},{"name":"Ks2","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Gain for low-pass filter for second input","valid_range":{"max":null,"min":0}},{"name":"Ks3","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Gain for second input","valid_range":{"max":null,"min":0}},{"name":"T8","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for ramp tracking filter","valid_range":{"max":null,"min":0}},{"name":"T9","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for ramp tracking filter","valid_range":{"max":null,"min":"eps()"}},{"name":"Ks1","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Gain before lead-lag blocks","valid_range":{"max":null,"min":0}},{"name":"T1","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for first lead-lag block","valid_range":{"max":null,"min":0}},{"name":"T2","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for first lead-lag block","valid_range":{"max":null,"min":0}},{"name":"T3","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for second lead-lag block","valid_range":{"max":null,"min":0}},{"name":"T4","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for second lead-lag block","valid_range":{"max":null,"min":0}},{"name":"T10","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for third lead-lag block","valid_range":{"max":null,"min":0}},{"name":"T11","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for third lead-lag block","valid_range":{"max":null,"min":0}},{"name":"Vs1_lim","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"First input limits `(Vs1_min, Vs1_max)`"},{"name":"Vs2_lim","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Second input limits `(Vs2_min, Vs2_max)`"},{"name":"Vst_lim","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"PSS output limits `(Vst_min, Vst_max)`"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tx_p1: 1st washout 1st input, \n\tx_p2: 2nd washout 1st input, \n\tx_p3: transducer 1st input, \n\tx_p4: 1st washout 2nd input, \n\tx_p5: 2nd washout 2nd input, \n\tx_p6: transducer 2nd input, \n\tx_p7: ramp tracking filter state 1, \n\tx_p8: ramp tracking filter state 2, \n\tx_p9: ramp tracking filter state 3, \n\tx_p10: ramp tracking filter state 4, \n\tx_p11: ramp tracking filter state 5, \n\tx_p12: ramp tracking filter state 6, \n\tx_p13: ramp tracking filter state 7, \n\tx_p14: ramp tracking filter state 8, \n\tx_p15: 1st lead-lag, \n\tx_p16: 2nd lead-lag, \n\tx_p17: 3rd lead-lag,","internal_default":"[:x_p1, :x_p2, :x_p3, :x_p4, :x_p5, :x_p6, :x_p7, :x_p8, :x_p9, :x_p10, :x_p11, :x_p12, :x_p13, :x_p14, :x_p15, :x_p16, :x_p17]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"IEEEST has 17 states","internal_default":17},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"IEEEST has 17 differential states","internal_default":"[StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"IEEE 421.5 2005 PSS2B IEEE Dual-Input Stabilizer Model","struct_name":"PSS2B","supertype":"PSS"},{"fields":[{"name":"input_code_1","data_type":"Int","null_value":1,"validation_action":"error","comment":"First Input Code for stabilizer","valid_range":{"max":7,"min":1}},{"name":"remote_bus_control_1","data_type":"Int","null_value":0,"comment":"First Input Remote Bus number for control."},{"name":"input_code_2","data_type":"Int","null_value":1,"validation_action":"error","comment":"Second Input Code for stabilizer","valid_range":{"max":6,"min":1}},{"name":"remote_bus_control_2","data_type":"Int","null_value":0,"comment":"Second Input Remote Bus number for control."},{"name":"M_rtf","data_type":"Int","null_value":0,"validation_action":"error","comment":"M parameter for ramp tracking filter","valid_range":{"max":8,"min":0}},{"name":"N_rtf","data_type":"Int","null_value":0,"validation_action":"error","comment":"N parameter for ramp tracking filter","valid_range":{"max":8,"min":0}},{"name":"Tw1","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for first washout filter for first input","valid_range":{"max":null,"min":"eps()"}},{"name":"Tw2","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for second washout filter for first input","valid_range":{"max":null,"min":0}},{"name":"T6","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for low-pass filter for first input","valid_range":{"max":null,"min":0}},{"name":"Tw3","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for first washout filter for second input","valid_range":{"max":null,"min":"eps()"}},{"name":"Tw4","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for second washout filter for second input","valid_range":{"max":null,"min":0}},{"name":"T7","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for low-pass filter for second input","valid_range":{"max":null,"min":0}},{"name":"Ks2","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Gain for low-pass filter for second input","valid_range":{"max":null,"min":0}},{"name":"Ks3","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Gain for second input","valid_range":{"max":null,"min":0}},{"name":"T8","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for ramp tracking filter","valid_range":{"max":null,"min":0}},{"name":"T9","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for ramp tracking filter","valid_range":{"max":null,"min":"eps()"}},{"name":"Ks1","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Gain before lead-lag blocks","valid_range":{"max":null,"min":0}},{"name":"T1","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for first lead-lag block","valid_range":{"max":null,"min":0}},{"name":"T2","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for first lead-lag block","valid_range":{"max":null,"min":0}},{"name":"T3","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for second lead-lag block","valid_range":{"max":null,"min":0}},{"name":"T4","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for second lead-lag block","valid_range":{"max":null,"min":0}},{"name":"T10","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for third lead-lag block","valid_range":{"max":null,"min":0}},{"name":"T11","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for third lead-lag block","valid_range":{"max":null,"min":0}},{"name":"Vs1_lim","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"First input limits `(Vs1_min, Vs1_max)`"},{"name":"Vs2_lim","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Second input limits `(Vs2_min, Vs2_max)`"},{"name":"Vst_lim","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"PSS output limits `(Vst_min, Vst_max)`"},{"name":"T12","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for fourth lead-lag block","valid_range":{"max":null,"min":0}},{"name":"T13","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for fourth lead-lag block","valid_range":{"max":null,"min":0}},{"name":"PSS_Hysteresis_param","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"PSS output hysteresis parameters `(PSSOFF, PSSON)`"},{"name":"Xcomp","data_type":"Float64","null_value":0,"comment":"Stator Leakage Reactance","valid_range":{"max":null,"min":0}},{"name":"Tcomp","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Time measured with compensated frequency","valid_range":{"max":null,"min":"eps()"}},{"name":"hysteresis_binary_logic","default":"1","data_type":"Int","null_value":0,"comment":"Hysteresis memory variable"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tx_p1: 1st washout 1st input, \n\tx_p2: 2nd washout 1st input, \n\tx_p3: transducer 1st input, \n\tx_p4: 1st washout 2nd input, \n\tx_p5: 2nd washout 2nd input, \n\tx_p6: transducer 2nd input, \n\tx_p7: ramp tracking filter state 1, \n\tx_p8: ramp tracking filter state 2, \n\tx_p9: ramp tracking filter state 3, \n\tx_p10: ramp tracking filter state 4, \n\tx_p11: ramp tracking filter state 5, \n\tx_p12: ramp tracking filter state 6, \n\tx_p13: ramp tracking filter state 7, \n\tx_p14: ramp tracking filter state 8, \n\tx_p15: 1st lead-lag, \n\tx_p16: 2nd lead-lag, \n\tx_p17: 3rd lead-lag, \n\tx_p18: 4th lead-lag, \n\tx_p19: washout block for compensated frequency,","internal_default":"[:x_p1, :x_p2, :x_p3, :x_p4, :x_p5, :x_p6, :x_p7, :x_p8, :x_p9, :x_p10, :x_p11, :x_p12, :x_p13, :x_p14, :x_p15, :x_p16, :x_p17, :x_p18, :x_p19]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"IEEEST has 19 states","internal_default":19},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"IEEEST has 19 differential states","internal_default":"[StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"IEEE 421.5 2016 PSS2C IEEE Dual-Input Stabilizer Model","struct_name":"PSS2C","supertype":"PSS"},{"fields":[{"name":"H","data_type":"Float64","null_value":0,"comment":"Rotor inertia constant in MWs/MVA","valid_range":{"max":null,"min":0}},{"name":"D","data_type":"Float64","null_value":0,"comment":"Rotor natural damping in pu","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tδ: rotor angle,\n\tω: rotor speed","internal_default":"[:δ, :ω]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"SingleMass has 1 state","internal_default":2},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of single mass shaft model. Typically represents the rotor mass.","struct_name":"SingleMass","supertype":"Shaft"},{"fields":[{"name":"H","data_type":"Float64","null_value":0,"comment":"Rotor inertia constant in MWs/MVA","valid_range":{"max":null,"min":0}},{"name":"H_hp","data_type":"Float64","null_value":0,"comment":"High pressure turbine inertia constant in MWs/MVA","valid_range":{"max":null,"min":0}},{"name":"H_ip","data_type":"Float64","null_value":0,"comment":"Intermediate pressure turbine inertia constant in MWs/MVA","valid_range":{"max":null,"min":0}},{"name":"H_lp","data_type":"Float64","null_value":0,"comment":"Low pressure turbine inertia constant in MWs/MVA","valid_range":{"max":null,"min":0}},{"name":"H_ex","data_type":"Float64","null_value":0,"comment":" Exciter inertia constant in MWs/MVA","valid_range":{"max":null,"min":0}},{"name":"D","data_type":"Float64","null_value":0,"comment":"Rotor natural damping in pu","valid_range":{"max":null,"min":0}},{"name":"D_hp","data_type":"Float64","null_value":0,"comment":"High pressure turbine natural damping in pu","valid_range":{"max":null,"min":0}},{"name":"D_ip","data_type":"Float64","null_value":0,"comment":"Intermediate pressure turbine natural damping in pu","valid_range":{"max":null,"min":0}},{"name":"D_lp","data_type":"Float64","null_value":0,"comment":"Low pressure turbine natural damping in pu","valid_range":{"max":null,"min":0}},{"name":"D_ex","data_type":"Float64","null_value":0,"comment":"Exciter natural damping in pu","valid_range":{"max":null,"min":0}},{"name":"D_12","data_type":"Float64","null_value":0,"comment":"High-Intermediate pressure turbine damping","valid_range":{"max":null,"min":0}},{"name":"D_23","data_type":"Float64","null_value":0,"comment":"Intermediate-Low pressure turbine damping","valid_range":{"max":null,"min":0}},{"name":"D_34","data_type":"Float64","null_value":0,"comment":"Low pressure turbine-Rotor damping","valid_range":{"max":null,"min":0}},{"name":"D_45","data_type":"Float64","null_value":0,"comment":"Rotor-Exciter damping","valid_range":{"max":null,"min":0}},{"name":"K_hp","data_type":"Float64","null_value":0,"comment":"High pressure turbine angle coefficient","valid_range":{"max":null,"min":0}},{"name":"K_ip","data_type":"Float64","null_value":0,"comment":"Intermediate pressure turbine angle coefficient","valid_range":{"max":null,"min":0}},{"name":"K_lp","data_type":"Float64","null_value":0,"comment":"Low pressure turbine angle coefficient","valid_range":{"max":null,"min":0}},{"name":"K_ex","data_type":"Float64","null_value":0,"comment":"Exciter angle coefficient","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tδ: rotor angle,\n\tω: rotor speed,\n\tδ_hp: rotor angle of high pressure turbine,\n\tω_hp: rotor speed of high pressure turbine,\n\tδ_ip: rotor angle of intermediate pressure turbine,\n\tω_ip: rotor speed of intermediate pressure turbine,\n\tδ_lp: rotor angle of low pressure turbine,\n\tω_lp: rotor speed of low pressure turbine,\n\tδ_ex: rotor angle of exciter,\n\tω_lp: rotor speed of exciter","internal_default":"[:δ, :ω, :δ_hp, :ω_hp, :δ_ip, :ω_ip, :δ_lp, :ω_lp, :δ_ex, :ω_ex]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"FiveMassShaft has 10 states","internal_default":10},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of 5 mass-spring shaft model.\n It contains a High-Pressure (HP) steam turbine, Intermediate-Pressure (IP)\n steam turbine, Low-Pressure (LP) steam turbine, the Rotor and an Exciter (EX) mover.","struct_name":"FiveMassShaft","supertype":"Shaft"},{"fields":[{"name":"efficiency","data_type":"Float64","null_value":0,"comment":" Efficiency factor that multiplies P_ref","valid_range":{"max":null,"min":0}},{"name":"P_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Power Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"","internal_default":"Vector{Symbol}()"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"TGFixed has no states","internal_default":0},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of a fixed Turbine Governor that returns a fixed mechanical torque\n given by the product of P_ref*efficiency","struct_name":"TGFixed","supertype":"TurbineGov"},{"fields":[{"name":"R","data_type":"Float64","null_value":0,"comment":"Speed droop parameter","valid_range":{"max":0.1,"min":"eps()"}},{"name":"T1","data_type":"Float64","null_value":0,"comment":"Governor time constant in s","valid_range":{"max":0.5,"min":"eps()"}},{"name":"T2","data_type":"Float64","null_value":0,"comment":"Combustion chamber time constant","valid_range":{"max":0.5,"min":"eps()"}},{"name":"T3","data_type":"Float64","null_value":0,"comment":"Load limit time constant (exhaust gas measurement time)","valid_range":{"max":5,"min":"eps()"}},{"name":"AT","data_type":"Float64","null_value":0,"comment":"Ambient temperature load limit","valid_range":{"max":1,"min":0}},{"name":"Kt","data_type":"Float64","null_value":0,"comment":"Load limit feedback gain","valid_range":{"max":5,"min":0}},{"name":"V_lim","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Operational control limits on fuel valve opening (V_min, V_max)"},{"name":"D_turb","data_type":"Float64","null_value":0,"comment":"Speed damping coefficient of gas turbine rotor","valid_range":{"max":0.5,"min":0}},{"name":"P_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Load Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the GAST model are:\n\tx_g1: Fuel valve opening,\n\tx_g2: Fuel flow,\n\tx_g3: Exhaust temperature load","internal_default":"[:x_g1, :x_g2, :x_g3]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"GasTG has 3 states","internal_default":3},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"GAST has 3 differential states","internal_default":"[StateTypes.Differential, StateTypes.Differential, StateTypes.Differential]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of Gas Turbine-Governor. GAST in PSSE and GAST_PTI in PowerWorld.","struct_name":"GasTG","supertype":"TurbineGov"},{"fields":[{"name":"T1","data_type":"Float64","null_value":0,"comment":"Governor mechanism time constant","valid_range":{"max":100,"min":"eps()"}},{"name":"T2","data_type":"Float64","null_value":0,"comment":"Turbine power time constant","valid_range":{"max":100,"min":"eps()"}},{"name":"T3","data_type":"Float64","null_value":0,"comment":"Turbine exhaust temperature time constant","valid_range":{"max":100,"min":"eps()"}},{"name":"K","data_type":"Float64","null_value":0,"comment":"Governor gain (reciprocal of droop)","valid_range":{"max":100,"min":"eps()"}},{"name":"T4","data_type":"Float64","null_value":0,"comment":"Governor lead time constant","valid_range":{"max":100,"min":"eps()"}},{"name":"T5","data_type":"Float64","null_value":0,"comment":"Governor lag time constant","valid_range":{"max":100,"min":"eps()"}},{"name":"T6","data_type":"Float64","null_value":0,"comment":"Actuator time constant","valid_range":{"max":100,"min":"eps()"}},{"name":"Td","data_type":"Float64","null_value":0,"comment":"Engine time delay","valid_range":{"max":100,"min":"eps()"}},{"name":"P_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Load Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the DEGOV model are:\n\tx_ecb1: Electric control box 1,\n\tx_ecb2: Electric control box 2,\n\tx_a1: Actuator 1,\n\tx_a2: Actuator 2,\n\tx_a3: Actuator 3,","internal_default":"[:x_ecb1, :x_ecb2, :x_a1, :x_a2, :x_a3]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"DEGOV has 5 states","internal_default":5},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"DEGOV has 5 differential states","internal_default":"[StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters Woodward Diesel Governor Model. DEGOV in PowerWorld.","struct_name":"DEGOV","supertype":"TurbineGov"},{"fields":[{"name":"Rselect","data_type":"Int","null_value":1,"validation_action":"error","comment":"Feedback signal for governor droop","valid_range":{"max":1,"min":-2}},{"name":"fuel_flag","data_type":"Int","null_value":0,"validation_action":"error","comment":"Flag Switch for fuel source characteristic","valid_range":{"max":1,"min":0}},{"name":"R","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Speed droop parameter","valid_range":{"max":null,"min":"eps()"}},{"name":"Tpelec","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Electrical power transducer time constant, seconds","valid_range":{"max":null,"min":"eps()"}},{"name":"speed_error_signal","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Speed error signal limits"},{"name":"Kp_gov","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Governor proportional gain","valid_range":{"max":null,"min":0}},{"name":"Ki_gov","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Governor integral gain","valid_range":{"max":null,"min":0}},{"name":"Kd_gov","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Governor derivative gain","valid_range":{"max":null,"min":0}},{"name":"Td_gov","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Governor derivative time constant","valid_range":{"max":null,"min":0}},{"name":"valve_position_limits","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Valve position limits"},{"name":"T_act","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Actuator time constant","valid_range":{"max":null,"min":0}},{"name":"K_turb","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Turbine gain","valid_range":{"max":null,"min":0}},{"name":"Wf_nl","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"No load fuel flow, pu","valid_range":{"max":null,"min":0}},{"name":"Tb","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Turbine lag time constant, sec","valid_range":{"max":null,"min":0}},{"name":"Tc","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Turbine lead time constant, sec","valid_range":{"max":null,"min":0}},{"name":"T_eng","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Transport lag time constant for diesel engine, sec","valid_range":{"max":null,"min":0}},{"name":"Tf_load","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Load limiter time constant","valid_range":{"max":null,"min":0}},{"name":"Kp_load","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Load limiter proportional gain for PI controller","valid_range":{"max":null,"min":0}},{"name":"Ki_load","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Load integral gain for PI controller","valid_range":{"max":null,"min":0}},{"name":"Ld_ref","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Load limiter integral gain for PI controller","valid_range":{"max":null,"min":0}},{"name":"Dm","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Mechanical damping coefficient, pu","valid_range":{"max":null,"min":0}},{"name":"R_open","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Maximum valve opening rate, pu/sec","valid_range":{"max":null,"min":0}},{"name":"R_close","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Maximum valve closing rate, pu/sec","valid_range":{"max":null,"min":0}},{"name":"Ki_mw","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Power controller (reset) gain","valid_range":{"max":null,"min":0}},{"name":"A_set","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Acceleration limiter setpoint, pu/sec","valid_range":{"max":null,"min":0}},{"name":"Ka","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Acceleration limiter gain","valid_range":{"max":null,"min":0}},{"name":"Ta","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Acceleration limiter time constant ","valid_range":{"max":null,"min":"eps()"}},{"name":"T_rate","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Turbine rating","valid_range":{"max":null,"min":0}},{"name":"db","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Speed governor deadband","valid_range":{"max":null,"min":0}},{"name":"Tsa","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Temperature detection lead time constant","valid_range":{"max":null,"min":0}},{"name":"Tsb","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Temperature detection lag time constant","valid_range":{"max":null,"min":0}},{"name":"R_lim","data_type":"UpDown","null_value":"(up = 0.0, down = 0.0)","comment":"Maximum rate of load increa"},{"name":"P_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Power Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the GGOV1 model are:\n\tPe: Machine Electrical Power Measurement,\n\tx_g1: Governor differential control,\n\tx_g2: Governor integral control, \n\tx_g3: Turbine actuator, \n\tx_g4: Turbine Lead-Lag, \n\tx_g5: Turbine load limiter measurement, \n\tx_g6: Turbine Load Limiter Integral Control, \n\tx_g7: Supervisory Load Control, \n\tx_g8: Acceleration Control, \n\tx_g9 Temperature Detection Lead - Lag:","internal_default":"[:Pe, :x_g1, :x_g2, :x_g3, :x_g4, :x_g5, :x_g6, :x_g7, :x_g8, :x_g9]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"GeneralGovModel has 10 states","internal_default":10},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"GGOV1 has 10 differential states","internal_default":"[StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Differential, StateTypes.Hybrid]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"GE General Governor/Turbine Model. The GeneralGovModel (GGOV1) model is a general purpose governor model used for a variety of prime movers controlled by proportional-integral-derivative (PID) governors including gas turbines.","struct_name":"GeneralGovModel","supertype":"TurbineGov"},{"fields":[{"name":"R","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Droop parameter","valid_range":{"max":0.1,"min":0}},{"name":"T1","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Governor time constant","valid_range":{"max":0.5,"min":"eps()"}},{"name":"valve_position_limits","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Valve position limits"},{"name":"T2","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Lead Lag Lead Time constant ","valid_range":{"max":null,"min":0}},{"name":"T3","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Lead Lag Lag Time constant ","valid_range":{"max":10,"min":"eps()"}},{"name":"D_T","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Turbine Damping","valid_range":{"max":0.5,"min":0}},{"name":"DB_h","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Deadband for overspeed","valid_range":{"max":null,"min":0}},{"name":"DB_l","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Deadband for underspeed","valid_range":{"max":0,"min":null}},{"name":"T_rate","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Turbine Rate (MW). If zero, generator base is used.","valid_range":{"max":null,"min":0}},{"name":"P_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Power Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the SteamTurbineGov1 model are:\n\tx_g1: Valve Opening,\n\tx_g2: Lead-lag state","internal_default":"[:x_g1, :x_g2]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"TGOV1 has 2 states","internal_default":2},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"TGOV1 has 2 differential states","internal_default":"[StateTypes.Differential, StateTypes.Differential]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Steam Turbine-Governor. This model considers both TGOV1 or TGOV1DU in PSS/E.","struct_name":"SteamTurbineGov1","supertype":"TurbineGov"},{"fields":[{"name":"R","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Permanent droop parameter","valid_range":{"max":0.1,"min":0}},{"name":"r","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Temporary Droop","valid_range":{"max":2,"min":0}},{"name":"Tr","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Governor time constant","valid_range":{"max":30,"min":"eps()"}},{"valiation_action":"error","name":"Tf","data_type":"Float64","null_value":0,"comment":"Filter Time constant","valid_range":{"max":0.1,"min":"eps()"}},{"name":"Tg","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Servo time constant","valid_range":{"max":1,"min":"eps()"}},{"name":"VELM","data_type":"Float64","null_value":0,"validation_action":"error","comment":"gate velocity limit","valid_range":{"max":0.3,"min":"eps()"}},{"name":"gate_position_limits","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Gate position limits"},{"name":"Tw","data_type":"Float64","null_value":0,"validation_action":"error","comment":"water time constant","valid_range":{"max":3,"min":"eps()"}},{"name":"At","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Turbine gain","valid_range":{"max":1.5,"min":0.8}},{"name":"D_T","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Turbine Damping","valid_range":{"max":0.5,"min":0}},{"name":"q_nl","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"No-power flow","valid_range":{"max":null,"min":0}},{"name":"P_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Power Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the HydroTurbineGov model are:\n\tx_g1: filter_output,\n\tx_g2: desired gate, \n\tx_g3: gate opening, \n\tx_g4: turbine flow","internal_default":"[:x_g1, :x_g2, :x_g3, :x_g4]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"HYGOV has 4 states","internal_default":4},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"HYGOV has 4 differential states","internal_default":"[StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Hydro Turbine-Governor.","struct_name":"HydroTurbineGov","supertype":"TurbineGov"},{"fields":[{"name":"K","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Governor Gain","valid_range":{"max":30,"min":5}},{"name":"T1","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Input Filter Lag","valid_range":{"max":5,"min":0}},{"name":"T2","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Input Filter Lead","valid_range":{"max":10,"min":0}},{"name":"T3","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Valve position Time Constant","valid_range":{"max":1,"min":"eps()"}},{"name":"U0","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Maximum Valve Opening Rate","valid_range":{"max":0.03,"min":0.01}},{"name":"U_c","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Maximum Valve closing rate","valid_range":{"max":0,"min":-0.3}},{"name":"valve_position_limits","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Valve position limits in MW"},{"name":"T4","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time Constant inlet steam","valid_range":{"max":1,"min":0}},{"name":"K1","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Fraction of high presure shaft power","valid_range":{"max":1,"min":-2}},{"name":"K2","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Fraction of low presure shaft power","valid_range":{"max":null,"min":0}},{"name":"T5","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for second boiler pass","valid_range":{"max":10,"min":0}},{"name":"K3","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Fraction of high presure shaft power second boiler pass","valid_range":{"max":0.5,"min":0}},{"name":"K4","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Fraction of low presure shaft power second boiler pass","valid_range":{"max":0.5,"min":0}},{"name":"T6","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for third boiler pass","valid_range":{"max":10,"min":0}},{"name":"K5","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Fraction of high presure shaft power third boiler pass","valid_range":{"max":0.35,"min":0}},{"name":"K6","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Fraction of low presure shaft power third boiler pass","valid_range":{"max":0.55,"min":0}},{"name":"T7","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for fourth boiler pass","valid_range":{"max":10,"min":0}},{"name":"K7","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Fraction of high presure shaft power fourth boiler pass","valid_range":{"max":0.3,"min":0}},{"name":"K8","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Fraction of low presure shaft power fourth boiler pass","valid_range":{"max":0.3,"min":0}},{"name":"P_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Power Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the IEEETurbineGov model are:\n\tx_g1: First Governor integrator,\n\tx_g2: Governor output,\n\tx_g3: First Turbine integrator, \n\tx_g4: Second Turbine Integrator, \n\tx_g5: Third Turbine Integrator, \n\tx_g6: Fourth Turbine Integrator, ","internal_default":"[:x_g1, :x_g2, :x_g3, :x_g4, :x_g5, :x_g6]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"IEEEG1 has 6 states","internal_default":6},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"IEEEG1 has 6 differential states","internal_default":"[StateTypes.Differential, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"IEEE Type 1 Speed-Governing Model","struct_name":"IEEETurbineGov1","supertype":"TurbineGov"},{"fields":[{"name":"R","data_type":"Float64","null_value":0,"comment":"Droop parameter","valid_range":{"max":null,"min":0}},{"name":"Ts","data_type":"Float64","null_value":0,"comment":"Governor time constant","valid_range":{"max":null,"min":0}},{"name":"Tc","data_type":"Float64","null_value":0,"comment":"Servo time constant","valid_range":{"max":null,"min":0}},{"name":"T3","data_type":"Float64","null_value":0,"comment":"Transient gain time constant","valid_range":{"max":null,"min":0}},{"name":"T4","data_type":"Float64","null_value":0,"comment":"Power fraction time constant","valid_range":{"max":null,"min":0}},{"name":"T5","data_type":"Float64","null_value":0,"comment":"Reheat time constant","valid_range":{"max":null,"min":0}},{"name":"valve_position_limits","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Valve position limits in MW"},{"name":"P_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Power Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the TGTypeI model are:\n\tx_g1: Governor state,\n\tx_g2: Servo state,\n\tx_g3: Reheat state","internal_default":"[:x_g1, :x_g2, :x_g3]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"TGTypeI has 3 states","internal_default":3},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of a Turbine Governor Type I.","struct_name":"TGTypeI","supertype":"TurbineGov"},{"fields":[{"name":"R","data_type":"Float64","null_value":0,"comment":"Droop parameter","valid_range":{"max":null,"min":0}},{"name":"T1","data_type":"Float64","null_value":0,"comment":"Transient gain time constant","valid_range":{"max":null,"min":0}},{"name":"T2","data_type":"Float64","null_value":0,"comment":"Power fraction time constant","valid_range":{"max":null,"min":0}},{"name":"τ_limits","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Power into the governor limits"},{"name":"P_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Power Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the TGTypeI model are:\n\tx_g1: lead-lag state","internal_default":"[:xg]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"TGTypeII has 1 state","internal_default":1},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of a Turbine Governor Type II.","struct_name":"TGTypeII","supertype":"TurbineGov"},{"fields":[{"name":"rated_voltage","data_type":"Float64","null_value":0,"comment":"rated voltage","valid_range":{"max":null,"min":0}},{"name":"rated_current","data_type":"Float64","null_value":0,"comment":"rated VA","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"","internal_default":"Vector{Symbol}()"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"AverageConverter has no states","internal_default":0}],"docstring":"Parameters of an average converter model","struct_name":"AverageConverter","supertype":"Converter"},{"fields":[{"name":"T_g","data_type":"Float64","null_value":0,"comment":"Converter time constant (s)","valid_range":{"max":null,"min":0}},{"name":"Rrpwr","data_type":"Float64","null_value":0,"comment":"Low Voltage Power Logic (LVPL) ramp rate limit (pu/s)","valid_range":{"max":null,"min":0}},{"name":"Brkpt","data_type":"Float64","null_value":0,"comment":"LVPL characteristic voltage 2 (pu)","valid_range":{"max":null,"min":0}},{"name":"Zerox","data_type":"Float64","null_value":0,"comment":"LVPL characteristic voltage 1 (pu)","valid_range":{"max":null,"min":0}},{"name":"Lvpl1","data_type":"Float64","null_value":0,"comment":"LVPL gain (pu)","valid_range":{"max":null,"min":0}},{"name":"Vo_lim","data_type":"Float64","null_value":0,"comment":"Voltage limit for high voltage reactive current management (pu)","valid_range":{"max":null,"min":0}},{"name":"Lv_pnts","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Voltage points for low voltage active current management (pu) (Lvpnt0, Lvpnt1)"},{"name":"Io_lim","data_type":"Float64","null_value":0,"comment":"Current limit (pu) for high voltage reactive current management (specified as a negative value)","valid_range":{"max":0,"min":null}},{"name":"T_fltr","data_type":"Float64","null_value":0,"comment":"Voltage filter time constant for low voltage active current management (s)","valid_range":{"max":null,"min":0}},{"name":"K_hv","data_type":"Float64","null_value":0,"comment":"Overvoltage compensation gain used in the high voltage reactive current management","valid_range":{"max":null,"min":0}},{"name":"Iqr_lims","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Limit on rate of change for reactive current (pu/s) (Iqr_min, Iqr_max)"},{"name":"Accel","data_type":"Float64","null_value":0,"comment":"Acceleration factor","valid_range":{"max":1,"min":0}},{"name":"Lvpl_sw","data_type":"Int","null_value":0,"comment":"Low voltage power logic (LVPL) switch. (0: LVPL not present, 1: LVPL present)","valid_range":{"max":1,"min":0}},{"name":"Q_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Initial machine reactive power from power flow","valid_range":{"max":null,"min":0}},{"name":"R_source","default":"0.0","data_type":"Float64","null_value":0,"comment":"Output resistor used for the Thevenin Equivalent","valid_range":{"max":null,"min":0}},{"name":"X_source","default":"1.0e5","data_type":"Float64","null_value":0,"comment":"Output resistor used for the Thevenin Equivalent","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\tIp: Converter lag for Ipcmd,\tIq: Converter lag for Iqcmd,\tVmeas: Voltage filter for low voltage active current management","internal_default":"[:Ip, :Iq, :Vmeas]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"RenewableEnergyConverterTypeA has 3 states","internal_default":3}],"docstring":"Parameters of a renewable energy generator/converter model, this model corresponds to REGCA1 in PSSE","struct_name":"RenewableEnergyConverterTypeA","supertype":"Converter"},{"fields":[{"name":"T_g","data_type":"Float64","null_value":0,"comment":"Converter time constant (s)","valid_range":{"max":null,"min":0}},{"name":"Rrpwr","data_type":"Float64","null_value":0,"comment":"Low Voltage Power Logic (LVPL) ramp rate limit (pu/s)","valid_range":{"max":null,"min":0}},{"name":"Brkpt","data_type":"Float64","null_value":0,"comment":"LVPL characteristic voltage 2 (pu)","valid_range":{"max":null,"min":0}},{"name":"Zerox","data_type":"Float64","null_value":0,"comment":"LVPL characteristic voltage 1 (pu)","valid_range":{"max":null,"min":0}},{"name":"Lvpl1","data_type":"Float64","null_value":0,"comment":"LVPL gain (pu)","valid_range":{"max":null,"min":0}},{"name":"Vo_lim","data_type":"Float64","null_value":0,"comment":"Voltage limit for high voltage reactive current management (pu)","valid_range":{"max":null,"min":0}},{"name":"Lv_pnts","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Voltage points for low voltage active current management (pu) (Lvpnt0, Lvpnt1)"},{"name":"Io_lim","data_type":"Float64","null_value":0,"comment":"Current limit (pu) for high voltage reactive current management (specified as a negative value)","valid_range":{"max":0,"min":null}},{"name":"T_fltr","data_type":"Float64","null_value":0,"comment":"Voltage filter time constant for low voltage active current management (s)","valid_range":{"max":null,"min":0}},{"name":"K_hv","data_type":"Float64","null_value":0,"comment":"Overvoltage compensation gain used in the high voltage reactive current management","valid_range":{"max":null,"min":0}},{"name":"Iqr_lims","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Limit on rate of change for reactive current (pu/s) (Iqr_min, Iqr_max)"},{"name":"Accel","data_type":"Float64","null_value":0,"comment":"Acceleration factor","valid_range":{"max":1,"min":0}},{"name":"Lvpl_sw","data_type":"Int","null_value":0,"comment":"Low voltage power logic (LVPL) switch. (0: LVPL not present, 1: LVPL present)","valid_range":{"max":1,"min":0}},{"name":"Q_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Initial machine reactive power from power flow","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\tIp: Converter lag for Ipcmd,\tIq: Converter lag for Iqcmd,\tVmeas: Voltage filter for low voltage active current management","internal_default":"[:Ip, :Iq, :Vmeas]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"RenewableEnergyVoltageConverterTypeA has 3 states","internal_default":3}],"docstring":"Parameters of a renewable energy generator/converter model, this model corresponds to REGCA1 in PSSE, but to be interfaced using a Voltage Source instead of a Current Source.","struct_name":"RenewableEnergyVoltageConverterTypeA","supertype":"Converter"},{"fields":[{"name":"voltage","data_type":"Float64","null_value":0,"comment":"rated VA","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"","internal_default":"Vector{Symbol}()"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"FixedDCSource has no states","internal_default":0},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of a Fixed DC Source that returns a fixed DC voltage","struct_name":"FixedDCSource","supertype":"DCSource"},{"fields":[{"name":"rated_voltage","data_type":"Float64","null_value":0,"comment":"rated voltage","valid_range":{"max":null,"min":0}},{"name":"rated_current","data_type":"Float64","null_value":0,"comment":"rated current","valid_range":{"max":null,"min":0}},{"name":"battery_voltage","data_type":"Float64","null_value":0,"comment":"battery voltage","valid_range":{"max":null,"min":0}},{"name":"battery_resistance","data_type":"Float64","null_value":0,"comment":"battery_resistance","valid_range":{"max":null,"min":0}},{"name":"dc_dc_inductor","data_type":"Float64","null_value":0,"comment":"DC/DC inductance","valid_range":{"max":null,"min":0}},{"name":"dc_link_capacitance","data_type":"Float64","null_value":0,"comment":"DC-link capacitor","valid_range":{"max":null,"min":0}},{"name":"fs","data_type":"Float64","null_value":0,"comment":"DC/DC converter switching frequency","valid_range":{"max":null,"min":0}},{"name":"kpv","data_type":"Float64","null_value":0,"comment":"voltage controller proportional gain","valid_range":{"max":null,"min":0}},{"name":"kiv","data_type":"Float64","null_value":0,"comment":"voltage controller integral gain","valid_range":{"max":null,"min":0}},{"name":"kpi","data_type":"Float64","null_value":0,"comment":"current controller proportional gain","valid_range":{"max":null,"min":0}},{"name":"kii","data_type":"Float64","null_value":0,"comment":"current controller integral gain","valid_range":{"max":null,"min":0}},{"name":"Vdc_ref","default":"1.1","data_type":"Float64","null_value":0,"comment":"Reference DC-Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the ZeroOrderBESS model are:\n\tv_dc: DC-link votlage,\n\ti_b: Battery current,\n\t ν: integrator state of the voltage controller,\n\t ζ: integrator state of the PI current controller","internal_default":"[:v_dc, :i_b, :ν, :ζ]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"ZeroOrderBESS has 4 states","internal_default":4}],"docstring":"Parameters for the DC-side with a Battery Energy Storage System from paper at https://arxiv.org/abs/2007.11776","struct_name":"ZeroOrderBESS","supertype":"DCSource"},{"fields":[{"name":"lf","data_type":"Float64","null_value":0,"comment":"Series inductance in p.u. of converter filter","valid_range":{"max":null,"min":0}},{"name":"rf","data_type":"Float64","null_value":0,"comment":"Series resistance in p.u. of converter filter","valid_range":{"max":null,"min":0}},{"name":"cf","data_type":"Float64","null_value":0,"comment":"Shunt capacitance in p.u. of converter filter","valid_range":{"max":null,"min":0}},{"name":"lg","data_type":"Float64","null_value":0,"comment":"Series inductance in p.u. of converter filter to the grid","valid_range":{"max":null,"min":0}},{"name":"rg","data_type":"Float64","null_value":0,"comment":"Series resistance in p.u. of converter filter to the grid","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the LCLFilter model are:\n\tir_cnv: Real current out of the converter,\n\tii_cnv: Imaginary current out of the converter,\n\tvr_filter: Real voltage at the filter's capacitor,\n\tvi_filter: Imaginary voltage at the filter's capacitor,\n\tir_filter: Real current out of the filter,\n\tii_filter: Imaginary current out of the filter","internal_default":"[:ir_cnv, :ii_cnv, :vr_filter, :vi_filter, :ir_filter, :ii_filter]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"LCLFilter has 6 states","internal_default":6}],"docstring":"Parameters of a LCL filter outside the converter, the states are in the grid's reference frame","struct_name":"LCLFilter","supertype":"Filter"},{"fields":[{"name":"lf","data_type":"Float64","null_value":0,"comment":"filter inductance","valid_range":{"max":null,"min":0}},{"name":"rf","data_type":"Float64","null_value":0,"comment":"filter resistance","valid_range":{"max":null,"min":0}},{"name":"cf","data_type":"Float64","null_value":0,"comment":"filter capacitance","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the LCFilter model are:\n\tir_filter: Real current out of the filter,\n\tii_filter: Imaginary current out of the filter","internal_default":"[:ir_filter, :ii_filter]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"LCFilter has two states","internal_default":2}],"docstring":"Parameters of a LCL filter outside the converter","struct_name":"LCFilter","supertype":"Filter"},{"fields":[{"name":"rf","data_type":"Float64","null_value":0,"comment":"Series resistance in p.u. of converter filter to the grid","valid_range":{"max":null,"min":0}},{"name":"lf","data_type":"Float64","null_value":0,"comment":"Series inductance in p.u. of converter filter to the grid","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"RLFilter has zero states","internal_default":"Vector{Symbol}()"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"RLFilter has zero states","internal_default":0}],"docstring":"Parameters of RL series filter in algebraic representation","struct_name":"RLFilter","supertype":"Filter"},{"fields":[{"name":"ω_lp","data_type":"Float64","null_value":0,"comment":"PLL low-pass filter frequency (rad/sec)","valid_range":{"max":null,"min":0}},{"name":"kp_pll","data_type":"Float64","null_value":0,"comment":"PLL proportional gain","valid_range":{"max":null,"min":0}},{"name":"ki_pll","data_type":"Float64","null_value":0,"comment":"PLL integral gain","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the KauraPLL model are:\n\tvd_pll: d-axis of the measured voltage in the PLL synchronous reference frame (SRF),\n\tvq_pll: q-axis of the measured voltage in the PLL SRF,\n\tε_pll: Integrator state of the PI controller,\n\tθ_pll: Phase angle displacement in the PLL SRF","internal_default":"[:vd_pll, :vq_pll, :ε_pll, :θ_pll]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"KauraPLL has 4 states","internal_default":4}],"docstring":"Parameters of a Phase-Locked Loop (PLL) based on Kaura, Vikram, and Vladimir Blasko.\n\"Operation of a phase locked loop system under distorted utility conditions.\"\nIEEE Transactions on Industry applications 33.1 (1997): 58-63.","struct_name":"KauraPLL","supertype":"FrequencyEstimator"},{"fields":[{"name":"ω_lp","data_type":"Float64","null_value":0,"comment":"PLL low-pass filter frequency (rad/sec)","valid_range":{"max":null,"min":0}},{"name":"kp_pll","data_type":"Float64","null_value":0,"comment":"PLL proportional gain","valid_range":{"max":null,"min":0}},{"name":"ki_pll","data_type":"Float64","null_value":0,"comment":"PLL integral gain","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the ReducedOrderPLL model are:\n\tvq_pll: q-axis of the measured voltage in the PLL synchronous reference frame (SRF),\n\tε_pll: Integrator state of the PI controller,\n\tθ_pll: Phase angle displacement in the PLL SRF","internal_default":"[:vq_pll, :ε_pll, :θ_pll]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"ReducedOrderPLL has 3 states","internal_default":3}],"docstring":"Parameters of a Phase-Locked Loop (PLL) based on Purba, Dhople, Jafarpour, Bullo and Johnson.\n\"Reduced-order Structure-preserving Model for Parallel-connected Three-phase Grid-tied Inverters.\"\n2017 IEEE 18th Workshop on Control and Modeling for Power Electronics (COMPEL): 1-7.","struct_name":"ReducedOrderPLL","supertype":"FrequencyEstimator"},{"fields":[{"name":"frequency","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference used"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"FixedFrequency has no states","internal_default":"Vector{Symbol}()"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"FixedFrequency has no states","internal_default":0}],"docstring":"Parameters of a Fixed Frequency Estimator (i.e. no PLL).","struct_name":"FixedFrequency","supertype":"FrequencyEstimator"},{"fields":[{"name":"Ta","data_type":"Float64","null_value":0,"comment":"VSM inertia constant","valid_range":{"max":null,"min":0}},{"name":"kd","data_type":"Float64","null_value":0,"comment":"VSM damping constant","valid_range":{"max":null,"min":0}},{"name":"kω","data_type":"Float64","null_value":0,"comment":"frequency droop gain","valid_range":{"max":null,"min":0}},{"name":"P_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Power Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the VirtualInertia model are:\n\tθ_oc: Phase angle displacement of the virtual synchronous generator model\n\tω_oc: Speed of the rotating reference frame of the virtual synchronous generator model","internal_default":"[:θ_oc, :ω_oc]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"VirtualInertia has two states","internal_default":2}],"docstring":"Parameters of a Virtual Inertia with SRF using VSM for active power controller","struct_name":"VirtualInertia","supertype":"ActivePowerControl"},{"fields":[{"name":"Rp","data_type":"Float64","null_value":0,"comment":"Droop Gain","valid_range":{"max":null,"min":0}},{"name":"ωz","data_type":"Float64","null_value":0,"comment":"filter frequency cutoff","valid_range":{"max":null,"min":0}},{"name":"P_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Power Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the ActivePowerDroop model are:\n\tθ_oc: Phase angle displacement of the inverter model,\n\tp_oc: Measured active power of the inverter model","internal_default":"[:θ_oc, :p_oc]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"ActivePowerDroop has two states","internal_default":2}],"docstring":"Parameters of an Active Power droop controller","struct_name":"ActivePowerDroop","supertype":"ActivePowerControl"},{"fields":[{"name":"Kp_p","data_type":"Float64","null_value":0,"comment":"Proportional Gain","valid_range":{"max":null,"min":0}},{"name":"Ki_p","data_type":"Float64","null_value":0,"comment":"Integral Gain","valid_range":{"max":null,"min":0}},{"name":"ωz","data_type":"Float64","null_value":0,"comment":"filter frequency cutoff","valid_range":{"max":null,"min":0}},{"name":"P_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Power Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the ActivePowerPI model are:\n\tσp_oc: Integrator state of the PI Controller,\n\tp_oc: Measured active power of the inverter model","internal_default":"[:σp_oc, :p_oc]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"ActivePowerPI has two states","internal_default":2}],"docstring":"Parameters of a Proportional-Integral Active Power controller for a specified power reference","struct_name":"ActivePowerPI","supertype":"ActivePowerControl"},{"fields":[{"name":"k1","data_type":"Float64","null_value":0,"comment":"VOC Synchronization Gain","valid_range":{"max":null,"min":0}},{"name":"ψ","data_type":"Float64","null_value":0,"comment":"Rotation angle of the controller","valid_range":{"max":null,"min":0}},{"name":"P_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Power Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the ActiveVirtualOscillator model are:\n\tθ_oc: Phase angle displacement of the inverter model","internal_default":"[:θ_oc]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"ActiveVirtualOscillator has one state","internal_default":1}],"docstring":"Parameters of an Active Virtual Oscillator controller. Model is based from the paper Model Reduction for Inverters with Current Limiting and Dispatchable Virtual Oscillator Control by O. Ajala et al.","struct_name":"ActiveVirtualOscillator","supertype":"ActivePowerControl"},{"fields":[{"name":"bus_control","data_type":"Int","null_value":0,"comment":"Bus Number for voltage control; ","valid_range":{"max":null,"min":0}},{"name":"from_branch_control","data_type":"Int","null_value":0,"comment":"Monitored branch FROM bus number for line drop compensation (if 0 generator power will be used)","valid_range":{"max":null,"min":0}},{"name":"to_branch_control","data_type":"Int","null_value":0,"comment":"Monitored branch TO bus number for line drop compensation (if 0 generator power will be used)","valid_range":{"max":null,"min":0}},{"name":"branch_id_control","data_type":"String","null_value":0,"comment":"Branch circuit id for line drop compensation (as a string). If 0 generator power will be used"},{"name":"Freq_Flag","data_type":"Int","null_value":0,"comment":"Frequency Flag for REPCA1: 0: disable, 1:enable","valid_range":{"max":1,"min":0}},{"name":"K_pg","data_type":"Float64","null_value":0,"comment":"Active power PI control proportional gain","valid_range":{"max":null,"min":0}},{"name":"K_ig","data_type":"Float64","null_value":0,"comment":"Active power PI control integral gain","valid_range":{"max":null,"min":0}},{"name":"T_p","data_type":"Float64","null_value":0,"comment":"Real power measurement filter time constant (s)","valid_range":{"max":null,"min":0}},{"name":"fdbd_pnts","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Frequency error dead band thresholds `(fdbd1, fdbd2)`"},{"name":"fe_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Upper/Lower limit on frequency error `(fe_min, fe_max)`"},{"name":"P_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Upper/Lower limit on power reference `(P_min, P_max)`"},{"name":"T_g","data_type":"Float64","null_value":0,"comment":"Power Controller lag time constant","valid_range":{"max":null,"min":0}},{"name":"D_dn","data_type":"Float64","null_value":0,"comment":"Droop for over-frequency conditions","valid_range":{"max":0,"min":null}},{"name":"D_up","data_type":"Float64","null_value":0,"comment":"Droop for under-frequency conditions","valid_range":{"max":null,"min":0}},{"name":"dP_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Upper/Lower limit on power reference ramp rates`(dP_min, dP_max)`"},{"name":"P_lim_inner","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Upper/Lower limit on power reference for REECB`(P_min_inner, P_max_inner)`"},{"name":"T_pord","data_type":"Float64","null_value":0,"comment":"Power filter time constant REECB time constant","valid_range":{"max":null,"min":0}},{"name":"P_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Power Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the ActiveRenewableControllerAB model depends on the Flag","internal_default":"PowerSystems.get_activeRETypeAB_states(Freq_Flag)[1]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"The states of the ActiveRenewableControllerAB model depends on the Flag","internal_default":"PowerSystems.get_activeRETypeAB_states(Freq_Flag)[2]"}],"docstring":"Parameters of Active Power Controller including REPCA1 and REECB1","struct_name":"ActiveRenewableControllerAB","supertype":"ActivePowerControl"},{"fields":[{"name":"bus_control","data_type":"Int","null_value":0,"comment":"Bus Number for voltage control; ","valid_range":{"max":null,"min":0}},{"name":"from_branch_control","data_type":"Int","null_value":0,"comment":"Monitored branch FROM bus number for line drop compensation (if 0 generator power will be used)","valid_range":{"max":null,"min":0}},{"name":"to_branch_control","data_type":"Int","null_value":0,"comment":"Monitored branch TO bus number for line drop compensation (if 0 generator power will be used)","valid_range":{"max":null,"min":0}},{"name":"branch_id_control","data_type":"String","null_value":0,"comment":"Branch circuit id for line drop compensation (as a string). If 0 generator power will be used"},{"name":"VC_Flag","data_type":"Int","null_value":0,"comment":"Voltage Compensator Flag for REPCA1","valid_range":{"max":1,"min":0}},{"name":"Ref_Flag","data_type":"Int","null_value":0,"comment":"Flag for Reactive Power Control for REPCA1. 0: Q-control, 1: V-control","valid_range":{"max":1,"min":0}},{"name":"PF_Flag","data_type":"Int","null_value":0,"comment":"Flag for Power Factor Control for Outer Control of REECB1. 0: Q-control, 1: Power Factor Control","valid_range":{"max":1,"min":0}},{"name":"V_Flag","data_type":"Int","null_value":0,"comment":"Flag for Voltage Control for Outer Control of REECB1. 0: Voltage Control, 1: Q-Control","valid_range":{"max":1,"min":0}},{"name":"T_fltr","data_type":"Float64","null_value":0,"comment":"Voltage or Q-power of REPCA Filter Time Constant","valid_range":{"max":null,"min":0}},{"name":"K_p","data_type":"Float64","null_value":0,"comment":"Reactive power PI control proportional gain","valid_range":{"max":null,"min":0}},{"name":"K_i","data_type":"Float64","null_value":0,"comment":"Reactive power PI control integral gain","valid_range":{"max":null,"min":0}},{"name":"T_ft","data_type":"Float64","null_value":0,"comment":"Reactive power lead time constant (s)","valid_range":{"max":null,"min":0}},{"name":"T_fv","data_type":"Float64","null_value":0,"comment":"Reactive power lag time constant (s)","valid_range":{"max":null,"min":0}},{"name":"V_frz","data_type":"Float64","null_value":0,"comment":"Voltage below which state ξq_oc (integrator state) is freeze","valid_range":{"max":null,"min":0}},{"name":"R_c","data_type":"Float64","null_value":0,"comment":"Line drop compensation resistance (used when VC_Flag = 1)","valid_range":{"max":null,"min":0}},{"name":"X_c","data_type":"Float64","null_value":0,"comment":"Line drop compensation reactance (used when VC_Flag = 1)","valid_range":{"max":null,"min":0}},{"name":"K_c","data_type":"Float64","null_value":0,"comment":"Reactive current compensation gain (pu) (used when VC_Flag = 0)","valid_range":{"max":null,"min":0}},{"name":"e_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Upper/Lower limit on Voltage or Q-power deadband output `(e_min, e_max)`"},{"name":"dbd_pnts","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Voltage or Q-power error dead band thresholds `(dbd1, dbd2)`"},{"name":"Q_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Upper/Lower limit on reactive power V/Q control in REPCA `(Q_min, Q_max)`"},{"name":"T_p","data_type":"Float64","null_value":0,"comment":"Active power lag time constant in REECB (s). Used only when PF_Flag = 1","valid_range":{"max":null,"min":0}},{"name":"Q_lim_inner","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Upper/Lower limit on reactive power input in REECB `(Q_min_inner, Q_max_inner)`. Only used when V_Flag = 1"},{"name":"V_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Upper/Lower limit on reactive power PI controller in REECB `(V_min, V_max)`. Only used when V_Flag = 1"},{"name":"K_qp","data_type":"Float64","null_value":0,"comment":"Reactive power regulator proportional gain (used when V_Flag = 1)","valid_range":{"max":null,"min":0}},{"name":"K_qi","data_type":"Float64","null_value":0,"comment":"Reactive power regulator integral gain (used when V_Flag = 1)","valid_range":{"max":null,"min":0}},{"name":"Q_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Power Set-point","valid_range":{"max":null,"min":0}},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the ReactiveRenewableControllerAB model depends on the Flag","internal_default":"PowerSystems.get_reactiveRETypeAB_states(Ref_Flag, PF_Flag, V_Flag)[1]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"The states of the ReactiveRenewableControllerAB model depends on the Flag","internal_default":"PowerSystems.get_reactiveRETypeAB_states(Ref_Flag, PF_Flag, V_Flag)[2]"}],"docstring":"Parameters of Reactive Power Controller including REPCA1 and REECB1","struct_name":"ReactiveRenewableControllerAB","supertype":"ReactivePowerControl"},{"fields":[{"name":"kq","data_type":"Float64","null_value":0,"comment":"frequency droop gain","valid_range":{"max":null,"min":0}},{"name":"ωf","data_type":"Float64","null_value":0,"comment":"filter frequency cutoff","valid_range":{"max":null,"min":0}},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the ReactivePowerDroop model are:\n\tq_oc: Filtered reactive output power","internal_default":"[:q_oc]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"ReactivePowerDroop has 1 state","internal_default":1}],"docstring":"Parameters of a Reactive Power droop controller","struct_name":"ReactivePowerDroop","supertype":"ReactivePowerControl"},{"fields":[{"name":"Kp_q","data_type":"Float64","null_value":0,"comment":"Proportional Gain","valid_range":{"max":null,"min":0}},{"name":"Ki_q","data_type":"Float64","null_value":0,"comment":"Integral Gain","valid_range":{"max":null,"min":0}},{"name":"ωf","data_type":"Float64","null_value":0,"comment":"filter frequency cutoff","valid_range":{"max":null,"min":0}},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"Q_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reactive Power Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the ReactivePowerPI model are:\n\tσq_oc: Integrator state of the PI Controller,\n\tq_oc: Measured reactive power of the inverter model","internal_default":"[:σq_oc, :q_oc]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"ReactivePowerPI has two states","internal_default":2}],"docstring":"Parameters of a Proportional-Integral Reactive Power controller for a specified power reference","struct_name":"ReactivePowerPI","supertype":"ReactivePowerControl"},{"fields":[{"name":"k2","data_type":"Float64","null_value":0,"comment":"VOC voltage-amplitude control gain","valid_range":{"max":null,"min":0}},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"Q_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Reactive Power Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the ReactiveVirtualOscilator model are:\n\tE_oc: voltage reference state for inner control in the d-axis","internal_default":"[:E_oc]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"ReactiveVirtualOscillator has 1 state","internal_default":1}],"docstring":"Parameters of a Reactive Virtual Oscillator controller. Model is based from the paper Model Reduction for Inverters with Current Limiting and Dispatchable Virtual Oscillator Control by O. Ajala et al.","struct_name":"ReactiveVirtualOscillator","supertype":"ReactivePowerControl"},{"fields":[{"name":"kpv","data_type":"Float64","null_value":0,"comment":"voltage controller proportional gain","valid_range":{"max":null,"min":0}},{"name":"kiv","data_type":"Float64","null_value":0,"comment":"voltage controller integral gain","valid_range":{"max":null,"min":0}},{"name":"kffv","data_type":"Float64","null_value":0,"comment":"Binary variable to enable feed-forward gain of voltage.","valid_range":{"max":null,"min":0}},{"name":"rv","data_type":"Float64","null_value":0,"comment":"virtual resistance","valid_range":{"max":null,"min":0}},{"name":"lv","data_type":"Float64","null_value":0,"comment":"virtual inductance","valid_range":{"max":null,"min":0}},{"name":"kpc","data_type":"Float64","null_value":0,"comment":"current controller proportional gain","valid_range":{"max":null,"min":0}},{"name":"kic","data_type":"Float64","null_value":0,"comment":"current controller integral gain","valid_range":{"max":null,"min":0}},{"name":"kffi","data_type":"Float64","null_value":0,"comment":"Binary variable to enable feed-forward gain of current","valid_range":{"max":null,"min":0}},{"name":"ωad","data_type":"Float64","null_value":0,"comment":"active damping filter cutoff frequency (rad/sec)","valid_range":{"max":null,"min":0}},{"name":"kad","data_type":"Float64","null_value":0,"comment":"active damping gain","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the VoltageModeControl model are:\n\tξd_ic: d-axis integrator state of the PI voltage controller,\n\tξq_ic: q-axis integrator state of the PI voltage controller,\n\tγd_ic: d-axis integrator state of the PI current controller,\n\tγq_ic: q-axis integrator state of the PI current controller,\n\tϕd_ic: d-axis low-pass filter of active damping,\n\tϕq_ic: q-axis low-pass filter of active damping","internal_default":"[:ξd_ic, :ξq_ic, :γd_ic, :γq_ic, :ϕd_ic, :ϕq_ic]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"VoltageModeControl has 6 states","internal_default":6}],"docstring":"Parameters of an inner loop current control PID using virtual impedance based on D'Arco, Suul and Fosso.\n\"A Virtual Synchronous Machine implementation for distributed control of power converters in SmartGrids.\"\nElectric Power Systems Research 122 (2015) 180–197.","struct_name":"VoltageModeControl","supertype":"InnerControl"},{"fields":[{"name":"kpc","data_type":"Float64","null_value":0,"comment":"Current controller proportional gain","valid_range":{"max":null,"min":0}},{"name":"kic","data_type":"Float64","null_value":0,"comment":"Current controller integral gain","valid_range":{"max":null,"min":0}},{"name":"kffv","data_type":"Float64","null_value":0,"comment":"Gain to enable feed-forward gain of voltage.","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the CurrentModeControl model are:\n\tγd_ic: d-axis integrator state of the PI current controller,\n\tγq_ic: q-axis integrator state of the PI current controller","internal_default":"[:γd_ic, :γq_ic]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"CurrentControl has 2 states","internal_default":2}],"docstring":"Parameters of an inner loop PI current control using based on Purba, Dhople, Jafarpour, Bullo and Johnson.\n\"Reduced-order Structure-preserving Model for Parallel-connected Three-phase Grid-tied Inverters.\"\n2017 IEEE 18th Workshop on Control and Modeling for Power Electronics (COMPEL): 1-7.","struct_name":"CurrentModeControl","supertype":"InnerControl"},{"fields":[{"name":"Q_Flag","data_type":"Int","null_value":0,"comment":"Q Flag used for I_qinj","valid_range":{"max":1,"min":0}},{"name":"PQ_Flag","data_type":"Int","null_value":0,"comment":"PQ Flag used for the Current Limit Logic","valid_range":{"max":1,"min":0}},{"name":"Vdip_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Limits for Voltage Dip Logic `(Vdip, Vup)`"},{"name":"T_rv","data_type":"Float64","null_value":0,"comment":"Voltage Filter Time Constant","valid_range":{"max":null,"min":0}},{"name":"dbd_pnts","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Voltage error deadband thresholds `(dbd1, dbd2)`"},{"name":"K_qv","data_type":"Float64","null_value":0,"comment":"Reactive current injection gain during over and undervoltage conditions","valid_range":{"max":null,"min":0}},{"name":"Iqinj_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Limits for Iqinj `(I_qh1, I_ql1)`"},{"name":"V_ref0","data_type":"Float64","null_value":0,"comment":"User defined reference. If 0, PSID initializes to initial terminal voltage","valid_range":{"max":null,"min":0}},{"name":"K_vp","data_type":"Float64","null_value":0,"comment":"Voltage regulator proportional gain (used when QFlag = 1)","valid_range":{"max":null,"min":0}},{"name":"K_vi","data_type":"Float64","null_value":0,"comment":"Voltage regulator integral gain (used when QFlag = 1)","valid_range":{"max":null,"min":0}},{"name":"T_iq","data_type":"Float64","null_value":0,"comment":"Time constant for low-pass filter for state q_V when QFlag = 0","valid_range":{"max":null,"min":0}},{"name":"I_max","data_type":"Float64","null_value":0,"comment":"Maximum limit on total converter current","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the RECurrentControlB depends on the Flags","internal_default":"PowerSystems.get_REControlB_states(Q_Flag)"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"The states of the RECurrentControlB depends on the Flags","internal_default":"2"}],"docstring":"Parameters of the Inner Control part of the REECB model in PSS/E","struct_name":"RECurrentControlB","supertype":"InnerControl"},{"fields":[{"name":"I_max","data_type":"Float64","null_value":0,"comment":"Maximum limit on current controller input current (device base)","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"}],"docstring":"Parameters of Magnitude (Circular) Current Controller Limiter","struct_name":"MagnitudeCurrentLimiter","supertype":"InverterLimiter"},{"fields":[{"name":"Id_max","data_type":"Float64","null_value":0,"comment":"Maximum limit on d-axis current controller input current (device base)","valid_range":{"max":null,"min":0}},{"name":"Iq_max","data_type":"Float64","null_value":0,"comment":"Maximum limit on d-axis current controller input current (device base)","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"}],"docstring":"Parameters of Instantaneous (Square) Current Controller Limiter","struct_name":"InstantaneousCurrentLimiter","supertype":"InverterLimiter"},{"fields":[{"name":"I_max","data_type":"Float64","null_value":0,"comment":"Maximum limit on current controller input current (device base)","valid_range":{"max":null,"min":0}},{"name":"ϕ_I","data_type":"Float64","null_value":0,"comment":"Pre-defined angle (measured against the d-axis) for Iref once limit is hit","valid_range":{"max":1.571,"min":-1.571}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"}],"docstring":"Parameters of Priority-Based Current Controller Limiter","struct_name":"PriorityCurrentLimiter","supertype":"InverterLimiter"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"Pf_Flag","data_type":"Int","null_value":0,"comment":"Flag for Power Factor Control","valid_range":{"max":1,"min":0}},{"name":"Freq_Flag","data_type":"Int","null_value":0,"comment":"Flag to enable/disable frequency control","valid_range":{"max":1,"min":0}},{"name":"PQ_Flag","data_type":"Int","null_value":0,"comment":"Flag used to enforce maximum current","valid_range":{"max":1,"min":0}},{"name":"Gen_Flag","data_type":"Int","null_value":0,"comment":"Flag to specify generator or storage","valid_range":{"max":1,"min":0}},{"name":"Vtrip_Flag","data_type":"Int","null_value":0,"comment":"Flag to enable/disable voltage trip logic","valid_range":{"max":1,"min":0}},{"name":"Ftrip_Flag","data_type":"Int","null_value":0,"comment":"Flag to enable/disable frequency trip logic","valid_range":{"max":1,"min":0}},{"name":"T_rv","data_type":"Float64","null_value":0,"comment":"Voltage measurement transducer time constant","valid_range":{"max":null,"min":0}},{"name":"Trf","data_type":"Float64","null_value":0,"comment":"Frequency measurement transducer time constant","valid_range":{"max":null,"min":0}},{"name":"dbd_pnts","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Voltage deadband thresholds `(dbd1, dbd2)`"},{"name":"K_qv","data_type":"Float64","null_value":0,"comment":"Proportional voltage control gain (pu)","valid_range":{"max":null,"min":0}},{"name":"Tp","data_type":"Float64","null_value":0,"comment":"Power measurement transducer time constant","valid_range":{"max":null,"min":0}},{"name":"T_iq","data_type":"Float64","null_value":0,"comment":"Time constant for low-pass filter for state q_V when QFlag = 0","valid_range":{"max":null,"min":0}},{"name":"D_dn","data_type":"Float64","null_value":0,"comment":"Reciprocal of droop for over-frequency conditions (>0) (pu)","valid_range":{"max":null,"min":0}},{"name":"D_up","data_type":"Float64","null_value":0,"comment":"Reciprocal of droop for under-frequency conditions <=0) (pu)","valid_range":{"max":null,"min":0}},{"name":"fdbd_pnts","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Frequency control deadband thresholds `(fdbd1, fdbd2)`"},{"name":"fe_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Frequency error limits (femin, femax)"},{"name":"P_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Power limits (Pmin, Pmax)"},{"name":"dP_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Power reference ramp rate limits (dPmin, dPmax)"},{"name":"Tpord","data_type":"Float64","null_value":0,"comment":"Power filter time constant","valid_range":{"max":null,"min":0}},{"name":"Kpg","data_type":"Float64","null_value":0,"comment":"PI controller proportional gain (pu)","valid_range":{"max":null,"min":0}},{"name":"Kig","data_type":"Float64","null_value":0,"comment":"PI controller integral gain (pu)","valid_range":{"max":null,"min":0}},{"name":"I_max","data_type":"Float64","null_value":0,"comment":"Maximum limit on total converter current (pu)","valid_range":{"max":null,"min":0}},{"name":"vl_pnts","data_type":"Vector{Tuple{Float64,Float64}}","null_value":"[(0.0, 0.0), (0.0, 0.0)]","comment":"Low voltage cutout points `[(tv10, vl0), (tv11, vl1)]`"},{"name":"vh_pnts","data_type":"Vector{Tuple{Float64,Float64}}","null_value":"[(0.0, 0.0), (0.0, 0.0)]","comment":"High voltage cutout points `[(tvh0, vh0), (tvh1, vh1)]`"},{"name":"Vrfrac","data_type":"Float64","null_value":0,"comment":"Fraction of device that recovers after voltage comes back to within vl1 < V < vh1 (0 <= Vrfrac <= 1)","valid_range":{"max":1,"min":0}},{"name":"fl","data_type":"Float64","null_value":0,"comment":"Inverter frequency break-point for low frequency cut-out (Hz)","valid_range":{"max":null,"min":0}},{"name":"fh","data_type":"Float64","null_value":0,"comment":"Inverter frequency break-point for high frequency cut-out (Hz)","valid_range":{"max":null,"min":0}},{"name":"tfl","data_type":"Float64","null_value":0,"comment":"Low frequency cut-out timer corresponding to frequency fl (s)","valid_range":{"max":null,"min":0}},{"name":"tfh","data_type":"Float64","null_value":0,"comment":"High frequency cut-out timer corresponding to frequency fh (s)","valid_range":{"max":null,"min":0}},{"name":"Tg","data_type":"Float64","null_value":0,"comment":"Current control time constant (to represent behavior of inner control loops) (> 0) (s)","valid_range":{"max":null,"min":0}},{"name":"rrpwr","data_type":"Float64","null_value":0,"comment":"Ramp rate for real power increase following a fault (pu/s)","valid_range":{"max":null,"min":0}},{"name":"Tv","data_type":"Float64","null_value":0,"comment":"Time constant on the output of the multiplier (s)","valid_range":{"max":null,"min":0}},{"name":"Vpr","data_type":"Float64","null_value":0,"comment":"Voltage below which frequency tripping is disabled (pu)","valid_range":{"max":null,"min":0}},{"name":"Iq_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Reactive current injection limits (Iqll, Iqhl)"},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"User defined voltage reference. If 0, PSID initializes to initial terminal voltage","valid_range":{"max":null,"min":0}},{"name":"Pfa_ref","default":"0.0","data_type":"Float64","null_value":0,"comment":"Reference power factor","valid_range":{"max":null,"min":0}},{"name":"ω_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference frequency","valid_range":{"max":null,"min":0}},{"name":"Q_ref","default":"0.0","data_type":"Float64","null_value":0,"comment":"Reference reactive power, in pu","valid_range":{"max":null,"min":0}},{"name":"P_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference active power, in pu","valid_range":{"max":null,"min":0}},{"name":"base_power","default":"100.0","data_type":"Float64","null_value":0,"comment":"Base power"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of AggregateDistributedGenerationA depends on the Flags","internal_default":"PowerSystems.get_AggregateDistributedGenerationA_states(Freq_Flag)[1]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"The states of AggregateDistributedGenerationA depends on the Flags","internal_default":"PowerSystems.get_AggregateDistributedGenerationA_states(Freq_Flag)[2]"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of the DERA1 model in PSS/E","struct_name":"AggregateDistributedGenerationA","supertype":"DynamicInjection"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"bus","data_type":"ACBus","null_value":"ACBus(nothing)"},{"name":"active_power","data_type":"Float64","null_value":"0.0"},{"name":"reactive_power","data_type":"Float64","null_value":"0.0"},{"name":"R_th","data_type":"Float64","null_value":0,"comment":"Source Thevenin resistance","valid_range":{"max":null,"min":0}},{"name":"X_th","data_type":"Float64","null_value":0,"comment":"Source Thevenin reactance","valid_range":{"max":null,"min":0}},{"name":"internal_voltage","default":"1.0","data_type":"Float64","null_value":0,"comment":"Internal Voltage","valid_range":{"max":null,"min":0}},{"name":"internal_angle","default":"0.0","data_type":"Float64","null_value":0,"comment":"Internal Angle"},{"name":"dynamic_injector","default":"nothing","data_type":"Union{Nothing, DynamicInjection}","exclude_setter":true,"null_value":"nothing","comment":"corresponding dynamic injection device"},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"This struct acts as an infinity bus.","struct_name":"Source","supertype":"StaticInjection"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"R_th","data_type":"Float64","null_value":0,"comment":"Source Thevenin resistance","valid_range":{"max":null,"min":0}},{"name":"X_th","data_type":"Float64","null_value":0,"comment":"Source Thevenin reactance","valid_range":{"max":null,"min":0}},{"name":"internal_voltage_bias","default":"0.0","data_type":"Float64","null_value":0,"comment":"a0 term of the Fourier Series for the voltage"},{"name":"internal_voltage_frequencies","default":"[0.0]","data_type":"Vector{Float64}","null_value":[0],"comment":"Frequencies in radians/s"},{"name":"internal_voltage_coefficients","default":"[(0.0, 0.0)]","data_type":"Vector{Tuple{Float64,Float64}}","null_value":"[(0.0, 0.0)]","comment":"Coefficients for terms n > 1. First component corresponds to sin and second component to cos"},{"name":"internal_angle_bias","default":"0.0","data_type":"Float64","null_value":0,"comment":"a0 term of the Fourier Series for the angle"},{"name":"internal_angle_frequencies","default":"[0.0]","data_type":"Vector{Float64}","null_value":[0],"comment":"Frequencies in radians/s"},{"name":"internal_angle_coefficients","default":"[(0.0, 0.0)]","data_type":"Vector{Tuple{Float64,Float64}}","null_value":"[(0.0, 0.0)]","comment":"Coefficients for terms n > 1. First component corresponds to sin and second component to cos"},{"name":"base_power","default":"100.0","data_type":"Float64","null_value":0,"comment":"Base power"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"State for time, voltage and angle","internal_default":"[:Vt, :θt]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"null_value":2,"internal_default":2},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"This struct acts as an infinity bus with time varying phasor values magnitude and angle V(t) \theta(t). Time varying functions are represented using fourier series","struct_name":"PeriodicVariableSource","supertype":"DynamicInjection"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"Qref_Flag","data_type":"Int","null_value":1,"comment":"Reactive Power Control Mode. 1 VoltVar Control, 2 Constant Q Control, 3 Constant PF Control","valid_range":{"max":3,"min":1}},{"name":"PQ_Flag","data_type":"Int","null_value":0,"comment":"Active and reactive power priority mode. 0 for Q priority, 1 for P priority","valid_range":{"max":1,"min":0}},{"name":"Gen_Flag","data_type":"Int","null_value":0,"comment":"Define generator or storage system. 0 unit is a storage device, 1 unit is a generator","valid_range":{"max":1,"min":0}},{"name":"PerOp_Flag","data_type":"Int","null_value":0,"comment":"Defines operation of permisible region in VRT characteristic. 0 for cease, 1 for continuous operation","valid_range":{"max":1,"min":0}},{"name":"Recon_Flag","data_type":"Int","null_value":0,"comment":"Defines if DER can reconnect after voltage ride-through disconnection","valid_range":{"max":1,"min":0}},{"name":"Trv","data_type":"Float64","null_value":0,"comment":"Voltage measurement transducer's time constant, in s","valid_range":{"max":null,"min":0}},{"name":"VV_pnts","data_type":"NamedTuple{(:V1, :V2, :V3, :V4), Tuple{Float64, Float64, Float64, Float64}}","null_value":"(V1=0.0, V2=0.0, V3=0.0, V4=0.0)","comment":"Y-axis Volt-var curve points (V1,V2,V3,V4)"},{"name":"Q_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Reactive power limits in pu (Q_min, Q_max)"},{"name":"Tp","data_type":"Float64","null_value":0,"comment":"Power measurement transducer's time constant, in s","valid_range":{"max":null,"min":0}},{"name":"e_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Error limit in PI controller for q control (e_min, e_max)"},{"name":"Kpq","data_type":"Float64","null_value":0,"comment":"PI controller proportional gain for q control","valid_range":{"max":null,"min":0}},{"name":"Kiq","data_type":"Float64","null_value":0,"comment":"PI controller integral gain for q control","valid_range":{"max":null,"min":0}},{"name":"Iqr_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Limit on rate of change for reactive current (pu/s) (Iqr_min, Iqr_max)"},{"name":"I_max","data_type":"Float64","null_value":0,"comment":"Max. inverter's current","valid_range":{"max":null,"min":0}},{"name":"Tg","data_type":"Float64","null_value":0,"comment":"Current control's time constant, in s","valid_range":{"max":null,"min":0}},{"name":"kWh_Cap","data_type":"Float64","null_value":0,"comment":"BESS capacity in kWh","valid_range":{"max":null,"min":0}},{"name":"SOC_ini","data_type":"Float64","null_value":0,"comment":"Initial state of charge (SOC) in pu","valid_range":{"max":1,"min":0}},{"name":"SOC_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Battery's SOC limits (SOC_min, SOC_max)"},{"name":"Trf","data_type":"Float64","null_value":0,"comment":"Time constant to estimate system frequency, in s","valid_range":{"max":null,"min":0}},{"name":"fdbd_pnts","data_type":"NamedTuple{(:fdbd1, :fdbd2), Tuple{Float64, Float64}}","null_value":"(fdbd1=0.0, fdbd2=0.0)","comment":"Frequency error dead band thresholds `(fdbd1, fdbd2)`"},{"name":"D_dn","data_type":"Float64","null_value":0,"comment":"reciprocal of droop for over-frequency conditions, in pu","valid_range":{"max":null,"min":0}},{"name":"D_up","data_type":"Float64","null_value":0,"comment":"reciprocal of droop for under-frequency conditions, in pu","valid_range":{"max":null,"min":0}},{"name":"fe_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Frequency error limits in pu (fe_min, fe_max)"},{"name":"Kpp","data_type":"Float64","null_value":0,"comment":"PI controller proportional gain for p control","valid_range":{"max":null,"min":0}},{"name":"Kip","data_type":"Float64","null_value":0,"comment":"PI controller integral gain for p control","valid_range":{"max":null,"min":0}},{"name":"P_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Active power limits in pu (P_min, P_max)"},{"name":"dP_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Ramp rate limits for active power in pu/s (dP_min, dP_max)"},{"name":"T_pord","data_type":"Float64","null_value":0,"comment":"Power filter time constant in s","valid_range":{"max":null,"min":0}},{"name":"rrpwr","data_type":"Float64","null_value":0,"comment":"Ramp rate for real power increase following a fault, in pu/s","valid_range":{"max":null,"min":0}},{"name":"VRT_pnts","data_type":"NamedTuple{(:vrt1, :vrt2, :vrt3, :vrt4, :vrt5), Tuple{Float64, Float64, Float64, Float64, Float64}}","null_value":"(vrt1=0.0, vrt2=0.0, vrt3=0.0, vrt4=0.0, vrt5=0.0)","comment":"Voltage ride through v points (vrt1,vrt2,vrt3,vrt4,vrt5)"},{"name":"TVRT_pnts","data_type":"NamedTuple{(:tvrt1, :tvrt2, :tvrt3), Tuple{Float64, Float64, Float64}}","null_value":"(tvrt1=0.0, tvrt2=0.0, tvrt3=0.0)","comment":"Voltage ride through time points (tvrt1,tvrt2,tvrt3)"},{"name":"tV_delay","data_type":"Float64","null_value":0,"comment":"Time delay for reconnection after voltage ride-through disconnection","valid_range":{"max":null,"min":0}},{"name":"VES_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Min and max voltage for entering service (VES_min,VES_max)"},{"name":"FRT_pnts","data_type":"NamedTuple{(:frt1, :frt2, :frt3, :frt4), Tuple{Float64, Float64, Float64, Float64}}","null_value":"(frt1=0.0, frt2=0.0, frt3=0.0, frt4=0.0)","comment":"Frequency ride through v points (frt1,frt2,frt3,frt4)"},{"name":"TFRT_pnts","data_type":"NamedTuple{(:tfrt1, :tfrt2), Tuple{Float64, Float64}}","null_value":"(tfrt1=0.0, tfrt2=0.0)","comment":"Frequency ride through time points (tfrt1,tfrt2)"},{"name":"tF_delay","data_type":"Float64","null_value":0,"comment":"Time delay for reconnection after frequency ride-through disconnection","valid_range":{"max":null,"min":0}},{"name":"FES_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Min and max frequency for entering service (FES_min,FES_max)"},{"name":"Pfa_ref","default":"0.0","data_type":"Float64","null_value":0,"comment":"Reference power factor","valid_range":{"max":null,"min":0}},{"name":"Q_ref","default":"0.0","data_type":"Float64","null_value":0,"comment":"Reference reactive power, in pu","valid_range":{"max":null,"min":0}},{"name":"P_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference active power, in pu","valid_range":{"max":null,"min":0}},{"name":"base_power","default":"100.0","data_type":"Float64","null_value":0,"comment":"Base power"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of GenericDER depend on the Flags","internal_default":"PowerSystems.get_GenericDER_states(Qref_Flag)[1]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"The states of GenericDER depend on the Flags","internal_default":"PowerSystems.get_GenericDER_states(Qref_Flag)[2]"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of a Generic Distributed Energy Resource Model. Based on https://scholarspace.manoa.hawaii.edu/bitstream/10125/70994/0304.pdf","struct_name":"GenericDER","supertype":"DynamicInjection"},{"fields":[{"name":"device"},{"name":"droop","data_type":"Float64","valid_range":{"max":null,"min":0}},{"name":"participation_factor","data_type":"UpDown"},{"name":"reserve_limit_dn","data_type":"Float64","valid_range":{"max":null,"min":0}},{"name":"reserve_limit_up","data_type":"Float64","valid_range":{"max":null,"min":0}},{"name":"inertia","data_type":"Float64","valid_range":{"max":null,"min":0}},{"name":"cost","data_type":"Float64","valid_range":{"max":null,"min":0}},{"name":"time_series_container","data_type":"InfrastructureSystems.TimeSeriesContainer"},{"name":"internal","data_type":"InfrastructureSystems.InfrastructureSystemsInternal"}],"struct_name":"RegulationDevice"}]} \ No newline at end of file diff --git a/dev/tutorials/threebus_sys.json b/dev/tutorials/threebus_sys.json index dfc5be4d7..37ec136f7 100644 --- a/dev/tutorials/threebus_sys.json +++ b/dev/tutorials/threebus_sys.json @@ -1 +1 @@ -{"internal":{"uuid":{"value":"5758fe7f-c347-4914-989e-fca1268404ea"},"ext":{},"units_info":null},"data":{"time_series_in_memory":false,"masked_components":[],"version_info":{"julia_version":"1.10.4","package_info":"Status `~/work/PowerSimulationsDynamics.jl/PowerSimulationsDynamics.jl/docs/Manifest.toml`\n [47edcb42] ADTypes v1.5.3\n [a4c015fc] ANSIColoredPrinters v0.0.1\n [1520ce14] AbstractTrees v0.4.5\n [7d9f7c33] Accessors v0.1.36\n [79e6a3ab] Adapt v4.0.4\n [ec485272] ArnoldiMethod v0.4.0\n [4fba245c] ArrayInterface v7.11.0\n [4c555306] ArrayLayouts v1.10.0\n [d1d4a3ce] BitFlags v0.1.9\n [62783981] BitTwiddlingConvenienceFunctions v0.1.6\n [a74b3585] Blosc v0.7.3\n [fa961155] CEnum v0.5.0\n [2a0fbf3d] CPUSummary v0.2.6\n [336ed68f] CSV v0.10.14\n [d360d2e6] ChainRulesCore v1.24.0\n [fb6a15b2] CloseOpenIntervals v0.1.13\n [944b1d66] CodecZlib v0.7.4\n [35d6a980] ColorSchemes v3.25.0\n [3da002f7] ColorTypes v0.11.5\n [c3611d14] ColorVectorSpace v0.10.0\n [5ae59095] Colors v0.12.11\n [38540f10] CommonSolve v0.2.4\n [bbf7d656] CommonSubexpressions v0.3.0\n [f70d9fcc] CommonWorldInvalidations v1.0.0\n [34da2185] Compat v4.15.0\n [a33af91c] CompositionsBase v0.1.2\n [2569d6c7] ConcreteStructs v0.2.3\n [f0e56b4a] ConcurrentUtilities v2.4.1\n [187b0558] ConstructionBase v1.5.5\n [d38c429a] Contour v0.6.3\n [adafc99b] CpuId v0.3.1\n [a8cc5b0e] Crayons v4.1.1\n [9a962f9c] DataAPI v1.16.0\n [a93c6f00] DataFrames v1.6.1\n [864edb3b] DataStructures v0.18.20\n [e2d170a0] DataValueInterfaces v1.0.0\n [8bb1440f] DelimitedFiles v1.9.1\n [2b5f629d] DiffEqBase v6.151.5\n [163ba53b] DiffResults v1.1.0\n [b552c78f] DiffRules v1.15.1\n [a0c0ee7d] DifferentiationInterface v0.5.7\n [b4f34e82] Distances v0.10.11\n [ffbed154] DocStringExtensions v0.9.3\n⌅ [e30172f5] Documenter v0.27.25\n [35a29f4d] DocumenterTools v0.1.19\n [4e289a0a] EnumX v1.0.4\n [f151be2c] EnzymeCore v0.7.6\n [460bff9d] ExceptionUnwrapping v0.1.10\n [d4d017d3] ExponentialUtilities v1.26.1\n [e2ba6199] ExprTools v0.1.10\n [c87230d0] FFMPEG v0.4.1\n [7034ab61] FastBroadcast v0.3.4\n [9aa1b823] FastClosures v0.3.2\n [29a986be] FastLapackInterface v2.0.4\n [48062228] FilePathsBase v0.9.21\n [1a297f60] FillArrays v1.11.0\n [6a86dc24] FiniteDiff v2.23.1\n [53c48c17] FixedPointNumbers v0.8.5\n [1fa38f19] Format v1.3.7\n [f6369f11] ForwardDiff v0.10.36\n [069b7b12] FunctionWrappers v1.1.3\n [77dc65aa] FunctionWrappersWrappers v0.1.3\n [46192b85] GPUArraysCore v0.1.6\n⌃ [28b8d3ca] GR v0.73.5\n [c145ed77] GenericSchur v0.5.4\n [86223c79] Graphs v1.11.2\n [42e2da0e] Grisu v1.0.2\n [708ec375] Gumbo v0.8.2\n [c8ec2601] H5Zblosc v0.1.2\n [f67ccb44] HDF5 v0.17.2\n [cd3eb016] HTTP v1.10.8\n [3e5b6fbb] HostCPUFeatures v0.1.17\n [b5f81e59] IOCapture v0.2.5\n [615f187c] IfElse v0.1.1\n [d25df0c9] Inflate v0.1.5\n⌅ [2cd47ed4] InfrastructureSystems v1.22.2\n [842dd82b] InlineStrings v1.4.1\n [3587e190] InverseFunctions v0.1.14\n [41ab1584] InvertedIndices v1.3.0\n [92d709cd] IrrationalConstants v0.2.2\n [82899510] IteratorInterfaceExtensions v1.0.0\n [1019f520] JLFzf v0.1.7\n [692b3bcd] JLLWrappers v1.5.0\n [682c06a0] JSON v0.21.4\n [0f8b85d8] JSON3 v1.14.0\n [ef3ab10e] KLU v0.6.0\n [ba0b0d4f] Krylov v0.9.6\n [b964fa9f] LaTeXStrings v1.3.1\n [23fbe1c1] Latexify v0.16.3\n [10f19ff3] LayoutPointers v0.1.17\n [5078a376] LazyArrays v2.1.1\n [1d6d02ad] LeftChildRightSiblingTrees v0.2.0\n [d3d80556] LineSearches v7.2.0\n [7ed4a6bd] LinearSolve v2.30.2\n [2ab3a3ac] LogExpFunctions v0.3.28\n [e6f89c97] LoggingExtras v1.0.3\n [bdcacae8] LoopVectorization v0.12.171\n⌅ [33e6dc65] MKL v0.6.3\n [3da0fdf6] MPIPreferences v0.1.11\n [1914dd2f] MacroTools v0.5.13\n [d125e4d3] ManualMemory v0.1.8\n [299715c1] MarchingCubes v0.1.9\n [bb5d69b7] MaybeInplace v0.1.3\n [739be429] MbedTLS v1.1.9\n [442fdcdd] Measures v0.3.2\n [e1d29d7a] Missings v1.2.0\n [46d2c3a1] MuladdMacro v0.2.4\n [ffc61752] Mustache v1.0.19\n [d41bc354] NLSolversBase v7.8.3\n [2774e3e8] NLsolve v4.5.1\n [77ba4419] NaNMath v1.0.2\n [8913a72c] NonlinearSolve v3.13.1\n [6fe1bfb0] OffsetArrays v1.14.0\n [4d8831e6] OpenSSL v1.4.3\n [bac558e1] OrderedCollections v1.6.3\n [1dea7af3] OrdinaryDiffEq v6.85.0\n [65ce6f38] PackageExtensionCompat v1.0.2\n [d96e819e] Parameters v0.12.3\n [46dd5b70] Pardiso v0.5.7\n [69de0a69] Parsers v2.8.1\n [b98c9c47] Pipe v1.3.0\n [ccf2f8ad] PlotThemes v3.2.0\n [995b91a9] PlotUtils v1.4.1\n [91a5bcdd] Plots v1.40.4\n [f517fe37] Polyester v0.7.15\n [1d0040c9] PolyesterWeave v0.2.2\n [2dfb63ee] PooledArrays v1.4.3\n [dd99e9e3] PowerFlowData v1.5.0\n [94fada2c] PowerFlows v0.6.2\n⌅ [bed98974] PowerNetworkMatrices v0.10.3\n [398b2ede] PowerSimulationsDynamics v0.14.2 `~/work/PowerSimulationsDynamics.jl/PowerSimulationsDynamics.jl`\n⌃ [f00506e0] PowerSystemCaseBuilder v1.2.5\n⌅ [bcd98974] PowerSystems v3.3.0\n [d236fae5] PreallocationTools v0.4.22\n [aea7be01] PrecompileTools v1.2.1\n [21216c6a] Preferences v1.4.3\n [08abe8d2] PrettyTables v2.3.2\n [33c8b6b6] ProgressLogging v0.1.4\n [3cdcf5f2] RecipesBase v1.3.4\n [01d81517] RecipesPipeline v0.6.12\n [731186ca] RecursiveArrayTools v3.23.1\n [f2c3362d] RecursiveFactorization v0.2.23\n [189a3867] Reexport v1.2.2\n [05181044] RelocatableFolders v1.0.1\n [ae029012] Requires v1.3.0\n [7e49a35a] RuntimeGeneratedFunctions v0.5.13\n [94e857df] SIMDTypes v0.1.0\n [476501e8] SLEEFPirates v0.6.43\n [322a6be2] Sass v0.2.0\n [0bca4576] SciMLBase v2.42.0\n [c0aeaf25] SciMLOperators v0.3.8\n [53ae85a6] SciMLStructures v1.4.1\n [6c6a2e73] Scratch v1.2.1\n [91c51154] SentinelArrays v1.4.3\n [efcf1570] Setfield v1.1.1\n [992d4aef] Showoff v1.0.3\n [777ac1f9] SimpleBufferStream v1.1.0\n [727e6d20] SimpleNonlinearSolve v1.10.1\n [699a6c99] SimpleTraits v0.9.4\n [ce78b400] SimpleUnPack v1.1.0\n [a2af1166] SortingAlgorithms v1.2.1\n [47a9eef4] SparseDiffTools v2.19.0\n [0a514795] SparseMatrixColorings v0.3.3\n [e56a9233] Sparspak v0.3.9\n [276daf66] SpecialFunctions v2.4.0\n [aedffcd0] Static v1.1.0\n [0d7ed370] StaticArrayInterface v1.5.1\n [90137ffa] StaticArrays v1.9.6\n [1e83bf80] StaticArraysCore v1.4.3\n [82ae8749] StatsAPI v1.7.0\n [2913bbd2] StatsBase v0.34.3\n [7792a7ef] StrideArraysCore v0.5.7\n [69024149] StringEncodings v0.3.7\n [892a3eda] StringManipulation v0.3.4\n [856f2bd8] StructTypes v1.10.0\n [c3572dad] Sundials v4.24.0\n [2efcf032] SymbolicIndexingInterface v0.3.22\n [3783bdb8] TableTraits v1.0.1\n [bd369af6] Tables v1.11.1\n [62fd8b95] TensorCore v0.1.1\n [5d786b92] TerminalLoggers v0.1.7\n [8290d209] ThreadingUtilities v0.5.2\n⌅ [9e3dc215] TimeSeries v0.23.2\n [a759f4b9] TimerOutputs v0.5.24\n⌅ [3bb67fe8] TranscodingStreams v0.10.10\n [d5829a12] TriangularSolve v0.2.1\n [410a4b4d] Tricks v0.1.8\n [781d530d] TruncatedStacktraces v1.4.0\n [5c2747f8] URIs v1.5.1\n [3a884ed6] UnPack v1.0.2\n [1cfade01] UnicodeFun v0.4.1\n [b8865327] UnicodePlots v3.6.4\n [1986cc42] Unitful v1.20.0\n [45397f5d] UnitfulLatexify v1.6.3\n [41fe7b60] Unzip v0.2.0\n [3d5dd08c] VectorizationBase v0.21.70\n [19fa3120] VertexSafeGraphs v0.2.0\n [ea10d353] WeakRefStrings v1.4.2\n [76eceee3] WorkerUtilities v1.6.1\n [ddb6d928] YAML v0.4.11\n [0b7ba130] Blosc_jll v1.21.5+0\n [6e34b625] Bzip2_jll v1.0.8+1\n [83423d85] Cairo_jll v1.18.0+2\n [2702e6a9] EpollShim_jll v0.0.20230411+0\n [2e619515] Expat_jll v2.6.2+0\n⌅ [b22a6f82] FFMPEG_jll v4.4.2+2\n [a3f928ae] Fontconfig_jll v2.13.96+0\n [d7e528f0] FreeType2_jll v2.13.2+0\n [559328eb] FriBidi_jll v1.0.14+0\n [0656b61e] GLFW_jll v3.4.0+0\n⌅ [d2c73de3] GR_jll v0.73.5+0\n [78b55507] Gettext_jll v0.21.0+0\n [7746bdde] Glib_jll v2.80.2+0\n [3b182d85] Graphite2_jll v1.3.14+0\n [528830af] Gumbo_jll v0.10.2+0\n⌃ [0234f1f7] HDF5_jll v1.12.2+2\n [2e76f6c2] HarfBuzz_jll v2.8.1+1\n [1d5cc7b8] IntelOpenMP_jll v2024.1.0+0\n [aacddb02] JpegTurbo_jll v3.0.3+0\n [c1c5ebd0] LAME_jll v3.100.2+0\n⌅ [88015f11] LERC_jll v3.0.0+1\n [1d63c593] LLVMOpenMP_jll v15.0.7+0\n [dd4b983a] LZO_jll v2.10.2+0\n⌅ [e9f186c6] Libffi_jll v3.2.2+1\n [d4300ac3] Libgcrypt_jll v1.8.11+0\n [7e76a0d4] Libglvnd_jll v1.6.0+0\n [7add5ba3] Libgpg_error_jll v1.49.0+0\n [94ce4f54] Libiconv_jll v1.17.0+0\n [4b2f31a3] Libmount_jll v2.40.1+0\n⌅ [89763e89] Libtiff_jll v4.5.1+1\n [38a345b3] Libuuid_jll v2.40.1+0\n [5ced341a] Lz4_jll v1.9.4+0\n [856f044c] MKL_jll v2024.1.0+0\n [e7412a2a] Ogg_jll v1.3.5+1\n⌅ [9bd350c2] OpenSSH_jll v8.9.0+1\n⌅ [458c3c95] OpenSSL_jll v1.1.23+0\n [efe28fd5] OpenSpecFun_jll v0.5.5+0\n [91d4177d] Opus_jll v1.3.2+0\n [30392449] Pixman_jll v0.43.4+0\n⌅ [c0090381] Qt6Base_jll v6.5.2+2\n⌅ [fb77eaff] Sundials_jll v5.2.2+0\n [a44049a8] Vulkan_Loader_jll v1.3.243+0\n [a2964d1f] Wayland_jll v1.21.0+1\n [2381bf8a] Wayland_protocols_jll v1.31.0+0\n [02c8fc9c] XML2_jll v2.13.1+0\n [aed1982a] XSLT_jll v1.1.41+0\n [ffd25f8a] XZ_jll v5.4.6+0\n [f67eecfb] Xorg_libICE_jll v1.1.1+0\n [c834827a] Xorg_libSM_jll v1.2.4+0\n [4f6342f7] Xorg_libX11_jll v1.8.6+0\n [0c0b7dd1] Xorg_libXau_jll v1.0.11+0\n [935fb764] Xorg_libXcursor_jll v1.2.0+4\n [a3789734] Xorg_libXdmcp_jll v1.1.4+0\n [1082639a] Xorg_libXext_jll v1.3.6+0\n [d091e8ba] Xorg_libXfixes_jll v5.0.3+4\n [a51aa0fd] Xorg_libXi_jll v1.7.10+4\n [d1454406] Xorg_libXinerama_jll v1.1.4+4\n [ec84b674] Xorg_libXrandr_jll v1.5.2+4\n [ea2f1a96] Xorg_libXrender_jll v0.9.11+0\n [14d82f49] Xorg_libpthread_stubs_jll v0.1.1+0\n [c7cfdc94] Xorg_libxcb_jll v1.17.0+0\n [cc61e674] Xorg_libxkbfile_jll v1.1.2+0\n [e920d4aa] Xorg_xcb_util_cursor_jll v0.1.4+0\n [12413925] Xorg_xcb_util_image_jll v0.4.0+1\n [2def613f] Xorg_xcb_util_jll v0.4.0+1\n [975044d2] Xorg_xcb_util_keysyms_jll v0.4.0+1\n [0d47668e] Xorg_xcb_util_renderutil_jll v0.3.9+1\n [c22f9ab0] Xorg_xcb_util_wm_jll v0.4.1+1\n [35661453] Xorg_xkbcomp_jll v1.4.6+0\n [33bec58e] Xorg_xkeyboard_config_jll v2.39.0+0\n [c5fb5394] Xorg_xtrans_jll v1.5.0+0\n [3161d3a3] Zstd_jll v1.5.6+0\n [35ca27e7] eudev_jll v3.2.9+0\n⌅ [214eeab7] fzf_jll v0.43.0+0\n [1a1c6b14] gperf_jll v3.1.1+0\n [a4ae2306] libaom_jll v3.9.0+0\n [0ac62f75] libass_jll v0.15.1+0\n [2db6ffa8] libevdev_jll v1.11.0+0\n [f638f0a6] libfdk_aac_jll v2.0.2+0\n [36db933b] libinput_jll v1.18.0+0\n [b53b4c65] libpng_jll v1.6.43+1\n [47bcb7c8] libsass_jll v3.6.6+0\n [f27f6e37] libvorbis_jll v1.3.7+1\n [009596ad] mtdev_jll v1.1.6+0\n [1317d2d5] oneTBB_jll v2021.12.0+0\n [1270edf5] x264_jll v2021.5.5+0\n [dfaa095f] x265_jll v3.5.0+0\n [d8fb68d0] xkbcommon_jll v1.4.1+1\n [0dad84c5] ArgTools v1.1.1\n [56f22d72] Artifacts\n [2a0f44e3] Base64\n [ade2ca70] Dates\n [8ba89e20] Distributed\n [f43a241f] Downloads v1.6.0\n [7b1f6079] FileWatching\n [9fa8497b] Future\n [b77e0a4c] InteractiveUtils\n [4af54fe1] LazyArtifacts\n [b27032c2] LibCURL v0.6.4\n [76f85450] LibGit2\n [8f399da3] Libdl\n [37e2e46d] LinearAlgebra\n [56ddb016] Logging\n [d6f4376e] Markdown\n [a63ad114] Mmap\n [ca575930] NetworkOptions v1.2.0\n [44cfe95a] Pkg v1.10.0\n [de0858da] Printf\n [3fa0cd96] REPL\n [9a3f8284] Random\n [ea8e919c] SHA v0.7.0\n [9e88b42a] Serialization\n [1a1011a3] SharedArrays\n [6462fe0b] Sockets\n [2f01184e] SparseArrays v1.10.0\n [10745b16] Statistics v1.10.0\n [4607b0f0] SuiteSparse\n [fa267f1f] TOML v1.0.3\n [a4e569a6] Tar v1.10.0\n [8dfed614] Test\n [cf7118a7] UUIDs\n [4ec0a83e] Unicode\n [e66e0078] CompilerSupportLibraries_jll v1.1.1+0\n [deac9b47] LibCURL_jll v8.4.0+0\n [e37daf67] LibGit2_jll v1.6.4+0\n [29816b5a] LibSSH2_jll v1.11.0+1\n [c8ffd9c3] MbedTLS_jll v2.28.2+1\n [14a3606d] MozillaCACerts_jll v2023.1.10\n [4536629a] OpenBLAS_jll v0.3.23+4\n [05823500] OpenLibm_jll v0.8.1+2\n [efcefdf7] PCRE2_jll v10.42.0+1\n [bea87d4a] SuiteSparse_jll v7.2.1+1\n [83775a58] Zlib_jll v1.2.13+1\n [8e850b90] libblastrampoline_jll v5.8.0+1\n [8e850ede] nghttp2_jll v1.52.0+1\n [3f19e933] p7zip_jll v17.4.0+2\nInfo Packages marked with ⌃ and ⌅ have new versions available. Those with ⌃ may be upgradable, but those with ⌅ are restricted by compatibility constraints from upgrading. To see why use `status --outdated -m`\n"},"internal":{"uuid":{"value":"20814d40-f8d1-448f-b8d2-8192586ef21f"},"ext":{},"units_info":null},"time_series_compression_enabled":false,"components":[{"__metadata__":{"module":"PowerSystems","type":"LoadZone"},"name":"1","internal":{"uuid":{"value":"2816a137-159f-47d5-952c-163696eb16c0"},"ext":null,"units_info":null},"peak_active_power":1.8,"peak_reactive_power":0.5,"time_series_container":[]},{"load_response":0.0,"name":"1","__metadata__":{"module":"PowerSystems","type":"Area"},"internal":{"uuid":{"value":"81231acb-8b76-414d-bb8e-905683066f93"},"ext":null,"units_info":null},"peak_active_power":0.0,"peak_reactive_power":0.0,"time_series_container":[]},{"number":103,"base_voltage":138.0,"bustype":"PV","angle":0.0,"name":"BUS 3","magnitude":1.0059,"__metadata__":{"module":"PowerSystems","type":"ACBus"},"internal":{"uuid":{"value":"bd007418-2e3a-4e42-9ffe-76e5c14efc15"},"ext":null,"units_info":null},"area":{"value":"81231acb-8b76-414d-bb8e-905683066f93"},"ext":{},"voltage_limits":{"min":0.9,"max":1.1},"load_zone":{"value":"2816a137-159f-47d5-952c-163696eb16c0"}},{"number":101,"base_voltage":138.0,"bustype":"REF","angle":0.0,"name":"BUS 1","magnitude":1.02,"__metadata__":{"module":"PowerSystems","type":"ACBus"},"internal":{"uuid":{"value":"07c823a5-975e-4f26-bc45-1bf95fca708b"},"ext":null,"units_info":null},"area":{"value":"81231acb-8b76-414d-bb8e-905683066f93"},"ext":{},"voltage_limits":{"min":0.9,"max":1.1},"load_zone":{"value":"2816a137-159f-47d5-952c-163696eb16c0"}},{"number":102,"base_voltage":138.0,"bustype":"PV","angle":0.0,"name":"BUS 2","magnitude":1.0142,"__metadata__":{"module":"PowerSystems","type":"ACBus"},"internal":{"uuid":{"value":"3337efc0-ac1d-45d6-8c90-6eee41a01bc7"},"ext":null,"units_info":null},"area":{"value":"81231acb-8b76-414d-bb8e-905683066f93"},"ext":{},"voltage_limits":{"min":0.9,"max":1.1},"load_zone":{"value":"2816a137-159f-47d5-952c-163696eb16c0"}},{"internal_voltage":1.0,"services":[],"bus":{"value":"d2754af5-8685-45c7-a870-863a0d2e47d6"},"available":true,"name":"InfBus","internal_angle":0.0,"active_power":0.0,"dynamic_injector":null,"__metadata__":{"module":"PowerSystems","type":"Source"},"internal":{"uuid":{"value":"bc626e71-ec6c-4973-8430-b64db1099bec"},"ext":null,"units_info":null},"ext":{},"X_th":5.0e-6,"R_th":0.0,"reactive_power":0.0},{"internal":{"uuid":{"value":"fc81f226-8f3f-4d42-b9bd-8f08ee94e86c"},"ext":null,"units_info":null},"to":{"value":"bd007418-2e3a-4e42-9ffe-76e5c14efc15"},"from":{"value":"07c823a5-975e-4f26-bc45-1bf95fca708b"},"__metadata__":{"module":"PowerSystems","type":"Arc"}},{"internal":{"uuid":{"value":"fd428f99-50fd-432f-92d0-faa30a5ebca3"},"ext":null,"units_info":null},"to":{"value":"3337efc0-ac1d-45d6-8c90-6eee41a01bc7"},"from":{"value":"07c823a5-975e-4f26-bc45-1bf95fca708b"},"__metadata__":{"module":"PowerSystems","type":"Arc"}},{"internal":{"uuid":{"value":"ef76b8d2-1ec3-4f5f-9ac7-fc04b776383b"},"ext":null,"units_info":null},"to":{"value":"bd007418-2e3a-4e42-9ffe-76e5c14efc15"},"from":{"value":"3337efc0-ac1d-45d6-8c90-6eee41a01bc7"},"__metadata__":{"module":"PowerSystems","type":"Arc"}},{"base_power":100.0,"filter":{"rg":0.01,"cf":0.074,"n_states":6,"ext":{},"lf":0.08,"lg":0.2,"states":["ir_cnv","ii_cnv","vr_filter","vi_filter","ir_filter","ii_filter"],"rf":0.003,"__metadata__":{"module":"PowerSystems","type":"LCLFilter"}},"states":["θ_oc","ω_oc","q_oc","ξd_ic","ξq_ic","γd_ic","γq_ic","ϕd_ic","ϕq_ic","vd_pll","vq_pll","ε_pll","θ_pll","ir_cnv","ii_cnv","vr_filter","vi_filter","ir_filter","ii_filter"],"dc_source":{"__metadata__":{"module":"PowerSystems","type":"FixedDCSource"},"internal":{"uuid":{"value":"b35d21fb-6021-4fae-bac0-81f860074fde"},"ext":null,"units_info":null},"n_states":0,"ext":{},"states":[],"voltage":600.0},"name":"generator-103-1","converter":{"rated_voltage":138.0,"n_states":0,"ext":{},"rated_current":100.0,"states":[],"__metadata__":{"module":"PowerSystems","type":"AverageConverter"}},"n_states":19,"ω_ref":1.0,"__metadata__":{"parameters":["AverageConverter","OuterControl","VoltageModeControl","FixedDCSource","KauraPLL","LCLFilter","Nothing"],"module":"PowerSystems","type":"DynamicInverter"},"internal":{"uuid":{"value":"b74f84d3-877a-47e2-870c-b0dac083e59c"},"ext":null,"units_info":null},"ext":{},"outer_control":{"active_power_control":{"__metadata__":{"module":"PowerSystems","type":"VirtualInertia"},"P_ref":1.0,"kω":20.0,"n_states":2,"ext":{},"states":["θ_oc","ω_oc"],"kd":400.0,"Ta":2.0},"reactive_power_control":{"kq":0.2,"n_states":1,"ext":{},"V_ref":1.0,"ωf":1000.0,"states":["q_oc"],"__metadata__":{"module":"PowerSystems","type":"ReactivePowerDroop"}},"n_states":3,"ext":{},"states":["θ_oc","ω_oc","q_oc"],"__metadata__":{"parameters":["VirtualInertia","ReactivePowerDroop"],"module":"PowerSystems","type":"OuterControl"}},"freq_estimator":{"ω_lp":500.0,"n_states":4,"ki_pll":4.69,"ext":{},"kp_pll":0.084,"states":["vd_pll","vq_pll","ε_pll","θ_pll"],"__metadata__":{"module":"PowerSystems","type":"KauraPLL"}},"inner_control":{"rv":0.0,"lv":0.2,"ωad":50.0,"kpc":1.27,"ext":{},"states":["ξd_ic","ξq_ic","γd_ic","γq_ic","ϕd_ic","ϕq_ic"],"kffi":0.0,"kffv":0.0,"n_states":6,"kpv":0.59,"kiv":736.0,"kad":0.2,"kic":14.3,"__metadata__":{"module":"PowerSystems","type":"VoltageModeControl"}},"limiter":null},{"base_power":100.0,"services":[],"bus":{"value":"07c823a5-975e-4f26-bc45-1bf95fca708b"},"max_constant_active_power":0.5,"available":true,"time_series_container":[],"name":"load1011","max_current_active_power":0.0,"constant_active_power":0.5,"dynamic_injector":null,"__metadata__":{"module":"PowerSystems","type":"StandardLoad"},"current_active_power":0.0,"current_reactive_power":0.0,"internal":{"uuid":{"value":"4989f1ad-fa5e-4cbb-ad98-eec2b357e269"},"ext":null,"units_info":null},"ext":{},"max_constant_reactive_power":0.1,"max_current_reactive_power":0.0,"impedance_reactive_power":0.0,"impedance_active_power":0.0,"max_impedance_active_power":0.0,"constant_reactive_power":0.1,"max_impedance_reactive_power":0.0},{"base_power":100.0,"services":[],"bus":{"value":"bd007418-2e3a-4e42-9ffe-76e5c14efc15"},"max_constant_active_power":0.3,"available":true,"time_series_container":[],"name":"load1031","max_current_active_power":0.0,"constant_active_power":0.3,"dynamic_injector":null,"__metadata__":{"module":"PowerSystems","type":"StandardLoad"},"current_active_power":0.0,"current_reactive_power":0.0,"internal":{"uuid":{"value":"6394b761-4f15-46f5-973b-357552a251b6"},"ext":null,"units_info":null},"ext":{},"max_constant_reactive_power":0.1,"max_current_reactive_power":0.0,"impedance_reactive_power":0.0,"impedance_active_power":0.0,"max_impedance_active_power":0.0,"constant_reactive_power":0.1,"max_impedance_reactive_power":0.0},{"base_power":100.0,"services":[],"bus":{"value":"3337efc0-ac1d-45d6-8c90-6eee41a01bc7"},"max_constant_active_power":1.0,"available":true,"time_series_container":[],"name":"load1021","max_current_active_power":0.0,"constant_active_power":1.0,"dynamic_injector":null,"__metadata__":{"module":"PowerSystems","type":"StandardLoad"},"current_active_power":0.0,"current_reactive_power":0.0,"internal":{"uuid":{"value":"c55d0322-877e-4232-9737-b8fa7e480ed6"},"ext":null,"units_info":null},"ext":{},"max_constant_reactive_power":0.3,"max_current_reactive_power":0.0,"impedance_reactive_power":0.0,"impedance_active_power":0.0,"max_impedance_active_power":0.0,"constant_reactive_power":0.3,"max_impedance_reactive_power":0.0},{"services":[],"x":0.12,"b":{"from":0.1,"to":0.1},"r":0.01,"rate":2.5,"available":true,"time_series_container":[],"name":"BUS 1-BUS 3-i_1","reactive_power_flow":0.0,"arc":{"value":"fc81f226-8f3f-4d42-b9bd-8f08ee94e86c"},"__metadata__":{"module":"PowerSystems","type":"Line"},"internal":{"uuid":{"value":"99a6b1b5-bc56-4a98-90ee-e9e306afdfb4"},"ext":null,"units_info":null},"ext":{},"active_power_flow":0.0,"angle_limits":{"min":-1.0472,"max":1.0472}},{"services":[],"x":0.12,"b":{"from":0.1,"to":0.1},"r":0.01,"rate":2.5,"available":true,"time_series_container":[],"name":"BUS 1-BUS 2-i_1","reactive_power_flow":0.0,"arc":{"value":"fd428f99-50fd-432f-92d0-faa30a5ebca3"},"__metadata__":{"module":"PowerSystems","type":"Line"},"internal":{"uuid":{"value":"e69efbd3-0c36-409e-9254-2ef85e6ee997"},"ext":null,"units_info":null},"ext":{},"active_power_flow":0.0,"angle_limits":{"min":-1.0472,"max":1.0472}},{"services":[],"x":0.9,"b":{"from":0.5,"to":0.5},"r":0.02,"rate":2.5,"available":true,"time_series_container":[],"name":"BUS 2-BUS 3-i_1","reactive_power_flow":0.0,"arc":{"value":"ef76b8d2-1ec3-4f5f-9ac7-fc04b776383b"},"__metadata__":{"module":"PowerSystems","type":"Line"},"internal":{"uuid":{"value":"40529c82-ba4b-465a-a841-37108672df1f"},"ext":null,"units_info":null},"ext":{},"active_power_flow":0.0,"angle_limits":{"min":-1.0472,"max":1.0472}},{"base_power":100.0,"shaft":{"internal":{"uuid":{"value":"effd620d-32e8-4311-811f-1c48572ec625"},"ext":null,"units_info":null},"n_states":2,"ext":{},"D":0.0,"states":["δ","ω"],"H":3.01,"__metadata__":{"module":"PowerSystems","type":"SingleMass"}},"states":["eq_p","ed_p","δ","ω","Vf","Vr1","Vr2","Vm"],"name":"generator-102-1","n_states":8,"ω_ref":1.0,"__metadata__":{"parameters":["OneDOneQMachine","SingleMass","AVRTypeI","TGFixed","PSSFixed"],"module":"PowerSystems","type":"DynamicGenerator"},"avr":{"Ta":0.2,"Te":0.314,"states_types":["Differential","Differential","Differential","Differential"],"__metadata__":{"module":"PowerSystems","type":"AVRTypeI"},"internal":{"uuid":{"value":"454709ab-eaa8-45a1-a6cf-9f76a8539384"},"ext":null,"units_info":null},"Ke":0.01,"ext":{},"Kf":0.063,"V_ref":1.0,"states":["Vf","Vr1","Vr2","Vm"],"Ae":0.0039,"n_states":4,"Tf":0.35,"Tr":0.001,"Va_lim":{"min":-5.0,"max":5.0},"Be":1.555,"Ka":20.0},"internal":{"uuid":{"value":"ad50a6fe-5765-4d50-b1e8-13bdaf05b9ec"},"ext":null,"units_info":null},"ext":{},"machine":{"internal":{"uuid":{"value":"364de0f6-4fc4-4431-bd11-e47746a203df"},"ext":null,"units_info":null},"Xq":1.2578,"ext":{},"states":["eq_p","ed_p"],"Tq0_p":0.6,"n_states":2,"Xd":1.3125,"Xd_p":0.1813,"Xq_p":0.25,"Td0_p":5.89,"R":0.0,"__metadata__":{"module":"PowerSystems","type":"OneDOneQMachine"}},"pss":{"V_pss":0.0,"internal":{"uuid":{"value":"b59c08ad-8b35-493c-bd0c-657e6f633889"},"ext":null,"units_info":null},"n_states":0,"ext":{},"states":[],"__metadata__":{"module":"PowerSystems","type":"PSSFixed"}},"prime_mover":{"P_ref":1.0,"internal":{"uuid":{"value":"ea98464c-1e4f-4c31-bfe3-e64ad7be7bba"},"ext":null,"units_info":null},"efficiency":1.0,"n_states":0,"ext":{},"states":[],"__metadata__":{"module":"PowerSystems","type":"TGFixed"}}},{"base_power":100.0,"prime_mover_type":"OT","rating":3.333526661060325,"services":[],"bus":{"value":"3337efc0-ac1d-45d6-8c90-6eee41a01bc7"},"available":true,"time_series_container":[],"name":"generator-102-1","status":true,"active_power":0.7,"dynamic_injector":{"value":"ad50a6fe-5765-4d50-b1e8-13bdaf05b9ec"},"__metadata__":{"module":"PowerSystems","type":"ThermalStandard"},"fuel":"OTHER","internal":{"uuid":{"value":"8dbea365-c0e7-4519-9f19-8d642ab706d0"},"ext":null,"units_info":null},"reactive_power_limits":{"min":-1.0,"max":1.0},"ext":{"z_source":{"x":1,"r":0}},"operation_cost":{"start_up":0.0,"fixed":0.0,"shut_down":0.0,"variable":{"cost":[0.0,1.0]},"__metadata__":{"module":"PowerSystems","type":"ThreePartCost"}},"time_limits":null,"must_run":false,"ramp_limits":{"up":3.18,"down":3.18},"time_at_status":10000.0,"active_power_limits":{"min":0.0,"max":3.18},"reactive_power":0.0},{"base_power":100.0,"prime_mover_type":"OT","rating":3.333526661060325,"services":[],"bus":{"value":"bd007418-2e3a-4e42-9ffe-76e5c14efc15"},"available":true,"time_series_container":[],"name":"generator-103-1","status":true,"active_power":0.8,"dynamic_injector":{"value":"b74f84d3-877a-47e2-870c-b0dac083e59c"},"__metadata__":{"module":"PowerSystems","type":"ThermalStandard"},"fuel":"OTHER","internal":{"uuid":{"value":"c24b6f03-6344-49f4-a197-e3221e6309af"},"ext":null,"units_info":null},"reactive_power_limits":{"min":-1.0,"max":1.0},"ext":{"z_source":{"x":1,"r":0}},"operation_cost":{"start_up":0.0,"fixed":0.0,"shut_down":0.0,"variable":{"cost":[0.0,1.0]},"__metadata__":{"module":"PowerSystems","type":"ThreePartCost"}},"time_limits":null,"must_run":false,"ramp_limits":{"up":3.18,"down":3.18},"time_at_status":10000.0,"active_power_limits":{"min":0.0,"max":3.18},"reactive_power":0.0}],"validation_descriptor_file":"threebus_sys_validation_descriptors.json","time_series_params":{"__metadata__":{"module":"InfrastructureSystems","type":"TimeSeriesParameters"},"resolution":{"value":0,"type":"Minute"},"forecast_params":{"initial_timestamp":"0001-01-01T00:00:00.0","interval":{"value":0,"type":"Minute"},"horizon":0,"count":0,"__metadata__":{"module":"InfrastructureSystems","type":"ForecastParameters"}}}},"units_settings":{"base_value":100.0,"unit_system":"SYSTEM_BASE"},"frequency":60.0,"runchecks":true,"metadata":{"name":null,"description":null,"__metadata__":{"module":"PowerSystems","type":"SystemMetadata"}},"data_format_version":"3.0.0"} \ No newline at end of file +{"internal":{"uuid":{"value":"b5becb8b-f141-4365-8577-36a74ba0cf16"},"ext":{},"units_info":null},"data":{"masked_components":[],"supplemental_attribute_manager":{"attributes":[],"associations":[]},"internal":{"uuid":{"value":"32988bf8-3cd7-4276-8e30-6747604bec65"},"ext":{},"units_info":null},"time_series_compression_enabled":false,"components":[{"base_power":100.0,"filter":{"rg":0.01,"cf":0.074,"n_states":6,"ext":{},"lf":0.08,"lg":0.2,"states":["ir_cnv","ii_cnv","vr_filter","vi_filter","ir_filter","ii_filter"],"rf":0.003,"__metadata__":{"module":"PowerSystems","type":"LCLFilter"}},"states":["θ_oc","ω_oc","q_oc","ξd_ic","ξq_ic","γd_ic","γq_ic","ϕd_ic","ϕq_ic","vd_pll","vq_pll","ε_pll","θ_pll","ir_cnv","ii_cnv","vr_filter","vi_filter","ir_filter","ii_filter"],"dc_source":{"__metadata__":{"module":"PowerSystems","type":"FixedDCSource"},"internal":{"uuid":{"value":"e0241068-1efe-480b-ab64-dc09e75e6876"},"ext":null,"units_info":null},"n_states":0,"ext":{},"states":[],"voltage":600.0},"name":"generator-103-1","converter":{"rated_voltage":138.0,"n_states":0,"ext":{},"rated_current":100.0,"states":[],"__metadata__":{"module":"PowerSystems","type":"AverageConverter"}},"n_states":19,"ω_ref":1.0,"__metadata__":{"parameters":["AverageConverter","OuterControl","VoltageModeControl","FixedDCSource","KauraPLL","LCLFilter","Nothing"],"module":"PowerSystems","type":"DynamicInverter"},"internal":{"uuid":{"value":"e730d0f8-db26-44b6-8840-e57003912739"},"ext":null,"units_info":null},"ext":{},"outer_control":{"active_power_control":{"__metadata__":{"module":"PowerSystems","type":"VirtualInertia"},"P_ref":1.0,"kω":20.0,"n_states":2,"ext":{},"states":["θ_oc","ω_oc"],"kd":400.0,"Ta":2.0},"reactive_power_control":{"kq":0.2,"n_states":1,"ext":{},"V_ref":1.0,"ωf":1000.0,"states":["q_oc"],"__metadata__":{"module":"PowerSystems","type":"ReactivePowerDroop"}},"n_states":3,"ext":{},"states":["θ_oc","ω_oc","q_oc"],"__metadata__":{"parameters":["VirtualInertia","ReactivePowerDroop"],"module":"PowerSystems","type":"OuterControl"}},"freq_estimator":{"ω_lp":500.0,"n_states":4,"ki_pll":4.69,"ext":{},"kp_pll":0.084,"states":["vd_pll","vq_pll","ε_pll","θ_pll"],"__metadata__":{"module":"PowerSystems","type":"KauraPLL"}},"inner_control":{"rv":0.0,"lv":0.2,"ωad":50.0,"kpc":1.27,"ext":{},"states":["ξd_ic","ξq_ic","γd_ic","γq_ic","ϕd_ic","ϕq_ic"],"kffi":0.0,"kffv":0.0,"n_states":6,"kpv":0.59,"kiv":736.0,"kad":0.2,"kic":14.3,"__metadata__":{"module":"PowerSystems","type":"VoltageModeControl"}},"limiter":null},{"number":103,"base_voltage":138.0,"bustype":"PV","angle":0.0,"name":"BUS 3","magnitude":1.0059,"__metadata__":{"module":"PowerSystems","type":"ACBus"},"internal":{"uuid":{"value":"6f84f8dd-e5c5-4656-9f22-8547c8e5b693"},"ext":null,"units_info":null},"area":{"value":"cd599955-2721-4133-8edb-eea3b9593b6c"},"ext":{},"voltage_limits":{"min":0.9,"max":1.1},"load_zone":{"value":"62d8ad01-23fd-4b98-82cf-4d1b5667bf80"}},{"number":101,"base_voltage":138.0,"bustype":"REF","angle":0.0,"name":"BUS 1","magnitude":1.02,"__metadata__":{"module":"PowerSystems","type":"ACBus"},"internal":{"uuid":{"value":"54a60455-d7e2-4030-9d95-e72fbb443eb0"},"ext":null,"units_info":null},"area":{"value":"cd599955-2721-4133-8edb-eea3b9593b6c"},"ext":{},"voltage_limits":{"min":0.9,"max":1.1},"load_zone":{"value":"62d8ad01-23fd-4b98-82cf-4d1b5667bf80"}},{"number":102,"base_voltage":138.0,"bustype":"PV","angle":0.0,"name":"BUS 2","magnitude":1.0142,"__metadata__":{"module":"PowerSystems","type":"ACBus"},"internal":{"uuid":{"value":"bc008aa5-ef59-4703-8034-213237eb7632"},"ext":null,"units_info":null},"area":{"value":"cd599955-2721-4133-8edb-eea3b9593b6c"},"ext":{},"voltage_limits":{"min":0.9,"max":1.1},"load_zone":{"value":"62d8ad01-23fd-4b98-82cf-4d1b5667bf80"}},{"name":"1","internal":{"uuid":{"value":"62d8ad01-23fd-4b98-82cf-4d1b5667bf80"},"ext":null,"units_info":null},"ext":{},"peak_active_power":1.8,"peak_reactive_power":0.5,"__metadata__":{"module":"PowerSystems","type":"LoadZone"}},{"base_power":100.0,"shaft":{"internal":{"uuid":{"value":"94d799d0-0531-4886-b2cd-abb40e965ae6"},"ext":null,"units_info":null},"n_states":2,"ext":{},"D":0.0,"states":["δ","ω"],"H":3.01,"__metadata__":{"module":"PowerSystems","type":"SingleMass"}},"states":["eq_p","ed_p","δ","ω","Vf","Vr1","Vr2","Vm"],"name":"generator-102-1","n_states":8,"ω_ref":1.0,"__metadata__":{"parameters":["OneDOneQMachine","SingleMass","AVRTypeI","TGFixed","PSSFixed"],"module":"PowerSystems","type":"DynamicGenerator"},"avr":{"Ta":0.2,"Te":0.314,"states_types":["Differential","Differential","Differential","Differential"],"__metadata__":{"module":"PowerSystems","type":"AVRTypeI"},"internal":{"uuid":{"value":"b8b4bb67-7d8f-4cb9-959b-20e295054fe6"},"ext":null,"units_info":null},"Ke":0.01,"ext":{},"Kf":0.063,"V_ref":1.0,"states":["Vf","Vr1","Vr2","Vm"],"Ae":0.0039,"n_states":4,"Tf":0.35,"Tr":0.001,"Va_lim":{"min":-5.0,"max":5.0},"Be":1.555,"Ka":20.0},"internal":{"uuid":{"value":"5aa9b1d1-70b8-48b4-a589-c68a06509b46"},"ext":null,"units_info":null},"ext":{},"machine":{"internal":{"uuid":{"value":"1b595aff-3ee4-4e91-852c-8d4788e8499b"},"ext":null,"units_info":null},"Xq":1.2578,"ext":{},"states":["eq_p","ed_p"],"Tq0_p":0.6,"n_states":2,"Xd":1.3125,"Xd_p":0.1813,"Xq_p":0.25,"Td0_p":5.89,"R":0.0,"__metadata__":{"module":"PowerSystems","type":"OneDOneQMachine"}},"pss":{"V_pss":0.0,"internal":{"uuid":{"value":"177ad8bf-c181-465d-8efe-fad67756d2d1"},"ext":null,"units_info":null},"n_states":0,"ext":{},"states":[],"__metadata__":{"module":"PowerSystems","type":"PSSFixed"}},"prime_mover":{"P_ref":1.0,"internal":{"uuid":{"value":"7a1fd243-3949-43f1-a4a2-a9ee7711ec51"},"ext":null,"units_info":null},"efficiency":1.0,"n_states":0,"ext":{},"states":[],"__metadata__":{"module":"PowerSystems","type":"TGFixed"}}},{"load_response":0.0,"name":"1","internal":{"uuid":{"value":"cd599955-2721-4133-8edb-eea3b9593b6c"},"ext":null,"units_info":null},"ext":{},"peak_active_power":0.0,"peak_reactive_power":0.0,"__metadata__":{"module":"PowerSystems","type":"Area"}},{"base_power":100.0,"services":[],"bus":{"value":"54a60455-d7e2-4030-9d95-e72fbb443eb0"},"max_constant_active_power":0.5,"available":true,"name":"load1011","max_current_active_power":0.0,"constant_active_power":0.5,"dynamic_injector":null,"__metadata__":{"module":"PowerSystems","type":"StandardLoad"},"current_active_power":0.0,"current_reactive_power":0.0,"internal":{"uuid":{"value":"e7dc1e2a-db59-4966-b831-3975c85eaa03"},"ext":null,"units_info":null},"ext":{},"max_constant_reactive_power":0.1,"max_current_reactive_power":0.0,"impedance_reactive_power":0.0,"impedance_active_power":0.0,"max_impedance_active_power":0.0,"constant_reactive_power":0.1,"max_impedance_reactive_power":0.0},{"base_power":100.0,"services":[],"bus":{"value":"6f84f8dd-e5c5-4656-9f22-8547c8e5b693"},"max_constant_active_power":0.3,"available":true,"name":"load1031","max_current_active_power":0.0,"constant_active_power":0.3,"dynamic_injector":null,"__metadata__":{"module":"PowerSystems","type":"StandardLoad"},"current_active_power":0.0,"current_reactive_power":0.0,"internal":{"uuid":{"value":"5a9d43c7-d6d1-4bbd-9846-f05460c4a1cb"},"ext":null,"units_info":null},"ext":{},"max_constant_reactive_power":0.1,"max_current_reactive_power":0.0,"impedance_reactive_power":0.0,"impedance_active_power":0.0,"max_impedance_active_power":0.0,"constant_reactive_power":0.1,"max_impedance_reactive_power":0.0},{"base_power":100.0,"services":[],"bus":{"value":"bc008aa5-ef59-4703-8034-213237eb7632"},"max_constant_active_power":1.0,"available":true,"name":"load1021","max_current_active_power":0.0,"constant_active_power":1.0,"dynamic_injector":null,"__metadata__":{"module":"PowerSystems","type":"StandardLoad"},"current_active_power":0.0,"current_reactive_power":0.0,"internal":{"uuid":{"value":"1b483ed8-cc05-429b-80ba-1b54836e7d2d"},"ext":null,"units_info":null},"ext":{},"max_constant_reactive_power":0.3,"max_current_reactive_power":0.0,"impedance_reactive_power":0.0,"impedance_active_power":0.0,"max_impedance_active_power":0.0,"constant_reactive_power":0.3,"max_impedance_reactive_power":0.0},{"internal":{"uuid":{"value":"9fd44ef6-4867-479f-ba08-06ef61e3446d"},"ext":null,"units_info":null},"to":{"value":"6f84f8dd-e5c5-4656-9f22-8547c8e5b693"},"from":{"value":"54a60455-d7e2-4030-9d95-e72fbb443eb0"},"__metadata__":{"module":"PowerSystems","type":"Arc"}},{"internal":{"uuid":{"value":"c55189e0-2cbe-4664-ab9e-b5ad24addc7b"},"ext":null,"units_info":null},"to":{"value":"bc008aa5-ef59-4703-8034-213237eb7632"},"from":{"value":"54a60455-d7e2-4030-9d95-e72fbb443eb0"},"__metadata__":{"module":"PowerSystems","type":"Arc"}},{"internal":{"uuid":{"value":"3e7c8d36-85cd-49b7-82df-26b20c64df03"},"ext":null,"units_info":null},"to":{"value":"6f84f8dd-e5c5-4656-9f22-8547c8e5b693"},"from":{"value":"bc008aa5-ef59-4703-8034-213237eb7632"},"__metadata__":{"module":"PowerSystems","type":"Arc"}},{"base_power":100.0,"prime_mover_type":"OT","rating":3.333526661060325,"services":[],"bus":{"value":"bc008aa5-ef59-4703-8034-213237eb7632"},"available":true,"name":"generator-102-1","status":true,"active_power":0.7,"dynamic_injector":{"value":"5aa9b1d1-70b8-48b4-a589-c68a06509b46"},"__metadata__":{"module":"PowerSystems","type":"ThermalStandard"},"fuel":"OTHER","internal":{"uuid":{"value":"5b7e1497-1bfc-40b7-acb5-e3b39d5325fb"},"ext":null,"units_info":null},"reactive_power_limits":{"min":-1.0,"max":1.0},"ext":{"z_source":{"x":1,"r":0}},"operation_cost":{"start_up":0.0,"fixed":0.0,"shut_down":0.0,"variable":{"__metadata__":{"parameters":["InputOutputCurve"],"module":"PowerSystems","type":"CostCurve"},"value_curve":{"input_at_zero":null,"function_data":{"__metadata__":{"module":"InfrastructureSystems","type":"QuadraticFunctionData"},"quadratic_term":0.0,"constant_term":0.0,"proportional_term":1.0},"__metadata__":{"parameters":["QuadraticFunctionData"],"module":"PowerSystems","type":"InputOutputCurve"}},"power_units":"DEVICE_BASE","vom_cost":{"input_at_zero":null,"function_data":{"__metadata__":{"module":"InfrastructureSystems","type":"LinearFunctionData"},"constant_term":0.0,"proportional_term":0.0},"__metadata__":{"parameters":["LinearFunctionData"],"module":"PowerSystems","type":"InputOutputCurve"}}},"__metadata__":{"module":"PowerSystems","type":"ThermalGenerationCost"}},"time_limits":null,"must_run":false,"ramp_limits":{"up":3.18,"down":3.18},"time_at_status":10000.0,"active_power_limits":{"min":0.0,"max":3.18},"reactive_power":0.0},{"base_power":100.0,"prime_mover_type":"OT","rating":3.333526661060325,"services":[],"bus":{"value":"6f84f8dd-e5c5-4656-9f22-8547c8e5b693"},"available":true,"name":"generator-103-1","status":true,"active_power":0.8,"dynamic_injector":{"value":"e730d0f8-db26-44b6-8840-e57003912739"},"__metadata__":{"module":"PowerSystems","type":"ThermalStandard"},"fuel":"OTHER","internal":{"uuid":{"value":"4618df43-eaed-42e1-8bf1-5cef75049c4b"},"ext":null,"units_info":null},"reactive_power_limits":{"min":-1.0,"max":1.0},"ext":{"z_source":{"x":1,"r":0}},"operation_cost":{"start_up":0.0,"fixed":0.0,"shut_down":0.0,"variable":{"__metadata__":{"parameters":["InputOutputCurve"],"module":"PowerSystems","type":"CostCurve"},"value_curve":{"input_at_zero":null,"function_data":{"__metadata__":{"module":"InfrastructureSystems","type":"QuadraticFunctionData"},"quadratic_term":0.0,"constant_term":0.0,"proportional_term":1.0},"__metadata__":{"parameters":["QuadraticFunctionData"],"module":"PowerSystems","type":"InputOutputCurve"}},"power_units":"DEVICE_BASE","vom_cost":{"input_at_zero":null,"function_data":{"__metadata__":{"module":"InfrastructureSystems","type":"LinearFunctionData"},"constant_term":0.0,"proportional_term":0.0},"__metadata__":{"parameters":["LinearFunctionData"],"module":"PowerSystems","type":"InputOutputCurve"}}},"__metadata__":{"module":"PowerSystems","type":"ThermalGenerationCost"}},"time_limits":null,"must_run":false,"ramp_limits":{"up":3.18,"down":3.18},"time_at_status":10000.0,"active_power_limits":{"min":0.0,"max":3.18},"reactive_power":0.0},{"rating":2.5,"services":[],"x":0.12,"b":{"from":0.1,"to":0.1},"r":0.01,"available":true,"name":"BUS 1-BUS 3-i_1","reactive_power_flow":0.0,"arc":{"value":"9fd44ef6-4867-479f-ba08-06ef61e3446d"},"__metadata__":{"module":"PowerSystems","type":"Line"},"internal":{"uuid":{"value":"3725c589-acf4-4d6d-91f3-3639a5c64924"},"ext":null,"units_info":null},"ext":{},"active_power_flow":0.0,"angle_limits":{"min":-1.0472,"max":1.0472}},{"rating":2.5,"services":[],"x":0.12,"b":{"from":0.1,"to":0.1},"r":0.01,"available":true,"name":"BUS 1-BUS 2-i_1","reactive_power_flow":0.0,"arc":{"value":"c55189e0-2cbe-4664-ab9e-b5ad24addc7b"},"__metadata__":{"module":"PowerSystems","type":"Line"},"internal":{"uuid":{"value":"014f84f0-2952-4c1d-b7e7-77feceaa5d6b"},"ext":null,"units_info":null},"ext":{},"active_power_flow":0.0,"angle_limits":{"min":-1.0472,"max":1.0472}},{"rating":2.5,"services":[],"x":0.9,"b":{"from":0.5,"to":0.5},"r":0.02,"available":true,"name":"BUS 2-BUS 3-i_1","reactive_power_flow":0.0,"arc":{"value":"3e7c8d36-85cd-49b7-82df-26b20c64df03"},"__metadata__":{"module":"PowerSystems","type":"Line"},"internal":{"uuid":{"value":"1f407832-418a-4a2f-9dc8-ab22ed42743d"},"ext":null,"units_info":null},"ext":{},"active_power_flow":0.0,"angle_limits":{"min":-1.0472,"max":1.0472}}],"subsystems":{},"version_info":{"julia_version":"1.10.4","package_info":"Status `~/work/PowerSimulationsDynamics.jl/PowerSimulationsDynamics.jl/docs/Manifest.toml`\n [47edcb42] ADTypes v1.5.3\n [a4c015fc] ANSIColoredPrinters v0.0.1\n [1520ce14] AbstractTrees v0.4.5\n [7d9f7c33] Accessors v0.1.36\n [79e6a3ab] Adapt v4.0.4\n [ec485272] ArnoldiMethod v0.4.0\n [4fba245c] ArrayInterface v7.12.0\n [4c555306] ArrayLayouts v1.10.2\n [d1d4a3ce] BitFlags v0.1.9\n [62783981] BitTwiddlingConvenienceFunctions v0.1.6\n [a74b3585] Blosc v0.7.3\n [fa961155] CEnum v0.5.0\n [2a0fbf3d] CPUSummary v0.2.6\n [336ed68f] CSV v0.10.14\n [d360d2e6] ChainRulesCore v1.24.0\n [fb6a15b2] CloseOpenIntervals v0.1.13\n [944b1d66] CodecZlib v0.7.5\n [35d6a980] ColorSchemes v3.25.0\n [3da002f7] ColorTypes v0.11.5\n [c3611d14] ColorVectorSpace v0.10.0\n [5ae59095] Colors v0.12.11\n [38540f10] CommonSolve v0.2.4\n [bbf7d656] CommonSubexpressions v0.3.0\n [f70d9fcc] CommonWorldInvalidations v1.0.0\n [34da2185] Compat v4.15.0\n [a33af91c] CompositionsBase v0.1.2\n [2569d6c7] ConcreteStructs v0.2.3\n [f0e56b4a] ConcurrentUtilities v2.4.2\n [187b0558] ConstructionBase v1.5.5\n [d38c429a] Contour v0.6.3\n [adafc99b] CpuId v0.3.1\n [a8cc5b0e] Crayons v4.1.1\n [a10d1c49] DBInterface v2.6.1\n [9a962f9c] DataAPI v1.16.0\n [a93c6f00] DataFrames v1.6.1\n [864edb3b] DataStructures v0.18.20\n [e2d170a0] DataValueInterfaces v1.0.0\n [8bb1440f] DelimitedFiles v1.9.1\n [2b5f629d] DiffEqBase v6.151.5\n [163ba53b] DiffResults v1.1.0\n [b552c78f] DiffRules v1.15.1\n [a0c0ee7d] DifferentiationInterface v0.5.7\n [b4f34e82] Distances v0.10.11\n [ffbed154] DocStringExtensions v0.9.3\n⌅ [e30172f5] Documenter v0.27.25\n [35a29f4d] DocumenterTools v0.1.19\n [4e289a0a] EnumX v1.0.4\n [f151be2c] EnzymeCore v0.7.6\n [460bff9d] ExceptionUnwrapping v0.1.10\n [d4d017d3] ExponentialUtilities v1.26.1\n [e2ba6199] ExprTools v0.1.10\n [c87230d0] FFMPEG v0.4.1\n [7034ab61] FastBroadcast v0.3.4\n [9aa1b823] FastClosures v0.3.2\n [29a986be] FastLapackInterface v2.0.4\n [48062228] FilePathsBase v0.9.21\n [1a297f60] FillArrays v1.11.0\n [6a86dc24] FiniteDiff v2.23.1\n [53c48c17] FixedPointNumbers v0.8.5\n [1fa38f19] Format v1.3.7\n [f6369f11] ForwardDiff v0.10.36\n [069b7b12] FunctionWrappers v1.1.3\n [77dc65aa] FunctionWrappersWrappers v0.1.3\n [46192b85] GPUArraysCore v0.1.6\n⌃ [28b8d3ca] GR v0.73.5\n [c145ed77] GenericSchur v0.5.4\n [86223c79] Graphs v1.11.2\n [42e2da0e] Grisu v1.0.2\n [708ec375] Gumbo v0.8.2\n [c8ec2601] H5Zblosc v0.1.2\n [f67ccb44] HDF5 v0.17.2\n [cd3eb016] HTTP v1.10.8\n [3e5b6fbb] HostCPUFeatures v0.1.17\n [b5f81e59] IOCapture v0.2.5\n [615f187c] IfElse v0.1.1\n [d25df0c9] Inflate v0.1.5\n [2cd47ed4] InfrastructureSystems v2.0.1\n [842dd82b] InlineStrings v1.4.1\n [3587e190] InverseFunctions v0.1.14\n [41ab1584] InvertedIndices v1.3.0\n [92d709cd] IrrationalConstants v0.2.2\n [82899510] IteratorInterfaceExtensions v1.0.0\n [1019f520] JLFzf v0.1.7\n [692b3bcd] JLLWrappers v1.5.0\n [682c06a0] JSON v0.21.4\n [0f8b85d8] JSON3 v1.14.0\n [ef3ab10e] KLU v0.6.0\n [ba0b0d4f] Krylov v0.9.6\n [b964fa9f] LaTeXStrings v1.3.1\n [23fbe1c1] Latexify v0.16.4\n [10f19ff3] LayoutPointers v0.1.17\n [5078a376] LazyArrays v2.1.5\n [1d6d02ad] LeftChildRightSiblingTrees v0.2.0\n [d3d80556] LineSearches v7.2.0\n [7ed4a6bd] LinearSolve v2.30.2\n [2ab3a3ac] LogExpFunctions v0.3.28\n [e6f89c97] LoggingExtras v1.0.3\n [bdcacae8] LoopVectorization v0.12.171\n⌅ [33e6dc65] MKL v0.6.3\n [3da0fdf6] MPIPreferences v0.1.11\n [1914dd2f] MacroTools v0.5.13\n [d125e4d3] ManualMemory v0.1.8\n [299715c1] MarchingCubes v0.1.9\n [bb5d69b7] MaybeInplace v0.1.3\n [739be429] MbedTLS v1.1.9\n [442fdcdd] Measures v0.3.2\n [e1d29d7a] Missings v1.2.0\n [46d2c3a1] MuladdMacro v0.2.4\n [ffc61752] Mustache v1.0.19\n [d41bc354] NLSolversBase v7.8.3\n [2774e3e8] NLsolve v4.5.1\n [77ba4419] NaNMath v1.0.2\n [8913a72c] NonlinearSolve v3.13.1\n [6fe1bfb0] OffsetArrays v1.14.1\n [4d8831e6] OpenSSL v1.4.3\n [bac558e1] OrderedCollections v1.6.3\n [1dea7af3] OrdinaryDiffEq v6.85.0\n [65ce6f38] PackageExtensionCompat v1.0.2\n [d96e819e] Parameters v0.12.3\n [46dd5b70] Pardiso v0.5.7\n [69de0a69] Parsers v2.8.1\n [b98c9c47] Pipe v1.3.0\n [ccf2f8ad] PlotThemes v3.2.0\n [995b91a9] PlotUtils v1.4.1\n [91a5bcdd] Plots v1.40.5\n [f517fe37] Polyester v0.7.15\n [1d0040c9] PolyesterWeave v0.2.2\n [2dfb63ee] PooledArrays v1.4.3\n [dd99e9e3] PowerFlowData v1.5.0\n [94fada2c] PowerFlows v0.7.0\n [bed98974] PowerNetworkMatrices v0.11.0\n [398b2ede] PowerSimulationsDynamics v0.15.0 `~/work/PowerSimulationsDynamics.jl/PowerSimulationsDynamics.jl`\n [f00506e0] PowerSystemCaseBuilder v1.3.3\n [bcd98974] PowerSystems v4.1.1\n [d236fae5] PreallocationTools v0.4.22\n [aea7be01] PrecompileTools v1.2.1\n [21216c6a] Preferences v1.4.3\n [08abe8d2] PrettyTables v2.3.2\n [33c8b6b6] ProgressLogging v0.1.4\n [3cdcf5f2] RecipesBase v1.3.4\n [01d81517] RecipesPipeline v0.6.12\n [731186ca] RecursiveArrayTools v3.26.0\n [f2c3362d] RecursiveFactorization v0.2.23\n [189a3867] Reexport v1.2.2\n [05181044] RelocatableFolders v1.0.1\n [ae029012] Requires v1.3.0\n [7e49a35a] RuntimeGeneratedFunctions v0.5.13\n [94e857df] SIMDTypes v0.1.0\n [476501e8] SLEEFPirates v0.6.43\n [0aa819cd] SQLite v1.6.1\n [322a6be2] Sass v0.2.0\n [0bca4576] SciMLBase v2.42.0\n [c0aeaf25] SciMLOperators v0.3.8\n [53ae85a6] SciMLStructures v1.4.1\n [6c6a2e73] Scratch v1.2.1\n [91c51154] SentinelArrays v1.4.5\n [efcf1570] Setfield v1.1.1\n [992d4aef] Showoff v1.0.3\n [777ac1f9] SimpleBufferStream v1.1.0\n [727e6d20] SimpleNonlinearSolve v1.10.1\n [699a6c99] SimpleTraits v0.9.4\n [ce78b400] SimpleUnPack v1.1.0\n [a2af1166] SortingAlgorithms v1.2.1\n [47a9eef4] SparseDiffTools v2.19.0\n [0a514795] SparseMatrixColorings v0.3.3\n [e56a9233] Sparspak v0.3.9\n [276daf66] SpecialFunctions v2.4.0\n [aedffcd0] Static v1.1.0\n [0d7ed370] StaticArrayInterface v1.5.1\n [90137ffa] StaticArrays v1.9.7\n [1e83bf80] StaticArraysCore v1.4.3\n [82ae8749] StatsAPI v1.7.0\n [2913bbd2] StatsBase v0.34.3\n [7792a7ef] StrideArraysCore v0.5.7\n [69024149] StringEncodings v0.3.7\n [892a3eda] StringManipulation v0.3.4\n [856f2bd8] StructTypes v1.10.0\n [c3572dad] Sundials v4.24.0\n [2efcf032] SymbolicIndexingInterface v0.3.26\n [3783bdb8] TableTraits v1.0.1\n [bd369af6] Tables v1.11.1\n [62fd8b95] TensorCore v0.1.1\n [5d786b92] TerminalLoggers v0.1.7\n [8290d209] ThreadingUtilities v0.5.2\n [9e3dc215] TimeSeries v0.24.2\n [a759f4b9] TimerOutputs v0.5.24\n [3bb67fe8] TranscodingStreams v0.11.0\n [d5829a12] TriangularSolve v0.2.1\n [410a4b4d] Tricks v0.1.8\n [781d530d] TruncatedStacktraces v1.4.0\n [5c2747f8] URIs v1.5.1\n [3a884ed6] UnPack v1.0.2\n [1cfade01] UnicodeFun v0.4.1\n [b8865327] UnicodePlots v3.6.4\n [1986cc42] Unitful v1.20.0\n [45397f5d] UnitfulLatexify v1.6.4\n [41fe7b60] Unzip v0.2.0\n [3d5dd08c] VectorizationBase v0.21.70\n [19fa3120] VertexSafeGraphs v0.2.0\n [ea10d353] WeakRefStrings v1.4.2\n [76eceee3] WorkerUtilities v1.6.1\n [ddb6d928] YAML v0.4.11\n [0b7ba130] Blosc_jll v1.21.5+0\n [6e34b625] Bzip2_jll v1.0.8+1\n [83423d85] Cairo_jll v1.18.0+2\n [2702e6a9] EpollShim_jll v0.0.20230411+0\n [2e619515] Expat_jll v2.6.2+0\n⌅ [b22a6f82] FFMPEG_jll v4.4.2+2\n [a3f928ae] Fontconfig_jll v2.13.96+0\n [d7e528f0] FreeType2_jll v2.13.2+0\n [559328eb] FriBidi_jll v1.0.14+0\n [0656b61e] GLFW_jll v3.4.0+0\n⌅ [d2c73de3] GR_jll v0.73.5+0\n [78b55507] Gettext_jll v0.21.0+0\n [7746bdde] Glib_jll v2.80.2+0\n [3b182d85] Graphite2_jll v1.3.14+0\n [528830af] Gumbo_jll v0.10.2+0\n⌃ [0234f1f7] HDF5_jll v1.12.2+2\n [2e76f6c2] HarfBuzz_jll v2.8.1+1\n [1d5cc7b8] IntelOpenMP_jll v2024.2.0+0\n [aacddb02] JpegTurbo_jll v3.0.3+0\n [c1c5ebd0] LAME_jll v3.100.2+0\n⌅ [88015f11] LERC_jll v3.0.0+1\n [1d63c593] LLVMOpenMP_jll v15.0.7+0\n [dd4b983a] LZO_jll v2.10.2+0\n⌅ [e9f186c6] Libffi_jll v3.2.2+1\n [d4300ac3] Libgcrypt_jll v1.8.11+0\n [7e76a0d4] Libglvnd_jll v1.6.0+0\n [7add5ba3] Libgpg_error_jll v1.49.0+0\n [94ce4f54] Libiconv_jll v1.17.0+0\n [4b2f31a3] Libmount_jll v2.40.1+0\n⌅ [89763e89] Libtiff_jll v4.5.1+1\n [38a345b3] Libuuid_jll v2.40.1+0\n [5ced341a] Lz4_jll v1.9.4+0\n [856f044c] MKL_jll v2024.2.0+0\n [e7412a2a] Ogg_jll v1.3.5+1\n⌅ [9bd350c2] OpenSSH_jll v8.9.0+1\n⌅ [458c3c95] OpenSSL_jll v1.1.23+0\n [efe28fd5] OpenSpecFun_jll v0.5.5+0\n [91d4177d] Opus_jll v1.3.2+0\n [30392449] Pixman_jll v0.43.4+0\n⌅ [c0090381] Qt6Base_jll v6.5.2+2\n [76ed43ae] SQLite_jll v3.45.3+0\n⌅ [fb77eaff] Sundials_jll v5.2.2+0\n [a44049a8] Vulkan_Loader_jll v1.3.243+0\n [a2964d1f] Wayland_jll v1.21.0+1\n [2381bf8a] Wayland_protocols_jll v1.31.0+0\n [02c8fc9c] XML2_jll v2.13.1+0\n [aed1982a] XSLT_jll v1.1.41+0\n [ffd25f8a] XZ_jll v5.4.6+0\n [f67eecfb] Xorg_libICE_jll v1.1.1+0\n [c834827a] Xorg_libSM_jll v1.2.4+0\n [4f6342f7] Xorg_libX11_jll v1.8.6+0\n [0c0b7dd1] Xorg_libXau_jll v1.0.11+0\n [935fb764] Xorg_libXcursor_jll v1.2.0+4\n [a3789734] Xorg_libXdmcp_jll v1.1.4+0\n [1082639a] Xorg_libXext_jll v1.3.6+0\n [d091e8ba] Xorg_libXfixes_jll v5.0.3+4\n [a51aa0fd] Xorg_libXi_jll v1.7.10+4\n [d1454406] Xorg_libXinerama_jll v1.1.4+4\n [ec84b674] Xorg_libXrandr_jll v1.5.2+4\n [ea2f1a96] Xorg_libXrender_jll v0.9.11+0\n [14d82f49] Xorg_libpthread_stubs_jll v0.1.1+0\n [c7cfdc94] Xorg_libxcb_jll v1.17.0+0\n [cc61e674] Xorg_libxkbfile_jll v1.1.2+0\n [e920d4aa] Xorg_xcb_util_cursor_jll v0.1.4+0\n [12413925] Xorg_xcb_util_image_jll v0.4.0+1\n [2def613f] Xorg_xcb_util_jll v0.4.0+1\n [975044d2] Xorg_xcb_util_keysyms_jll v0.4.0+1\n [0d47668e] Xorg_xcb_util_renderutil_jll v0.3.9+1\n [c22f9ab0] Xorg_xcb_util_wm_jll v0.4.1+1\n [35661453] Xorg_xkbcomp_jll v1.4.6+0\n [33bec58e] Xorg_xkeyboard_config_jll v2.39.0+0\n [c5fb5394] Xorg_xtrans_jll v1.5.0+0\n [3161d3a3] Zstd_jll v1.5.6+0\n [35ca27e7] eudev_jll v3.2.9+0\n⌅ [214eeab7] fzf_jll v0.43.0+0\n [1a1c6b14] gperf_jll v3.1.1+0\n [a4ae2306] libaom_jll v3.9.0+0\n [0ac62f75] libass_jll v0.15.1+0\n [2db6ffa8] libevdev_jll v1.11.0+0\n [f638f0a6] libfdk_aac_jll v2.0.2+0\n [36db933b] libinput_jll v1.18.0+0\n [b53b4c65] libpng_jll v1.6.43+1\n [47bcb7c8] libsass_jll v3.6.6+0\n [f27f6e37] libvorbis_jll v1.3.7+1\n [009596ad] mtdev_jll v1.1.6+0\n [1317d2d5] oneTBB_jll v2021.12.0+0\n [1270edf5] x264_jll v2021.5.5+0\n [dfaa095f] x265_jll v3.5.0+0\n [d8fb68d0] xkbcommon_jll v1.4.1+1\n [0dad84c5] ArgTools v1.1.1\n [56f22d72] Artifacts\n [2a0f44e3] Base64\n [ade2ca70] Dates\n [8ba89e20] Distributed\n [f43a241f] Downloads v1.6.0\n [7b1f6079] FileWatching\n [9fa8497b] Future\n [b77e0a4c] InteractiveUtils\n [4af54fe1] LazyArtifacts\n [b27032c2] LibCURL v0.6.4\n [76f85450] LibGit2\n [8f399da3] Libdl\n [37e2e46d] LinearAlgebra\n [56ddb016] Logging\n [d6f4376e] Markdown\n [a63ad114] Mmap\n [ca575930] NetworkOptions v1.2.0\n [44cfe95a] Pkg v1.10.0\n [de0858da] Printf\n [3fa0cd96] REPL\n [9a3f8284] Random\n [ea8e919c] SHA v0.7.0\n [9e88b42a] Serialization\n [1a1011a3] SharedArrays\n [6462fe0b] Sockets\n [2f01184e] SparseArrays v1.10.0\n [10745b16] Statistics v1.10.0\n [4607b0f0] SuiteSparse\n [fa267f1f] TOML v1.0.3\n [a4e569a6] Tar v1.10.0\n [8dfed614] Test\n [cf7118a7] UUIDs\n [4ec0a83e] Unicode\n [e66e0078] CompilerSupportLibraries_jll v1.1.1+0\n [deac9b47] LibCURL_jll v8.4.0+0\n [e37daf67] LibGit2_jll v1.6.4+0\n [29816b5a] LibSSH2_jll v1.11.0+1\n [c8ffd9c3] MbedTLS_jll v2.28.2+1\n [14a3606d] MozillaCACerts_jll v2023.1.10\n [4536629a] OpenBLAS_jll v0.3.23+4\n [05823500] OpenLibm_jll v0.8.1+2\n [efcefdf7] PCRE2_jll v10.42.0+1\n [bea87d4a] SuiteSparse_jll v7.2.1+1\n [83775a58] Zlib_jll v1.2.13+1\n [8e850b90] libblastrampoline_jll v5.8.0+1\n [8e850ede] nghttp2_jll v1.52.0+1\n [3f19e933] p7zip_jll v17.4.0+2\nInfo Packages marked with ⌃ and ⌅ have new versions available. Those with ⌃ may be upgradable, but those with ⌅ are restricted by compatibility constraints from upgrading. To see why use `status --outdated -m`\n"},"time_series_in_memory":false},"units_settings":{"base_value":100.0,"unit_system":"SYSTEM_BASE","__metadata__":{"module":"InfrastructureSystems","type":"SystemUnitsSettings"}},"frequency":60.0,"runchecks":true,"metadata":{"name":null,"description":null,"__metadata__":{"module":"PowerSystems","type":"SystemMetadata"}},"data_format_version":"4.0.0"} \ No newline at end of file diff --git a/dev/tutorials/threebus_sys_metadata.json b/dev/tutorials/threebus_sys_metadata.json index dd7bc141c..26410afea 100644 --- a/dev/tutorials/threebus_sys_metadata.json +++ b/dev/tutorials/threebus_sys_metadata.json @@ -2,7 +2,8 @@ "name": "", "description": "", "frequency": 60, - "time_series_resolution_milliseconds": 0, + "time_series_resolutions_milliseconds": [ + ], "component_counts": [ { "type": "ACBus", @@ -17,11 +18,11 @@ "count": 1 }, { - "type": "DynamicGenerator", + "type": "DynamicGenerator{OneDOneQMachine, SingleMass, AVRTypeI, TGFixed, PSSFixed}", "count": 1 }, { - "type": "DynamicInverter", + "type": "DynamicInverter{AverageConverter, OuterControl{VirtualInertia, ReactivePowerDroop}, VoltageModeControl, FixedDCSource, KauraPLL, LCLFilter, Nothing}", "count": 1 }, { @@ -32,10 +33,6 @@ "type": "LoadZone", "count": 1 }, - { - "type": "Source", - "count": 1 - }, { "type": "StandardLoad", "count": 3 diff --git a/dev/tutorials/threebus_sys_validation_descriptors.json b/dev/tutorials/threebus_sys_validation_descriptors.json deleted file mode 100644 index e9df79ac3..000000000 --- a/dev/tutorials/threebus_sys_validation_descriptors.json +++ /dev/null @@ -1 +0,0 @@ -{"struct_validation_descriptors":[{"fields":[{"name":"variable","data_type":"VariableCost","null_value":"VariableCost((0.0, 0.0))","comment":"variable cost"},{"name":"fixed","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"fixed cost","valid_range":{"max":null,"min":0}}],"docstring":"Data Structure Operational Cost Data in two parts: fixed and variable cost.","struct_name":"TwoPartCost","supertype":"OperationalCost"},{"fields":[{"name":"variable","data_type":"VariableCost","null_value":"VariableCost((0.0, 0.0))","comment":"variable cost"},{"name":"fixed","data_type":"Float64","null_value":"0.0","comment":"fixed cost"},{"name":"start_up","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"start-up cost","valid_range":{"max":null,"min":0}},{"name":"shut_down","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"shut-down cost","valid_range":{"max":null,"min":0}}],"docstring":"Data Structure Operational Cost Data in Three parts fixed, variable cost and start - stop costs.","struct_name":"ThreePartCost","supertype":"OperationalCost"},{"fields":[{"name":"variable","default":"VariableCost((0.0, 0.0))","data_type":"VariableCost","null_value":"VariableCost((0.0, 0.0))","comment":"variable cost"},{"name":"fixed","default":"0.0","data_type":"Float64","null_value":"0.0","comment":"fixed cost"},{"name":"start_up","default":"0.0","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"start-up cost","valid_range":{"max":null,"min":0}},{"name":"shut_down","default":"0.0","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"shut-down cost","valid_range":{"max":null,"min":0}},{"name":"energy_shortage_cost","default":"0.0","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"Cost incurred by the model for being short of the energy target.","valid_range":{"max":null,"min":0}},{"name":"energy_surplus_cost","default":"0.0","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"Cost incurred by the model for surplus energy stored.","valid_range":{"max":null,"min":0}}],"docstring":"Data Structure for Operational Cost Data like variable cost and start - stop costs and energy storage cost.","struct_name":"StorageManagementCost","supertype":"OperationalCost"},{"fields":[{"name":"no_load","data_type":"Float64","null_value":"0.0","comment":"no load cost"},{"name":"start_up","data_type":"NamedTuple{(:hot, :warm, :cold), NTuple{3, Float64}}","null_value":"(hot = START_COST, warm = START_COST, cold = START_COST)","comment":"start-up cost at different stages of the thermal cycle. Warm is also refered as intermediate in some markets"},{"name":"shut_down","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"shut-down cost","valid_range":{"max":null,"min":0}},{"name":"variable","default":"nothing","data_type":"Union{Nothing, IS.TimeSeriesKey}","null_value":"nothing","comment":"Variable Cost TimeSeriesKey"},{"name":"ancillary_services","default":"Vector{Service}()","data_type":"Vector{Service}","null_value":"Vector{Service}()","comment":"Bids for the ancillary services"}],"docstring":"Data Structure Operational Cost to reflect market bids of energy and ancilliary services.\nCompatible with most US Market bidding mechanisms","struct_name":"MarketBidCost","supertype":"OperationalCost"},{"fields":[{"name":"variable","data_type":"VariableCost","null_value":"VariableCost((0.0, 0.0))","comment":"variable cost"},{"name":"no_load","data_type":"Float64","null_value":"0.0","comment":"no load cost"},{"name":"fixed","data_type":"Float64","null_value":"0.0","comment":"fixed cost"},{"name":"start_up","data_type":"NamedTuple{(:hot, :warm, :cold), NTuple{3, Float64}}","null_value":"(hot = START_COST, warm = START_COST, cold = START_COST)","comment":"start-up cost"},{"name":"shut_down","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"shut-down cost","valid_range":{"max":null,"min":0}}],"docstring":"Data Structure Operational Cost Data which includes fixed, variable cost, multiple start up cost and stop costs.","struct_name":"MultiStartCost","supertype":"OperationalCost"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"peak_active_power","needs_conversion":true,"default":"0.0","data_type":"Float64","null_value":"0.0"},{"name":"peak_reactive_power","needs_conversion":true,"default":"0.0","data_type":"Float64","null_value":"0.0"},{"name":"load_response","default":"0.0","data_type":"Float64","null_value":"0.0"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"A collection of buses for control purposes.","struct_name":"Area","supertype":"AggregationTopology"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"peak_active_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"peak_reactive_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"A collection of buses for electricity price analysis.","struct_name":"LoadZone","supertype":"AggregationTopology"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"active_power_flow_limits","needs_conversion":true,"data_type":"MinMax","null_value":"(min=0.0, max=0.0)"},{"name":"violation_penalty","default":"INFINITE_COST","data_type":"Float64","null_value":"0.0","comment":"Penalty for violating the flow limits in the interface"},{"name":"direction_mapping","default":"Dict{String, Int}()","data_type":"Dict{String, Int}","null_value":"Dict{String, Int}()","comment":"Map to set of multiplier to the flow in the line for cases when the line has a reverse direction with respect to the interface"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"A collection of branches that make up an interface or corridor for the transfer of power.","struct_name":"TransmissionInterface","supertype":"Service"},{"inner_constructor_check":"check_bus_params","fields":[{"name":"number","data_type":"Int","null_value":"0","comment":"number associated with the bus"},{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init","comment":"the name of the bus"},{"name":"bustype","data_type":"Union{Nothing, ACBusTypes}","null_value":"nothing","comment":"bus type"},{"name":"angle","data_type":"Union{Nothing, Float64}","null_value":"0.0","validation_action":"error","comment":"angle of the bus in radians","valid_range":{"max":1.571,"min":-1.571}},{"name":"magnitude","data_type":"Union{Nothing, Float64}","null_value":"0.0","validation_action":"warn","comment":"voltage as a multiple of basevoltage","valid_range":"voltage_limits"},{"name":"voltage_limits","data_type":"Union{Nothing, MinMax}","null_value":"(min=0.0, max=0.0)","comment":"limits on the voltage variation as multiples of basevoltage"},{"name":"base_voltage","data_type":"Union{Nothing, Float64}","null_value":"nothing","validation_action":"error","comment":"the base voltage in kV","valid_range":{"max":null,"min":0}},{"name":"area","default":"nothing","data_type":"Union{Nothing, Area}","null_value":"nothing","comment":"the area containing the bus"},{"name":"load_zone","default":"nothing","data_type":"Union{Nothing, LoadZone}","null_value":"nothing","comment":"the load zone containing the bus"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"A power-system bus.","struct_name":"ACBus","supertype":"Bus"},{"fields":[{"name":"number","data_type":"Int","null_value":"0","comment":"number associated with the DC bus"},{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init","comment":"the name of the DC bus"},{"name":"magnitude","data_type":"Union{Nothing, Float64}","null_value":"0.0","validation_action":"warn","comment":"voltage as a multiple of basevoltage","valid_range":"voltage_limits"},{"name":"voltage_limits","data_type":"Union{Nothing, MinMax}","null_value":"(min=0.0, max=0.0)","comment":"limits on the voltage variation as multiples of basevoltage"},{"name":"base_voltage","data_type":"Union{Nothing, Float64}","null_value":"nothing","validation_action":"error","comment":"the base voltage in kV","valid_range":{"max":null,"min":0}},{"name":"area","default":"nothing","data_type":"Union{Nothing, Area}","null_value":"nothing","comment":"the area containing the DC bus"},{"name":"load_zone","default":"nothing","data_type":"Union{Nothing, LoadZone}","null_value":"nothing","comment":"the load zone containing the DC bus"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"A power-system DC bus.","struct_name":"DCBus","supertype":"Bus"},{"fields":[{"name":"from","data_type":"Bus","null_value":"ACBus(nothing)","comment":"The initial bus"},{"name":"to","data_type":"Bus","null_value":"ACBus(nothing)","comment":"The terminal bus"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"A topological Arc.","struct_name":"Arc","supertype":"Topology","custom_code":"get_name(arc::Arc) = (get_name ∘ get_from)(arc) * \" -> \" * (get_name ∘ get_to)(arc)"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"active_power_flow","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"reactive_power_flow","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"arc","data_type":"Arc","null_value":"Arc(ACBus(nothing), ACBus(nothing))"},{"name":"r","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"System per-unit value","valid_range":{"max":4,"min":0}},{"name":"x","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"System per-unit value","valid_range":{"max":4,"min":0}},{"name":"b","data_type":"FromTo","null_value":"(from=0.0, to=0.0)","validation_action":"warn","comment":"System per-unit value","valid_range":{"max":100,"min":0}},{"name":"rate","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"angle_limits","data_type":"MinMax","null_value":"(min=-1.571, max=1.571)","validation_action":"error","valid_range":{"max":1.571,"min":-1.571}},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"struct_name":"Line","supertype":"ACBranch"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"active_power_flow","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"reactive_power_flow","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"arc","data_type":"Arc","null_value":"Arc(ACBus(nothing), ACBus(nothing))"},{"name":"r","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"System per-unit value","valid_range":{"max":4,"min":0}},{"name":"x","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"System per-unit value","valid_range":{"max":4,"min":0}},{"name":"b","data_type":"FromTo","null_value":"(from=0.0, to=0.0)","validation_action":"warn","comment":"System per-unit value","valid_range":{"max":2,"min":0}},{"name":"flow_limits","needs_conversion":true,"data_type":"FromTo_ToFrom","null_value":"(from_to=0.0, to_from=0.0)","comment":"throw warning above max SIL"},{"name":"rate","needs_conversion":true,"data_type":"Float64","null_value":"0.0","comment":"compare to SIL (warn) (theoretical limit)"},{"name":"angle_limits","data_type":"MinMax","null_value":"(min=-1.571, max=1.571)","validation_action":"error","valid_range":{"max":1.571,"min":-1.571}},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"struct_name":"MonitoredLine","supertype":"ACBranch"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"active_power_flow","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"reactive_power_flow","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"arc","data_type":"Arc","null_value":"Arc(ACBus(nothing), ACBus(nothing))"},{"name":"r","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"System per-unit value","valid_range":{"max":4,"min":0}},{"name":"x","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"System per-unit value","valid_range":{"max":4,"min":-2}},{"name":"primary_shunt","Comment":"System per-unit value","data_type":"Float64","null_value":"0.0","validation_action":"warn","valid_range":{"max":2,"min":0}},{"name":"tap","data_type":"Float64","null_value":"1.0","validation_action":"error","valid_range":{"max":2,"min":0}},{"name":"α","data_type":"Float64","null_value":"0.0","validation_action":"warn","valid_range":{"max":1.571,"min":-1.571}},{"name":"rate","needs_conversion":true,"data_type":"Union{Nothing, Float64}","null_value":"0.0","validation_action":"error","valid_range":{"max":null,"min":0}},{"name":"phase_angle_limits","default":"(min=-1.571, max=1.571)","data_type":"MinMax","null_value":"(min=-1.571, max=1.571)","validation_action":"error","valid_range":{"max":1.571,"min":-1.571}},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"struct_name":"PhaseShiftingTransformer","supertype":"ACBranch"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"active_power_flow","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"reactive_power_flow","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"arc","data_type":"Arc","null_value":"Arc(ACBus(nothing), ACBus(nothing))"},{"name":"r","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"System per-unit value","valid_range":{"max":2,"min":-2}},{"name":"x","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"System per-unit value","valid_range":{"max":4,"min":-2}},{"name":"primary_shunt","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"System per-unit value","valid_range":{"max":2,"min":0}},{"name":"tap","data_type":"Float64","null_value":"1.0","validation_action":"error","valid_range":{"max":2,"min":0}},{"name":"rate","needs_conversion":true,"data_type":"Union{Nothing, Float64}","null_value":"0.0","validation_action":"error","valid_range":{"max":null,"min":0}},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"struct_name":"TapTransformer","supertype":"ACBranch"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"active_power_flow","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"reactive_power_flow","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"arc","data_type":"Arc","null_value":"Arc(ACBus(nothing), ACBus(nothing))"},{"name":"r","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"System per-unit value","valid_range":{"max":4,"min":-2}},{"name":"x","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"System per-unit value","valid_range":{"max":4,"min":-2}},{"name":"primary_shunt","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"System per-unit value","valid_range":{"max":2,"min":0}},{"name":"rate","needs_conversion":true,"data_type":"Union{Nothing, Float64}","null_value":"nothing","validation_action":"error","valid_range":{"max":null,"min":0}},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"The 2-W transformer model uses an equivalent circuit assuming the impedance is on the High Voltage Side of the transformer. The model allocates the iron losses and magnetizing susceptance to the primary side.","struct_name":"Transformer2W","supertype":"ACBranch"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"active_power_flow","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"arc","data_type":"Arc","null_value":"Arc(ACBus(nothing), ACBus(nothing))"},{"name":"active_power_limits_from","needs_conversion":true,"data_type":"MinMax","null_value":"(min=0.0, max=0.0)"},{"name":"active_power_limits_to","needs_conversion":true,"data_type":"MinMax","null_value":"(min=0.0, max=0.0)"},{"name":"reactive_power_limits_from","needs_conversion":true,"data_type":"MinMax","null_value":"(min=0.0, max=0.0)"},{"name":"reactive_power_limits_to","needs_conversion":true,"data_type":"MinMax","null_value":"(min=0.0, max=0.0)"},{"name":"loss","data_type":"NamedTuple{(:l0, :l1), Tuple{Float64, Float64}}","null_value":"(l0=0.0, l1=0.0)"},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"a High voltage DC line.","struct_name":"TwoTerminalHVDCLine","supertype":"ACBranch"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"active_power_flow","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"arc","data_type":"Arc","null_value":"Arc(ACBus(nothing), ACBus(nothing))"},{"name":"rectifier_tap_limits","data_type":"MinMax","null_value":"(min=0.0, max=0.0)"},{"name":"rectifier_xrc","data_type":"Float64","null_value":"0.0"},{"name":"rectifier_firing_angle","data_type":"MinMax","null_value":"(min=0.0, max=0.0)"},{"name":"inverter_tap_limits","data_type":"MinMax","null_value":"(min=0.0, max=0.0)"},{"name":"inverter_xrc","data_type":"Float64","null_value":"0.0"},{"name":"inverter_firing_angle","data_type":"MinMax","null_value":"(min=0.0, max=0.0)"},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"As implemented in Milano's Book, Page 397.","struct_name":"TwoTerminalVSCDCLine","supertype":"ACBranch"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"active_power_flow","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"arc","data_type":"Arc","null_value":"Arc(DCBus(nothing), DCBus(nothing))"},{"name":"r","data_type":"Float64","null_value":"0.0","comment":"Series Resistance system per-unit value"},{"name":"l","data_type":"Float64","null_value":"0.0","comment":"Series Inductance system per-unit value"},{"name":"c","data_type":"Float64","null_value":"0.0","comment":"Shunt capacitance system per-unit value"},{"name":"active_power_limits_from","needs_conversion":true,"data_type":"MinMax","null_value":"(min=0.0, max=0.0)"},{"name":"active_power_limits_to","needs_conversion":true,"data_type":"MinMax","null_value":"(min=0.0, max=0.0)"},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"a HVDC T-Model DC line.","struct_name":"TModelHVDCLine","supertype":"DCBranch"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"bus","data_type":"ACBus","null_value":"ACBus(nothing)"},{"name":"active_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"reactive_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"max_active_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"max_reactive_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"base_power","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"Base power of the unit in MVA","valid_range":{"max":null,"min":0}},{"name":"operation_cost","data_type":"TwoPartCost","null_value":"TwoPartCost(nothing)","comment":"Operation Cost of Generation [`TwoPartCost`](@ref)"},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"dynamic_injector","default":"nothing","data_type":"Union{Nothing, DynamicInjection}","exclude_setter":true,"null_value":"nothing","comment":"corresponding dynamic injection device"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"struct_name":"InterruptiblePowerLoad","supertype":"ControllableLoad"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"bus","data_type":"ACBus","null_value":"ACBus(nothing)"},{"name":"Y","data_type":"Complex{Float64}","null_value":"0.0","comment":"System per-unit value"},{"name":"dynamic_injector","default":"nothing","data_type":"Union{Nothing, DynamicInjection}","exclude_setter":true,"null_value":"nothing","comment":"corresponding dynamic injection model for admittance"},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"struct_name":"FixedAdmittance","supertype":"ElectricLoad"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"bus","data_type":"ACBus","null_value":"ACBus(nothing)"},{"name":"Y","data_type":"Complex{Float64}","null_value":"0.0","comment":"Initial impedance at N = 0"},{"name":"number_of_steps","default":"0","data_type":"Int","null_value":"0","comment":"Number of steps for adjustable shunt"},{"name":"Y_increase","default":"0","data_type":"Complex{Float64}","null_value":"0","comment":"Admittance increment for each of step increase"},{"name":"dynamic_injector","default":"nothing","data_type":"Union{Nothing, DynamicInjection}","exclude_setter":true,"null_value":"nothing","comment":"corresponding dynamic injection model for admittance"},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"struct_name":"SwitchedAdmittance","supertype":"ElectricLoad"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"bus","data_type":"ACBus","null_value":"ACBus(nothing)"},{"name":"active_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"reactive_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"base_power","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"Base power of the unit in MVA","valid_range":{"max":null,"min":0}},{"name":"max_active_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"max_reactive_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"dynamic_injector","default":"nothing","data_type":"Union{Nothing, DynamicInjection}","exclude_setter":true,"null_value":"nothing","comment":"corresponding dynamic injection device"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Data structure for a static power load.","struct_name":"PowerLoad","supertype":"StaticLoad"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"bus","data_type":"ACBus","null_value":"ACBus(nothing)"},{"name":"base_power","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"Base power of the unit in MVA","valid_range":{"max":null,"min":0}},{"name":"constant_active_power","needs_conversion":true,"default":"0.0","data_type":"Float64","null_value":"0.0"},{"name":"constant_reactive_power","needs_conversion":true,"default":"0.0","data_type":"Float64","null_value":"0.0"},{"name":"impedance_active_power","needs_conversion":true,"default":"0.0","data_type":"Float64","null_value":"0.0"},{"name":"impedance_reactive_power","needs_conversion":true,"default":"0.0","data_type":"Float64","null_value":"0.0"},{"name":"current_active_power","needs_conversion":true,"default":"0.0","data_type":"Float64","null_value":"0.0"},{"name":"current_reactive_power","needs_conversion":true,"default":"0.0","data_type":"Float64","null_value":"0.0"},{"name":"max_constant_active_power","needs_conversion":true,"default":"0.0","data_type":"Float64","null_value":"0.0"},{"name":"max_constant_reactive_power","needs_conversion":true,"default":"0.0","data_type":"Float64","null_value":"0.0"},{"name":"max_impedance_active_power","needs_conversion":true,"default":"0.0","data_type":"Float64","null_value":"0.0"},{"name":"max_impedance_reactive_power","needs_conversion":true,"default":"0.0","data_type":"Float64","null_value":"0.0"},{"name":"max_current_active_power","needs_conversion":true,"default":"0.0","data_type":"Float64","null_value":"0.0"},{"name":"max_current_reactive_power","needs_conversion":true,"default":"0.0","data_type":"Float64","null_value":"0.0"},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"dynamic_injector","default":"nothing","data_type":"Union{Nothing, DynamicInjection}","exclude_setter":true,"null_value":"nothing","comment":"corresponding dynamic injection device"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Data structure for a standard load.","struct_name":"StandardLoad","supertype":"StaticLoad"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"bus","data_type":"ACBus","null_value":"ACBus(nothing)"},{"name":"active_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"reactive_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"active_power_coefficient","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"Coefficient relating voltage dependence for power P = P0 * V^α","valid_range":{"max":null,"min":0}},{"name":"reactive_power_coefficient","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"Coefficient relating voltage dependence for power Q = Q0 * V^β","valid_range":{"max":null,"min":0}},{"name":"base_power","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"Base power of the unit in MVA","valid_range":{"max":null,"min":0}},{"name":"max_active_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"max_reactive_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"dynamic_injector","default":"nothing","data_type":"Union{Nothing, DynamicInjection}","exclude_setter":true,"null_value":"nothing","comment":"corresponding dynamic injection device"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Data structure for a static exponential load.","struct_name":"ExponentialLoad","supertype":"StaticLoad"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"R_s","data_type":"Float64","null_value":0,"comment":"Armature stator resistance","valid_range":{"max":null,"min":0}},{"name":"R_r","data_type":"Float64","null_value":0,"comment":"Rotor resistance","valid_range":{"max":null,"min":0}},{"name":"X_ls","data_type":"Float64","null_value":0,"comment":"Stator Leakage Reactance","valid_range":{"max":null,"min":0}},{"name":"X_lr","data_type":"Float64","null_value":0,"comment":"Rotor Leakage Reactance","valid_range":{"max":null,"min":0}},{"name":"X_m","data_type":"Float64","null_value":0,"comment":"Stator-Rotor Mutual Reactance","valid_range":{"max":null,"min":0}},{"name":"H","data_type":"Float64","null_value":0,"comment":"Motor Inertia Constant [s]","valid_range":{"max":null,"min":0}},{"name":"A","data_type":"Float64","null_value":"0.0","comment":"Torque-Speed Quadratic Term","valid_range":{"max":1,"min":0}},{"name":"B","data_type":"Float64","null_value":"0.0","comment":"Torque-Speed Linear Term","valid_range":{"max":1,"min":0}},{"name":"base_power","data_type":"Float64","null_value":0,"comment":"Base power","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"C","data_type":"Float64","comment":"Torque-Speed Constant Term","internal_default":"PowerSystems.calculate_IM_torque_params(A, B)"},{"name":"τ_ref","data_type":"Float64","comment":"Reference torque parameter","internal_default":"1.0"},{"name":"B_shunt","data_type":"Float64","comment":"Susceptance Initialization Corrector Term","internal_default":"0.0"},{"name":"X_ad","data_type":"Float64","comment":"Equivalent d-axis reactance","internal_default":"(1.0 / X_m + 1.0 / X_ls + 1.0 / X_lr)^(-1)"},{"name":"X_aq","data_type":"Float64","comment":"Equivalent q-axis reactance","internal_default":"X_ad"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tψ_qs: stator flux in the q-axis,\n\tψ_ds: stator flux in the d-axis,\n\tψ_qr: rotor flux in the q-axis,\n\tψ_dr: rotor flux in the d-axis, \n\tωr: Rotor speed [pu],","internal_default":"[:ψ_qs, :ψ_ds, :ψ_qr, :ψ_dr, :ωr]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"SingleCageInductionMachine has 5 states","internal_default":5},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of 5-states three-phase single cage induction machine with quadratic torque-speed relationship.","struct_name":"SingleCageInductionMachine","supertype":"DynamicInjection"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"R_s","data_type":"Float64","null_value":0,"comment":"Armature stator resistance","valid_range":{"max":null,"min":0}},{"name":"R_r","data_type":"Float64","null_value":0,"comment":"Rotor resistance","valid_range":{"max":null,"min":0}},{"name":"X_ls","data_type":"Float64","null_value":0,"comment":"Stator Leakage Reactance","valid_range":{"max":null,"min":0}},{"name":"X_lr","data_type":"Float64","null_value":0,"comment":"Rotor Leakage Reactance","valid_range":{"max":null,"min":0}},{"name":"X_m","data_type":"Float64","null_value":0,"comment":"Stator-Rotor Mutual Reactance","valid_range":{"max":null,"min":0}},{"name":"H","data_type":"Float64","null_value":0,"comment":"Motor Inertia Constant [s]","valid_range":{"max":null,"min":0}},{"name":"A","data_type":"Float64","null_value":"0.0","comment":"Torque-Speed Quadratic Term","valid_range":{"max":1,"min":0}},{"name":"B","data_type":"Float64","null_value":"0.0","comment":"Torque-Speed Linear Term","valid_range":{"max":1,"min":0}},{"name":"base_power","data_type":"Float64","null_value":0,"comment":"Base power","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"C","data_type":"Float64","comment":"Torque-Speed Constant Term","internal_default":"PowerSystems.calculate_IM_torque_params(A, B)"},{"name":"τ_ref","data_type":"Float64","comment":"Reference torque parameter","internal_default":"1.0"},{"name":"B_shunt","data_type":"Float64","comment":"Susceptance Initialization Corrector Term","internal_default":"0.0"},{"name":"X_ss","data_type":"Float64","comment":"Stator self reactance","internal_default":"X_ls + X_m"},{"name":"X_rr","data_type":"Float64","comment":"Rotor self reactance","internal_default":"X_lr + X_m"},{"name":"X_p","data_type":"Float64","comment":"Transient reactance","internal_default":"X_ss - X_m^2 / X_rr"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tψ_qr: rotor flux in the q-axis,\n\tψ_dr: rotor flux in the d-axis, \n\tωr: Rotor speed [pu],","internal_default":"[:ψ_qr, :ψ_dr, :ωr]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"SimplifiedSingleCageInductionMachine has 3 states","internal_default":3},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of 3-states three-phase single cage induction machine with quadratic torque-speed relationship.","struct_name":"SimplifiedSingleCageInductionMachine","supertype":"DynamicInjection"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"a","data_type":"Float64","null_value":0,"comment":"Active power static exponential coefficient","valid_range":{"max":null,"min":0}},{"name":"b","data_type":"Float64","null_value":0,"comment":"Reactive power static exponential coefficient","valid_range":{"max":null,"min":0}},{"name":"α","data_type":"Float64","null_value":0,"comment":"Active power transient exponential coefficient","valid_range":{"max":null,"min":0}},{"name":"β","data_type":"Float64","null_value":0,"comment":"Reactive power transient exponential coefficient","valid_range":{"max":null,"min":0}},{"name":"T_p","data_type":"Float64","null_value":0,"comment":"Active Power Time Constant","valid_range":{"max":null,"min":0}},{"name":"T_q","data_type":"Float64","null_value":0,"comment":"Reactive Power Time Constant","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"base_power","data_type":"Float64","comment":"Base Power","internal_default":"100.0"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tx_p: Integrator state of the active power,\n\tx_q: Integrator state of the reactive power,","internal_default":"[:x_p, :x_q]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"DynamicExponentialLoad has 2 states","internal_default":2},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of 2-states of a generic dynamic load model based on VOLTAGE STABILITY ANALYSIS USING GENERIC DYNAMIC LOAD MODELS by W. Xu and Y. Mansour, IEEE Transactions on Power Systems, 1994.","struct_name":"DynamicExponentialLoad","supertype":"DynamicInjection"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"r_load","data_type":"Float64","null_value":0,"comment":"DC-side resistor","valid_range":{"max":null,"min":0}},{"name":"c_dc","data_type":"Float64","null_value":0,"comment":"DC-side capacitor","valid_range":{"max":null,"min":0}},{"name":"rf","data_type":"Float64","null_value":0,"comment":"Converter side filter resistance","valid_range":{"max":null,"min":0}},{"name":"lf","data_type":"Float64","null_value":0,"comment":"Converter side filter inductance","valid_range":{"max":null,"min":0}},{"name":"cf","data_type":"Float64","null_value":0,"comment":"AC Converter filter capacitance","valid_range":{"max":null,"min":0}},{"name":"rg","data_type":"Float64","null_value":0,"comment":"Network side filter resistance","valid_range":{"max":null,"min":0}},{"name":"lg","data_type":"Float64","null_value":0,"comment":"Network side filter inductance","valid_range":{"max":null,"min":0}},{"name":"kp_pll","data_type":"Float64","null_value":0,"comment":"Proportional constant for PI-PLL block","valid_range":{"max":null,"min":0}},{"name":"ki_pll","data_type":"Float64","null_value":0,"comment":"Integral constant for PI-PLL block","valid_range":{"max":null,"min":0}},{"name":"kpv","data_type":"Float64","null_value":0,"comment":"Proportional constant for Voltage Control block","valid_range":{"max":null,"min":0}},{"name":"kiv","data_type":"Float64","null_value":0,"comment":"Integral constant for Voltage Control block","valid_range":{"max":null,"min":0}},{"name":"kpc","data_type":"Float64","null_value":0,"comment":"Proportional constant for Current Control block","valid_range":{"max":null,"min":0}},{"name":"kic","data_type":"Float64","null_value":0,"comment":"Integral constant for Current Control block","valid_range":{"max":null,"min":0}},{"name":"base_power","data_type":"Float64","null_value":0,"comment":"Base power","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"P_ref","data_type":"Float64","comment":"Reference active power parameter","internal_default":"1.0"},{"name":"Q_ref","data_type":"Float64","comment":"Reference reactive power parameter","internal_default":"1.0"},{"name":"V_ref","data_type":"Float64","comment":"Reference voltage parameter","internal_default":"1.0"},{"name":"ω_ref","data_type":"Float64","comment":"Reference frequency parameter","internal_default":"1.0"},{"name":"is_filter_differential","data_type":"Int","comment":"Boolean to decide if filter states are differential or algebraic","internal_default":"1"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tθ_pll: PLL deviation angle, \n\tϵ_pll: PLL integrator state, \n\tη: DC-voltage controller integrator state, \n\tv_dc: DC voltage at the capacitor, \n\tγd: d-axis Current controller integrator state, \n\tγq: q-axis Current controller integrator state, \n\tir_cnv: Real current out of the converter,\n\tii_cnv: Imaginary current out of the converter,\n\tvr_filter: Real voltage at the filter's capacitor,\n\tvi_filter: Imaginary voltage at the filter's capacitor,\n\tir_filter: Real current out of the filter,\n\tii_filter: Imaginary current out of the filter","internal_default":"[:θ_pll, :ϵ_pll, :η, :v_dc, :γd, :γq, :ir_cnv, :ii_cnv, :vr_filter, :vi_filter, :ir_filter, :ii_filter]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"ActiveConstantPowerLoad has 12 states","internal_default":12},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of 12-states active power load based on the paper Dynamic Stability of a Microgrid With an Active Load from N. Bottrell, M. Prodanovic and T. Green in IEEE Transactions on Power Electronics, 2013.","struct_name":"ActiveConstantPowerLoad","supertype":"DynamicInjection"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"bus","data_type":"ACBus","null_value":"ACBus(nothing)"},{"name":"dc_bus","data_type":"DCBus","null_value":"DCBus(nothing)"},{"name":"active_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"Active Power on the DCSide","valid_range":"active_power_limits"},{"name":"rating","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"Thermal limited MVA Power Output of the converter. <= Capacity","valid_range":{"max":null,"min":0}},{"name":"active_power_limits","needs_conversion":true,"data_type":"MinMax","null_value":"(min=0.0, max=0.0)"},{"name":"base_power","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"Base power of the converter in MVA","valid_range":{"max":null,"min":0}},{"name":"operation_cost","default":"TwoPartCost(0.0, 0.0)","data_type":"OperationalCost","null_value":"TwoPartCost(nothing)","comment":"Operation Cost of Generation [`OperationalCost`](@ref)"},{"name":"efficiency","default":"1.0","data_type":"Float64","null_value":"0.0","comment":"Conversion efficiency from AC Power to DC Power"},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"dynamic_injector","default":"nothing","data_type":"Union{Nothing, DynamicInjection}","exclude_setter":true,"null_value":"nothing","comment":"corresponding dynamic injection device"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Interconnecting Power Converter (IPC) for transforming power from an ACBus to a DCBus","struct_name":"InterconnectingConverter","supertype":"StaticInjection"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"K","data_type":"Float64","null_value":0,"comment":"Gain in pu","valid_range":{"max":null,"min":0}},{"name":"T1","data_type":"Float64","null_value":0,"comment":"Time constant in s","valid_range":{"max":null,"min":0}},{"name":"T2","data_type":"Float64","null_value":0,"comment":"Time constant in s","valid_range":{"max":null,"min":0}},{"name":"T3","data_type":"Float64","null_value":0,"comment":"Time constant in s","valid_range":{"max":null,"min":"eps()"}},{"name":"T4","data_type":"Float64","null_value":0,"comment":"Time constant in s","valid_range":{"max":null,"min":0}},{"name":"T5","data_type":"Float64","null_value":0,"comment":"Time constant in s","valid_range":{"max":null,"min":0}},{"name":"Rmin","data_type":"Float64","null_value":0,"comment":"Reactor minimum Mvar","valid_range":{"max":null,"min":0}},{"name":"Vmax","data_type":"Float64","null_value":0,"comment":"Maximum voltage in pu","valid_range":{"max":null,"min":0}},{"name":"Vmin","data_type":"Float64","null_value":0,"comment":"Minimum voltage in pu","valid_range":{"max":null,"min":0}},{"name":"CBase","data_type":"Float64","null_value":0,"comment":"Capacitor Mvar","valid_range":{"max":null,"min":0}},{"name":"base_power","data_type":"Float64","null_value":0,"comment":"Base power","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"R_th","data_type":"Float64","comment":"Source Thevenin resistance","internal_default":"0.0"},{"name":"X_th","data_type":"Float64","comment":"Source Thevenin reactance","internal_default":"0.0"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tthy: thyristor,\n\tvr1: regulator output 1,\n\tvr2: regulator output 2","internal_default":"[:thy, :vr1, :vr2]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"CSVGN1 has 3 states","internal_default":3},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of static shunt compensator: CSVGN1 in PSSE","struct_name":"CSVGN1","supertype":"DynamicInjection"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"bus","data_type":"ACBus","null_value":"ACBus(nothing)"},{"name":"active_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"reactive_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"warn","valid_range":"reactive_power_limits"},{"name":"rating","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"Thermal limited MVA Power Output of the unit. <= Capacity","valid_range":{"max":null,"min":0}},{"name":"prime_mover_type","data_type":"PrimeMovers","null_value":"PrimeMovers.HY","comment":"Prime mover technology according to EIA 923"},{"name":"active_power_limits","needs_conversion":true,"data_type":"MinMax","null_value":"(min=0.0, max=0.0)"},{"name":"reactive_power_limits","needs_conversion":true,"data_type":"Union{Nothing, MinMax}","null_value":"nothing","validation_action":"warn"},{"name":"ramp_limits","needs_conversion":true,"data_type":"Union{Nothing, UpDown}","null_value":"nothing","validation_action":"error","comment":"ramp up and ramp down limits in MW (in component base per unit) per minute","valid_range":{"max":null,"min":0}},{"name":"time_limits","data_type":"Union{Nothing, UpDown}","null_value":"nothing","validation_action":"error","comment":"Minimum up and Minimum down time limits in hours","valid_range":{"max":null,"min":0}},{"name":"base_power","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"Base power of the unit in MVA","valid_range":{"max":null,"min":0}},{"name":"storage_capacity","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"Maximum storage capacity in the reservoir (units can be p.u-hr or m^3).","valid_range":{"max":null,"min":0}},{"name":"inflow","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"Baseline inflow into the reservoir (units can be p.u. or m^3/hr)","valid_range":{"max":null,"min":0}},{"name":"initial_storage","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"Initial storage capacity in the reservoir (units can be p.u-hr or m^3).","valid_range":{"max":null,"min":0}},{"name":"operation_cost","default":"TwoPartCost(0.0, 0.0)","data_type":"OperationalCost","null_value":"TwoPartCost(nothing)","comment":"Operation Cost of Generation [`OperationalCost`](@ref)"},{"name":"storage_target","default":"1.0","data_type":"Float64","null_value":"0.0","comment":"Storage target at the end of simulation as ratio of storage capacity."},{"name":"conversion_factor","default":"1.0","data_type":"Float64","null_value":"0.0","comment":"Conversion factor from flow/volume to energy: m^3 -> p.u-hr."},{"name":"time_at_status","default":"INFINITE_TIME","data_type":"Float64","null_value":"INFINITE_TIME"},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"dynamic_injector","default":"nothing","data_type":"Union{Nothing, DynamicInjection}","exclude_setter":true,"null_value":"nothing","comment":"corresponding dynamic injection device"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"struct_name":"HydroEnergyReservoir","supertype":"HydroGen"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"bus","data_type":"ACBus","null_value":"ACBus(nothing)"},{"name":"active_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"reactive_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"warn","valid_range":"reactive_power_limits"},{"name":"rating","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"Thermal limited MVA Power Output of the unit. <= Capacity","valid_range":{"max":null,"min":0}},{"name":"prime_mover_type","data_type":"PrimeMovers","null_value":"PrimeMovers.HY","comment":"Prime mover technology according to EIA 923"},{"name":"active_power_limits","needs_conversion":true,"data_type":"MinMax","null_value":"(min=0.0, max=0.0)","validation_action":"warn","valid_range":{"max":null,"min":0}},{"name":"reactive_power_limits","needs_conversion":true,"data_type":"Union{Nothing, MinMax}","null_value":"nothing","validation_action":"warn"},{"name":"ramp_limits","needs_conversion":true,"data_type":"Union{Nothing, UpDown}","null_value":"nothing","validation_action":"error","comment":"ramp up and ramp down limits in MW (in component base per unit) per minute","valid_range":{"max":null,"min":0}},{"name":"time_limits","data_type":"Union{Nothing, UpDown}","null_value":"nothing","validation_action":"error","comment":"Minimum up and Minimum down time limits in hours","valid_range":{"max":null,"min":0}},{"name":"base_power","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"Base power of the unit in MVA","valid_range":{"max":null,"min":0}},{"name":"operation_cost","default":"TwoPartCost(0.0, 0.0)","data_type":"OperationalCost","null_value":"TwoPartCost(nothing)","comment":"Operation Cost of Generation [`OperationalCost`](@ref)"},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"dynamic_injector","default":"nothing","data_type":"Union{Nothing, DynamicInjection}","exclude_setter":true,"null_value":"nothing","comment":"corresponding dynamic injection device"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"struct_name":"HydroDispatch","supertype":"HydroGen"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"bus","data_type":"ACBus","null_value":"ACBus(nothing)"},{"name":"active_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"reactive_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"rating","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"Thermal limited MVA Power Output of the unit. <= Capacity","valid_range":{"max":null,"min":0}},{"name":"base_power","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"Base power of the unit in MVA","valid_range":{"max":null,"min":0}},{"name":"prime_mover_type","data_type":"PrimeMovers","null_value":"PrimeMovers.HY","comment":"Prime mover technology according to EIA 923"},{"name":"active_power_limits","needs_conversion":true,"data_type":"MinMax","null_value":"(min=0.0, max=0.0)","validation_action":"warn","valid_range":{"max":null,"min":0}},{"name":"reactive_power_limits","needs_conversion":true,"data_type":"Union{Nothing, MinMax}","null_value":"nothing","validation_action":"warn"},{"name":"ramp_limits","needs_conversion":true,"data_type":"Union{Nothing, UpDown}","null_value":"nothing","validation_action":"error","comment":"ramp up and ramp down limits in MW (in component base per unit) per minute","valid_range":{"max":null,"min":0}},{"name":"time_limits","data_type":"Union{Nothing, UpDown}","null_value":"nothing","validation_action":"error","comment":"Minimum up and Minimum down time limits in hours","valid_range":{"max":null,"min":0}},{"name":"rating_pump","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"Thermal limited MVA Power Withdrawl of the pump. <= Capacity","valid_range":{"max":null,"min":0}},{"name":"active_power_limits_pump","needs_conversion":true,"data_type":"MinMax","null_value":"(min=0.0, max=0.0)"},{"name":"reactive_power_limits_pump","needs_conversion":true,"data_type":"Union{Nothing, MinMax}","null_value":"nothing","validation_action":"warn"},{"name":"ramp_limits_pump","needs_conversion":true,"data_type":"Union{Nothing, UpDown}","null_value":"nothing","validation_action":"error","comment":"ramp up and ramp down limits in MW (in component base per unit) per minute of pump","valid_range":{"max":null,"min":0}},{"name":"time_limits_pump","data_type":"Union{Nothing, UpDown}","null_value":"nothing","validation_action":"error","comment":"Minimum up and Minimum down time limits of pump in hours","valid_range":{"max":null,"min":0}},{"name":"storage_capacity","needs_conversion":true,"data_type":"UpDown","null_value":"(up=0.0, down=0.0)","validation_action":"error","comment":"Maximum storage capacity in the upper and lower reservoirs (units can be p.u-hr or m^3).","valid_range":{"max":null,"min":0}},{"name":"inflow","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"Baseline inflow into the upper reservoir (units can be p.u. or m^3/hr)","valid_range":{"max":null,"min":0}},{"name":"outflow","data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"Baseline outflow from the lower reservoir (units can be p.u. or m^3/hr)","valid_range":{"max":null,"min":0}},{"name":"initial_storage","needs_conversion":true,"data_type":"UpDown","null_value":"(up=0.0, down=0.0)","validation_action":"error","comment":"Initial storage capacity in the upper and lower reservoir (units can be p.u-hr or m^3).","valid_range":{"max":null,"min":0}},{"name":"storage_target","default":"(up=1.0, down=1.0)","data_type":"UpDown","null_value":"(up=0.0, down=0.0)","comment":"Storage target of upper reservoir at the end of simulation as ratio of storage capacity."},{"name":"operation_cost","default":"TwoPartCost(0.0, 0.0)","data_type":"OperationalCost","null_value":"TwoPartCost(nothing)","comment":"Operation Cost of Generation [`OperationalCost`](@ref)"},{"name":"pump_efficiency","default":"1.0","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"Efficiency of pump","valid_range":{"max":1,"min":0}},{"name":"conversion_factor","default":"1.0","data_type":"Float64","null_value":"0.0","comment":"Conversion factor from flow/volume to energy: m^3 -> p.u-hr."},{"name":"time_at_status","default":"INFINITE_TIME","data_type":"Float64","null_value":"INFINITE_TIME"},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"dynamic_injector","default":"nothing","data_type":"Union{Nothing, DynamicInjection}","exclude_setter":true,"null_value":"nothing","comment":"corresponding dynamic injection device"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"struct_name":"HydroPumpedStorage","supertype":"HydroGen"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"bus","data_type":"ACBus","null_value":"ACBus(nothing)"},{"name":"active_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"reactive_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"rating","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"Thermal limited MVA Power Output of the unit. <= Capacity","valid_range":{"max":null,"min":0}},{"name":"prime_mover_type","data_type":"PrimeMovers","null_value":"PrimeMovers.OT","comment":"Prime mover technology according to EIA 923"},{"name":"reactive_power_limits","needs_conversion":true,"data_type":"Union{Nothing, MinMax}","null_value":"nothing"},{"name":"power_factor","data_type":"Float64","null_value":"1.0","validation_action":"error","valid_range":{"max":1,"min":0}},{"name":"operation_cost","data_type":"TwoPartCost","null_value":"TwoPartCost(nothing)","comment":"Operation Cost of Generation [`TwoPartCost`](@ref)"},{"name":"base_power","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"Base power of the unit in MVA","valid_range":{"max":null,"min":0}},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"dynamic_injector","default":"nothing","data_type":"Union{Nothing, DynamicInjection}","exclude_setter":true,"null_value":"nothing","comment":"corresponding dynamic injection device"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"struct_name":"RenewableDispatch","supertype":"RenewableGen"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"bus","data_type":"ACBus","null_value":"ACBus(nothing)"},{"name":"active_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"reactive_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"rating","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"Thermal limited MVA Power Output of the unit. <= Capacity","valid_range":{"max":null,"min":0}},{"name":"prime_mover_type","data_type":"PrimeMovers","null_value":"PrimeMovers.OT","comment":"Prime mover technology according to EIA 923"},{"name":"power_factor","data_type":"Float64","null_value":"1.0","validation_action":"error","valid_range":{"max":1,"min":0}},{"name":"base_power","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"Base power of the unit in MVA","valid_range":{"max":null,"min":0}},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"dynamic_injector","default":"nothing","data_type":"Union{Nothing, DynamicInjection}","exclude_setter":true,"null_value":"nothing","comment":"corresponding dynamic injection device"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Data Structure for fixed renewable generation technologies.","struct_name":"RenewableFix","supertype":"RenewableGen"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"status","data_type":"Bool","null_value":"false"},{"name":"bus","data_type":"ACBus","null_value":"ACBus(nothing)"},{"name":"active_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"warn","valid_range":"active_power_limits"},{"name":"reactive_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"warn","valid_range":"reactive_power_limits"},{"name":"rating","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"Thermal limited MVA Power Output of the unit. <= Capacity","valid_range":{"max":null,"min":0}},{"name":"active_power_limits","needs_conversion":true,"data_type":"MinMax","null_value":"(min=0.0, max=0.0)","validation_action":"warn","valid_range":{"max":null,"min":0}},{"name":"reactive_power_limits","needs_conversion":true,"data_type":"Union{Nothing, MinMax}","null_value":"nothing"},{"name":"ramp_limits","needs_conversion":true,"data_type":"Union{Nothing, UpDown}","null_value":"nothing","validation_action":"error","comment":"ramp up and ramp down limits in MW (in component base per unit) per minute","valid_range":{"max":null,"min":0}},{"name":"operation_cost","data_type":"OperationalCost","null_value":"ThreePartCost(nothing)"},{"name":"base_power","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"Base power of the unit in MVA","valid_range":{"max":null,"min":0}},{"name":"time_limits","default":"nothing","data_type":"Union{Nothing, UpDown}","null_value":"nothing","validation_action":"error","comment":"Minimum up and Minimum down time limits in hours","valid_range":{"max":null,"min":0}},{"name":"must_run","default":"false","data_type":"Bool","null_value":"false"},{"name":"prime_mover_type","default":"PrimeMovers.OT","data_type":"PrimeMovers","null_value":"PrimeMovers.OT","comment":"Prime mover technology according to EIA 923"},{"name":"fuel","default":"ThermalFuels.OTHER","data_type":"ThermalFuels","null_value":"ThermalFuels.OTHER","comment":"Prime mover fuel according to EIA 923"},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"time_at_status","default":"INFINITE_TIME","data_type":"Float64","null_value":"INFINITE_TIME"},{"name":"dynamic_injector","default":"nothing","data_type":"Union{Nothing, DynamicInjection}","exclude_setter":true,"null_value":"nothing","comment":"corresponding dynamic injection device"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Data Structure for thermal generation technologies.","struct_name":"ThermalStandard","supertype":"ThermalGen"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"status","data_type":"Bool","null_value":"false"},{"name":"bus","data_type":"ACBus","null_value":"ACBus(nothing)"},{"name":"active_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"warn","valid_range":"active_power_limits"},{"name":"reactive_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"warn","valid_range":"reactive_power_limits"},{"name":"rating","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"Thermal limited MVA Power Output of the unit. <= Capacity","valid_range":{"max":null,"min":0}},{"name":"prime_mover_type","data_type":"PrimeMovers","null_value":"PrimeMovers.OT","comment":"Prime mover technology according to EIA 923"},{"name":"fuel","data_type":"ThermalFuels","null_value":"ThermalFuels.OTHER","comment":"Prime mover fuel according to EIA 923"},{"name":"active_power_limits","needs_conversion":true,"data_type":"MinMax","null_value":"(min=0.0, max=0.0)"},{"name":"reactive_power_limits","needs_conversion":true,"data_type":"Union{Nothing, MinMax}","null_value":"nothing"},{"name":"ramp_limits","needs_conversion":true,"data_type":"Union{Nothing, UpDown}","null_value":"nothing","validation_action":"error","valid_range":{"max":null,"min":0}},{"name":"power_trajectory","needs_conversion":true,"data_type":"Union{Nothing, StartUpShutDown}","null_value":"nothing","validation_action":"error","comment":"Power trajectory the unit will take during the start-up and shut-down ramp process","valid_range":{"max":null,"min":0}},{"name":"time_limits","data_type":"Union{Nothing, UpDown}","null_value":"nothing","validation_action":"error","comment":"Minimum up and Minimum down time limits in hours","valid_range":{"max":null,"min":0}},{"name":"start_time_limits","data_type":"Union{Nothing, NamedTuple{(:hot, :warm, :cold), Tuple{Float64, Float64, Float64}}}","null_value":"nothing","comment":" Time limits for start-up based on turbine temperature in hours"},{"name":"start_types","data_type":"Int","null_value":"1","validation_action":"error","comment":" Number of start-up based on turbine temperature","valid_range":{"max":3,"min":1}},{"name":"operation_cost","data_type":"OperationalCost","null_value":"MultiStartCost(nothing)"},{"name":"base_power","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"Base power of the unit in MVA","valid_range":{"max":null,"min":0}},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"time_at_status","default":"INFINITE_TIME","data_type":"Float64","null_value":"INFINITE_TIME"},{"name":"must_run","default":"false","data_type":"Bool","null_value":"false"},{"name":"dynamic_injector","default":"nothing","data_type":"Union{Nothing, DynamicInjection}","exclude_setter":true,"null_value":"nothing","comment":"corresponding dynamic injection device"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Data Structure for thermal generation technologies.","struct_name":"ThermalMultiStart","supertype":"ThermalGen"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"bus","data_type":"ACBus","null_value":"ACBus(nothing)"},{"name":"prime_mover_type","data_type":"PrimeMovers","null_value":"PrimeMovers.BA","comment":"Prime mover technology according to EIA 923"},{"name":"initial_energy","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"State of Charge of the Battery p.u.-hr","valid_range":{"max":null,"min":0}},{"name":"state_of_charge_limits","needs_conversion":true,"data_type":"MinMax","null_value":"(min=0.0, max=0.0)","validation_action":"error","comment":"Maximum and Minimum storage capacity in p.u.-hr","valid_range":{"max":null,"min":0}},{"name":"rating","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"active_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"input_active_power_limits","needs_conversion":true,"data_type":"MinMax","null_value":"(min=0.0, max=0.0)","validation_action":"error","valid_range":{"max":null,"min":0}},{"name":"output_active_power_limits","needs_conversion":true,"data_type":"MinMax","null_value":"(min=0.0, max=0.0)","validation_action":"error","valid_range":{"max":null,"min":0}},{"name":"efficiency","data_type":"NamedTuple{(:in, :out), Tuple{Float64, Float64}}","null_value":"(in=0.0, out=0.0)","validation_action":"warn","valid_range":{"max":1,"min":0}},{"name":"reactive_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"warn","valid_range":"reactive_power_limits"},{"name":"reactive_power_limits","needs_conversion":true,"data_type":"Union{Nothing, MinMax}","null_value":"(min=0.0, max=0.0)"},{"name":"base_power","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"Base power of the unit in MVA","valid_range":{"max":null,"min":0}},{"name":"operation_cost","default":"StorageManagementCost()","data_type":"Union{StorageManagementCost, MarketBidCost}","null_value":"StorageManagementCost()"},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"dynamic_injector","default":"nothing","data_type":"Union{Nothing, DynamicInjection}","exclude_setter":true,"null_value":"nothing","comment":"corresponding dynamic injection device"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Data structure for a generic battery","struct_name":"GenericBattery","supertype":"Storage"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"bus","data_type":"ACBus","null_value":"ACBus(nothing)"},{"name":"prime_mover_type","data_type":"PrimeMovers","null_value":"PrimeMovers.BA","comment":"Prime mover technology according to EIA 923"},{"name":"initial_energy","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"State of Charge of the Battery p.u.-hr","valid_range":{"max":null,"min":0}},{"name":"state_of_charge_limits","needs_conversion":true,"data_type":"MinMax","null_value":"(min=0.0, max=0.0)","validation_action":"error","comment":"Maximum and Minimum storage capacity in p.u.-hr","valid_range":{"max":null,"min":0}},{"name":"rating","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"active_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0"},{"name":"input_active_power_limits","needs_conversion":true,"data_type":"MinMax","null_value":"(min=0.0, max=0.0)","validation_action":"error","valid_range":{"max":null,"min":0}},{"name":"output_active_power_limits","needs_conversion":true,"data_type":"MinMax","null_value":"(min=0.0, max=0.0)","validation_action":"error","valid_range":{"max":null,"min":0}},{"name":"efficiency","data_type":"NamedTuple{(:in, :out), Tuple{Float64, Float64}}","null_value":"(in=0.0, out=0.0)","validation_action":"warn","valid_range":{"max":1,"min":0}},{"name":"reactive_power","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"warn","valid_range":"reactive_power_limits"},{"name":"reactive_power_limits","needs_conversion":true,"data_type":"Union{Nothing, MinMax}","null_value":"(min=0.0, max=0.0)"},{"name":"base_power","data_type":"Float64","null_value":"0.0","validation_action":"warn","comment":"Base power of the unit in MVA","valid_range":{"max":null,"min":0}},{"name":"operation_cost","default":"Union{StorageManagementCost, MarketBidCost}","data_type":"StorageManagementCost","null_value":"StorageManagementCost()"},{"name":"storage_target","default":"0.0","data_type":"Float64","null_value":"0.0","comment":"Storage target at the end of simulation as ratio of storage capacity."},{"name":"cycle_limits","default":"1e4","data_type":"Int","null_value":"0","comment":"Storage Maximum number of cycles per year"},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"dynamic_injector","default":"nothing","data_type":"Union{Nothing, DynamicInjection}","exclude_setter":true,"null_value":"nothing","comment":"corresponding dynamic injection device"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Data structure for a battery compatible with energy management formulations.","struct_name":"BatteryEMS","supertype":"Storage"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"time_frame","data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"the saturation time_frame in minutes to provide reserve contribution","valid_range":{"max":null,"min":0}},{"name":"requirement","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"the static value of required reserves in system p.u.","valid_range":{"max":null,"min":0}},{"name":"sustained_time","default":"3600.0","data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"the time in secounds reserve contribution must sustained at a specified level","valid_range":{"max":null,"min":0}},{"name":"max_output_fraction","default":"1.0","data_type":"Float64","null_value":"1.0","validation_action":"error","comment":"the maximum fraction of the device's output that can be assigned to the service","valid_range":{"max":1,"min":0}},{"name":"max_participation_factor","default":"1.0","data_type":"Float64","null_value":"1.0","validation_action":"error","comment":"the maximum limit of reserve contribution per device","valid_range":{"max":1,"min":0}},{"name":"deployed_fraction","default":"0.0","data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"Fraction of ancillary services participation deployed from the assignment","valid_range":{"max":1,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Data Structure for a proportional reserve product for system simulations.","parametric":"ReserveDirection","struct_name":"StaticReserve","supertype":"Reserve{T}"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"time_frame","data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"the saturation time_frame in minutes to provide reserve contribution","valid_range":{"max":null,"min":0}},{"name":"requirement","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"the static value of required reserves in system p.u.","valid_range":{"max":null,"min":0}},{"name":"sustained_time","default":"3600.0","data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"the time in secounds reserve contribution must sustained at a specified level","valid_range":{"max":null,"min":0}},{"name":"max_output_fraction","default":"1.0","data_type":"Float64","null_value":"1.0","validation_action":"error","comment":"the maximum fraction of the device's output that can be assigned to the service","valid_range":{"max":1,"min":0}},{"name":"max_participation_factor","default":"1.0","data_type":"Float64","null_value":"1.0","validation_action":"error","comment":"the maximum limit of reserve contribution per device","valid_range":{"max":1,"min":0}},{"name":"deployed_fraction","default":"0.0","data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"Fraction of ancillary services participation deployed from the assignment","valid_range":{"max":1,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Data Structure for a non-spinning reserve product for system simulations.","struct_name":"StaticReserveNonSpinning","supertype":"ReserveNonSpinning"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"requirement","needs_conversion":true,"data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"the static value of required reserves in system p.u.","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"contributing_services","default":"Vector{Service}()","data_type":"Vector{Service}","exclude_setter":true,"null_value":"Vector{Service}()","comment":"Services that contribute for this requirement constraint"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Data Structure for a group reserve product for system simulations.","parametric":"ReserveDirection","struct_name":"StaticReserveGroup","supertype":"Service"},{"fields":[{"name":"variable","data_type":"Union{Nothing, IS.TimeSeriesKey}","null_value":"nothing","comment":"Variable Cost TimeSeriesKey"},{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"time_frame","data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"the saturation time_frame in minutes to provide reserve contribution","valid_range":{"max":null,"min":0}},{"name":"sustained_time","default":"3600.0","data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"the time in secounds reserve contribution must sustained at a specified level","valid_range":{"max":null,"min":0}},{"name":"max_participation_factor","default":"1.0","data_type":"Float64","null_value":"1.0","validation_action":"error","comment":"the maximum limit of reserve contribution per device","valid_range":{"max":1,"min":0}},{"name":"deployed_fraction","default":"0.0","data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"Fraction of ancillary services participation deployed from the assignment","valid_range":{"max":1,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Data Structure for a operating reserve with demand curve product for system simulations.","parametric":"ReserveDirection","struct_name":"ReserveDemandCurve","supertype":"Reserve{T}"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"time_frame","data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"the saturation time_frame in minutes to provide reserve contribution","valid_range":{"max":null,"min":0}},{"name":"requirement","data_type":"Float64","null_value":"0.0","comment":"the required quantity of the product should be scaled by a TimeSeriesData"},{"name":"sustained_time","default":"3600.0","data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"the time in secounds reserve contribution must sustained at a specified level","valid_range":{"max":null,"min":0}},{"name":"max_output_fraction","default":"1.0","data_type":"Float64","null_value":"1.0","validation_action":"error","comment":"the maximum fraction of the device's output that can be assigned to the service","valid_range":{"max":1,"min":0}},{"name":"max_participation_factor","default":"1.0","data_type":"Float64","null_value":"1.0","validation_action":"error","comment":"the maximum limit of reserve contribution per device","valid_range":{"max":1,"min":0}},{"name":"deployed_fraction","default":"0.0","data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"Fraction of ancillary services participation deployed from the assignment","valid_range":{"max":1,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Data Structure for the procurement products for system simulations.","parametric":"ReserveDirection","struct_name":"VariableReserve","supertype":"Reserve{T}"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"time_frame","data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"the saturation time_frame in minutes to provide reserve contribution","valid_range":{"max":null,"min":0}},{"name":"requirement","needs_conversion":true,"data_type":"Float64","null_value":"0.0","comment":"the required quantity of the product should be scaled by a TimeSeriesData"},{"name":"sustained_time","default":"14400.0","data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"the time in secounds reserve contribution must sustained at a specified level","valid_range":{"max":null,"min":0}},{"name":"max_output_fraction","default":"1.0","data_type":"Float64","null_value":"1.0","validation_action":"error","comment":"the maximum fraction of the device's output that can be assigned to the service","valid_range":{"max":1,"min":0}},{"name":"max_participation_factor","default":"1.0","data_type":"Float64","null_value":"1.0","validation_action":"error","comment":"the maximum limit of reserve contribution per device","valid_range":{"max":1,"min":0}},{"name":"deployed_fraction","default":"0.0","data_type":"Float64","null_value":"0.0","validation_action":"error","comment":"Fraction of ancillary services participation deployed from the assignment","valid_range":{"max":1,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Data Structure for the procurement products for system simulations.","struct_name":"VariableReserveNonSpinning","supertype":"ReserveNonSpinning"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"bias","data_type":"Float64","null_value":"0.0"},{"name":"K_p","data_type":"Float64","null_value":"0.0","comment":"PID Proportional Constant"},{"name":"K_i","data_type":"Float64","null_value":"0.0","comment":"PID Integral Constant"},{"name":"K_d","data_type":"Float64","null_value":"0.0","comment":"PID Derrivative Constant"},{"name":"delta_t","data_type":"Float64","null_value":"0.0","comment":"PID Discretization period [Seconds]"},{"name":"area","default":"nothing","data_type":"Union{Nothing, Area}","null_value":"Area(nothing)","comment":"the area controlled by the AGC"},{"name":"initial_ace","default":"0.0","data_type":"Float64","null_value":"0.0","comment":"PID Discretization period [Seconds]"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"struct_name":"AGC","supertype":"Service"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"requirement","data_type":"Float64","null_value":"0.0"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"time_series_container","default":"InfrastructureSystems.TimeSeriesContainer()","data_type":"InfrastructureSystems.TimeSeriesContainer","null_value":"InfrastructureSystems.TimeSeriesContainer()","comment":"internal time_series storage"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"struct_name":"Transfer","supertype":"Service"},{"fields":[{"name":"Vf","data_type":"Float64","null_value":0,"comment":"Fixed voltage field applied to the rotor winding","valid_range":{"max":null,"min":0}},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"Fixed AVR has no states","internal_default":"Vector{Symbol}()"},{"name":"n_states","data_type":"Int","exclude_setter":true,"null_value":0,"comment":"Fixed AVR has no states","internal_default":0},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"Fixed AVR has no states","internal_default":"Vector{StateTypes}()"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of a AVR that returns a fixed voltage to the rotor winding","struct_name":"AVRFixed","supertype":"AVR"},{"fields":[{"name":"Kv","data_type":"Float64","null_value":0,"comment":"Proportional Gain","valid_range":{"max":null,"min":0}},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tVf: field voltage","internal_default":"[:Vf]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"Fixed AVR has 1 states","internal_default":1},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"Simple AVR has 1 differential states","internal_default":"[StateTypes.Differential]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of a simple proportional AVR in the derivative of EMF\ni.e. an integrator controller on EMF","struct_name":"AVRSimple","supertype":"AVR"},{"fields":[{"name":"Ta_Tb","data_type":"Float64","null_value":0,"comment":"Ratio of lead and lag time constants","valid_range":{"max":null,"min":0}},{"name":"Tb","data_type":"Float64","null_value":0,"comment":"Lag time constant","valid_range":{"max":null,"min":"eps()"}},{"name":"K","data_type":"Float64","null_value":0,"comment":"Gain","valid_range":{"max":null,"min":0}},{"name":"Te","data_type":"Float64","null_value":0,"comment":"Field circuit time constant in s","valid_range":{"max":null,"min":0}},{"name":"V_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Field voltage limits"},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\tVf: Voltage field,\tVr: Lead-lag state","internal_default":"[:Vf, :Vr]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"SEXS has 2 states","internal_default":2},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"SEXS has 2 differential states","internal_default":"[StateTypes.Differential, StateTypes.Differential]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of Simplified Excitation System Model - SEXS in PSSE","struct_name":"SEXS","supertype":"AVR"},{"fields":[{"name":"Tr","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Voltage Measurement Time Constant in s","valid_range":{"max":0.5,"min":0}},{"name":"Ka","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Amplifier Gain","valid_range":{"max":500,"min":10}},{"name":"Ta","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Amplifier Time Constant in s","valid_range":{"max":1,"min":0}},{"name":"Tb","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator input Time Constant in s","valid_range":{"max":null,"min":0}},{"name":"Tc","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator input Time Constant in s","valid_range":{"max":null,"min":0}},{"name":"Vr_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Voltage regulator limits (regulator output) (Vi_min, Vi_max)"},{"name":"Ke","data_type":"Float64","null_value":0,"comment":"Exciter constant related to self-excited field","valid_range":{"max":null,"min":0}},{"name":"Te","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Exciter time constant, integration rate associated with exciter control","valid_range":{"max":1,"min":"eps()"}},{"name":"Kf","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Excitation control system stabilizer gain","valid_range":{"max":0.3,"min":"eps()"}},{"name":"Tf","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Excitation control system stabilizer time constant","valid_range":{"max":null,"min":"eps()"}},{"name":"switch","data_type":"Int","null_value":0,"validation_action":"error","comment":"Switch","valid_range":{"max":1,"min":0}},{"name":"E_sat","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Exciter output voltage for saturation factor: (E1, E2)"},{"name":"Se","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Exciter saturation factor at exciter output voltage: (Se(E1), Se(E2))"},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"saturation_coeffs","default":"PowerSystems.get_avr_saturation(E_sat, Se)","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Coefficients (A,B) of the function: Se(V) = B(V - A)^2/V"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tVt: Terminal Voltage,\n\tVr1: input lead lag,\n\tVr2: Regulator Output,\n\tVf: Exciter Output, \n\tVr3: Rate feedback integrator","internal_default":"[:Vt, :Vr1, :Vr2, :Vf, :Vr3]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"The ESDC1A has 5 states","internal_default":5},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"ESDC1A has 5 differential states","internal_default":"[StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Differential, StateTypes.Differential]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Self-excited shunt fields with the voltage regulator operating in a mode commonly termed buck-boost. \nParameters of IEEE Std 421.5 Type DC1A Excitacion System. This model corresponds to ESDC1A in PSSE and PSLF","struct_name":"ESDC1A","supertype":"AVR"},{"fields":[{"name":"Tr","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Voltage Measurement Time Constant in s","valid_range":{"max":0.5,"min":0}},{"name":"Ka","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Amplifier Gain","valid_range":{"max":500,"min":10}},{"name":"Ta","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Amplifier Time Constant in s","valid_range":{"max":1,"min":0}},{"name":"Tb","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator input Time Constant in s","valid_range":{"max":null,"min":0}},{"name":"Tc","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator input Time Constant in s","valid_range":{"max":null,"min":0}},{"name":"Vr_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Voltage regulator limits (regulator output) (Vi_min, Vi_max)"},{"name":"Ke","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Exciter constant related to self-excited field","valid_range":{"max":1,"min":-1}},{"name":"Te","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Exciter time constant, integration rate associated with exciter control","valid_range":{"max":2,"min":"eps()"}},{"name":"Kf","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Excitation control system stabilizer gain","valid_range":{"max":0.3,"min":0}},{"name":"Tf","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Excitation control system stabilizer time constant. Appropiate Data: 5.0 <= Tf/Kf <= 15.0","valid_range":{"max":1.5,"min":"eps()"}},{"name":"switch","data_type":"Int","null_value":0,"validation_action":"error","comment":"Switch","valid_range":{"max":1,"min":0}},{"name":"E_sat","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Exciter output voltage for saturation factor: (E1, E2)"},{"name":"Se","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Exciter saturation factor at exciter output voltage: (Se(E1), Se(E2))"},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"saturation_coeffs","default":"PowerSystems.get_avr_saturation(E_sat, Se)","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Coefficients (A,B) of the function: Se(V) = B(V - A)^2/V"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tVt: Terminal Voltage,\n\tVr1: input lead lag,\n\tVr2: Regulator Output,\n\tVf: Exciter Output, \n\tVr3: Rate feedback integrator","internal_default":"[:Vt, :Vr1, :Vr2, :Vf, :Vr3]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"The ESDC2A has 5 states","internal_default":5},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"ESDC2A has 5 differential states","internal_default":"[StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Differential, StateTypes.Differential]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Is used to represent field-controlled dc commutator exciters with continuously acting voltage regulators having power supplies derived from the generator or auxiliaries bus.\nParameters of IEEE Std 421.5 Type DC2A Excitacion System. This model corresponds to ESDC2A in PSSE and PSLF","struct_name":"ESDC2A","supertype":"AVR"},{"fields":[{"name":"Tr","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Voltage Measurement Time Constant in s","valid_range":{"max":0.5,"min":0}},{"name":"Ka","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Amplifier Gain","valid_range":{"max":500,"min":10}},{"name":"Ta","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Amplifier Time Constant in s","valid_range":{"max":1,"min":0}},{"name":"Vr_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Voltage regulator limits (regulator output) (Vi_min, Vi_max)"},{"name":"Ke","data_type":"Float64","null_value":0,"comment":"Exciter constant related to self-excited field","valid_range":{"max":1,"min":-1}},{"name":"Te","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Exciter time constant, integration rate associated with exciter control","valid_range":{"max":1,"min":"eps()"}},{"name":"Kf","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Excitation control system stabilizer gain","valid_range":{"max":0.3,"min":"eps()"}},{"name":"Tf","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Excitation control system stabilizer time constant. Appropiate Data: 5 <= Tf/Kf <= 15","valid_range":{"max":null,"min":"eps()"}},{"name":"switch","data_type":"Int","null_value":0,"validation_action":"error","comment":"Switch","valid_range":{"max":1,"min":0}},{"name":"E_sat","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Exciter output voltage for saturation factor: (E1, E2)"},{"name":"Se","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Exciter saturation factor at exciter output voltage: (Se(E1), Se(E2))"},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"saturation_coeffs","default":"PowerSystems.get_avr_saturation(E_sat, Se)","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Coefficients (A,B) of the function: Se(V) = B(V - A)^2/V"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tVt: Terminal Voltage,\n\tVr: Regulator Output,\n\tVf: Exciter Output, \n\tVr3: Rate feedback integrator","internal_default":"[:Vt, :Vr1, :Vf, :Vr2]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"The IEEET1 has 4 states","internal_default":4},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"IEEET1 I has 4 differential states","internal_default":"[StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Differential, StateTypes.Differential]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"1968 IEEE type 1 excitation system model","struct_name":"IEEET1","supertype":"AVR"},{"fields":[{"name":"Ka","data_type":"Float64","null_value":0,"comment":"Amplifier Gain","valid_range":{"max":null,"min":0}},{"name":"Ke","data_type":"Float64","null_value":0,"comment":"Field circuit integral deviation","valid_range":{"max":null,"min":0}},{"name":"Kf","data_type":"Float64","null_value":0,"comment":"Stabilizer Gain in s * pu/pu","valid_range":{"max":null,"min":0}},{"name":"Ta","data_type":"Float64","null_value":0,"comment":"Amplifier Time Constant in s","valid_range":{"max":null,"min":0}},{"name":"Te","data_type":"Float64","null_value":0,"comment":"Field Circuit Time Constant in s","valid_range":{"max":null,"min":0}},{"name":"Tf","data_type":"Float64","null_value":0,"comment":"Stabilizer Time Constant in s","valid_range":{"max":null,"min":0}},{"name":"Tr","data_type":"Float64","null_value":0,"comment":"Voltage Measurement Time Constant in s","valid_range":{"max":null,"min":0}},{"name":"Va_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Limits for pi controler `(Va_min, Va_max)`"},{"name":"Ae","data_type":"Float64","null_value":0,"comment":"1st ceiling coefficient","valid_range":{"max":null,"min":0}},{"name":"Be","data_type":"Float64","null_value":0,"comment":"2nd ceiling coefficient","valid_range":{"max":null,"min":0}},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tVf: Voltage field,\n\tVr1: Amplifier State,\n\tVr2: Stabilizing Feedback State,\n\tVm: Measured voltage","internal_default":"[:Vf, :Vr1, :Vr2, :Vm]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"The AVR Type I has 4 states","internal_default":4},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"AVR Type I has 4 differential states","internal_default":"[StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of an Automatic Voltage Regulator Type I - Resembles IEEE Type DC1","struct_name":"AVRTypeI","supertype":"AVR"},{"fields":[{"name":"K0","data_type":"Float64","null_value":0,"comment":"Regulator Gain","valid_range":{"max":null,"min":0}},{"name":"T1","data_type":"Float64","null_value":0,"comment":"First Pole in s","valid_range":{"max":null,"min":0}},{"name":"T2","data_type":"Float64","null_value":0,"comment":"First zero in s","valid_range":{"max":null,"min":0}},{"name":"T3","data_type":"Float64","null_value":0,"comment":"First Pole in s","valid_range":{"max":null,"min":0}},{"name":"T4","data_type":"Float64","null_value":0,"comment":"First zero in s","valid_range":{"max":null,"min":0}},{"name":"Te","data_type":"Float64","null_value":0,"comment":"Field Circuit Time Constant in s","valid_range":{"max":null,"min":0}},{"name":"Tr","data_type":"Float64","null_value":0,"comment":"Voltage Measurement Time Constant in s","valid_range":{"max":null,"min":0}},{"name":"Va_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Limits for pi controler `(Va_min, Va_max)`"},{"name":"Ae","data_type":"Float64","null_value":0,"comment":"1st ceiling coefficient","valid_range":{"max":null,"min":0}},{"name":"Be","data_type":"Float64","null_value":0,"comment":"2nd ceiling coefficient","valid_range":{"max":null,"min":0}},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tVf: Voltage field,\n\tVr1: First Lead-Lag state,\n\tVr2: Second lead-lag state,\n\tVm: Measured voltage","internal_default":"[:Vf, :Vr1, :Vr2, :Vm]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"AVR Type II has 4 states","internal_default":4},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"AVR Type II has 4 differential states","internal_default":"[StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of an Automatic Voltage Regulator Type II - Typical static exciter model","struct_name":"AVRTypeII","supertype":"AVR"},{"fields":[{"name":"Ta_Tb","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Lead input constant ratio","valid_range":{"max":0.3,"min":0.05}},{"name":"Tb","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Lag input constant in s","valid_range":{"max":20,"min":5}},{"name":"K","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator Gain","valid_range":{"max":100,"min":20}},{"name":"Te","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator Time Constant","valid_range":{"max":1,"min":0}},{"name":"Efd_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Field Voltage regulator limits (regulator output) (Efd_min, Efd_max)"},{"name":"switch","data_type":"Int","null_value":0,"validation_action":"error","comment":"Switch","valid_range":{"max":1,"min":0}},{"name":"rc_rfd","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Field current capability. Set = 0 for negative current capability. Typical value 10","valid_range":{"max":10,"min":0}},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tVr1: First integrator,\n\tVr2: Second integrator","internal_default":"[:Vr1, :Vr2]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"SCRX has 2 states","internal_default":2},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"SCRX has 2 differential states","internal_default":"[StateTypes.Differential, StateTypes.Hybrid]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"This exciter is based on an IEEE type SCRX solid state exciter. The output field voltage is varied by a control system to maintain the system voltage at Vref. Please note that this exciter model has no initialization capabilities - this means that it will respond to whatever inputs it receives regardless of the state of the machine model.","struct_name":"SCRX","supertype":"AVR"},{"fields":[{"name":"Tr","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator input filter time constant in s","valid_range":{"max":0.5,"min":0}},{"name":"Tb","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator denominator (lag) time constant in s","valid_range":{"max":20,"min":0}},{"name":"Tc","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator numerator (lead) time constant in s","valid_range":{"max":20,"min":0}},{"name":"Ka","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator output gain","valid_range":{"max":1000,"min":0}},{"name":"Ta","data_type":"Float64","null_value":0,"comment":"Regulator output time constant in s","valid_range":{"max":10,"min":0}},{"name":"Va_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Limits for regulator output `(Va_min, Va_max)`"},{"name":"Te","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Exciter field time constant in s","valid_range":{"max":2,"min":"eps()"}},{"name":"Kf","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Rate feedback excitation system stabilizer gain","valid_range":{"max":0.3,"min":0}},{"name":"Tf","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Rate feedback time constant","valid_range":{"max":1.5,"min":"eps()"}},{"name":"Kc","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Rectifier loading factor proportional to commutating reactance","valid_range":{"max":1,"min":0}},{"name":"Kd","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Demagnetizing factor, function of exciter alternator reactances","valid_range":{"max":1,"min":0}},{"name":"Ke","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Exciter field proportional constant","valid_range":{"max":1,"min":0}},{"name":"E_sat","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Exciter output voltage for saturation factor: (E1, E2)"},{"name":"Se","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Exciter saturation factor at exciter output voltage: (Se(E1), Se(E2))"},{"name":"Vr_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Limits for exciter field voltage: `(Vr_min, Vr_max)`"},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"saturation_coeffs","default":"PowerSystems.get_avr_saturation(E_sat, Se)","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Coefficients (A,B) of the function: Se(x) = B(x - A)^2/x"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tVm: Sensed terminal voltage,\n\tVr1: Lead-lag state,\n\tVr2: Regulator output state,\n\tVe: Integrator output state,\n\tVr3: Feedback output state","internal_default":"[:Vm, :Vr1, :Vr2, :Ve, :Vr3]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"ESAC1A has 5 states","internal_default":5},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"ESAC1A has 5 states","internal_default":"[StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Differential, StateTypes.Differential]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"This excitation systems consists of an alternator main exciter feeding its output via non-controlled rectifiers.\nThe exciter does not employ self-excitation, and the voltage regulator power is taken from a source that is not affected by external transients.\nParameters of IEEE Std 421.5 Type AC1A Excitacion System. This model corresponds to ESAC1A in PSSE and PSLF","struct_name":"ESAC1A","supertype":"AVR"},{"fields":[{"name":"Tr","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator input filter time constant in s","valid_range":{"max":0.5,"min":0}},{"name":"Tb","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator denominator (lag) time constant in s","valid_range":{"max":20,"min":0}},{"name":"Tc","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator numerator (lead) time constant in s","valid_range":{"max":20,"min":0}},{"name":"Ka","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator output gain","valid_range":{"max":1000,"min":0}},{"name":"Ta","data_type":"Float64","null_value":0,"comment":"Regulator output time constant in s","valid_range":{"max":10,"min":0}},{"name":"Va_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Limits for regulator output `(Va_min, Va_max)`"},{"name":"Te","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Exciter field time constant in s","valid_range":{"max":2,"min":"eps()"}},{"name":"Kf","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Rate feedback excitation system stabilizer gain","valid_range":{"max":0.3,"min":0}},{"name":"Tf","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Rate feedback time constant","valid_range":{"max":1.5,"min":"eps()"}},{"name":"Kc","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Rectifier loading factor proportional to commutating reactance","valid_range":{"max":1,"min":0}},{"name":"Kd","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Demagnetizing factor, function of exciter alternator reactances","valid_range":{"max":1,"min":0}},{"name":"Ke","data_type":"Float64","null_value":0,"comment":"Exciter field proportional constant","valid_range":{"max":1,"min":0}},{"name":"E_sat","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Exciter output voltage for saturation factor: (E1, E2)"},{"name":"Se","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Exciter saturation factor at exciter output voltage: (Se(E1), Se(E2))"},{"name":"Vr_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Limits for exciter field voltage: `(Vr_min, Vr_max)`"},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"saturation_coeffs","default":"PowerSystems.get_avr_saturation(E_sat, Se)","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Coefficients (A,B) of the function: Se(x) = B(x - A)^2/x"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tVm: Sensed terminal voltage,\n\tVr1: Lead-lag state,\n\tVr2: Regulator output state,\n\tVe: Integrator output state,\n\tVr3: Feedback output state","internal_default":"[:Vm, :Vr1, :Vr2, :Ve, :Vr3]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"EXAC1A has 5 states","internal_default":5},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"EXAC1A has 5 states","internal_default":"[StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Differential, StateTypes.Differential]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Modified ESAC1A. This excitation systems consists of an alternator main exciter feeding its output via non-controlled rectifiers.\nThe exciter does not employ self-excitation, and the voltage regulator power is taken from a source that is not affected by external transients.\nParameters of IEEE Std 421.5 Type AC1A Excitacion System. EXAC1A in PSSE and PSLF","struct_name":"EXAC1A","supertype":"AVR"},{"fields":[{"name":"Tr","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator input filter time constant in s","valid_range":{"max":0.5,"min":0}},{"name":"Tb","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator denominator (lag) time constant in s","valid_range":{"max":20,"min":0}},{"name":"Tc","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator numerator (lead) time constant in s","valid_range":{"max":20,"min":0}},{"name":"Ka","data_type":"Float64","null_value":0,"comment":"Regulator output gain","valid_range":{"max":1000,"min":0}},{"name":"Ta","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator output time constant in s","valid_range":{"max":10,"min":0}},{"name":"Vr_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Limits for regulator output `(Vr_min, Vr_max)`"},{"name":"Te","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Exciter field time constant in s","valid_range":{"max":2,"min":"eps()"}},{"name":"Kf","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Rate feedback excitation system stabilizer gain","valid_range":{"max":0.3,"min":0}},{"name":"Tf","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Rate feedback time constant","valid_range":{"max":1.5,"min":"eps()"}},{"name":"Kc","data_type":"Float64","null_value":0,"comment":"Rectifier loading factor proportional to commutating reactance","valid_range":{"max":1,"min":0}},{"name":"Kd","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Demagnetizing factor, function of exciter alternator reactances","valid_range":{"max":1,"min":0}},{"name":"Ke","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Exciter field proportional constant","valid_range":{"max":1,"min":0}},{"name":"E_sat","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Exciter output voltage for saturation factor: (E1, E2)"},{"name":"Se","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Exciter saturation factor at exciter output voltage: (Se(E1), Se(E2))"},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"saturation_coeffs","default":"PowerSystems.get_avr_saturation(E_sat, Se)","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Coefficients (A,B) of the function: Se(V) = B(V - A)^2/V"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tVm: Sensed terminal voltage,\n\tVr1: Lead-lag state,\n\tVr2: Regulator output state,\n\tVe: Integrator output state,\n\tVr3: Feedback output state","internal_default":"[:Vm, :Vr1, :Vr2, :Ve, :Vr3]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"EXAC1 has 5 states","internal_default":5},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"EXAC1 has 5 states","internal_default":"[StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Differential, StateTypes.Differential]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Modified ESAC1A. This excitation systems consists of an alternator main exciter feeding its output via non-controlled rectifiers.\nThe exciter does not employ self-excitation, and the voltage regulator power is taken from a source that is not affected by external transients.\nParameters of IEEE Std 421.5 Type AC1A. EXAC1 in PSSE and PSLF","struct_name":"EXAC1","supertype":"AVR"},{"fields":[{"name":"Tr","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator input filter time constant in s","valid_range":{"max":0.5,"min":0}},{"name":"Tb","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator denominator (lag) time constant in s","valid_range":{"max":20,"min":0}},{"name":"Tc","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator numerator (lead) time constant in s","valid_range":{"max":20,"min":0}},{"name":"Ka","data_type":"Float64","null_value":0,"comment":"Regulator output gain","valid_range":{"max":1000,"min":0}},{"name":"Ta","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator output time constant in s","valid_range":{"max":10,"min":0}},{"name":"Va_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Limits for regulator output `(Va_min, Va_max)`"},{"name":"Kb","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Second Stage regulator gain","valid_range":{"max":500,"min":"eps()"}},{"name":"Vr_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Limits for exciter field voltage `(Vr_min, Vr_max)`"},{"name":"Te","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Exciter field time constant","valid_range":{"max":2,"min":"eps()"}},{"name":"Kl","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Exciter field current limiter gain","valid_range":{"max":1.1,"min":0}},{"name":"Kh","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Exciter field current regulator feedback gain","valid_range":{"max":1.1,"min":0}},{"name":"Kf","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Rate feedback excitation system stabilizer gain","valid_range":{"max":0.3,"min":0}},{"name":"Tf","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Rate feedback time constant","valid_range":{"max":null,"min":"eps()"}},{"name":"Kc","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Rectifier loading factor proportional to commutating reactance","valid_range":{"max":1,"min":0}},{"name":"Kd","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Demagnetizing factor, function of exciter alternator reactances","valid_range":{"max":1,"min":0}},{"name":"Ke","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Exciter field proportional constant","valid_range":{"max":1,"min":0}},{"name":"V_lr","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Maximum exciter field current","valid_range":{"max":null,"min":0}},{"name":"E_sat","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Exciter output voltage for saturation factor: (E1, E2)"},{"name":"Se","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Exciter saturation factor at exciter output voltage: (Se(E1), Se(E2))"},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"saturation_coeffs","default":"PowerSystems.get_avr_saturation(E_sat, Se)","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Coefficients (A,B) of the function: Se(V) = B(V - A)^2/V"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tVm: Sensed terminal voltage,\n\tVr1: Lead-lag state,\n\tVr2: Regulator output state,\n\tVe: Integrator output state,\n\tVr3: Feedback output state","internal_default":"[:Vm, :Vr1, :Vr2, :Ve, :Vr3]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"EXAC2 has 5 states","internal_default":5},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"EXAC2 has 5 states","internal_default":"[StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Differential, StateTypes.Differential]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Modified AC2. This excitation systems consists of an alternator main exciter feeding its output via non-controlled rectifiers.\nThe exciter does not employ self-excitation, and the voltage regulator power is taken from a source that is not affected by external transients.\nParameters of IEEE Std 421.5 Type AC2A Excitacion System. The alternator main exciter is used, feeding its output via non-controlled rectifiers. The Type AC2C model is similar to that of Type AC1C except for the inclusion of exciter time constant compensation and exciter field current limiting elements. EXAC2 in PSSE and PSLF.","struct_name":"EXAC2","supertype":"AVR"},{"fields":[{"name":"Tr","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator input filter time constant in s","valid_range":{"max":0.5,"min":0}},{"name":"Ka","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator output gain","valid_range":{"max":1000,"min":0}},{"name":"Ta","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator output lag time constant in s","valid_range":{"max":10,"min":0}},{"name":"Tk","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Voltage Regulator lead time constant","valid_range":{"max":10,"min":0}},{"name":"Tb","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator denominator (lag) time constant in s","valid_range":{"max":20,"min":0}},{"name":"Tc","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator numerator (lead) time constant in s","valid_range":{"max":20,"min":0}},{"name":"Va_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Limits for regulator output `(Va_min, Va_max)`"},{"name":"Vr_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Limits for exciter field voltage `(Vr_min, Vr_max)`"},{"name":"Te","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Exciter field time constant","valid_range":{"max":2,"min":"eps()"}},{"name":"VFE_lim","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Exciter field current limiter reference","valid_range":{"max":20,"min":-5}},{"name":"Kh","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Exciter field current regulator feedback gain","valid_range":{"max":100,"min":0}},{"name":"VH_max","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Exciter field current limiter maximum output","valid_range":{"max":100,"min":0}},{"name":"Th","data_type":"Float64","null_value":0,"comment":"Exciter field current limiter denominator (lag) time constant","valid_range":{"max":1,"min":0}},{"name":"Tj","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Exciter field current limiter numerator (lead) time constant","valid_range":{"max":1,"min":0}},{"name":"Kc","data_type":"Float64","null_value":0,"comment":"Rectifier loading factor proportional to commutating reactance","valid_range":{"max":1,"min":0}},{"name":"Kd","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Demagnetizing factor, function of exciter alternator reactances","valid_range":{"max":2,"min":0}},{"name":"Ke","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Exciter field proportional constant","valid_range":{"max":2,"min":0}},{"name":"E_sat","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Exciter output voltage for saturation factor: (E1, E2)"},{"name":"Se","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Exciter saturation factor at exciter output voltage: (Se(E1), Se(E2))"},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"saturation_coeffs","default":"PowerSystems.get_avr_saturation(E_sat, Se)","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Coefficients (A,B) of the function: Se(V) = B(V - A)^2/V"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tVm: Sensed terminal voltage,\n\tVr1: Lead-lag state,\n\tVr2: Regulator output state,\n\tVe: Integrator output state,\n\tVr3: Feedback output state","internal_default":"[:Vm, :Vr1, :Vr2, :Ve, :Vr3]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"ESAC6A has 5 states","internal_default":5},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"ESAC6A has 5 states","internal_default":"[StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Differential, StateTypes.Hybrid]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Modified AC6A. Used to represent field-controlled alternator-rectifier excitation systems with system-supplied electronic voltage regulators. \nParameters of IEEE Std 421.5 Type AC6A Excitacion System. ESAC6A in PSSE and PSLF.","struct_name":"ESAC6A","supertype":"AVR"},{"fields":[{"name":"UEL_flags","data_type":"Int","null_value":1,"validation_action":"warn","comment":"Code input for Underexcitization limiter (UEL) entry. Not supported.","valid_range":{"max":3,"min":1}},{"name":"PSS_flags","data_type":"Int","null_value":1,"comment":"Code input for Power System Stabilizer (PSS) or (VOS) entry.","valid_range":{"max":2,"min":1}},{"name":"Tr","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator input filter time constant in s","valid_range":{"max":0.1,"min":0}},{"name":"Vi_lim","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Voltage error limits (regulator input) (Vi_min, Vi_max)"},{"name":"Tc","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"First regulator denominator (lead) time constant in s","valid_range":{"max":10,"min":0}},{"name":"Tb","data_type":"Float64","null_value":0,"comment":"First regulator denominator (lag) time constant in s","valid_range":{"max":20,"min":0}},{"name":"Tc1","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Second regulator denominator (lead) time constant in s","valid_range":{"max":10,"min":0}},{"name":"Tb1","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Second regulator denominator (lead) time constant in s","valid_range":{"max":20,"min":0}},{"name":"Ka","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Voltage regulator gain","valid_range":{"max":1000,"min":50}},{"name":"Ta","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Voltage regulator time constant in s","valid_range":{"max":0.5,"min":0}},{"name":"Va_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Limits for regulator output `(Va_min, Va_max)`"},{"name":"Vr_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Limits for exciter output `(Vr_min, Vr_max)`"},{"name":"Kc","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Rectifier loading factor proportional to commutating reactance","valid_range":{"max":0.3,"min":0}},{"name":"Kf","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Rate feedback gain","valid_range":{"max":0.3,"min":0}},{"name":"Tf","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Rate feedback time constant in s","valid_range":{"max":1.5,"min":"eps()"}},{"name":"K_lr","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Exciter output current limiter gain","valid_range":{"max":5,"min":0}},{"name":"I_lr","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Exciter output current limit reference","valid_range":{"max":5,"min":0}},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tVm: Sensed terminal voltage,\n\tVr1: First Lead-lag state,\n\tVr2: Second lead-lag state,\n\tVa: Regulator output state,\n\tVr3: Feedback output state","internal_default":"[:Vm, :Vr1, :Vr2, :Va, :Vr3]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"ST1A has 5 states","internal_default":5},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"ST1A has 5 states","internal_default":"[StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Differential]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"This excitation system supplies power through a transformer from the generator terminals and its regulated by a controlled rectifier (via thyristors).\nParameters of IEEE Std 421.5 Type ST1A Excitacion System. ESST1A in PSSE and PSLF","struct_name":"ESST1A","supertype":"AVR"},{"fields":[{"name":"Tr","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator input filter time constant in s","valid_range":{"max":0.5,"min":0}},{"name":"Ka","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Voltage regulator gain","valid_range":{"max":500,"min":1}},{"name":"Ta","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Voltage regulator time constant in s","valid_range":{"max":10,"min":0}},{"name":"Va_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Limits for pi controler `(Vr_min, Vr_max)`"},{"name":"Ta_2","data_type":"Float64","null_value":0,"comment":"Voltage regulator time constant in s","valid_range":{"max":null,"min":0}},{"name":"Ta_3","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Voltage regulator time constant in s","valid_range":{"max":null,"min":0}},{"name":"Ta_4","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Voltage regulator time constant in s","valid_range":{"max":null,"min":0}},{"name":"Vr_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Voltage regulator limits (regulator output) (Vi_min, Vi_max)"},{"name":"Kf","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Rate feedback gain","valid_range":{"max":0.3,"min":0}},{"name":"Tf_1","validation_actions":"error","data_type":"Float64","null_value":0,"comment":"Rate Feedback time constant in s","valid_range":{"max":15,"min":"eps()"}},{"name":"Tf_2","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Rate Feedback time constant in s","valid_range":{"max":5,"min":0}},{"name":"Efd_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Field Voltage regulator limits (regulator output) (Efd_min, Efd_max)"},{"name":"Ke","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Exciter constant","valid_range":{"max":1,"min":0}},{"name":"Te","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Exciter time constant","valid_range":{"max":2,"min":0}},{"name":"E_sat","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Exciter output voltage for saturation factor: (E1, E2)"},{"name":"Se","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Exciter saturation factor at exciter output voltage: (Se(E1), Se(E2))"},{"name":"Kp","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Potential source gain","valid_range":{"max":5,"min":0}},{"name":"Ki","data_type":"Float64","null_value":0,"comment":"current source gain","valid_range":{"max":1.1,"min":0}},{"name":"Kc","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Exciter regulation factor","valid_range":{"max":2,"min":0}},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"saturation_coeffs","default":"PowerSystems.get_avr_saturation(E_sat, Se)","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Coefficients (A,B) of the function: Se(V) = B(V - A)^2/V"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tVm: Sensed terminal voltage,\n\tVr1: First Lead-lag state,\n\tVr2: Second regulator lead-lag state,\n\tVr2: Third regulator lead-lag state \n\tVf: Exciter output \n\tVr3: First feedback integrator,\n\tVr4: second feedback integrator","internal_default":"[:Vm, :Vr1, :Vr2, :Vf, :Vr3, :Vr4]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"EXPIC1 has 6 states","internal_default":6},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"EXPIC has 6 states","internal_default":"[StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Differential, StateTypes.Hybrid]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Generic Proportional/Integral Excitation System","struct_name":"EXPIC1","supertype":"AVR"},{"fields":[{"name":"Tr","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator input filter time constant in s","valid_range":{"max":0.5,"min":0}},{"name":"K_pr","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator propotional gain","valid_range":{"max":75,"min":0}},{"name":"K_ir","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Regulator integral gain","valid_range":{"max":75,"min":0}},{"name":"Vr_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Voltage regulator limits (Vi_min, Vi_max)"},{"name":"Ta","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Voltage regulator time constant in s","valid_range":{"max":1,"min":0}},{"name":"K_pm","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Voltage regulator proportional gain output","valid_range":{"max":1.2,"min":0}},{"name":"K_im","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Voltage regulator integral gain output","valid_range":{"max":18,"min":0}},{"name":"Vm_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Limits for inner loop output `(Vm_min, Vm_max)`"},{"name":"Kg","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Feedback gain constant of the inner loop field regulator","valid_range":{"max":1.1,"min":0}},{"name":"Kp","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Potential circuit (voltage) gain coefficient","valid_range":{"max":10,"min":0}},{"name":"Ki","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Compound circuit (current) gain coefficient","valid_range":{"max":1.1,"min":0}},{"name":"VB_max","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Maximum available exciter voltage","valid_range":{"max":20,"min":1}},{"name":"Kc","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Rectifier loading factor proportional to commutating reactance","valid_range":{"max":1,"min":0}},{"name":"Xl","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Reactance associated with potential source","valid_range":{"max":0.5,"min":0}},{"name":"θp","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Potential circuit phase angle (degrees)","valid_range":{"max":90,"min":-90}},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"θp_rad","default":"θp*π*inv(180)","data_type":"Float64","null_value":0,"comment":"Potential circuit phase angle (radians)"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tVm: Sensed terminal voltage,\n\tVt: Sensed Terminal Voltage,\n\tVr1: Regulator Integrator,\n\tVr2: Regulator Output,\n\tVm: Output integrator","internal_default":"[:Vt, :Vr1, :Vr2, :Vm]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"ST4B has 4 states","internal_default":4},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"ST4B has 4 states","internal_default":"[StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"In these excitation systems, voltage (and also current in compounded systems) is transformed to an appropriate level. Rectifiers, either controlled or non-controlled, provide the necessary direct current for the generator field.\nParameters of IEEE Std 421.5 Type ST4B Excitacion System. ESST4B in PSSE and PSLF","struct_name":"ESST4B","supertype":"AVR"},{"fields":[{"name":"Tr","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Voltage Measurement Time Constant in s","valid_range":{"max":null,"min":0}},{"name":"Vi_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Voltage input limits (Vi_min, Vi_max)"},{"name":"Tc","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Numerator lead-lag (lead) time constant in s","valid_range":{"max":null,"min":0}},{"name":"Tb","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Denominator lead-lag (lag) time constant in s","valid_range":{"max":null,"min":0}},{"name":"Ka","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Amplifier Gain","valid_range":{"max":null,"min":0}},{"name":"Ta","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Amplifier Time Constant in s","valid_range":{"max":null,"min":0}},{"name":"Vr_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Voltage regulator limits (regulator output) (Vr_min, Vr_max)"},{"name":"Kc","data_type":"Float64","null_value":0,"comment":"Current field constant limiter multiplier","valid_range":{"max":null,"min":0}},{"name":"Kf","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Excitation control system stabilizer gain","valid_range":{"max":0.3,"min":"eps()"}},{"name":"Tf","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Excitation control system stabilizer time constant","valid_range":{"max":null,"min":"eps()"}},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tVm: Sensed Terminal Voltage,\n\tVrll: Lead-Lag state,\n\tVr: Regulator Output, \n\tVfb: Feedback state","internal_default":"[:Vm, :Vrll, :Vr, :Vfb]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"The EXST1 has 4 states","internal_default":4},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"IEEE Type ST1 Excitation System (PTI version)","struct_name":"EXST1","supertype":"AVR"},{"fields":[{"name":"Iflim","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"OEL Field current limit","valid_range":{"max":null,"min":0}},{"name":"d","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"OEL parameter d","valid_range":{"max":null,"min":0}},{"name":"f","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"OEL parameter f","valid_range":{"max":null,"min":0}},{"name":"Spar","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"OEL parameter Spar","valid_range":{"max":null,"min":0}},{"name":"K1","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"OEL delay time constant","valid_range":{"max":null,"min":0}},{"name":"K2","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"OEL parameter K2","valid_range":{"max":null,"min":0}},{"name":"Oel_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Oel integrator limits (Oel_min, Oel_max)"},{"name":"G","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"AVR Exciter Gain","valid_range":{"max":null,"min":0}},{"name":"Ta","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Numerator lead-lag (lag) time constant in s","valid_range":{"max":null,"min":0}},{"name":"Tb","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Denominator lead-lag (lag) time constant in s","valid_range":{"max":null,"min":0}},{"name":"Te","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Exciter Time Constant in s","valid_range":{"max":null,"min":0}},{"name":"E_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Voltage regulator limits (regulator output) (E_min, E_max)"},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tVll: Lead-lag internal state,\n\tVex: Exciter Output, \n\toel: OEL integrator state","internal_default":"[:Vll, :Vex, :oel]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"The EX4VSA has 3 states","internal_default":3},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"IEEE Excitation System for Voltage Security Assesment","struct_name":"EX4VSA","supertype":"AVR"},{"fields":[{"name":"R","data_type":"Float64","null_value":0,"comment":"Resistance after EMF in machine per unit","valid_range":{"max":null,"min":0}},{"name":"Xd_p","data_type":"Float64","null_value":0,"comment":"Reactance after EMF in machine per unit","valid_range":{"max":null,"min":0}},{"name":"eq_p","data_type":"Float64","null_value":0,"comment":"Fixed EMF behind the impedance","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"BaseMachine has no states","internal_default":"Vector{Symbol}()"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"BaseMachine has no states","internal_default":0},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of a Classic Machine: GENCLS in PSSE and PSLF","struct_name":"BaseMachine","supertype":"Machine"},{"fields":[{"name":"R","data_type":"Float64","null_value":0,"comment":"Armature resistance","valid_range":{"max":null,"min":0}},{"name":"Td0_p","data_type":"Float64","null_value":0,"comment":"Time constant of transient d-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Td0_pp","data_type":"Float64","null_value":0,"comment":"Time constant of sub-transient d-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Tq0_p","data_type":"Float64","null_value":0,"comment":"Time constant of transient q-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Tq0_pp","data_type":"Float64","null_value":0,"comment":"Time constant of sub-transient q-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Xd","data_type":"Float64","null_value":0,"comment":"Reactance after EMF in d-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xq","data_type":"Float64","null_value":0,"comment":"Reactance after EMF in q-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xd_p","data_type":"Float64","null_value":0,"comment":"Transient reactance after EMF in d-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xq_p","data_type":"Float64","null_value":0,"comment":"Transient reactance after EMF in q-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xd_pp","data_type":"Float64","null_value":0,"comment":"Sub-Transient reactance after EMF in d-axis per unit. Note: Xd_pp = Xq_pp","valid_range":{"max":null,"min":0}},{"name":"Xl","data_type":"Float64","null_value":0,"comment":"Stator leakage reactance","valid_range":{"max":null,"min":0}},{"name":"Se","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Saturation factor at 1 and 1.2 pu flux: S(1.0) = B(|ψ_pp|-A)^2"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"γ_d1","data_type":"Float64","comment":"γ_d1 parameter","internal_default":"(Xd_pp - Xl) / (Xd_p - Xl)"},{"name":"γ_q1","data_type":"Float64","comment":"γ_q1 parameter","internal_default":"(Xd_pp - Xl) / (Xq_p - Xl)"},{"name":"γ_d2","data_type":"Float64","comment":"γ_d2 parameter","internal_default":"(Xd_p - Xd_pp) / (Xd_p - Xl)^2"},{"name":"γ_q2","data_type":"Float64","comment":"γ_q2 parameter","internal_default":"(Xq_p - Xd_pp) / (Xq_p - Xl)^2"},{"name":"γ_qd","data_type":"Float64","comment":"γ_qd parameter","internal_default":"(Xq - Xl) / (Xd - Xl)"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\teq_p: q-axis generator voltage behind the transient reactance,\n\ted_p: d-axis generator voltage behind the transient reactance,\n\tψ_kd: flux linkage in the first equivalent damping circuit in the d-axis,\n\tψ_kq: flux linkage in the first equivalent damping circuit in the d-axis","internal_default":"[:eq_p, :ed_p, :ψ_kd, :ψ_kq]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"RoundRotorMachine has 4 states","internal_default":4},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of 4-states round-rotor synchronous machine with quadratic/exponential saturation:\nIEEE Std 1110 §5.3.2 (Model 2.2). GENROU or GENROE model in PSSE and PSLF.","struct_name":"RoundRotorMachine","supertype":"Machine"},{"fields":[{"name":"R","data_type":"Float64","null_value":0,"comment":"Armature resistance","valid_range":{"max":null,"min":0}},{"name":"Td0_p","data_type":"Float64","null_value":0,"comment":"Time constant of transient d-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Td0_pp","data_type":"Float64","null_value":0,"comment":"Time constant of sub-transient d-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Tq0_pp","data_type":"Float64","null_value":0,"comment":"Time constant of sub-transient q-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Xd","data_type":"Float64","null_value":0,"comment":"Reactance after EMF in d-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xq","data_type":"Float64","null_value":0,"comment":"Reactance after EMF in q-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xd_p","data_type":"Float64","null_value":0,"comment":"Transient reactance after EMF in d-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xd_pp","data_type":"Float64","null_value":0,"comment":"Sub-Transient reactance after EMF in d-axis per unit. Note: Xd_pp = Xq_pp","valid_range":{"max":null,"min":0}},{"name":"Xl","data_type":"Float64","null_value":0,"comment":"Stator leakage reactance","valid_range":{"max":null,"min":0}},{"name":"Se","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Saturation factor at 1 and 1.2 pu flux: Se(eq_p) = B(eq_p-A)^2"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"γ_d1","data_type":"Float64","comment":"γ_d1 parameter","internal_default":"(Xd_pp - Xl) / (Xd_p - Xl)"},{"name":"γ_q1","data_type":"Float64","comment":"γ_q1 parameter","internal_default":"(Xd_p - Xd_pp) / (Xd_p - Xl)"},{"name":"γ_d2","data_type":"Float64","comment":"γ_d2 parameter","internal_default":"(Xd_p - Xd_pp) / (Xd_p - Xl)^2"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\teq_p: q-axis generator voltage behind the transient reactance,\n\tψ_kd: flux linkage in the first equivalent damping circuit in the d-axis,\n\tψq_pp: phasonf of the subtransient flux linkage in the q-axis","internal_default":"[:eq_p, :ψ_kd, :ψq_pp]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"SalientPoleMachine has 3 states","internal_default":3},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of 3-states salient-pole synchronous machine with quadratic/exponential saturation:\nIEEE Std 1110 §5.3.1 (Model 2.1). GENSAL or GENSAE model in PSSE and PSLF.","struct_name":"SalientPoleMachine","supertype":"Machine"},{"fields":[{"name":"R","data_type":"Float64","null_value":0,"comment":"Resistance after EMF in machine per unit","valid_range":{"max":null,"min":0}},{"name":"Xd","data_type":"Float64","null_value":0,"comment":"Reactance after EMF in d-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xq","data_type":"Float64","null_value":0,"comment":"Reactance after EMF in q-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xd_p","data_type":"Float64","null_value":0,"comment":"Transient reactance after EMF in d-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xq_p","data_type":"Float64","null_value":0,"comment":"Transient reactance after EMF in q-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xd_pp","data_type":"Float64","null_value":0,"comment":"Sub-Transient reactance after EMF in d-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xq_pp","data_type":"Float64","null_value":0,"comment":"Sub-Transient reactance after EMF in q-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Td0_p","data_type":"Float64","null_value":0,"comment":"Time constant of transient d-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Tq0_p","data_type":"Float64","null_value":0,"comment":"Time constant of transient q-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Td0_pp","data_type":"Float64","null_value":0,"comment":"Time constant of sub-transient d-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Tq0_pp","data_type":"Float64","null_value":0,"comment":"Time constant of sub-transient q-axis voltage","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tψq: q-axis stator flux,\n\tψd: d-axis stator flux,\n\teq_p: q-axis transient voltage,\n\ted_p: d-axis transient voltage,\n\teq_pp: q-axis subtransient voltage,\n\ted_pp: d-axis subtransient voltage","internal_default":"[:ψq, :ψd, :eq_p, :ed_p, :eq_pp, :ed_pp]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"AndersonFouadMachine has 6 states","internal_default":6},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of 6-states synchronous machine: Anderson-Fouad model","struct_name":"AndersonFouadMachine","supertype":"Machine"},{"fields":[{"name":"R","data_type":"Float64","null_value":0,"comment":"Resistance after EMF in machine per unit","valid_range":{"max":null,"min":0}},{"name":"R_f","data_type":"Float64","null_value":0,"comment":"Field rotor winding resistance in per unit","valid_range":{"max":null,"min":0}},{"name":"R_1d","data_type":"Float64","null_value":0,"comment":" Damping rotor winding resistance on d-axis in per unit. This value is denoted as RD in Machowski.","valid_range":{"max":null,"min":0}},{"name":"R_1q","data_type":"Float64","null_value":0,"comment":"Damping rotor winding resistance on q-axis in per unit. This value is denoted as RQ in Machowski.","valid_range":{"max":null,"min":0}},{"name":"L_d","data_type":"Float64","null_value":1,"comment":"Inductance of fictitious damping that represent the effect of the three-phase stator winding in the d-axis of the rotor, in per unit. This value is denoted as L_ad + L_l in Kundur (and Ld in Machowski).","valid_range":{"max":null,"min":0}},{"name":"L_q","data_type":"Float64","null_value":1,"comment":"Inductance of fictitious damping that represent the effect of the three-phase stator winding in the q-axis of the rotor, in per unit. This value is denoted as L_aq + L_l in Kundur.","valid_range":{"max":null,"min":0}},{"name":"L_ad","data_type":"Float64","null_value":2,"comment":"Mutual inductance between stator winding and rotor field (and damping) winding inductance on d-axis, in per unit","valid_range":{"max":null,"min":0}},{"name":"L_aq","data_type":"Float64","null_value":2,"comment":"Mutual inductance between stator winding and rotor damping winding inductance on q-axis, in per unit","valid_range":{"max":null,"min":0}},{"name":"L_f1d","data_type":"Float64","null_value":1,"comment":"Mutual inductance between rotor field winding and rotor damping winding inductance on d-axis, in per unit","valid_range":{"max":null,"min":0}},{"name":"L_ff","data_type":"Float64","null_value":2,"comment":"Field rotor winding inductance, in per unit","valid_range":{"max":null,"min":0}},{"name":"L_1d","data_type":"Float64","null_value":1,"comment":"Inductance of the d-axis rotor damping circuit, in per unit","valid_range":{"max":null,"min":0}},{"name":"L_1q","data_type":"Float64","null_value":1,"comment":"Inductance of the q-axis rotor damping circuit, in per unit","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"inv_d_fluxlink","data_type":"Array{Float64,2}","comment":"Equations 3.127, 3.130, 3.131 From Kundur","internal_default":"inv([[-L_d L_ad L_ad]; [-L_ad L_ff L_f1d]; [-L_ad L_f1d L_1d]])"},{"name":"inv_q_fluxlink","data_type":"Array{Float64,2}","comment":"Equations 3.128, 3.132 From Kundur","internal_default":"inv([[-L_q L_aq]; [-L_aq L_1q]])"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tψd: d-axis stator flux,\n\tψq: q-axis stator flux,\n\tψf: field rotor flux,\n\tψ1d: d-axis rotor damping flux,\n\tψ1q: q-axis rotor damping flux","internal_default":"[:ψd, :ψq, :ψf, :ψ1d, :ψ1q]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"FullMachine has 5 states","internal_default":5},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameter of a full order flux stator-rotor model without zero sequence flux in the stator.\n The derivative of stator fluxes (ψd and ψq) is NOT neglected. Only one q-axis damping circuit is considered. All parameters are in machine per unit.\n Refer to Chapter 3 of Power System Stability and Control by P. Kundur or Chapter 11 of Power System Dynamics: Stability and Control, by J. Machowski, J. Bialek and J. Bumby, for more details.\n Note that the models are somewhat different (but equivalent) due to the different Park Transformation used in both books.","struct_name":"FullMachine","supertype":"Machine"},{"fields":[{"name":"R","data_type":"Float64","null_value":0,"comment":"Resistance after EMF in machine per unit","valid_range":{"max":null,"min":0}},{"name":"Xd","data_type":"Float64","null_value":0,"comment":"Reactance after EMF in d-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xq","data_type":"Float64","null_value":0,"comment":"Reactance after EMF in q-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xd_p","data_type":"Float64","null_value":0,"comment":"Transient reactance after EMF in d-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xq_p","data_type":"Float64","null_value":0,"comment":"Transient reactance after EMF in q-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xd_pp","data_type":"Float64","null_value":0,"comment":"Sub-Transient reactance after EMF in d-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xq_pp","data_type":"Float64","null_value":0,"comment":"Sub-Transient reactance after EMF in q-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xl","data_type":"Float64","null_value":0,"comment":"Stator Leakage Reactance","valid_range":{"max":null,"min":0}},{"name":"Td0_p","data_type":"Float64","null_value":0,"comment":"Time constant of transient d-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Tq0_p","data_type":"Float64","null_value":0,"comment":"Time constant of transient q-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Td0_pp","data_type":"Float64","null_value":0,"comment":"Time constant of sub-transient d-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Tq0_pp","data_type":"Float64","null_value":0,"comment":"Time constant of sub-transient q-axis voltage","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"γ_d1","data_type":"Float64","comment":"","internal_default":"(Xd_pp-Xl)/(Xd_p-Xl)"},{"name":"γ_q1","data_type":"Float64","comment":"","internal_default":"(Xq_pp-Xl)/(Xq_p-Xl)"},{"name":"γ_d2","data_type":"Float64","comment":"","internal_default":"(Xd_p - Xd_pp) / (Xd_p - Xl)^2"},{"name":"γ_q2","data_type":"Float64","comment":"","internal_default":"(Xq_p - Xq_pp) / (Xq_p - Xl)^2"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tψq: q-axis stator flux,\n\tψd: d-axis stator flux,\n\teq_p: q-axis transient voltage,\n\ted_p: d-axis transient voltage\n\tψd_pp: subtransient flux linkage in the d-axis\n\tψq_pp: subtransient flux linkage in the q-axis","internal_default":"[:ψq, :ψd, :eq_p, :ed_p, :ψd_pp, :ψq_pp]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"SauerPaiMachine has 6 states","internal_default":6},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of synchronous machine: Sauer Pai model","struct_name":"SauerPaiMachine","supertype":"Machine"},{"fields":[{"name":"R","data_type":"Float64","null_value":0,"comment":"Resistance after EMF in machine per unit","valid_range":{"max":null,"min":0}},{"name":"Xd","data_type":"Float64","null_value":0,"comment":"Reactance after EMF in d-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xq","data_type":"Float64","null_value":0,"comment":"Reactance after EMF in q-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xd_p","data_type":"Float64","null_value":0,"comment":"Transient reactance after EMF in d-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xq_p","data_type":"Float64","null_value":0,"comment":"Transient reactance after EMF in q-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xd_pp","data_type":"Float64","null_value":0,"comment":"Sub-Transient reactance after EMF in d-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xq_pp","data_type":"Float64","null_value":0,"comment":"Sub-Transient reactance after EMF in q-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Td0_p","data_type":"Float64","null_value":0,"comment":"Time constant of transient d-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Tq0_p","data_type":"Float64","null_value":0,"comment":"Time constant of transient q-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Td0_pp","data_type":"Float64","null_value":0,"comment":"Time constant of sub-transient d-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Tq0_pp","data_type":"Float64","null_value":0,"comment":"Time constant of sub-transient q-axis voltage","valid_range":{"max":null,"min":0}},{"name":"T_AA","data_type":"Float64","null_value":0,"comment":"Time constant of d-axis additional leakage","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"γd","data_type":"Float64","comment":"","internal_default":"((Td0_pp*Xd_pp)/(Td0_p*Xd_p) )*(Xd-Xd_p)"},{"name":"γq","data_type":"Float64","comment":"","internal_default":"((Tq0_pp*Xq_pp)/(Tq0_p*Xq_p) )*(Xq-Xq_p)"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tψq: q-axis stator flux,\n\tψd: d-axis stator flux,\n\teq_p: q-axis transient voltage,\n\ted_p: d-axis transient voltage,\n\teq_pp: q-axis subtransient voltage,\n\ted_pp: d-axis subtransient voltage","internal_default":"[:ψq, :ψd, :eq_p, :ed_p, :eq_pp, :ed_pp]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"MarconatoMachine has 6 states","internal_default":6},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of 6-states synchronous machine: Marconato model","struct_name":"MarconatoMachine","supertype":"Machine"},{"fields":[{"name":"R","data_type":"Float64","null_value":0,"comment":"Resistance after EMF in machine per unit","valid_range":{"max":null,"min":0}},{"name":"Xd","data_type":"Float64","null_value":0,"comment":"Reactance after EMF in d-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xq","data_type":"Float64","null_value":0,"comment":"Reactance after EMF in q-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xd_p","data_type":"Float64","null_value":0,"comment":"Transient reactance after EMF in d-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xq_p","data_type":"Float64","null_value":0,"comment":"Transient reactance after EMF in q-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Td0_p","data_type":"Float64","null_value":0,"comment":"Time constant of transient d-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Tq0_p","data_type":"Float64","null_value":0,"comment":"Time constant of transient q-axis voltage","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\teq_p: q-axis transient voltage,\n\ted_p: d-axis transient voltage","internal_default":"[:eq_p, :ed_p]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"OneDOneQMachine has 2 states","internal_default":2},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of 4-states synchronous machine: Simplified Marconato model\n The derivative of stator fluxes (ψd and ψq) is neglected and ωψd = ψd and\n ωψq = ψq is assumed (i.e. ω=1.0). This is standard when\n transmission network dynamics is neglected.","struct_name":"OneDOneQMachine","supertype":"Machine"},{"fields":[{"name":"R","data_type":"Float64","null_value":0,"comment":"Resistance after EMF in machine per unit","valid_range":{"max":null,"min":0}},{"name":"Xd","data_type":"Float64","null_value":0,"comment":"Reactance after EMF in d-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xq","data_type":"Float64","null_value":0,"comment":"Reactance after EMF in q-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xd_p","data_type":"Float64","null_value":0,"comment":"Transient reactance after EMF in d-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xq_p","data_type":"Float64","null_value":0,"comment":"Transient reactance after EMF in q-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xd_pp","data_type":"Float64","null_value":0,"comment":"Sub-Transient reactance after EMF in d-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xq_pp","data_type":"Float64","null_value":0,"comment":"Sub-Transient reactance after EMF in q-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Td0_p","data_type":"Float64","null_value":0,"comment":"Time constant of transient d-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Tq0_p","data_type":"Float64","null_value":0,"comment":"Time constant of transient q-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Td0_pp","data_type":"Float64","null_value":0,"comment":"Time constant of sub-transient d-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Tq0_pp","data_type":"Float64","null_value":0,"comment":"Time constant of sub-transient q-axis voltage","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\teq_p: q-axis transient voltage,\n\ted_p: d-axis transient voltage,\n\teq_pp: q-axis subtransient voltage,\n\ted_pp: d-axis subtransient voltage","internal_default":"[:eq_p, :ed_p, :eq_pp, :ed_pp]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"SimpleAFMachine has 4 states","internal_default":4},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of 4-states simplified Anderson-Fouad (SimpleAFMachine) model.\n The derivative of stator fluxes (ψd and ψq) is neglected and ωψd = ψd and\n ωψq = ψq is assumed (i.e. ω=1.0). This is standard when transmission network\n dynamics is neglected.\n If transmission dynamics is considered use the full order Anderson Fouad model.","struct_name":"SimpleAFMachine","supertype":"Machine"},{"fields":[{"name":"R","data_type":"Float64","null_value":0,"comment":"Resistance after EMF in machine per unit","valid_range":{"max":null,"min":0}},{"name":"R_f","data_type":"Float64","null_value":0,"comment":"Field rotor winding resistance in per unit","valid_range":{"max":null,"min":0}},{"name":"R_1d","data_type":"Float64","null_value":0,"comment":" Damping rotor winding resistance on d-axis in per unit. This value is denoted as RD in Machowski.","valid_range":{"max":null,"min":0}},{"name":"R_1q","data_type":"Float64","null_value":0,"comment":"Damping rotor winding resistance on q-axis in per unit. This value is denoted as RQ in Machowski.","valid_range":{"max":null,"min":0}},{"name":"L_d","data_type":"Float64","null_value":1,"comment":"Inductance of fictitious damping that represent the effect of the three-phase stator winding in the d-axis of the rotor, in per unit. This value is denoted as L_ad + L_l in Kundur (and Ld in Machowski).","valid_range":{"max":null,"min":0}},{"name":"L_q","data_type":"Float64","null_value":1,"comment":"Inductance of fictitious damping that represent the effect of the three-phase stator winding in the q-axis of the rotor, in per unit. This value is denoted as L_aq + L_l in Kundur.","valid_range":{"max":null,"min":0}},{"name":"L_ad","data_type":"Float64","null_value":2,"comment":"Mutual inductance between stator winding and rotor field (and damping) winding inductance on d-axis, in per unit","valid_range":{"max":null,"min":0}},{"name":"L_aq","data_type":"Float64","null_value":1,"comment":"Mutual inductance between stator winding and rotor damping winding inductance on q-axis, in per unit","valid_range":{"max":null,"min":0}},{"name":"L_f1d","data_type":"Float64","null_value":1,"comment":"Mutual inductance between rotor field winding and rotor damping winding inductance on d-axis, in per unit","valid_range":{"max":null,"min":0}},{"name":"L_ff","data_type":"Float64","null_value":2,"comment":"Field rotor winding inductance, in per unit","valid_range":{"max":null,"min":0}},{"name":"L_1d","data_type":"Float64","null_value":1,"comment":"Inductance of the d-axis rotor damping circuit, in per unit","valid_range":{"max":null,"min":0}},{"name":"L_1q","data_type":"Float64","null_value":2,"comment":"Inductance of the q-axis rotor damping circuit, in per unit","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"inv_d_fluxlink","data_type":"Array{Float64,2}","comment":"Equations 3.127, 3.130, 3.131 From Kundur","internal_default":"inv([[-L_d L_ad L_ad]; [-L_ad L_ff L_f1d]; [-L_ad L_f1d L_1d]])"},{"name":"inv_q_fluxlink","data_type":"Array{Float64,2}","comment":"Equations 3.128, 3.132 From Kundur","internal_default":"inv([[-L_q L_aq]; [-L_aq L_1q]])"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tψf: field rotor flux,\n\tψ1d: d-axis rotor damping flux,\n\tψ1q: q-axis rotor damping flux","internal_default":"[:ψf, :ψ1d, :ψ1q]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"SimpleFullMachine has 3 states","internal_default":3},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameter of a full order flux stator-rotor model without zero sequence flux in the stator.\n The derivative of stator fluxes (ψd and ψq) is neglected. This is standard when\n transmission network dynamics is neglected. Only one q-axis damping circuit\n is considered. All per unit are in machine per unit.\n Refer to Chapter 3 of Power System Stability and Control by P. Kundur or Chapter 11 of Power System Dynamics: Stability and Control, by J. Machowski, J. Bialek and J. Bumby, for more details.\n Note that the models are somewhat different (but equivalent) due to the different Park Transformation used in both books.","struct_name":"SimpleFullMachine","supertype":"Machine"},{"fields":[{"name":"R","data_type":"Float64","null_value":0,"comment":"Resistance after EMF in machine per unit","valid_range":{"max":null,"min":0}},{"name":"Xd","data_type":"Float64","null_value":0,"comment":"Reactance after EMF in d-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xq","data_type":"Float64","null_value":0,"comment":"Reactance after EMF in q-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xd_p","data_type":"Float64","null_value":0,"comment":"Transient reactance after EMF in d-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xq_p","data_type":"Float64","null_value":0,"comment":"Transient reactance after EMF in q-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xd_pp","data_type":"Float64","null_value":0,"comment":"Sub-Transient reactance after EMF in d-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Xq_pp","data_type":"Float64","null_value":0,"comment":"Sub-Transient reactance after EMF in q-axis per unit","valid_range":{"max":null,"min":0}},{"name":"Td0_p","data_type":"Float64","null_value":0,"comment":"Time constant of transient d-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Tq0_p","data_type":"Float64","null_value":0,"comment":"Time constant of transient q-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Td0_pp","data_type":"Float64","null_value":0,"comment":"Time constant of sub-transient d-axis voltage","valid_range":{"max":null,"min":0}},{"name":"Tq0_pp","data_type":"Float64","null_value":0,"comment":"Time constant of sub-transient q-axis voltage","valid_range":{"max":null,"min":0}},{"name":"T_AA","data_type":"Float64","null_value":0,"comment":"Time constant of d-axis additional leakage","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"γd","data_type":"Float64","comment":"","internal_default":"((Td0_pp*Xd_pp)/(Td0_p*Xd_p) )*(Xd-Xd_p)"},{"name":"γq","data_type":"Float64","comment":"","internal_default":"((Tq0_pp*Xq_pp)/(Tq0_p*Xq_p) )*(Xq-Xq_p)"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\teq_p: q-axis transient voltage,\n\ted_p: d-axis transient voltage,\n\teq_pp: q-axis subtransient voltage,\n\ted_pp: d-axis subtransient voltage","internal_default":"[:eq_p, :ed_p, :eq_pp, :ed_pp]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"SimpleMarconatoMachine has 4 states","internal_default":4},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of 4-states synchronous machine: Simplified Marconato model\n The derivative of stator fluxes (ψd and ψq) is neglected and ωψd = ψd and\n ωψq = ψq is assumed (i.e. ω=1.0). This is standard when transmission network\n dynamics is neglected.","struct_name":"SimpleMarconatoMachine","supertype":"Machine"},{"fields":[{"name":"V_pss","data_type":"Float64","null_value":0,"comment":"Fixed voltage stabilization signal","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"","internal_default":"Vector{Symbol}()"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"PSSFixed has no states","internal_default":0},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of a PSS that returns a fixed voltage to add to the reference for the AVR","struct_name":"PSSFixed","supertype":"PSS"},{"fields":[{"name":"K_ω","data_type":"Float64","null_value":0,"comment":"Proportional gain for frequency","valid_range":{"max":null,"min":0}},{"name":"K_p","data_type":"Float64","null_value":0,"comment":"Proportional gain for active power","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"","internal_default":"Vector{Symbol}()"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"PSSSimple has no states","internal_default":0},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of a PSS that returns a proportional droop voltage to add to the reference for the AVR","struct_name":"PSSSimple","supertype":"PSS"},{"fields":[{"name":"input_code","data_type":"Int","null_value":1,"validation_action":"error","comment":"Code input for stabilizer","valid_range":{"max":6,"min":1}},{"name":"remote_bus_control","data_type":"Int","null_value":0,"comment":"Remote Bus number for control."},{"name":"A1","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Filter coefficient","valid_range":{"max":null,"min":0}},{"name":"A2","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Filter coefficient","valid_range":{"max":null,"min":0}},{"name":"A3","data_type":"Float64","null_value":0,"comment":"Filter coefficient","valid_range":{"max":null,"min":0}},{"name":"A4","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Filter coefficient","valid_range":{"max":null,"min":0}},{"name":"A5","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Filter coefficient","valid_range":{"max":null,"min":0}},{"name":"A6","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Filter coefficient","valid_range":{"max":null,"min":0}},{"name":"T1","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant","valid_range":{"max":10,"min":0}},{"name":"T2","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant","valid_range":{"max":10,"min":0}},{"name":"T3","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant","valid_range":{"max":10,"min":0}},{"name":"T4","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant","valid_range":{"max":10,"min":0}},{"name":"T5","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant","valid_range":{"max":10,"min":0}},{"name":"T6","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Time constant","valid_range":{"max":"2.0","min":"eps()"}},{"name":"Ks","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Proportional gain","valid_range":{"max":null,"min":0}},{"name":"Ls_lim","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"PSS output limits for regulator output `(Ls_min, Ls_max)`"},{"name":"Vcu","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Cutoff limiter upper bound","valid_range":{"max":"1.25","min":0}},{"name":"Vcl","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Cutoff limiter lower bound","valid_range":{"max":"1.0","min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tx_p1: 1st filter integration,\n\tx_p2: 2nd filter integration, \n\tx_p3: 3rd filter integration, \n\tx_p4: 4rd filter integration, \n\tx_p5: T1/T2 lead-lag integrator, \n\tx_p6: T3/T4 lead-lag integrator, \n\t:x_p7 last integer,","internal_default":"[:x_p1, :x_p2, :x_p3, :x_p4, :x_p5, :x_p6, :x_p7]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"IEEEST has 7 states","internal_default":7},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"IEEEST has 7 differential states","internal_default":"[StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Differential]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"IEEE Stabilizing Model PSS. ","struct_name":"IEEEST","supertype":"PSS"},{"fields":[{"name":"KT","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"K/T for washout filter","valid_range":{"max":null,"min":0}},{"name":"T","data_type":"Float64","null_value":0.01,"validation_action":"warn","comment":"Time constant for washout filter","valid_range":{"max":null,"min":0.01}},{"name":"T1T3","data_type":"Float64","null_value":0,"comment":"Time constant division T1/T3","valid_range":{"max":null,"min":0}},{"name":"T3","data_type":"Float64","null_value":0.01,"validation_action":"warn","comment":"Time constant","valid_range":{"max":null,"min":0.01}},{"name":"T2T4","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant division T2/T4","valid_range":{"max":null,"min":0}},{"name":"T4","data_type":"Float64","null_value":0.01,"validation_action":"warn","comment":"Time constant","valid_range":{"max":null,"min":0.01}},{"name":"H_lim","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"PSS output limit","valid_range":{"max":0.5,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tx_p1: washout filter,\n\tx_p2: T1/T3 lead-lag block, \n\tx_p3: T2/T4 lead-lag block,","internal_default":"[:x_p1, :x_p2, :x_p3]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"STAB1 has 3 states","internal_default":3},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"STAB1 has 3 differential states","internal_default":"[StateTypes.Differential, StateTypes.Differential, StateTypes.Differential]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Speed-Sensitive Stabilizing Model","struct_name":"STAB1","supertype":"PSS"},{"fields":[{"name":"input_code_1","data_type":"Int","null_value":1,"validation_action":"error","comment":"First Input Code for stabilizer","valid_range":{"max":6,"min":1}},{"name":"remote_bus_control_1","data_type":"Int","null_value":0,"comment":"First Input Remote Bus number for control."},{"name":"input_code_2","data_type":"Int","null_value":1,"validation_action":"error","comment":"Second Input Code for stabilizer","valid_range":{"max":6,"min":1}},{"name":"remote_bus_control_2","data_type":"Int","null_value":0,"comment":"Second Input Remote Bus number for control."},{"name":"M_rtf","data_type":"Int","null_value":0,"validation_action":"error","comment":"M parameter for ramp tracking filter","valid_range":{"max":8,"min":0}},{"name":"N_rtf","data_type":"Int","null_value":0,"validation_action":"error","comment":"N parameter for ramp tracking filter","valid_range":{"max":8,"min":0}},{"name":"Tw1","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for first washout filter for first input","valid_range":{"max":null,"min":"eps()"}},{"name":"Tw2","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for second washout filter for first input","valid_range":{"max":null,"min":0}},{"name":"T6","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for low-pass filter for first input","valid_range":{"max":null,"min":0}},{"name":"Tw3","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for first washout filter for second input","valid_range":{"max":null,"min":"eps()"}},{"name":"Tw4","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for second washout filter for second input","valid_range":{"max":null,"min":0}},{"name":"T7","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for low-pass filter for second input","valid_range":{"max":null,"min":0}},{"name":"Ks2","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Gain for low-pass filter for second input","valid_range":{"max":null,"min":0}},{"name":"Ks3","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Gain for second input","valid_range":{"max":null,"min":0}},{"name":"T8","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for ramp tracking filter","valid_range":{"max":null,"min":0}},{"name":"T9","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for ramp tracking filter","valid_range":{"max":null,"min":"eps()"}},{"name":"Ks1","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Gain before lead-lag blocks","valid_range":{"max":null,"min":0}},{"name":"T1","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for first lead-lag block","valid_range":{"max":null,"min":0}},{"name":"T2","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for first lead-lag block","valid_range":{"max":null,"min":0}},{"name":"T3","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for second lead-lag block","valid_range":{"max":null,"min":0}},{"name":"T4","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for second lead-lag block","valid_range":{"max":null,"min":0}},{"name":"Vst_lim","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"PSS output limits `(Vst_min, Vst_max)`"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tx_p1: 1st washout 1st input, \n\tx_p2: 2nd washout 1st input, \n\tx_p3: transducer 1st input, \n\tx_p4: 1st washout 2nd input, \n\tx_p5: 2nd washout 2nd input, \n\tx_p6: transducer 2nd input, \n\tx_p7: ramp tracking filter state 1, \n\tx_p8: ramp tracking filter state 2, \n\tx_p9: ramp tracking filter state 3, \n\tx_p10: ramp tracking filter state 4, \n\tx_p11: ramp tracking filter state 5, \n\tx_p12: ramp tracking filter state 6, \n\tx_p13: ramp tracking filter state 7, \n\tx_p14: ramp tracking filter state 8, \n\tx_p15: 1st lead-lag, \n\tx_p16: 2nd lead-lag,","internal_default":"[:x_p1, :x_p2, :x_p3, :x_p4, :x_p5, :x_p6, :x_p7, :x_p8, :x_p9, :x_p10, :x_p11, :x_p12, :x_p13, :x_p14, :x_p15, :x_p16]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"IEEEST has 16 states","internal_default":16},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"IEEEST has 16 differential states","internal_default":"[StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"IEEE Dual-Input Stabilizer Model","struct_name":"PSS2A","supertype":"PSS"},{"fields":[{"name":"input_code_1","data_type":"Int","null_value":1,"validation_action":"error","comment":"First Input Code for stabilizer","valid_range":{"max":6,"min":1}},{"name":"remote_bus_control_1","data_type":"Int","null_value":0,"comment":"First Input Remote Bus number for control."},{"name":"input_code_2","data_type":"Int","null_value":1,"validation_action":"error","comment":"Second Input Code for stabilizer","valid_range":{"max":6,"min":1}},{"name":"remote_bus_control_2","data_type":"Int","null_value":0,"comment":"Second Input Remote Bus number for control."},{"name":"M_rtf","data_type":"Int","null_value":0,"validation_action":"error","comment":"M parameter for ramp tracking filter","valid_range":{"max":8,"min":0}},{"name":"N_rtf","data_type":"Int","null_value":0,"validation_action":"error","comment":"N parameter for ramp tracking filter","valid_range":{"max":8,"min":0}},{"name":"Tw1","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for first washout filter for first input","valid_range":{"max":null,"min":"eps()"}},{"name":"Tw2","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for second washout filter for first input","valid_range":{"max":null,"min":0}},{"name":"T6","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for low-pass filter for first input","valid_range":{"max":null,"min":0}},{"name":"Tw3","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for first washout filter for second input","valid_range":{"max":null,"min":"eps()"}},{"name":"Tw4","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for second washout filter for second input","valid_range":{"max":null,"min":0}},{"name":"T7","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for low-pass filter for second input","valid_range":{"max":null,"min":0}},{"name":"Ks2","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Gain for low-pass filter for second input","valid_range":{"max":null,"min":0}},{"name":"Ks3","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Gain for second input","valid_range":{"max":null,"min":0}},{"name":"T8","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for ramp tracking filter","valid_range":{"max":null,"min":0}},{"name":"T9","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for ramp tracking filter","valid_range":{"max":null,"min":"eps()"}},{"name":"Ks1","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Gain before lead-lag blocks","valid_range":{"max":null,"min":0}},{"name":"T1","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for first lead-lag block","valid_range":{"max":null,"min":0}},{"name":"T2","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for first lead-lag block","valid_range":{"max":null,"min":0}},{"name":"T3","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for second lead-lag block","valid_range":{"max":null,"min":0}},{"name":"T4","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for second lead-lag block","valid_range":{"max":null,"min":0}},{"name":"T10","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for third lead-lag block","valid_range":{"max":null,"min":0}},{"name":"T11","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for third lead-lag block","valid_range":{"max":null,"min":0}},{"name":"Vs1_lim","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"First input limits `(Vs1_min, Vs1_max)`"},{"name":"Vs2_lim","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Second input limits `(Vs2_min, Vs2_max)`"},{"name":"Vst_lim","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"PSS output limits `(Vst_min, Vst_max)`"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tx_p1: 1st washout 1st input, \n\tx_p2: 2nd washout 1st input, \n\tx_p3: transducer 1st input, \n\tx_p4: 1st washout 2nd input, \n\tx_p5: 2nd washout 2nd input, \n\tx_p6: transducer 2nd input, \n\tx_p7: ramp tracking filter state 1, \n\tx_p8: ramp tracking filter state 2, \n\tx_p9: ramp tracking filter state 3, \n\tx_p10: ramp tracking filter state 4, \n\tx_p11: ramp tracking filter state 5, \n\tx_p12: ramp tracking filter state 6, \n\tx_p13: ramp tracking filter state 7, \n\tx_p14: ramp tracking filter state 8, \n\tx_p15: 1st lead-lag, \n\tx_p16: 2nd lead-lag, \n\tx_p17: 3rd lead-lag,","internal_default":"[:x_p1, :x_p2, :x_p3, :x_p4, :x_p5, :x_p6, :x_p7, :x_p8, :x_p9, :x_p10, :x_p11, :x_p12, :x_p13, :x_p14, :x_p15, :x_p16, :x_p17]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"IEEEST has 17 states","internal_default":17},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"IEEEST has 17 differential states","internal_default":"[StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"IEEE 421.5 2005 PSS2B IEEE Dual-Input Stabilizer Model","struct_name":"PSS2B","supertype":"PSS"},{"fields":[{"name":"input_code_1","data_type":"Int","null_value":1,"validation_action":"error","comment":"First Input Code for stabilizer","valid_range":{"max":7,"min":1}},{"name":"remote_bus_control_1","data_type":"Int","null_value":0,"comment":"First Input Remote Bus number for control."},{"name":"input_code_2","data_type":"Int","null_value":1,"validation_action":"error","comment":"Second Input Code for stabilizer","valid_range":{"max":6,"min":1}},{"name":"remote_bus_control_2","data_type":"Int","null_value":0,"comment":"Second Input Remote Bus number for control."},{"name":"M_rtf","data_type":"Int","null_value":0,"validation_action":"error","comment":"M parameter for ramp tracking filter","valid_range":{"max":8,"min":0}},{"name":"N_rtf","data_type":"Int","null_value":0,"validation_action":"error","comment":"N parameter for ramp tracking filter","valid_range":{"max":8,"min":0}},{"name":"Tw1","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for first washout filter for first input","valid_range":{"max":null,"min":"eps()"}},{"name":"Tw2","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for second washout filter for first input","valid_range":{"max":null,"min":0}},{"name":"T6","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for low-pass filter for first input","valid_range":{"max":null,"min":0}},{"name":"Tw3","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for first washout filter for second input","valid_range":{"max":null,"min":"eps()"}},{"name":"Tw4","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for second washout filter for second input","valid_range":{"max":null,"min":0}},{"name":"T7","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for low-pass filter for second input","valid_range":{"max":null,"min":0}},{"name":"Ks2","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Gain for low-pass filter for second input","valid_range":{"max":null,"min":0}},{"name":"Ks3","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Gain for second input","valid_range":{"max":null,"min":0}},{"name":"T8","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for ramp tracking filter","valid_range":{"max":null,"min":0}},{"name":"T9","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for ramp tracking filter","valid_range":{"max":null,"min":"eps()"}},{"name":"Ks1","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Gain before lead-lag blocks","valid_range":{"max":null,"min":0}},{"name":"T1","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for first lead-lag block","valid_range":{"max":null,"min":0}},{"name":"T2","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for first lead-lag block","valid_range":{"max":null,"min":0}},{"name":"T3","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for second lead-lag block","valid_range":{"max":null,"min":0}},{"name":"T4","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for second lead-lag block","valid_range":{"max":null,"min":0}},{"name":"T10","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for third lead-lag block","valid_range":{"max":null,"min":0}},{"name":"T11","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for third lead-lag block","valid_range":{"max":null,"min":0}},{"name":"Vs1_lim","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"First input limits `(Vs1_min, Vs1_max)`"},{"name":"Vs2_lim","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Second input limits `(Vs2_min, Vs2_max)`"},{"name":"Vst_lim","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"PSS output limits `(Vst_min, Vst_max)`"},{"name":"T12","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for fourth lead-lag block","valid_range":{"max":null,"min":0}},{"name":"T13","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for fourth lead-lag block","valid_range":{"max":null,"min":0}},{"name":"PSS_Hysteresis_param","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"PSS output hysteresis parameters `(PSSOFF, PSSON)`"},{"name":"Xcomp","data_type":"Float64","null_value":0,"comment":"Stator Leakage Reactance","valid_range":{"max":null,"min":0}},{"name":"Tcomp","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Time measured with compensated frequency","valid_range":{"max":null,"min":"eps()"}},{"name":"hysteresis_binary_logic","default":"1","data_type":"Int","null_value":0,"comment":"Hysteresis memory variable"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tx_p1: 1st washout 1st input, \n\tx_p2: 2nd washout 1st input, \n\tx_p3: transducer 1st input, \n\tx_p4: 1st washout 2nd input, \n\tx_p5: 2nd washout 2nd input, \n\tx_p6: transducer 2nd input, \n\tx_p7: ramp tracking filter state 1, \n\tx_p8: ramp tracking filter state 2, \n\tx_p9: ramp tracking filter state 3, \n\tx_p10: ramp tracking filter state 4, \n\tx_p11: ramp tracking filter state 5, \n\tx_p12: ramp tracking filter state 6, \n\tx_p13: ramp tracking filter state 7, \n\tx_p14: ramp tracking filter state 8, \n\tx_p15: 1st lead-lag, \n\tx_p16: 2nd lead-lag, \n\tx_p17: 3rd lead-lag, \n\tx_p18: 4th lead-lag, \n\tx_p19: washout block for compensated frequency,","internal_default":"[:x_p1, :x_p2, :x_p3, :x_p4, :x_p5, :x_p6, :x_p7, :x_p8, :x_p9, :x_p10, :x_p11, :x_p12, :x_p13, :x_p14, :x_p15, :x_p16, :x_p17, :x_p18, :x_p19]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"IEEEST has 19 states","internal_default":19},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"IEEEST has 19 differential states","internal_default":"[StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"IEEE 421.5 2016 PSS2C IEEE Dual-Input Stabilizer Model","struct_name":"PSS2C","supertype":"PSS"},{"fields":[{"name":"H","data_type":"Float64","null_value":0,"comment":"Rotor inertia constant in MWs/MVA","valid_range":{"max":null,"min":0}},{"name":"D","data_type":"Float64","null_value":0,"comment":"Rotor natural damping in pu","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tδ: rotor angle,\n\tω: rotor speed","internal_default":"[:δ, :ω]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"SingleMass has 1 state","internal_default":2},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of single mass shaft model. Typically represents the rotor mass.","struct_name":"SingleMass","supertype":"Shaft"},{"fields":[{"name":"H","data_type":"Float64","null_value":0,"comment":"Rotor inertia constant in MWs/MVA","valid_range":{"max":null,"min":0}},{"name":"H_hp","data_type":"Float64","null_value":0,"comment":"High pressure turbine inertia constant in MWs/MVA","valid_range":{"max":null,"min":0}},{"name":"H_ip","data_type":"Float64","null_value":0,"comment":"Intermediate pressure turbine inertia constant in MWs/MVA","valid_range":{"max":null,"min":0}},{"name":"H_lp","data_type":"Float64","null_value":0,"comment":"Low pressure turbine inertia constant in MWs/MVA","valid_range":{"max":null,"min":0}},{"name":"H_ex","data_type":"Float64","null_value":0,"comment":" Exciter inertia constant in MWs/MVA","valid_range":{"max":null,"min":0}},{"name":"D","data_type":"Float64","null_value":0,"comment":"Rotor natural damping in pu","valid_range":{"max":null,"min":0}},{"name":"D_hp","data_type":"Float64","null_value":0,"comment":"High pressure turbine natural damping in pu","valid_range":{"max":null,"min":0}},{"name":"D_ip","data_type":"Float64","null_value":0,"comment":"Intermediate pressure turbine natural damping in pu","valid_range":{"max":null,"min":0}},{"name":"D_lp","data_type":"Float64","null_value":0,"comment":"Low pressure turbine natural damping in pu","valid_range":{"max":null,"min":0}},{"name":"D_ex","data_type":"Float64","null_value":0,"comment":"Exciter natural damping in pu","valid_range":{"max":null,"min":0}},{"name":"D_12","data_type":"Float64","null_value":0,"comment":"High-Intermediate pressure turbine damping","valid_range":{"max":null,"min":0}},{"name":"D_23","data_type":"Float64","null_value":0,"comment":"Intermediate-Low pressure turbine damping","valid_range":{"max":null,"min":0}},{"name":"D_34","data_type":"Float64","null_value":0,"comment":"Low pressure turbine-Rotor damping","valid_range":{"max":null,"min":0}},{"name":"D_45","data_type":"Float64","null_value":0,"comment":"Rotor-Exciter damping","valid_range":{"max":null,"min":0}},{"name":"K_hp","data_type":"Float64","null_value":0,"comment":"High pressure turbine angle coefficient","valid_range":{"max":null,"min":0}},{"name":"K_ip","data_type":"Float64","null_value":0,"comment":"Intermediate pressure turbine angle coefficient","valid_range":{"max":null,"min":0}},{"name":"K_lp","data_type":"Float64","null_value":0,"comment":"Low pressure turbine angle coefficient","valid_range":{"max":null,"min":0}},{"name":"K_ex","data_type":"Float64","null_value":0,"comment":"Exciter angle coefficient","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\n\tδ: rotor angle,\n\tω: rotor speed,\n\tδ_hp: rotor angle of high pressure turbine,\n\tω_hp: rotor speed of high pressure turbine,\n\tδ_ip: rotor angle of intermediate pressure turbine,\n\tω_ip: rotor speed of intermediate pressure turbine,\n\tδ_lp: rotor angle of low pressure turbine,\n\tω_lp: rotor speed of low pressure turbine,\n\tδ_ex: rotor angle of exciter,\n\tω_lp: rotor speed of exciter","internal_default":"[:δ, :ω, :δ_hp, :ω_hp, :δ_ip, :ω_ip, :δ_lp, :ω_lp, :δ_ex, :ω_ex]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"FiveMassShaft has 10 states","internal_default":10},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of 5 mass-spring shaft model.\n It contains a High-Pressure (HP) steam turbine, Intermediate-Pressure (IP)\n steam turbine, Low-Pressure (LP) steam turbine, the Rotor and an Exciter (EX) mover.","struct_name":"FiveMassShaft","supertype":"Shaft"},{"fields":[{"name":"efficiency","data_type":"Float64","null_value":0,"comment":" Efficiency factor that multiplies P_ref","valid_range":{"max":null,"min":0}},{"name":"P_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Power Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"","internal_default":"Vector{Symbol}()"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"TGFixed has no states","internal_default":0},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of a fixed Turbine Governor that returns a fixed mechanical torque\n given by the product of P_ref*efficiency","struct_name":"TGFixed","supertype":"TurbineGov"},{"fields":[{"name":"R","data_type":"Float64","null_value":0,"comment":"Speed droop parameter","valid_range":{"max":0.1,"min":"eps()"}},{"name":"T1","data_type":"Float64","null_value":0,"comment":"Governor time constant in s","valid_range":{"max":0.5,"min":"eps()"}},{"name":"T2","data_type":"Float64","null_value":0,"comment":"Combustion chamber time constant","valid_range":{"max":0.5,"min":"eps()"}},{"name":"T3","data_type":"Float64","null_value":0,"comment":"Load limit time constant (exhaust gas measurement time)","valid_range":{"max":5,"min":"eps()"}},{"name":"AT","data_type":"Float64","null_value":0,"comment":"Ambient temperature load limit","valid_range":{"max":1,"min":0}},{"name":"Kt","data_type":"Float64","null_value":0,"comment":"Load limit feedback gain","valid_range":{"max":5,"min":0}},{"name":"V_lim","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Operational control limits on fuel valve opening (V_min, V_max)"},{"name":"D_turb","data_type":"Float64","null_value":0,"comment":"Speed damping coefficient of gas turbine rotor","valid_range":{"max":0.5,"min":0}},{"name":"P_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Load Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the GAST model are:\n\tx_g1: Fuel valve opening,\n\tx_g2: Fuel flow,\n\tx_g3: Exhaust temperature load","internal_default":"[:x_g1, :x_g2, :x_g3]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"GasTG has 3 states","internal_default":3},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"GAST has 3 differential states","internal_default":"[StateTypes.Differential, StateTypes.Differential, StateTypes.Differential]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of Gas Turbine-Governor. GAST in PSSE and GAST_PTI in PowerWorld.","struct_name":"GasTG","supertype":"TurbineGov"},{"fields":[{"name":"T1","data_type":"Float64","null_value":0,"comment":"Governor mechanism time constant","valid_range":{"max":100,"min":"eps()"}},{"name":"T2","data_type":"Float64","null_value":0,"comment":"Turbine power time constant","valid_range":{"max":100,"min":"eps()"}},{"name":"T3","data_type":"Float64","null_value":0,"comment":"Turbine exhaust temperature time constant","valid_range":{"max":100,"min":"eps()"}},{"name":"K","data_type":"Float64","null_value":0,"comment":"Governor gain (reciprocal of droop)","valid_range":{"max":100,"min":"eps()"}},{"name":"T4","data_type":"Float64","null_value":0,"comment":"Governor lead time constant","valid_range":{"max":100,"min":"eps()"}},{"name":"T5","data_type":"Float64","null_value":0,"comment":"Governor lag time constant","valid_range":{"max":100,"min":"eps()"}},{"name":"T6","data_type":"Float64","null_value":0,"comment":"Actuator time constant","valid_range":{"max":100,"min":"eps()"}},{"name":"Td","data_type":"Float64","null_value":0,"comment":"Engine time delay","valid_range":{"max":100,"min":"eps()"}},{"name":"P_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Load Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the DEGOV model are:\n\tx_ecb1: Electric control box 1,\n\tx_ecb2: Electric control box 2,\n\tx_a1: Actuator 1,\n\tx_a2: Actuator 2,\n\tx_a3: Actuator 3,","internal_default":"[:x_ecb1, :x_ecb2, :x_a1, :x_a2, :x_a3]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"DEGOV has 5 states","internal_default":5},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"DEGOV has 5 differential states","internal_default":"[StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters Woodward Diesel Governor Model. DEGOV in PowerWorld.","struct_name":"DEGOV","supertype":"TurbineGov"},{"fields":[{"name":"Rselect","data_type":"Int","null_value":1,"validation_action":"error","comment":"Feedback signal for governor droop","valid_range":{"max":1,"min":-2}},{"name":"fuel_flag","data_type":"Int","null_value":0,"validation_action":"error","comment":"Flag Switch for fuel source characteristic","valid_range":{"max":1,"min":0}},{"name":"R","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Speed droop parameter","valid_range":{"max":null,"min":"eps()"}},{"name":"Tpelec","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Electrical power transducer time constant, seconds","valid_range":{"max":null,"min":"eps()"}},{"name":"speed_error_signal","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Speed error signal limits"},{"name":"Kp_gov","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Governor proportional gain","valid_range":{"max":null,"min":0}},{"name":"Ki_gov","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Governor integral gain","valid_range":{"max":null,"min":0}},{"name":"Kd_gov","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Governor derivative gain","valid_range":{"max":null,"min":0}},{"name":"Td_gov","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Governor derivative time constant","valid_range":{"max":null,"min":0}},{"name":"valve_position_limits","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Valve position limits"},{"name":"T_act","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Actuator time constant","valid_range":{"max":null,"min":0}},{"name":"K_turb","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Turbine gain","valid_range":{"max":null,"min":0}},{"name":"Wf_nl","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"No load fuel flow, pu","valid_range":{"max":null,"min":0}},{"name":"Tb","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Turbine lag time constant, sec","valid_range":{"max":null,"min":0}},{"name":"Tc","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Turbine lead time constant, sec","valid_range":{"max":null,"min":0}},{"name":"T_eng","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Transport lag time constant for diesel engine, sec","valid_range":{"max":null,"min":0}},{"name":"Tf_load","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Load limiter time constant","valid_range":{"max":null,"min":0}},{"name":"Kp_load","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Load limiter proportional gain for PI controller","valid_range":{"max":null,"min":0}},{"name":"Ki_load","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Load integral gain for PI controller","valid_range":{"max":null,"min":0}},{"name":"Ld_ref","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Load limiter integral gain for PI controller","valid_range":{"max":null,"min":0}},{"name":"Dm","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Mechanical damping coefficient, pu","valid_range":{"max":null,"min":0}},{"name":"R_open","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Maximum valve opening rate, pu/sec","valid_range":{"max":null,"min":0}},{"name":"R_close","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Maximum valve closing rate, pu/sec","valid_range":{"max":null,"min":0}},{"name":"Ki_mw","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Power controller (reset) gain","valid_range":{"max":null,"min":0}},{"name":"A_set","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Acceleration limiter setpoint, pu/sec","valid_range":{"max":null,"min":0}},{"name":"Ka","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Acceleration limiter gain","valid_range":{"max":null,"min":0}},{"name":"Ta","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Acceleration limiter time constant ","valid_range":{"max":null,"min":"eps()"}},{"name":"T_rate","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Turbine rating","valid_range":{"max":null,"min":0}},{"name":"db","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Speed governor deadband","valid_range":{"max":null,"min":0}},{"name":"Tsa","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Temperature detection lead time constant","valid_range":{"max":null,"min":0}},{"name":"Tsb","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Temperature detection lag time constant","valid_range":{"max":null,"min":0}},{"name":"R_lim","data_type":"UpDown","null_value":"(up = 0.0, down = 0.0)","comment":"Maximum rate of load increa"},{"name":"P_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Power Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the GGOV1 model are:\n\tPe: Machine Electrical Power Measurement,\n\tx_g1: Governor differential control,\n\tx_g2: Governor integral control, \n\tx_g3: Turbine actuator, \n\tx_g4: Turbine Lead-Lag, \n\tx_g5: Turbine load limiter measurement, \n\tx_g6: Turbine Load Limiter Integral Control, \n\tx_g7: Supervisory Load Control, \n\tx_g8: Acceleration Control, \n\tx_g9 Temperature Detection Lead - Lag:","internal_default":"[:Pe, :x_g1, :x_g2, :x_g3, :x_g4, :x_g5, :x_g6, :x_g7, :x_g8, :x_g9]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"GeneralGovModel has 10 states","internal_default":10},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"GGOV1 has 10 differential states","internal_default":"[StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Differential, StateTypes.Hybrid]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"GE General Governor/Turbine Model. The GeneralGovModel (GGOV1) model is a general purpose governor model used for a variety of prime movers controlled by proportional-integral-derivative (PID) governors including gas turbines.","struct_name":"GeneralGovModel","supertype":"TurbineGov"},{"fields":[{"name":"R","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Droop parameter","valid_range":{"max":0.1,"min":0}},{"name":"T1","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Governor time constant","valid_range":{"max":0.5,"min":"eps()"}},{"name":"valve_position_limits","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Valve position limits"},{"name":"T2","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Lead Lag Lead Time constant ","valid_range":{"max":null,"min":0}},{"name":"T3","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Lead Lag Lag Time constant ","valid_range":{"max":10,"min":"eps()"}},{"name":"D_T","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Turbine Damping","valid_range":{"max":0.5,"min":0}},{"name":"DB_h","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Deadband for overspeed","valid_range":{"max":null,"min":0}},{"name":"DB_l","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Deadband for underspeed","valid_range":{"max":0,"min":null}},{"name":"T_rate","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Turbine Rate (MW). If zero, generator base is used.","valid_range":{"max":null,"min":0}},{"name":"P_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Power Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the SteamTurbineGov1 model are:\n\tx_g1: Valve Opening,\n\tx_g2: Lead-lag state","internal_default":"[:x_g1, :x_g2]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"TGOV1 has 2 states","internal_default":2},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"TGOV1 has 2 differential states","internal_default":"[StateTypes.Differential, StateTypes.Differential]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Steam Turbine-Governor. This model considers both TGOV1 or TGOV1DU in PSS/E.","struct_name":"SteamTurbineGov1","supertype":"TurbineGov"},{"fields":[{"name":"R","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Permanent droop parameter","valid_range":{"max":0.1,"min":0}},{"name":"r","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Temporary Droop","valid_range":{"max":2,"min":0}},{"name":"Tr","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Governor time constant","valid_range":{"max":30,"min":"eps()"}},{"valid_range":{"max":0.1,"min":"eps()"},"name":"Tf","data_type":"Float64","null_value":0,"valiation_action":"error","comment":"Filter Time constant"},{"name":"Tg","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Servo time constant","valid_range":{"max":1,"min":"eps()"}},{"name":"VELM","data_type":"Float64","null_value":0,"validation_action":"error","comment":"gate velocity limit","valid_range":{"max":0.3,"min":"eps()"}},{"name":"gate_position_limits","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Gate position limits"},{"name":"Tw","data_type":"Float64","null_value":0,"validation_action":"error","comment":"water time constant","valid_range":{"max":3,"min":"eps()"}},{"name":"At","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Turbine gain","valid_range":{"max":1.5,"min":0.8}},{"name":"D_T","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Turbine Damping","valid_range":{"max":0.5,"min":0}},{"name":"q_nl","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"No-power flow","valid_range":{"max":null,"min":0}},{"name":"P_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Power Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the HydroTurbineGov model are:\n\tx_g1: filter_output,\n\tx_g2: desired gate, \n\tx_g3: gate opening, \n\tx_g4: turbine flow","internal_default":"[:x_g1, :x_g2, :x_g3, :x_g4]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"HYGOV has 4 states","internal_default":4},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"HYGOV has 4 differential states","internal_default":"[StateTypes.Differential, StateTypes.Differential, StateTypes.Differential, StateTypes.Differential]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Hydro Turbine-Governor.","struct_name":"HydroTurbineGov","supertype":"TurbineGov"},{"fields":[{"name":"K","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Governor Gain","valid_range":{"max":30,"min":5}},{"name":"T1","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Input Filter Lag","valid_range":{"max":5,"min":0}},{"name":"T2","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Input Filter Lead","valid_range":{"max":10,"min":0}},{"name":"T3","data_type":"Float64","null_value":0,"validation_action":"error","comment":"Valve position Time Constant","valid_range":{"max":1,"min":"eps()"}},{"name":"U0","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Maximum Valve Opening Rate","valid_range":{"max":0.03,"min":0.01}},{"name":"U_c","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Maximum Valve closing rate","valid_range":{"max":0,"min":-0.3}},{"name":"valve_position_limits","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Valve position limits in MW"},{"name":"T4","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time Constant inlet steam","valid_range":{"max":1,"min":0}},{"name":"K1","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Fraction of high presure shaft power","valid_range":{"max":1,"min":-2}},{"name":"K2","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Fraction of low presure shaft power","valid_range":{"max":null,"min":0}},{"name":"T5","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for second boiler pass","valid_range":{"max":10,"min":0}},{"name":"K3","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Fraction of high presure shaft power second boiler pass","valid_range":{"max":0.5,"min":0}},{"name":"K4","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Fraction of low presure shaft power second boiler pass","valid_range":{"max":0.5,"min":0}},{"name":"T6","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for third boiler pass","valid_range":{"max":10,"min":0}},{"name":"K5","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Fraction of high presure shaft power third boiler pass","valid_range":{"max":0.35,"min":0}},{"name":"K6","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Fraction of low presure shaft power third boiler pass","valid_range":{"max":0.55,"min":0}},{"name":"T7","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Time constant for fourth boiler pass","valid_range":{"max":10,"min":0}},{"name":"K7","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Fraction of high presure shaft power fourth boiler pass","valid_range":{"max":0.3,"min":0}},{"name":"K8","data_type":"Float64","null_value":0,"validation_action":"warn","comment":"Fraction of low presure shaft power fourth boiler pass","valid_range":{"max":0.3,"min":0}},{"name":"P_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Power Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the IEEETurbineGov model are:\n\tx_g1: First Governor integrator,\n\tx_g2: Governor output,\n\tx_g3: First Turbine integrator, \n\tx_g4: Second Turbine Integrator, \n\tx_g5: Third Turbine Integrator, \n\tx_g6: Fourth Turbine Integrator, ","internal_default":"[:x_g1, :x_g2, :x_g3, :x_g4, :x_g5, :x_g6]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"IEEEG1 has 6 states","internal_default":6},{"name":"states_types","data_type":"Vector{StateTypes}","comment":"IEEEG1 has 6 differential states","internal_default":"[StateTypes.Differential, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid, StateTypes.Hybrid]"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"IEEE Type 1 Speed-Governing Model","struct_name":"IEEETurbineGov1","supertype":"TurbineGov"},{"fields":[{"name":"R","data_type":"Float64","null_value":0,"comment":"Droop parameter","valid_range":{"max":null,"min":0}},{"name":"Ts","data_type":"Float64","null_value":0,"comment":"Governor time constant","valid_range":{"max":null,"min":0}},{"name":"Tc","data_type":"Float64","null_value":0,"comment":"Servo time constant","valid_range":{"max":null,"min":0}},{"name":"T3","data_type":"Float64","null_value":0,"comment":"Transient gain time constant","valid_range":{"max":null,"min":0}},{"name":"T4","data_type":"Float64","null_value":0,"comment":"Power fraction time constant","valid_range":{"max":null,"min":0}},{"name":"T5","data_type":"Float64","null_value":0,"comment":"Reheat time constant","valid_range":{"max":null,"min":0}},{"name":"valve_position_limits","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Valve position limits in MW"},{"name":"P_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Power Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the TGTypeI model are:\n\tx_g1: Governor state,\n\tx_g2: Servo state,\n\tx_g3: Reheat state","internal_default":"[:x_g1, :x_g2, :x_g3]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"TGTypeI has 3 states","internal_default":3},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of a Turbine Governor Type I.","struct_name":"TGTypeI","supertype":"TurbineGov"},{"fields":[{"name":"R","data_type":"Float64","null_value":0,"comment":"Droop parameter","valid_range":{"max":null,"min":0}},{"name":"T1","data_type":"Float64","null_value":0,"comment":"Transient gain time constant","valid_range":{"max":null,"min":0}},{"name":"T2","data_type":"Float64","null_value":0,"comment":"Power fraction time constant","valid_range":{"max":null,"min":0}},{"name":"τ_limits","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Power into the governor limits"},{"name":"P_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Power Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the TGTypeI model are:\n\tx_g1: lead-lag state","internal_default":"[:xg]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"TGTypeII has 1 state","internal_default":1},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of a Turbine Governor Type II.","struct_name":"TGTypeII","supertype":"TurbineGov"},{"fields":[{"name":"rated_voltage","data_type":"Float64","null_value":0,"comment":"rated voltage","valid_range":{"max":null,"min":0}},{"name":"rated_current","data_type":"Float64","null_value":0,"comment":"rated VA","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"","internal_default":"Vector{Symbol}()"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"AverageConverter has no states","internal_default":0}],"docstring":"Parameters of an average converter model","struct_name":"AverageConverter","supertype":"Converter"},{"fields":[{"name":"T_g","data_type":"Float64","null_value":0,"comment":"Converter time constant (s)","valid_range":{"max":null,"min":0}},{"name":"Rrpwr","data_type":"Float64","null_value":0,"comment":"Low Voltage Power Logic (LVPL) ramp rate limit (pu/s)","valid_range":{"max":null,"min":0}},{"name":"Brkpt","data_type":"Float64","null_value":0,"comment":"LVPL characteristic voltage 2 (pu)","valid_range":{"max":null,"min":0}},{"name":"Zerox","data_type":"Float64","null_value":0,"comment":"LVPL characteristic voltage 1 (pu)","valid_range":{"max":null,"min":0}},{"name":"Lvpl1","data_type":"Float64","null_value":0,"comment":"LVPL gain (pu)","valid_range":{"max":null,"min":0}},{"name":"Vo_lim","data_type":"Float64","null_value":0,"comment":"Voltage limit for high voltage reactive current management (pu)","valid_range":{"max":null,"min":0}},{"name":"Lv_pnts","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Voltage points for low voltage active current management (pu) (Lvpnt0, Lvpnt1)"},{"name":"Io_lim","data_type":"Float64","null_value":0,"comment":"Current limit (pu) for high voltage reactive current management (specified as a negative value)","valid_range":{"max":0,"min":null}},{"name":"T_fltr","data_type":"Float64","null_value":0,"comment":"Voltage filter time constant for low voltage active current management (s)","valid_range":{"max":null,"min":0}},{"name":"K_hv","data_type":"Float64","null_value":0,"comment":"Overvoltage compensation gain used in the high voltage reactive current management","valid_range":{"max":null,"min":0}},{"name":"Iqr_lims","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Limit on rate of change for reactive current (pu/s) (Iqr_min, Iqr_max)"},{"name":"Accel","data_type":"Float64","null_value":0,"comment":"Acceleration factor","valid_range":{"max":1,"min":0}},{"name":"Lvpl_sw","data_type":"Int","null_value":0,"comment":"Low voltage power logic (LVPL) switch. (0: LVPL not present, 1: LVPL present)","valid_range":{"max":1,"min":0}},{"name":"Q_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Initial machine reactive power from power flow","valid_range":{"max":null,"min":0}},{"name":"R_source","default":"0.0","data_type":"Float64","null_value":0,"comment":"Output resistor used for the Thevenin Equivalent","valid_range":{"max":null,"min":0}},{"name":"X_source","default":"1.0e5","data_type":"Float64","null_value":0,"comment":"Output resistor used for the Thevenin Equivalent","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\tIp: Converter lag for Ipcmd,\tIq: Converter lag for Iqcmd,\tVmeas: Voltage filter for low voltage active current management","internal_default":"[:Ip, :Iq, :Vmeas]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"RenewableEnergyConverterTypeA has 3 states","internal_default":3}],"docstring":"Parameters of a renewable energy generator/converter model, this model corresponds to REGCA1 in PSSE","struct_name":"RenewableEnergyConverterTypeA","supertype":"Converter"},{"fields":[{"name":"T_g","data_type":"Float64","null_value":0,"comment":"Converter time constant (s)","valid_range":{"max":null,"min":0}},{"name":"Rrpwr","data_type":"Float64","null_value":0,"comment":"Low Voltage Power Logic (LVPL) ramp rate limit (pu/s)","valid_range":{"max":null,"min":0}},{"name":"Brkpt","data_type":"Float64","null_value":0,"comment":"LVPL characteristic voltage 2 (pu)","valid_range":{"max":null,"min":0}},{"name":"Zerox","data_type":"Float64","null_value":0,"comment":"LVPL characteristic voltage 1 (pu)","valid_range":{"max":null,"min":0}},{"name":"Lvpl1","data_type":"Float64","null_value":0,"comment":"LVPL gain (pu)","valid_range":{"max":null,"min":0}},{"name":"Vo_lim","data_type":"Float64","null_value":0,"comment":"Voltage limit for high voltage reactive current management (pu)","valid_range":{"max":null,"min":0}},{"name":"Lv_pnts","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Voltage points for low voltage active current management (pu) (Lvpnt0, Lvpnt1)"},{"name":"Io_lim","data_type":"Float64","null_value":0,"comment":"Current limit (pu) for high voltage reactive current management (specified as a negative value)","valid_range":{"max":0,"min":null}},{"name":"T_fltr","data_type":"Float64","null_value":0,"comment":"Voltage filter time constant for low voltage active current management (s)","valid_range":{"max":null,"min":0}},{"name":"K_hv","data_type":"Float64","null_value":0,"comment":"Overvoltage compensation gain used in the high voltage reactive current management","valid_range":{"max":null,"min":0}},{"name":"Iqr_lims","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Limit on rate of change for reactive current (pu/s) (Iqr_min, Iqr_max)"},{"name":"Accel","data_type":"Float64","null_value":0,"comment":"Acceleration factor","valid_range":{"max":1,"min":0}},{"name":"Lvpl_sw","data_type":"Int","null_value":0,"comment":"Low voltage power logic (LVPL) switch. (0: LVPL not present, 1: LVPL present)","valid_range":{"max":1,"min":0}},{"name":"Q_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Initial machine reactive power from power flow","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states are:\tIp: Converter lag for Ipcmd,\tIq: Converter lag for Iqcmd,\tVmeas: Voltage filter for low voltage active current management","internal_default":"[:Ip, :Iq, :Vmeas]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"RenewableEnergyVoltageConverterTypeA has 3 states","internal_default":3}],"docstring":"Parameters of a renewable energy generator/converter model, this model corresponds to REGCA1 in PSSE, but to be interfaced using a Voltage Source instead of a Current Source.","struct_name":"RenewableEnergyVoltageConverterTypeA","supertype":"Converter"},{"fields":[{"name":"voltage","data_type":"Float64","null_value":0,"comment":"rated VA","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"","internal_default":"Vector{Symbol}()"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"FixedDCSource has no states","internal_default":0},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of a Fixed DC Source that returns a fixed DC voltage","struct_name":"FixedDCSource","supertype":"DCSource"},{"fields":[{"name":"rated_voltage","data_type":"Float64","null_value":0,"comment":"rated voltage","valid_range":{"max":null,"min":0}},{"name":"rated_current","data_type":"Float64","null_value":0,"comment":"rated current","valid_range":{"max":null,"min":0}},{"name":"battery_voltage","data_type":"Float64","null_value":0,"comment":"battery voltage","valid_range":{"max":null,"min":0}},{"name":"battery_resistance","data_type":"Float64","null_value":0,"comment":"battery_resistance","valid_range":{"max":null,"min":0}},{"name":"dc_dc_inductor","data_type":"Float64","null_value":0,"comment":"DC/DC inductance","valid_range":{"max":null,"min":0}},{"name":"dc_link_capacitance","data_type":"Float64","null_value":0,"comment":"DC-link capacitor","valid_range":{"max":null,"min":0}},{"name":"fs","data_type":"Float64","null_value":0,"comment":"DC/DC converter switching frequency","valid_range":{"max":null,"min":0}},{"name":"kpv","data_type":"Float64","null_value":0,"comment":"voltage controller proportional gain","valid_range":{"max":null,"min":0}},{"name":"kiv","data_type":"Float64","null_value":0,"comment":"voltage controller integral gain","valid_range":{"max":null,"min":0}},{"name":"kpi","data_type":"Float64","null_value":0,"comment":"current controller proportional gain","valid_range":{"max":null,"min":0}},{"name":"kii","data_type":"Float64","null_value":0,"comment":"current controller integral gain","valid_range":{"max":null,"min":0}},{"name":"Vdc_ref","default":"1.1","data_type":"Float64","null_value":0,"comment":"Reference DC-Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the ZeroOrderBESS model are:\n\tv_dc: DC-link votlage,\n\ti_b: Battery current,\n\t ν: integrator state of the voltage controller,\n\t ζ: integrator state of the PI current controller","internal_default":"[:v_dc, :i_b, :ν, :ζ]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"ZeroOrderBESS has 4 states","internal_default":4}],"docstring":"Parameters for the DC-side with a Battery Energy Storage System from paper at https://arxiv.org/abs/2007.11776","struct_name":"ZeroOrderBESS","supertype":"DCSource"},{"fields":[{"name":"lf","data_type":"Float64","null_value":0,"comment":"Series inductance in p.u. of converter filter","valid_range":{"max":null,"min":0}},{"name":"rf","data_type":"Float64","null_value":0,"comment":"Series resistance in p.u. of converter filter","valid_range":{"max":null,"min":0}},{"name":"cf","data_type":"Float64","null_value":0,"comment":"Shunt capacitance in p.u. of converter filter","valid_range":{"max":null,"min":0}},{"name":"lg","data_type":"Float64","null_value":0,"comment":"Series inductance in p.u. of converter filter to the grid","valid_range":{"max":null,"min":0}},{"name":"rg","data_type":"Float64","null_value":0,"comment":"Series resistance in p.u. of converter filter to the grid","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the LCLFilter model are:\n\tir_cnv: Real current out of the converter,\n\tii_cnv: Imaginary current out of the converter,\n\tvr_filter: Real voltage at the filter's capacitor,\n\tvi_filter: Imaginary voltage at the filter's capacitor,\n\tir_filter: Real current out of the filter,\n\tii_filter: Imaginary current out of the filter","internal_default":"[:ir_cnv, :ii_cnv, :vr_filter, :vi_filter, :ir_filter, :ii_filter]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"LCLFilter has 6 states","internal_default":6}],"docstring":"Parameters of a LCL filter outside the converter, the states are in the grid's reference frame","struct_name":"LCLFilter","supertype":"Filter"},{"fields":[{"name":"lf","data_type":"Float64","null_value":0,"comment":"filter inductance","valid_range":{"max":null,"min":0}},{"name":"rf","data_type":"Float64","null_value":0,"comment":"filter resistance","valid_range":{"max":null,"min":0}},{"name":"cf","data_type":"Float64","null_value":0,"comment":"filter capacitance","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the LCFilter model are:\n\tir_filter: Real current out of the filter,\n\tii_filter: Imaginary current out of the filter","internal_default":"[:ir_filter, :ii_filter]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"LCFilter has two states","internal_default":2}],"docstring":"Parameters of a LCL filter outside the converter","struct_name":"LCFilter","supertype":"Filter"},{"fields":[{"name":"rf","data_type":"Float64","null_value":0,"comment":"Series resistance in p.u. of converter filter to the grid","valid_range":{"max":null,"min":0}},{"name":"lf","data_type":"Float64","null_value":0,"comment":"Series inductance in p.u. of converter filter to the grid","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"RLFilter has zero states","internal_default":"Vector{Symbol}()"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"RLFilter has zero states","internal_default":0}],"docstring":"Parameters of RL series filter in algebraic representation","struct_name":"RLFilter","supertype":"Filter"},{"fields":[{"name":"ω_lp","data_type":"Float64","null_value":0,"comment":"PLL low-pass filter frequency (rad/sec)","valid_range":{"max":null,"min":0}},{"name":"kp_pll","data_type":"Float64","null_value":0,"comment":"PLL proportional gain","valid_range":{"max":null,"min":0}},{"name":"ki_pll","data_type":"Float64","null_value":0,"comment":"PLL integral gain","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the KauraPLL model are:\n\tvd_pll: d-axis of the measured voltage in the PLL synchronous reference frame (SRF),\n\tvq_pll: q-axis of the measured voltage in the PLL SRF,\n\tε_pll: Integrator state of the PI controller,\n\tθ_pll: Phase angle displacement in the PLL SRF","internal_default":"[:vd_pll, :vq_pll, :ε_pll, :θ_pll]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"KauraPLL has 4 states","internal_default":4}],"docstring":"Parameters of a Phase-Locked Loop (PLL) based on Kaura, Vikram, and Vladimir Blasko.\n\"Operation of a phase locked loop system under distorted utility conditions.\"\nIEEE Transactions on Industry applications 33.1 (1997): 58-63.","struct_name":"KauraPLL","supertype":"FrequencyEstimator"},{"fields":[{"name":"ω_lp","data_type":"Float64","null_value":0,"comment":"PLL low-pass filter frequency (rad/sec)","valid_range":{"max":null,"min":0}},{"name":"kp_pll","data_type":"Float64","null_value":0,"comment":"PLL proportional gain","valid_range":{"max":null,"min":0}},{"name":"ki_pll","data_type":"Float64","null_value":0,"comment":"PLL integral gain","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the ReducedOrderPLL model are:\n\tvq_pll: q-axis of the measured voltage in the PLL synchronous reference frame (SRF),\n\tε_pll: Integrator state of the PI controller,\n\tθ_pll: Phase angle displacement in the PLL SRF","internal_default":"[:vq_pll, :ε_pll, :θ_pll]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"ReducedOrderPLL has 3 states","internal_default":3}],"docstring":"Parameters of a Phase-Locked Loop (PLL) based on Purba, Dhople, Jafarpour, Bullo and Johnson.\n\"Reduced-order Structure-preserving Model for Parallel-connected Three-phase Grid-tied Inverters.\"\n2017 IEEE 18th Workshop on Control and Modeling for Power Electronics (COMPEL): 1-7.","struct_name":"ReducedOrderPLL","supertype":"FrequencyEstimator"},{"fields":[{"name":"frequency","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference used"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"FixedFrequency has no states","internal_default":"Vector{Symbol}()"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"FixedFrequency has no states","internal_default":0}],"docstring":"Parameters of a Fixed Frequency Estimator (i.e. no PLL).","struct_name":"FixedFrequency","supertype":"FrequencyEstimator"},{"fields":[{"name":"Ta","data_type":"Float64","null_value":0,"comment":"VSM inertia constant","valid_range":{"max":null,"min":0}},{"name":"kd","data_type":"Float64","null_value":0,"comment":"VSM damping constant","valid_range":{"max":null,"min":0}},{"name":"kω","data_type":"Float64","null_value":0,"comment":"frequency droop gain","valid_range":{"max":null,"min":0}},{"name":"P_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Power Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the VirtualInertia model are:\n\tθ_oc: Phase angle displacement of the virtual synchronous generator model\n\tω_oc: Speed of the rotating reference frame of the virtual synchronous generator model","internal_default":"[:θ_oc, :ω_oc]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"VirtualInertia has two states","internal_default":2}],"docstring":"Parameters of a Virtual Inertia with SRF using VSM for active power controller","struct_name":"VirtualInertia","supertype":"ActivePowerControl"},{"fields":[{"name":"Rp","data_type":"Float64","null_value":0,"comment":"Droop Gain","valid_range":{"max":null,"min":0}},{"name":"ωz","data_type":"Float64","null_value":0,"comment":"filter frequency cutoff","valid_range":{"max":null,"min":0}},{"name":"P_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Power Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the ActivePowerDroop model are:\n\tθ_oc: Phase angle displacement of the inverter model,\n\tp_oc: Measured active power of the inverter model","internal_default":"[:θ_oc, :p_oc]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"ActivePowerDroop has two states","internal_default":2}],"docstring":"Parameters of an Active Power droop controller","struct_name":"ActivePowerDroop","supertype":"ActivePowerControl"},{"fields":[{"name":"Kp_p","data_type":"Float64","null_value":0,"comment":"Proportional Gain","valid_range":{"max":null,"min":0}},{"name":"Ki_p","data_type":"Float64","null_value":0,"comment":"Integral Gain","valid_range":{"max":null,"min":0}},{"name":"ωz","data_type":"Float64","null_value":0,"comment":"filter frequency cutoff","valid_range":{"max":null,"min":0}},{"name":"P_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Power Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the ActivePowerPI model are:\n\tσp_oc: Integrator state of the PI Controller,\n\tp_oc: Measured active power of the inverter model","internal_default":"[:σp_oc, :p_oc]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"ActivePowerPI has two states","internal_default":2}],"docstring":"Parameters of a Proportional-Integral Active Power controller for a specified power reference","struct_name":"ActivePowerPI","supertype":"ActivePowerControl"},{"fields":[{"name":"k1","data_type":"Float64","null_value":0,"comment":"VOC Synchronization Gain","valid_range":{"max":null,"min":0}},{"name":"ψ","data_type":"Float64","null_value":0,"comment":"Rotation angle of the controller","valid_range":{"max":null,"min":0}},{"name":"P_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Power Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the ActiveVirtualOscillator model are:\n\tθ_oc: Phase angle displacement of the inverter model","internal_default":"[:θ_oc]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"ActiveVirtualOscillator has one state","internal_default":1}],"docstring":"Parameters of an Active Virtual Oscillator controller. Model is based from the paper Model Reduction for Inverters with Current Limiting and Dispatchable Virtual Oscillator Control by O. Ajala et al.","struct_name":"ActiveVirtualOscillator","supertype":"ActivePowerControl"},{"fields":[{"name":"bus_control","data_type":"Int","null_value":0,"comment":"Bus Number for voltage control; ","valid_range":{"max":null,"min":0}},{"name":"from_branch_control","data_type":"Int","null_value":0,"comment":"Monitored branch FROM bus number for line drop compensation (if 0 generator power will be used)","valid_range":{"max":null,"min":0}},{"name":"to_branch_control","data_type":"Int","null_value":0,"comment":"Monitored branch TO bus number for line drop compensation (if 0 generator power will be used)","valid_range":{"max":null,"min":0}},{"name":"branch_id_control","data_type":"String","null_value":0,"comment":"Branch circuit id for line drop compensation (as a string). If 0 generator power will be used"},{"name":"Freq_Flag","data_type":"Int","null_value":0,"comment":"Frequency Flag for REPCA1: 0: disable, 1:enable","valid_range":{"max":1,"min":0}},{"name":"K_pg","data_type":"Float64","null_value":0,"comment":"Active power PI control proportional gain","valid_range":{"max":null,"min":0}},{"name":"K_ig","data_type":"Float64","null_value":0,"comment":"Active power PI control integral gain","valid_range":{"max":null,"min":0}},{"name":"T_p","data_type":"Float64","null_value":0,"comment":"Real power measurement filter time constant (s)","valid_range":{"max":null,"min":0}},{"name":"fdbd_pnts","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Frequency error dead band thresholds `(fdbd1, fdbd2)`"},{"name":"fe_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Upper/Lower limit on frequency error `(fe_min, fe_max)`"},{"name":"P_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Upper/Lower limit on power reference `(P_min, P_max)`"},{"name":"T_g","data_type":"Float64","null_value":0,"comment":"Power Controller lag time constant","valid_range":{"max":null,"min":0}},{"name":"D_dn","data_type":"Float64","null_value":0,"comment":"Droop for over-frequency conditions","valid_range":{"max":0,"min":null}},{"name":"D_up","data_type":"Float64","null_value":0,"comment":"Droop for under-frequency conditions","valid_range":{"max":null,"min":0}},{"name":"dP_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Upper/Lower limit on power reference ramp rates`(dP_min, dP_max)`"},{"name":"P_lim_inner","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Upper/Lower limit on power reference for REECB`(P_min_inner, P_max_inner)`"},{"name":"T_pord","data_type":"Float64","null_value":0,"comment":"Power filter time constant REECB time constant","valid_range":{"max":null,"min":0}},{"name":"P_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Power Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the ActiveRenewableControllerAB model depends on the Flag","internal_default":"PowerSystems.get_activeRETypeAB_states(Freq_Flag)[1]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"The states of the ActiveRenewableControllerAB model depends on the Flag","internal_default":"PowerSystems.get_activeRETypeAB_states(Freq_Flag)[2]"}],"docstring":"Parameters of Active Power Controller including REPCA1 and REECB1","struct_name":"ActiveRenewableControllerAB","supertype":"ActivePowerControl"},{"fields":[{"name":"bus_control","data_type":"Int","null_value":0,"comment":"Bus Number for voltage control; ","valid_range":{"max":null,"min":0}},{"name":"from_branch_control","data_type":"Int","null_value":0,"comment":"Monitored branch FROM bus number for line drop compensation (if 0 generator power will be used)","valid_range":{"max":null,"min":0}},{"name":"to_branch_control","data_type":"Int","null_value":0,"comment":"Monitored branch TO bus number for line drop compensation (if 0 generator power will be used)","valid_range":{"max":null,"min":0}},{"name":"branch_id_control","data_type":"String","null_value":0,"comment":"Branch circuit id for line drop compensation (as a string). If 0 generator power will be used"},{"name":"VC_Flag","data_type":"Int","null_value":0,"comment":"Voltage Compensator Flag for REPCA1","valid_range":{"max":1,"min":0}},{"name":"Ref_Flag","data_type":"Int","null_value":0,"comment":"Flag for Reactive Power Control for REPCA1. 0: Q-control, 1: V-control","valid_range":{"max":1,"min":0}},{"name":"PF_Flag","data_type":"Int","null_value":0,"comment":"Flag for Power Factor Control for Outer Control of REECB1. 0: Q-control, 1: Power Factor Control","valid_range":{"max":1,"min":0}},{"name":"V_Flag","data_type":"Int","null_value":0,"comment":"Flag for Voltage Control for Outer Control of REECB1. 0: Voltage Control, 1: Q-Control","valid_range":{"max":1,"min":0}},{"name":"T_fltr","data_type":"Float64","null_value":0,"comment":"Voltage or Q-power of REPCA Filter Time Constant","valid_range":{"max":null,"min":0}},{"name":"K_p","data_type":"Float64","null_value":0,"comment":"Reactive power PI control proportional gain","valid_range":{"max":null,"min":0}},{"name":"K_i","data_type":"Float64","null_value":0,"comment":"Reactive power PI control integral gain","valid_range":{"max":null,"min":0}},{"name":"T_ft","data_type":"Float64","null_value":0,"comment":"Reactive power lead time constant (s)","valid_range":{"max":null,"min":0}},{"name":"T_fv","data_type":"Float64","null_value":0,"comment":"Reactive power lag time constant (s)","valid_range":{"max":null,"min":0}},{"name":"V_frz","data_type":"Float64","null_value":0,"comment":"Voltage below which state ξq_oc (integrator state) is freeze","valid_range":{"max":null,"min":0}},{"name":"R_c","data_type":"Float64","null_value":0,"comment":"Line drop compensation resistance (used when VC_Flag = 1)","valid_range":{"max":null,"min":0}},{"name":"X_c","data_type":"Float64","null_value":0,"comment":"Line drop compensation reactance (used when VC_Flag = 1)","valid_range":{"max":null,"min":0}},{"name":"K_c","data_type":"Float64","null_value":0,"comment":"Reactive current compensation gain (pu) (used when VC_Flag = 0)","valid_range":{"max":null,"min":0}},{"name":"e_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Upper/Lower limit on Voltage or Q-power deadband output `(e_min, e_max)`"},{"name":"dbd_pnts","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Voltage or Q-power error dead band thresholds `(dbd1, dbd2)`"},{"name":"Q_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Upper/Lower limit on reactive power V/Q control in REPCA `(Q_min, Q_max)`"},{"name":"T_p","data_type":"Float64","null_value":0,"comment":"Active power lag time constant in REECB (s). Used only when PF_Flag = 1","valid_range":{"max":null,"min":0}},{"name":"Q_lim_inner","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Upper/Lower limit on reactive power input in REECB `(Q_min_inner, Q_max_inner)`. Only used when V_Flag = 1"},{"name":"V_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Upper/Lower limit on reactive power PI controller in REECB `(V_min, V_max)`. Only used when V_Flag = 1"},{"name":"K_qp","data_type":"Float64","null_value":0,"comment":"Reactive power regulator proportional gain (used when V_Flag = 1)","valid_range":{"max":null,"min":0}},{"name":"K_qi","data_type":"Float64","null_value":0,"comment":"Reactive power regulator integral gain (used when V_Flag = 1)","valid_range":{"max":null,"min":0}},{"name":"Q_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Power Set-point","valid_range":{"max":null,"min":0}},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the ReactiveRenewableControllerAB model depends on the Flag","internal_default":"PowerSystems.get_reactiveRETypeAB_states(Ref_Flag, PF_Flag, V_Flag)[1]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"The states of the ReactiveRenewableControllerAB model depends on the Flag","internal_default":"PowerSystems.get_reactiveRETypeAB_states(Ref_Flag, PF_Flag, V_Flag)[2]"}],"docstring":"Parameters of Reactive Power Controller including REPCA1 and REECB1","struct_name":"ReactiveRenewableControllerAB","supertype":"ReactivePowerControl"},{"fields":[{"name":"kq","data_type":"Float64","null_value":0,"comment":"frequency droop gain","valid_range":{"max":null,"min":0}},{"name":"ωf","data_type":"Float64","null_value":0,"comment":"filter frequency cutoff","valid_range":{"max":null,"min":0}},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the ReactivePowerDroop model are:\n\tq_oc: Filtered reactive output power","internal_default":"[:q_oc]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"ReactivePowerDroop has 1 state","internal_default":1}],"docstring":"Parameters of a Reactive Power droop controller","struct_name":"ReactivePowerDroop","supertype":"ReactivePowerControl"},{"fields":[{"name":"Kp_q","data_type":"Float64","null_value":0,"comment":"Proportional Gain","valid_range":{"max":null,"min":0}},{"name":"Ki_q","data_type":"Float64","null_value":0,"comment":"Integral Gain","valid_range":{"max":null,"min":0}},{"name":"ωf","data_type":"Float64","null_value":0,"comment":"filter frequency cutoff","valid_range":{"max":null,"min":0}},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"Q_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reactive Power Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the ReactivePowerPI model are:\n\tσq_oc: Integrator state of the PI Controller,\n\tq_oc: Measured reactive power of the inverter model","internal_default":"[:σq_oc, :q_oc]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"ReactivePowerPI has two states","internal_default":2}],"docstring":"Parameters of a Proportional-Integral Reactive Power controller for a specified power reference","struct_name":"ReactivePowerPI","supertype":"ReactivePowerControl"},{"fields":[{"name":"k2","data_type":"Float64","null_value":0,"comment":"VOC voltage-amplitude control gain","valid_range":{"max":null,"min":0}},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Voltage Set-point","valid_range":{"max":null,"min":0}},{"name":"Q_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference Reactive Power Set-point","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the ReactiveVirtualOscilator model are:\n\tE_oc: voltage reference state for inner control in the d-axis","internal_default":"[:E_oc]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"ReactiveVirtualOscillator has 1 state","internal_default":1}],"docstring":"Parameters of a Reactive Virtual Oscillator controller. Model is based from the paper Model Reduction for Inverters with Current Limiting and Dispatchable Virtual Oscillator Control by O. Ajala et al.","struct_name":"ReactiveVirtualOscillator","supertype":"ReactivePowerControl"},{"fields":[{"name":"kpv","data_type":"Float64","null_value":0,"comment":"voltage controller proportional gain","valid_range":{"max":null,"min":0}},{"name":"kiv","data_type":"Float64","null_value":0,"comment":"voltage controller integral gain","valid_range":{"max":null,"min":0}},{"name":"kffv","data_type":"Float64","null_value":0,"comment":"Binary variable to enable feed-forward gain of voltage.","valid_range":{"max":null,"min":0}},{"name":"rv","data_type":"Float64","null_value":0,"comment":"virtual resistance","valid_range":{"max":null,"min":0}},{"name":"lv","data_type":"Float64","null_value":0,"comment":"virtual inductance","valid_range":{"max":null,"min":0}},{"name":"kpc","data_type":"Float64","null_value":0,"comment":"current controller proportional gain","valid_range":{"max":null,"min":0}},{"name":"kic","data_type":"Float64","null_value":0,"comment":"current controller integral gain","valid_range":{"max":null,"min":0}},{"name":"kffi","data_type":"Float64","null_value":0,"comment":"Binary variable to enable feed-forward gain of current","valid_range":{"max":null,"min":0}},{"name":"ωad","data_type":"Float64","null_value":0,"comment":"active damping filter cutoff frequency (rad/sec)","valid_range":{"max":null,"min":0}},{"name":"kad","data_type":"Float64","null_value":0,"comment":"active damping gain","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the VoltageModeControl model are:\n\tξd_ic: d-axis integrator state of the PI voltage controller,\n\tξq_ic: q-axis integrator state of the PI voltage controller,\n\tγd_ic: d-axis integrator state of the PI current controller,\n\tγq_ic: q-axis integrator state of the PI current controller,\n\tϕd_ic: d-axis low-pass filter of active damping,\n\tϕq_ic: q-axis low-pass filter of active damping","internal_default":"[:ξd_ic, :ξq_ic, :γd_ic, :γq_ic, :ϕd_ic, :ϕq_ic]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"VoltageModeControl has 6 states","internal_default":6}],"docstring":"Parameters of an inner loop current control PID using virtual impedance based on D'Arco, Suul and Fosso.\n\"A Virtual Synchronous Machine implementation for distributed control of power converters in SmartGrids.\"\nElectric Power Systems Research 122 (2015) 180–197.","struct_name":"VoltageModeControl","supertype":"InnerControl"},{"fields":[{"name":"kpc","data_type":"Float64","null_value":0,"comment":"Current controller proportional gain","valid_range":{"max":null,"min":0}},{"name":"kic","data_type":"Float64","null_value":0,"comment":"Current controller integral gain","valid_range":{"max":null,"min":0}},{"name":"kffv","data_type":"Float64","null_value":0,"comment":"Gain to enable feed-forward gain of voltage.","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the CurrentModeControl model are:\n\tγd_ic: d-axis integrator state of the PI current controller,\n\tγq_ic: q-axis integrator state of the PI current controller","internal_default":"[:γd_ic, :γq_ic]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"CurrentControl has 2 states","internal_default":2}],"docstring":"Parameters of an inner loop PI current control using based on Purba, Dhople, Jafarpour, Bullo and Johnson.\n\"Reduced-order Structure-preserving Model for Parallel-connected Three-phase Grid-tied Inverters.\"\n2017 IEEE 18th Workshop on Control and Modeling for Power Electronics (COMPEL): 1-7.","struct_name":"CurrentModeControl","supertype":"InnerControl"},{"fields":[{"name":"Q_Flag","data_type":"Int","null_value":0,"comment":"Q Flag used for I_qinj","valid_range":{"max":1,"min":0}},{"name":"PQ_Flag","data_type":"Int","null_value":0,"comment":"PQ Flag used for the Current Limit Logic","valid_range":{"max":1,"min":0}},{"name":"Vdip_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Limits for Voltage Dip Logic `(Vdip, Vup)`"},{"name":"T_rv","data_type":"Float64","null_value":0,"comment":"Voltage Filter Time Constant","valid_range":{"max":null,"min":0}},{"name":"dbd_pnts","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Voltage error deadband thresholds `(dbd1, dbd2)`"},{"name":"K_qv","data_type":"Float64","null_value":0,"comment":"Reactive current injection gain during over and undervoltage conditions","valid_range":{"max":null,"min":0}},{"name":"Iqinj_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Limits for Iqinj `(I_qh1, I_ql1)`"},{"name":"V_ref0","data_type":"Float64","null_value":0,"comment":"User defined reference. If 0, PSID initializes to initial terminal voltage","valid_range":{"max":null,"min":0}},{"name":"K_vp","data_type":"Float64","null_value":0,"comment":"Voltage regulator proportional gain (used when QFlag = 1)","valid_range":{"max":null,"min":0}},{"name":"K_vi","data_type":"Float64","null_value":0,"comment":"Voltage regulator integral gain (used when QFlag = 1)","valid_range":{"max":null,"min":0}},{"name":"T_iq","data_type":"Float64","null_value":0,"comment":"Time constant for low-pass filter for state q_V when QFlag = 0","valid_range":{"max":null,"min":0}},{"name":"I_max","data_type":"Float64","null_value":0,"comment":"Maximum limit on total converter current","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of the RECurrentControlB depends on the Flags","internal_default":"PowerSystems.get_REControlB_states(Q_Flag)"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"The states of the RECurrentControlB depends on the Flags","internal_default":"2"}],"docstring":"Parameters of the Inner Control part of the REECB model in PSS/E","struct_name":"RECurrentControlB","supertype":"InnerControl"},{"fields":[{"name":"I_max","data_type":"Float64","null_value":0,"comment":"Maximum limit on current controller input current (device base)","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"}],"docstring":"Parameters of Magnitude (Circular) Current Controller Limiter","struct_name":"MagnitudeCurrentLimiter","supertype":"InverterLimiter"},{"fields":[{"name":"Id_max","data_type":"Float64","null_value":0,"comment":"Maximum limit on d-axis current controller input current (device base)","valid_range":{"max":null,"min":0}},{"name":"Iq_max","data_type":"Float64","null_value":0,"comment":"Maximum limit on d-axis current controller input current (device base)","valid_range":{"max":null,"min":0}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"}],"docstring":"Parameters of Instantaneous (Square) Current Controller Limiter","struct_name":"InstantaneousCurrentLimiter","supertype":"InverterLimiter"},{"fields":[{"name":"I_max","data_type":"Float64","null_value":0,"comment":"Maximum limit on current controller input current (device base)","valid_range":{"max":null,"min":0}},{"name":"ϕ_I","data_type":"Float64","null_value":0,"comment":"Pre-defined angle (measured against the d-axis) for Iref once limit is hit","valid_range":{"max":1.571,"min":-1.571}},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"}],"docstring":"Parameters of Priority-Based Current Controller Limiter","struct_name":"PriorityCurrentLimiter","supertype":"InverterLimiter"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"Pf_Flag","data_type":"Int","null_value":0,"comment":"Flag for Power Factor Control","valid_range":{"max":1,"min":0}},{"name":"Freq_Flag","data_type":"Int","null_value":0,"comment":"Flag to enable/disable frequency control","valid_range":{"max":1,"min":0}},{"name":"PQ_Flag","data_type":"Int","null_value":0,"comment":"Flag used to enforce maximum current","valid_range":{"max":1,"min":0}},{"name":"Gen_Flag","data_type":"Int","null_value":0,"comment":"Flag to specify generator or storage","valid_range":{"max":1,"min":0}},{"name":"Vtrip_Flag","data_type":"Int","null_value":0,"comment":"Flag to enable/disable voltage trip logic","valid_range":{"max":1,"min":0}},{"name":"Ftrip_Flag","data_type":"Int","null_value":0,"comment":"Flag to enable/disable frequency trip logic","valid_range":{"max":1,"min":0}},{"name":"T_rv","data_type":"Float64","null_value":0,"comment":"Voltage measurement transducer time constant","valid_range":{"max":null,"min":0}},{"name":"Trf","data_type":"Float64","null_value":0,"comment":"Frequency measurement transducer time constant","valid_range":{"max":null,"min":0}},{"name":"dbd_pnts","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Voltage deadband thresholds `(dbd1, dbd2)`"},{"name":"K_qv","data_type":"Float64","null_value":0,"comment":"Proportional voltage control gain (pu)","valid_range":{"max":null,"min":0}},{"name":"Tp","data_type":"Float64","null_value":0,"comment":"Power measurement transducer time constant","valid_range":{"max":null,"min":0}},{"name":"T_iq","data_type":"Float64","null_value":0,"comment":"Time constant for low-pass filter for state q_V when QFlag = 0","valid_range":{"max":null,"min":0}},{"name":"D_dn","data_type":"Float64","null_value":0,"comment":"Reciprocal of droop for over-frequency conditions (>0) (pu)","valid_range":{"max":null,"min":0}},{"name":"D_up","data_type":"Float64","null_value":0,"comment":"Reciprocal of droop for under-frequency conditions <=0) (pu)","valid_range":{"max":null,"min":0}},{"name":"fdbd_pnts","data_type":"Tuple{Float64, Float64}","null_value":"(0.0, 0.0)","comment":"Frequency control deadband thresholds `(fdbd1, fdbd2)`"},{"name":"fe_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Frequency error limits (femin, femax)"},{"name":"P_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Power limits (Pmin, Pmax)"},{"name":"dP_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Power reference ramp rate limits (dPmin, dPmax)"},{"name":"Tpord","data_type":"Float64","null_value":0,"comment":"Power filter time constant","valid_range":{"max":null,"min":0}},{"name":"Kpg","data_type":"Float64","null_value":0,"comment":"PI controller proportional gain (pu)","valid_range":{"max":null,"min":0}},{"name":"Kig","data_type":"Float64","null_value":0,"comment":"PI controller integral gain (pu)","valid_range":{"max":null,"min":0}},{"name":"I_max","data_type":"Float64","null_value":0,"comment":"Maximum limit on total converter current (pu)","valid_range":{"max":null,"min":0}},{"name":"vl_pnts","data_type":"Vector{Tuple{Float64,Float64}}","null_value":"[(0.0, 0.0), (0.0, 0.0)]","comment":"Low voltage cutout points `[(tv10, vl0), (tv11, vl1)]`"},{"name":"vh_pnts","data_type":"Vector{Tuple{Float64,Float64}}","null_value":"[(0.0, 0.0), (0.0, 0.0)]","comment":"High voltage cutout points `[(tvh0, vh0), (tvh1, vh1)]`"},{"name":"Vrfrac","data_type":"Float64","null_value":0,"comment":"Fraction of device that recovers after voltage comes back to within vl1 < V < vh1 (0 <= Vrfrac <= 1)","valid_range":{"max":1,"min":0}},{"name":"fl","data_type":"Float64","null_value":0,"comment":"Inverter frequency break-point for low frequency cut-out (Hz)","valid_range":{"max":null,"min":0}},{"name":"fh","data_type":"Float64","null_value":0,"comment":"Inverter frequency break-point for high frequency cut-out (Hz)","valid_range":{"max":null,"min":0}},{"name":"tfl","data_type":"Float64","null_value":0,"comment":"Low frequency cut-out timer corresponding to frequency fl (s)","valid_range":{"max":null,"min":0}},{"name":"tfh","data_type":"Float64","null_value":0,"comment":"High frequency cut-out timer corresponding to frequency fh (s)","valid_range":{"max":null,"min":0}},{"name":"Tg","data_type":"Float64","null_value":0,"comment":"Current control time constant (to represent behavior of inner control loops) (> 0) (s)","valid_range":{"max":null,"min":0}},{"name":"rrpwr","data_type":"Float64","null_value":0,"comment":"Ramp rate for real power increase following a fault (pu/s)","valid_range":{"max":null,"min":0}},{"name":"Tv","data_type":"Float64","null_value":0,"comment":"Time constant on the output of the multiplier (s)","valid_range":{"max":null,"min":0}},{"name":"Vpr","data_type":"Float64","null_value":0,"comment":"Voltage below which frequency tripping is disabled (pu)","valid_range":{"max":null,"min":0}},{"name":"Iq_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Reactive current injection limits (Iqll, Iqhl)"},{"name":"V_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"User defined voltage reference. If 0, PSID initializes to initial terminal voltage","valid_range":{"max":null,"min":0}},{"name":"Pfa_ref","default":"0.0","data_type":"Float64","null_value":0,"comment":"Reference power factor","valid_range":{"max":null,"min":0}},{"name":"ω_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference frequency","valid_range":{"max":null,"min":0}},{"name":"Q_ref","default":"0.0","data_type":"Float64","null_value":0,"comment":"Reference reactive power, in pu","valid_range":{"max":null,"min":0}},{"name":"P_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference active power, in pu","valid_range":{"max":null,"min":0}},{"name":"base_power","default":"100.0","data_type":"Float64","null_value":0,"comment":"Base power"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of AggregateDistributedGenerationA depends on the Flags","internal_default":"PowerSystems.get_AggregateDistributedGenerationA_states(Freq_Flag)[1]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"The states of AggregateDistributedGenerationA depends on the Flags","internal_default":"PowerSystems.get_AggregateDistributedGenerationA_states(Freq_Flag)[2]"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of the DERA1 model in PSS/E","struct_name":"AggregateDistributedGenerationA","supertype":"DynamicInjection"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"available","data_type":"Bool","null_value":"false"},{"name":"bus","data_type":"ACBus","null_value":"ACBus(nothing)"},{"name":"active_power","data_type":"Float64","null_value":"0.0"},{"name":"reactive_power","data_type":"Float64","null_value":"0.0"},{"name":"R_th","data_type":"Float64","null_value":0,"comment":"Source Thevenin resistance","valid_range":{"max":null,"min":0}},{"name":"X_th","data_type":"Float64","null_value":0,"comment":"Source Thevenin reactance","valid_range":{"max":null,"min":0}},{"name":"internal_voltage","default":"1.0","data_type":"Float64","null_value":0,"comment":"Internal Voltage","valid_range":{"max":null,"min":0}},{"name":"internal_angle","default":"0.0","data_type":"Float64","null_value":0,"comment":"Internal Angle"},{"name":"dynamic_injector","default":"nothing","data_type":"Union{Nothing, DynamicInjection}","exclude_setter":true,"null_value":"nothing","comment":"corresponding dynamic injection device"},{"name":"services","default":"Device[]","data_type":"Vector{Service}","null_value":"Device[]","comment":"Services that this device contributes to"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"This struct acts as an infinity bus.","struct_name":"Source","supertype":"StaticInjection"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"R_th","data_type":"Float64","null_value":0,"comment":"Source Thevenin resistance","valid_range":{"max":null,"min":0}},{"name":"X_th","data_type":"Float64","null_value":0,"comment":"Source Thevenin reactance","valid_range":{"max":null,"min":0}},{"name":"internal_voltage_bias","default":"0.0","data_type":"Float64","null_value":0,"comment":"a0 term of the Fourier Series for the voltage"},{"name":"internal_voltage_frequencies","default":"[0.0]","data_type":"Vector{Float64}","null_value":[0],"comment":"Frequencies in radians/s"},{"name":"internal_voltage_coefficients","default":"[(0.0, 0.0)]","data_type":"Vector{Tuple{Float64,Float64}}","null_value":"[(0.0, 0.0)]","comment":"Coefficients for terms n > 1. First component corresponds to sin and second component to cos"},{"name":"internal_angle_bias","default":"0.0","data_type":"Float64","null_value":0,"comment":"a0 term of the Fourier Series for the angle"},{"name":"internal_angle_frequencies","default":"[0.0]","data_type":"Vector{Float64}","null_value":[0],"comment":"Frequencies in radians/s"},{"name":"internal_angle_coefficients","default":"[(0.0, 0.0)]","data_type":"Vector{Tuple{Float64,Float64}}","null_value":"[(0.0, 0.0)]","comment":"Coefficients for terms n > 1. First component corresponds to sin and second component to cos"},{"name":"base_power","default":"100.0","data_type":"Float64","null_value":0,"comment":"Base power"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"State for time, voltage and angle","internal_default":"[:Vt, :θt]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"null_value":2,"internal_default":2},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"This struct acts as an infinity bus with time varying phasor values magnitude and angle V(t) \theta(t). Time varying functions are represented using fourier series","struct_name":"PeriodicVariableSource","supertype":"DynamicInjection"},{"fields":[{"name":"name","data_type":"String","exclude_setter":true,"null_value":"init"},{"name":"Qref_Flag","data_type":"Int","null_value":1,"comment":"Reactive Power Control Mode. 1 VoltVar Control, 2 Constant Q Control, 3 Constant PF Control","valid_range":{"max":3,"min":1}},{"name":"PQ_Flag","data_type":"Int","null_value":0,"comment":"Active and reactive power priority mode. 0 for Q priority, 1 for P priority","valid_range":{"max":1,"min":0}},{"name":"Gen_Flag","data_type":"Int","null_value":0,"comment":"Define generator or storage system. 0 unit is a storage device, 1 unit is a generator","valid_range":{"max":1,"min":0}},{"name":"PerOp_Flag","data_type":"Int","null_value":0,"comment":"Defines operation of permisible region in VRT characteristic. 0 for cease, 1 for continuous operation","valid_range":{"max":1,"min":0}},{"name":"Recon_Flag","data_type":"Int","null_value":0,"comment":"Defines if DER can reconnect after voltage ride-through disconnection","valid_range":{"max":1,"min":0}},{"name":"Trv","data_type":"Float64","null_value":0,"comment":"Voltage measurement transducer's time constant, in s","valid_range":{"max":null,"min":0}},{"name":"VV_pnts","data_type":"NamedTuple{(:V1, :V2, :V3, :V4), Tuple{Float64, Float64, Float64, Float64}}","null_value":"(V1=0.0, V2=0.0, V3=0.0, V4=0.0)","comment":"Y-axis Volt-var curve points (V1,V2,V3,V4)"},{"name":"Q_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Reactive power limits in pu (Q_min, Q_max)"},{"name":"Tp","data_type":"Float64","null_value":0,"comment":"Power measurement transducer's time constant, in s","valid_range":{"max":null,"min":0}},{"name":"e_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Error limit in PI controller for q control (e_min, e_max)"},{"name":"Kpq","data_type":"Float64","null_value":0,"comment":"PI controller proportional gain for q control","valid_range":{"max":null,"min":0}},{"name":"Kiq","data_type":"Float64","null_value":0,"comment":"PI controller integral gain for q control","valid_range":{"max":null,"min":0}},{"name":"Iqr_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Limit on rate of change for reactive current (pu/s) (Iqr_min, Iqr_max)"},{"name":"I_max","data_type":"Float64","null_value":0,"comment":"Max. inverter's current","valid_range":{"max":null,"min":0}},{"name":"Tg","data_type":"Float64","null_value":0,"comment":"Current control's time constant, in s","valid_range":{"max":null,"min":0}},{"name":"kWh_Cap","data_type":"Float64","null_value":0,"comment":"BESS capacity in kWh","valid_range":{"max":null,"min":0}},{"name":"SOC_ini","data_type":"Float64","null_value":0,"comment":"Initial state of charge (SOC) in pu","valid_range":{"max":1,"min":0}},{"name":"SOC_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Battery's SOC limits (SOC_min, SOC_max)"},{"name":"Trf","data_type":"Float64","null_value":0,"comment":"Time constant to estimate system frequency, in s","valid_range":{"max":null,"min":0}},{"name":"fdbd_pnts","data_type":"NamedTuple{(:fdbd1, :fdbd2), Tuple{Float64, Float64}}","null_value":"(fdbd1=0.0, fdbd2=0.0)","comment":"Frequency error dead band thresholds `(fdbd1, fdbd2)`"},{"name":"D_dn","data_type":"Float64","null_value":0,"comment":"reciprocal of droop for over-frequency conditions, in pu","valid_range":{"max":null,"min":0}},{"name":"D_up","data_type":"Float64","null_value":0,"comment":"reciprocal of droop for under-frequency conditions, in pu","valid_range":{"max":null,"min":0}},{"name":"fe_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Frequency error limits in pu (fe_min, fe_max)"},{"name":"Kpp","data_type":"Float64","null_value":0,"comment":"PI controller proportional gain for p control","valid_range":{"max":null,"min":0}},{"name":"Kip","data_type":"Float64","null_value":0,"comment":"PI controller integral gain for p control","valid_range":{"max":null,"min":0}},{"name":"P_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Active power limits in pu (P_min, P_max)"},{"name":"dP_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Ramp rate limits for active power in pu/s (dP_min, dP_max)"},{"name":"T_pord","data_type":"Float64","null_value":0,"comment":"Power filter time constant in s","valid_range":{"max":null,"min":0}},{"name":"rrpwr","data_type":"Float64","null_value":0,"comment":"Ramp rate for real power increase following a fault, in pu/s","valid_range":{"max":null,"min":0}},{"name":"VRT_pnts","data_type":"NamedTuple{(:vrt1, :vrt2, :vrt3, :vrt4, :vrt5), Tuple{Float64, Float64, Float64, Float64, Float64}}","null_value":"(vrt1=0.0, vrt2=0.0, vrt3=0.0, vrt4=0.0, vrt5=0.0)","comment":"Voltage ride through v points (vrt1,vrt2,vrt3,vrt4,vrt5)"},{"name":"TVRT_pnts","data_type":"NamedTuple{(:tvrt1, :tvrt2, :tvrt3), Tuple{Float64, Float64, Float64}}","null_value":"(tvrt1=0.0, tvrt2=0.0, tvrt3=0.0)","comment":"Voltage ride through time points (tvrt1,tvrt2,tvrt3)"},{"name":"tV_delay","data_type":"Float64","null_value":0,"comment":"Time delay for reconnection after voltage ride-through disconnection","valid_range":{"max":null,"min":0}},{"name":"VES_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Min and max voltage for entering service (VES_min,VES_max)"},{"name":"FRT_pnts","data_type":"NamedTuple{(:frt1, :frt2, :frt3, :frt4), Tuple{Float64, Float64, Float64, Float64}}","null_value":"(frt1=0.0, frt2=0.0, frt3=0.0, frt4=0.0)","comment":"Frequency ride through v points (frt1,frt2,frt3,frt4)"},{"name":"TFRT_pnts","data_type":"NamedTuple{(:tfrt1, :tfrt2), Tuple{Float64, Float64}}","null_value":"(tfrt1=0.0, tfrt2=0.0)","comment":"Frequency ride through time points (tfrt1,tfrt2)"},{"name":"tF_delay","data_type":"Float64","null_value":0,"comment":"Time delay for reconnection after frequency ride-through disconnection","valid_range":{"max":null,"min":0}},{"name":"FES_lim","data_type":"MinMax","null_value":"(min=0.0, max=0.0)","comment":"Min and max frequency for entering service (FES_min,FES_max)"},{"name":"Pfa_ref","default":"0.0","data_type":"Float64","null_value":0,"comment":"Reference power factor","valid_range":{"max":null,"min":0}},{"name":"Q_ref","default":"0.0","data_type":"Float64","null_value":0,"comment":"Reference reactive power, in pu","valid_range":{"max":null,"min":0}},{"name":"P_ref","default":"1.0","data_type":"Float64","null_value":0,"comment":"Reference active power, in pu","valid_range":{"max":null,"min":0}},{"name":"base_power","default":"100.0","data_type":"Float64","null_value":0,"comment":"Base power"},{"name":"states","data_type":"Vector{Symbol}","exclude_setter":true,"comment":"The states of GenericDER depend on the Flags","internal_default":"PowerSystems.get_GenericDER_states(Qref_Flag)[1]"},{"name":"n_states","data_type":"Int","exclude_setter":true,"comment":"The states of GenericDER depend on the Flags","internal_default":"PowerSystems.get_GenericDER_states(Qref_Flag)[2]"},{"name":"ext","default":"Dict{String, Any}()","data_type":"Dict{String, Any}","null_value":"Dict{String, Any}()"},{"name":"internal","data_type":"InfrastructureSystemsInternal","exclude_setter":true,"comment":"power system internal reference, do not modify","internal_default":"InfrastructureSystemsInternal()"}],"docstring":"Parameters of a Generic Distributed Energy Resource Model. Based on https://scholarspace.manoa.hawaii.edu/bitstream/10125/70994/0304.pdf","struct_name":"GenericDER","supertype":"DynamicInjection"},{"fields":[{"name":"device"},{"name":"droop","data_type":"Float64","valid_range":{"max":null,"min":0}},{"name":"participation_factor","data_type":"UpDown"},{"name":"reserve_limit_dn","data_type":"Float64","valid_range":{"max":null,"min":0}},{"name":"reserve_limit_up","data_type":"Float64","valid_range":{"max":null,"min":0}},{"name":"inertia","data_type":"Float64","valid_range":{"max":null,"min":0}},{"name":"cost","data_type":"Float64","valid_range":{"max":null,"min":0}},{"name":"time_series_container","data_type":"InfrastructureSystems.TimeSeriesContainer"},{"name":"internal","data_type":"InfrastructureSystems.InfrastructureSystemsInternal"}],"struct_name":"RegulationDevice"}]} \ No newline at end of file diff --git a/dev/tutorials/tutorial_240bus/index.html b/dev/tutorials/tutorial_240bus/index.html index 0c4d8ca7d..854f6ea2d 100644 --- a/dev/tutorials/tutorial_240bus/index.html +++ b/dev/tutorials/tutorial_240bus/index.html @@ -4,14 +4,10 @@ # Transform the system's load┌ Info: Building new system WECC 240 Bus from raw data └ sys_descriptor.raw_data = "" -┌ Warning: System is saved in the data format version 2.0.0 will be automatically upgraded to 3.0.0 upon saving -└ @ PowerSystems ~/.julia/packages/PowerSystems/xh3fM/src/data_format_conversions.jl:82 ┌ Warning: The System was deserialized with checks disabled, and so was not validated. -└ @ PowerSystems ~/.julia/packages/PowerSystems/xh3fM/src/base.jl:1464 -┌ Warning: System is saved in the data format version 2.0.0 will be automatically upgraded to 3.0.0 upon saving -└ @ PowerSystems ~/.julia/packages/PowerSystems/xh3fM/src/data_format_conversions.jl:110 -[ Info: Serialized System to /home/runner/.julia/packages/PowerSystemCaseBuilder/vlTjU/data/serialized_system/NoArgs/WECC 240 Bus.json -[ Info: Serialized System metadata to /home/runner/.julia/packages/PowerSystemCaseBuilder/vlTjU/data/serialized_system/NoArgs/WECC 240 Bus_metadata.json +└ @ PowerSystems ~/.julia/packages/PowerSystems/OQdiE/src/base.jl:1819 +[ Info: Serialized System to /home/runner/.julia/packages/PowerSystemCaseBuilder/9AsiG/data/serialized_system/e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855/WECC 240 Bus.json +[ Info: Serialized System metadata to /home/runner/.julia/packages/PowerSystemCaseBuilder/9AsiG/data/serialized_system/e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855/WECC 240 Bus_metadata.json System ┌───────────────────┬─────────────┐ │ Property │ Value │ @@ -25,33 +21,34 @@ └───────────────────┴─────────────┘ Static Components -┌─────────────────┬───────┬────────────────────────┬───────────────┐ -│ Type │ Count │ Has Static Time Series │ Has Forecasts │ -├─────────────────┼───────┼────────────────────────┼───────────────┤ -│ ACBus │ 243 │ false │ false │ -│ Arc │ 351 │ false │ false │ -│ Area │ 4 │ false │ false │ -│ FixedAdmittance │ 7 │ false │ false │ -│ Line │ 329 │ false │ false │ -│ LoadZone │ 14 │ false │ false │ -│ StandardLoad │ 139 │ false │ false │ -│ TapTransformer │ 2 │ false │ false │ -│ ThermalStandard │ 146 │ false │ false │ -│ Transformer2W │ 120 │ false │ false │ -└─────────────────┴───────┴────────────────────────┴───────────────┘ +┌─────────────────┬───────┐ +│ Type │ Count │ +├─────────────────┼───────┤ +│ ACBus │ 243 │ +│ Arc │ 351 │ +│ Area │ 4 │ +│ FixedAdmittance │ 7 │ +│ Line │ 329 │ +│ LoadZone │ 14 │ +│ StandardLoad │ 139 │ +│ TapTransformer │ 2 │ +│ ThermalStandard │ 146 │ +│ Transformer2W │ 120 │ +└─────────────────┴───────┘ Dynamic Components -┌──────────────────┬───────┐ -│ Type │ Count │ -├──────────────────┼───────┤ -│ DynamicGenerator │ 36 │ -│ DynamicGenerator │ 22 │ -│ DynamicGenerator │ 6 │ -│ DynamicGenerator │ 3 │ -│ DynamicGenerator │ 41 │ -│ DynamicGenerator │ 1 │ -│ DynamicInverter │ 37 │ -└──────────────────┴───────┘
      julia> for l in get_components(PSY.StandardLoad, sys) +┌─────────────────────────────────────────────────────────────────────────────── +│ Type ⋯ +├─────────────────────────────────────────────────────────────────────────────── +│ DynamicGenerator{RoundRotorQuadratic, SingleMass, SEXS, GasTG, IEEEST} ⋯ +│ DynamicGenerator{RoundRotorQuadratic, SingleMass, SEXS, GasTG, PSSFixed} ⋯ +│ DynamicGenerator{RoundRotorQuadratic, SingleMass, SEXS, HydroTurbineGov, IEE ⋯ +│ DynamicGenerator{RoundRotorQuadratic, SingleMass, SEXS, HydroTurbineGov, PSS ⋯ +│ DynamicGenerator{RoundRotorQuadratic, SingleMass, SEXS, SteamTurbineGov1, IE ⋯ +│ DynamicGenerator{RoundRotorQuadratic, SingleMass, SEXS, SteamTurbineGov1, PS ⋯ +│ DynamicInverter{RenewableEnergyConverterTypeA, OuterControl{ActiveRenewableC ⋯ +└─────────────────────────────────────────────────────────────────────────────── + 2 columns omitted
      julia> for l in get_components(PSY.StandardLoad, sys) transform_load_to_constant_impedance(l) end┌ Warning: Load data is transformed under the assumption of a 1.0 p.u. Voltage Magnitude └ @ PowerSimulationsDynamics ~/work/PowerSimulationsDynamics.jl/PowerSimulationsDynamics.jl/src/utils/psy_utils.jl:81 @@ -341,14 +338,14 @@ [ Info: Pre-Initializing Simulation States [ Info: Unit System changed to UnitSystem.SYSTEM_BASE = 0 ┌ Warning: Unit generator-3631-NB set at the limit -0.14000000000000004. Q_max = 0.20000000000000004 Q_min = -0.14000000000000004 -└ @ PowerFlows ~/.julia/packages/PowerFlows/6nw6s/src/post_processing.jl:352 +└ @ PowerFlows ~/.julia/packages/PowerFlows/zesCE/src/post_processing.jl:352 ┌ Warning: Unit generator-6132-G set at the limit -1.47. Q_max = 1.47 Q_min = -1.47 -└ @ PowerFlows ~/.julia/packages/PowerFlows/6nw6s/src/post_processing.jl:352 +└ @ PowerFlows ~/.julia/packages/PowerFlows/zesCE/src/post_processing.jl:352 ┌ Warning: Unit generator-6433-E set at the limit 0.59. Q_max = 0.59 Q_min = -0.59 -└ @ PowerFlows ~/.julia/packages/PowerFlows/6nw6s/src/post_processing.jl:352 +└ @ PowerFlows ~/.julia/packages/PowerFlows/zesCE/src/post_processing.jl:352 [ Info: PowerFlow solve converged, the results have been stored in the system [ Info: Unit System changed to UnitSystem.DEVICE_BASE = 1 -[ Info: Residual from initial guess: max = 9.82774084334892e-10 at 1268, total = 2.3309883363794544e-8 +[ Info: Residual from initial guess: max = 9.82774084334892e-10 at 1268, total = 2.3309814665287872e-8 Iter f(x) inf-norm Step 2-norm ------ -------------- -------------- [ Info: Initialization non-linear solve succeeded with a tolerance of 1.0e-9 using solver trust_region. Saving solution. @@ -358,25 +355,25 @@ │ ─────────────────────────────────────────────────────────────────────────────── │ Time Allocations │ ─────────────── ─────────────── -│ Total measured: 27.3s 4.85GiB +│ Total measured: 25.9s 4.84GiB │ │ Section ncalls time %tot alloc %tot │ ─────────────────────────────────────────────────────────────────────────────── -│ Build Simulation 1 27.3s 100.0% 4.85GiB 100.0% -│ Build Simulation Inputs 1 2.62s 9.6% 141MiB 2.8% -│ Wrap Branches 1 11.9μs 0.0% 208B 0.0% -│ Wrap Dynamic Injectors 1 1.69s 6.2% 95.4MiB 1.9% -│ Calculate MM, DAE_vector, Tota... 1 234ms 0.9% 18.6MiB 0.4% -│ Wrap Static Injectors 1 240ms 0.9% 5.93MiB 0.1% -│ Pre-initialization 1 5.50s 20.2% 311MiB 6.3% -│ Power Flow solution 1 1.12s 4.1% 44.0MiB 0.9% -│ Initialize Static Injectors 1 1.03μs 0.0% 0.00B 0.0% -│ Initialize Dynamic Injectors 1 4.37s 16.1% 267MiB 5.4% -│ Calculate Jacobian 1 14.0s 51.3% 4.15GiB 85.6% -│ Make Model Function 1 24.6μs 0.0% 32.0KiB 0.0% -│ Initial Condition NLsolve refine... 1 4.69s 17.2% 249MiB 5.0% -│ Build Perturbations 1 130μs 0.0% 75.1KiB 0.0% -│ Make DiffEq Problem 1 463ms 1.7% 11.2MiB 0.2% +│ Build Simulation 1 25.9s 100.0% 4.84GiB 100.0% +│ Build Simulation Inputs 1 2.54s 9.8% 147MiB 3.0% +│ Wrap Branches 1 9.67μs 0.0% 208B 0.0% +│ Wrap Dynamic Injectors 1 1.54s 5.9% 95.3MiB 1.9% +│ Calculate MM, DAE_vector, Tota... 1 240ms 0.9% 18.6MiB 0.4% +│ Wrap Static Injectors 1 230ms 0.9% 5.91MiB 0.1% +│ Pre-initialization 1 5.19s 20.1% 292MiB 5.9% +│ Power Flow solution 1 1.06s 4.1% 44.0MiB 0.9% +│ Initialize Static Injectors 1 982ns 0.0% 0.00B 0.0% +│ Initialize Dynamic Injectors 1 4.12s 15.9% 248MiB 5.0% +│ Calculate Jacobian 1 13.3s 51.3% 4.16GiB 85.9% +│ Make Model Function 1 23.8μs 0.0% 32.0KiB 0.0% +│ Initial Condition NLsolve refine... 1 4.42s 17.1% 249MiB 5.0% +│ Build Perturbations 1 135μs 0.0% 75.1KiB 0.0% +│ Make DiffEq Problem 1 456ms 1.8% 11.3MiB 0.2% │ ─────────────────────────────────────────────────────────────────────────────── └ Simulation Summary @@ -391,16 +388,16 @@ │ Number of States │ 2164 │ │ Number of Perturbations │ 1 │ └─────────────────────────┴────────────────┘

      Run the simulation using Sundials

      We will now run the simulation using Sundials.jl solver IDA() by specifying the maximum dt we want for the simulation. In our experience with this solver, solution times are faster when supplying information about the maximum time step than the tolerances as we can see in the example

      julia> execute!(sim_ida, IDA(), dtmax = 0.01)SIMULATION_FINALIZED::BUILD_STATUS = 6

      Read the results and plot a system variable

      After the simulation is completed, we can extract the results and make plots as desired. In this case, we will plot the voltage magnitude at the bus at which the line was connected.

      julia> res_ida = read_results(sim_ida)Simulation Results Summary
      -┌────────────────────────────┬─────────────┐
      -│ Property                   │ Value       │
      -├────────────────────────────┼─────────────┤
      -│ System Base Power [MVA]    │ 100.0       │
      -│ System Base Frequency [Hz] │ 60.0        │
      -│ Time Span                  │ (0.0, 20.0) │
      -│ Total Time Steps           │ 2015        │
      -│ Number of States           │ 2164        │
      -│ Total solve time           │ 16.51434986 │
      -└────────────────────────────┴─────────────┘
      julia> v1101_ida = get_voltage_magnitude_series(res_ida, 1101);
      julia> plot(v1101_ida);

      plot

      Run the simulation using Rodas4()

      In this case, we will use a MassMatrixModel formulation, for more details about the formulation checkout the Models Section in PowerSimulationsDynamics.jl documentation

      julia> sim_rodas = Simulation(
      +┌────────────────────────────┬──────────────┐
      +│ Property                   │ Value        │
      +├────────────────────────────┼──────────────┤
      +│ System Base Power [MVA]    │ 100.0        │
      +│ System Base Frequency [Hz] │ 60.0         │
      +│ Time Span                  │ (0.0, 20.0)  │
      +│ Total Time Steps           │ 2015         │
      +│ Number of States           │ 2164         │
      +│ Total solve time           │ 16.066686232 │
      +└────────────────────────────┴──────────────┘
      julia> v1101_ida = get_voltage_magnitude_series(res_ida, 1101);
      julia> plot(v1101_ida);

      plot

      Run the simulation using Rodas4()

      In this case, we will use a MassMatrixModel formulation, for more details about the formulation checkout the Models Section in PowerSimulationsDynamics.jl documentation

      julia> sim_rodas = Simulation(
                  MassMatrixModel,
                  sys, #system
                  pwd(),
      @@ -411,14 +408,14 @@
       [ Info: Pre-Initializing Simulation States
       [ Info: Unit System changed to UnitSystem.SYSTEM_BASE = 0
       ┌ Warning: Unit generator-3631-NB set at the limit -0.14000000000000004. Q_max = 0.20000000000000004 Q_min = -0.14000000000000004
      -└ @ PowerFlows ~/.julia/packages/PowerFlows/6nw6s/src/post_processing.jl:352
      +└ @ PowerFlows ~/.julia/packages/PowerFlows/zesCE/src/post_processing.jl:352
       ┌ Warning: Unit generator-6132-G set at the limit -1.47. Q_max = 1.47 Q_min = -1.47
      -└ @ PowerFlows ~/.julia/packages/PowerFlows/6nw6s/src/post_processing.jl:352
      +└ @ PowerFlows ~/.julia/packages/PowerFlows/zesCE/src/post_processing.jl:352
       ┌ Warning: Unit generator-6433-E set at the limit 0.59. Q_max = 0.59 Q_min = -0.59
      -└ @ PowerFlows ~/.julia/packages/PowerFlows/6nw6s/src/post_processing.jl:352
      +└ @ PowerFlows ~/.julia/packages/PowerFlows/zesCE/src/post_processing.jl:352
       [ Info: PowerFlow solve converged, the results have been stored in the system
       [ Info: Unit System changed to UnitSystem.DEVICE_BASE = 1
      -[ Info: Residual from initial guess: max = 9.82774084334892e-10 at 1268, total = 2.3309883363794544e-8
      +[ Info: Residual from initial guess: max = 9.82774084334892e-10 at 1268, total = 2.3309814665287872e-8
       Iter     f(x) inf-norm    Step 2-norm 
       ------   --------------   --------------
       [ Info: Initialization non-linear solve succeeded with a tolerance of 1.0e-9 using solver trust_region. Saving solution.
      @@ -428,25 +425,25 @@
       │  ───────────────────────────────────────────────────────────────────────────────
       │                                                      Time          Allocations  
       │                                                ───────────────   ───────────────
      -│                 Total measured:                     8.89s             803MiB    
      +│                 Total measured:                     8.68s             800MiB    
       │ 
       │  Section                               ncalls     time    %tot     alloc    %tot
       │  ───────────────────────────────────────────────────────────────────────────────
      -│  Build Simulation                           1    8.89s  100.0%    803MiB  100.0%
      -│    Build Simulation Inputs                  1   36.0ms    0.4%   7.33MiB    0.9%
      -│      Wrap Branches                          1   4.90μs    0.0%      208B    0.0%
      -│      Wrap Dynamic Injectors                 1   33.5ms    0.4%   2.47MiB    0.3%
      -│      Calculate MM, DAE_vector, Tota...      1    619μs    0.0%   1.90MiB    0.2%
      -│      Wrap Static Injectors                  1    448μs    0.0%    290KiB    0.0%
      -│    Pre-initialization                       1   16.0ms    0.2%   9.64MiB    1.2%
      -│      Power Flow solution                    1   10.9ms    0.1%   5.72MiB    0.7%
      -│      Initialize Static Injectors            1    591ns    0.0%     0.00B    0.0%
      -│      Initialize Dynamic Injectors           1   4.68ms    0.1%   3.76MiB    0.5%
      -│    Calculate Jacobian                       1    7.16s   80.5%    599MiB   74.6%
      -│    Make Model Function                      1   6.63ms    0.1%    154KiB    0.0%
      -│    Initial Condition NLsolve refine...      1    1.27s   14.3%    167MiB   20.9%
      -│    Build Perturbations                      1   17.4ms    0.2%    626KiB    0.1%
      -│    Make DiffEq Problem                      1    387ms    4.4%   18.2MiB    2.3%
      +│  Build Simulation                           1    8.68s  100.0%    800MiB  100.0%
      +│    Build Simulation Inputs                  1   6.59ms    0.1%   7.33MiB    0.9%
      +│      Wrap Branches                          1   5.75μs    0.0%      208B    0.0%
      +│      Wrap Dynamic Injectors                 1   3.75ms    0.0%   2.47MiB    0.3%
      +│      Calculate MM, DAE_vector, Tota...      1    580μs    0.0%   1.90MiB    0.2%
      +│      Wrap Static Injectors                  1    425μs    0.0%    290KiB    0.0%
      +│    Pre-initialization                       1   16.0ms    0.2%   9.63MiB    1.2%
      +│      Power Flow solution                    1   10.7ms    0.1%   5.72MiB    0.7%
      +│      Initialize Static Injectors            1    642ns    0.0%     0.00B    0.0%
      +│      Initialize Dynamic Injectors           1   4.76ms    0.1%   3.76MiB    0.5%
      +│    Calculate Jacobian                       1    6.99s   80.5%    597MiB   74.6%
      +│    Make Model Function                      1   6.11ms    0.1%    154KiB    0.0%
      +│    Initial Condition NLsolve refine...      1    1.27s   14.7%    167MiB   20.9%
      +│    Build Perturbations                      1   16.7ms    0.2%    626KiB    0.1%
      +│    Make DiffEq Problem                      1    375ms    4.3%   18.1MiB    2.3%
       │  ───────────────────────────────────────────────────────────────────────────────
       └ 
       Simulation Summary
      @@ -476,5 +473,5 @@
       │ Time Span                  │ (0.0, 20.0)  │
       │ Total Time Steps           │ 2002         │
       │ Number of States           │ 2164         │
      -│ Total solve time           │ 32.708131248 │
      -└────────────────────────────┴──────────────┘

      Compare the results

      After the simulation is completed, we can extract the results and make plots as desired. In this case, we will plot the voltage magnitude at the bus at which the line was connected. For both of the solution techniques.

      julia> v1101 = get_voltage_magnitude_series(res_rodas, 1101);
      julia> plot(v1101, label = "RODAS4");
      julia> plot!(v1101_ida, label = "IDA");

      plot

      +│ Total solve time │ 31.736760058 │ +└────────────────────────────┴──────────────┘

      Compare the results

      After the simulation is completed, we can extract the results and make plots as desired. In this case, we will plot the voltage magnitude at the bus at which the line was connected. For both of the solution techniques.

      julia> v1101 = get_voltage_magnitude_series(res_rodas, 1101);
      julia> plot(v1101, label = "RODAS4");
      julia> plot!(v1101_ida, label = "IDA");

      plot

      diff --git a/dev/tutorials/tutorial_activeload/index.html b/dev/tutorials/tutorial_activeload/index.html index 558f33937..ece3da278 100644 --- a/dev/tutorials/tutorial_activeload/index.html +++ b/dev/tutorials/tutorial_activeload/index.html @@ -1,6 +1,6 @@ Active Load Model · PowerSimulationsDynamics.jl

      Tutorial Active Constant Power Load model

      Originally Contributed by: Rodrigo Henriquez-Auba

      Introduction

      This tutorial will introduce you to the functionality of PowerSimulationsDynamics and PowerSystems to explore active load components and a small-signal analysis.

      This tutorial presents a simulation of a two-bus system with a GFM inverter at bus 1, and a load on bus 2. We will change the model from a constant power load model, to a constant impedance model and then to a 12-state active constant power load model.

      Dependencies

      julia> using PowerSimulationsDynamics;
      julia> PSID = PowerSimulationsDynamicsPowerSimulationsDynamics
      julia> using PowerSystemCaseBuilder
      julia> using PowerSystems
      julia> const PSY = PowerSystems;
      Note

      PowerSystemCaseBuilder.jl is a helper library that makes it easier to reproduce examples in the documentation and tutorials. Normally you would pass your local files to create the system data instead of calling the function build_system. For more details visit PowerSystemCaseBuilder Documentation

      PowerSystems (abbreviated with PSY) is used to properly define the data structure and establish an equilibrium point initial condition with a power flow routine using PowerFlows.

      Load the system

      We load the system using PowerSystemCaseBuilder.jl. This system has an inverter located at bus 1.

      julia> sys = build_system(PSIDSystems, "2 Bus Load Tutorial Droop")┌ Info: Building new system 2 Bus Load Tutorial Droop from raw data
      -└   sys_descriptor.raw_data = "/home/runner/.julia/artifacts/e72e0ad2722dc7be918ec2879d80adedb4d65576/PowerSystemsTestData-2.1/psid_tests/data_examples/Omib_Load.raw"
      +└   sys_descriptor.raw_data = "/home/runner/.julia/artifacts/906591a156d0f786940f105e4f6aeceffefa7a2e/PowerSystemsTestData-3.0/psid_tests/data_examples/Omib_Load.raw"
       [ Info: The PSS(R)E parser currently supports buses, loads, shunts, generators, branches, transformers, and dc lines
       [ Info: The PSS(R)E parser currently supports buses, loads, shunts, generators, branches, transformers, and dc lines
       [ Info: Parsing PSS(R)E Bus data into a PowerModels Dict...
      @@ -11,9 +11,9 @@
       [ Info: Parsing PSS(R)E Transformer data into a PowerModels Dict...
       [ Info: Parsing PSS(R)E Two-Terminal and VSC DC line data into a PowerModels Dict...
       ┌ Warning: This PSS(R)E parser currently doesn't support Storage data parsing...
      -└ @ PowerSystems ~/.julia/packages/PowerSystems/xh3fM/src/parsers/pm_io/psse.jl:985
      +└ @ PowerSystems ~/.julia/packages/PowerSystems/OQdiE/src/parsers/pm_io/psse.jl:998
       ┌ Warning: This PSS(R)E parser currently doesn't support Switch data parsing...
      -└ @ PowerSystems ~/.julia/packages/PowerSystems/xh3fM/src/parsers/pm_io/psse.jl:991
      +└ @ PowerSystems ~/.julia/packages/PowerSystems/OQdiE/src/parsers/pm_io/psse.jl:1004
       [ Info: angmin and angmax values are 0, widening these values on branch 1 to +/- 60.0 deg.
       ┌ Info: Constructing System from Power Models
       │   data["name"] = "omib_load"
      @@ -23,11 +23,11 @@
       [ Info: Reading LoadZones data in PowerModels dict to populate System ...
       [ Info: Reading generator data
       [ Info: Reading branch data
      -[ Info: Reading branch data
      +[ Info: Reading shunt data
       [ Info: Reading DC Line data
       [ Info: Reading storage data
      -[ Info: Serialized System to /home/runner/.julia/packages/PowerSystemCaseBuilder/vlTjU/data/serialized_system/NoArgs/2 Bus Load Tutorial Droop.json
      -[ Info: Serialized System metadata to /home/runner/.julia/packages/PowerSystemCaseBuilder/vlTjU/data/serialized_system/NoArgs/2 Bus Load Tutorial Droop_metadata.json
      +[ Info: Serialized System to /home/runner/.julia/packages/PowerSystemCaseBuilder/9AsiG/data/serialized_system/e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855/2 Bus Load Tutorial Droop.json
      +[ Info: Serialized System metadata to /home/runner/.julia/packages/PowerSystemCaseBuilder/9AsiG/data/serialized_system/e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855/2 Bus Load Tutorial Droop_metadata.json
       System
       ┌───────────────────┬─────────────┐
       │ Property          │ Value       │
      @@ -41,24 +41,25 @@
       └───────────────────┴─────────────┘
       
       Static Components
      -┌─────────────────┬───────┬────────────────────────┬───────────────┐
      -│ Type            │ Count │ Has Static Time Series │ Has Forecasts │
      -├─────────────────┼───────┼────────────────────────┼───────────────┤
      -│ ACBus           │ 2     │ false                  │ false         │
      -│ Arc             │ 1     │ false                  │ false         │
      -│ Area            │ 1     │ false                  │ false         │
      -│ ExponentialLoad │ 1     │ false                  │ false         │
      -│ Line            │ 1     │ false                  │ false         │
      -│ LoadZone        │ 1     │ false                  │ false         │
      -│ ThermalStandard │ 1     │ false                  │ false         │
      -└─────────────────┴───────┴────────────────────────┴───────────────┘
      -
      -Dynamic Components
       ┌─────────────────┬───────┐
       │ Type            │ Count │
       ├─────────────────┼───────┤
      -│ DynamicInverter │ 1     │
      -└─────────────────┴───────┘
      julia> first(get_components(DynamicInverter, sys))generator-101-1 (DynamicInverter{AverageConverter, OuterControl{ActivePowerDroop, ReactivePowerDroop}, VoltageModeControl, FixedDCSource, FixedFrequency, LCLFilter, Nothing}):
      +│ ACBus           │ 2     │
      +│ Arc             │ 1     │
      +│ Area            │ 1     │
      +│ ExponentialLoad │ 1     │
      +│ Line            │ 1     │
      +│ LoadZone        │ 1     │
      +│ ThermalStandard │ 1     │
      +└─────────────────┴───────┘
      +
      +Dynamic Components
      +┌───────────────────────────────────────────────────────────────────────────────
      +│ Type                                                                         ⋯
      +├───────────────────────────────────────────────────────────────────────────────
      +│ DynamicInverter{AverageConverter, OuterControl{ActivePowerDroop, ReactivePow ⋯
      +└───────────────────────────────────────────────────────────────────────────────
      +                                                               2 columns omitted
      julia> first(get_components(DynamicInverter, sys))DynamicInverter: generator-101-1:
          name: generator-101-1
          ω_ref: 1.0
          converter: AverageConverter
      @@ -74,24 +75,27 @@
          ext: Dict{String, Any}()
          InfrastructureSystems.SystemUnitsSettings:
             base_value: 100.0
      -      unit_system: UnitSystem.SYSTEM_BASE = 0

      The load is an exponential load modeled as a constant power load since the coefficients are set to zero.

      julia> first(get_components(PSY.ExponentialLoad, sys))load1021 (PowerSystems.ExponentialLoad):
      +      unit_system: UnitSystem.SYSTEM_BASE = 0
      +   has_supplemental_attributes: false
      +   has_time_series: false

      The load is an exponential load modeled as a constant power load since the coefficients are set to zero.

      julia> first(get_components(PSY.ExponentialLoad, sys))ExponentialLoad: load1021:
          name: load1021
          available: true
      -   bus: BUS 2 (ACBus)
      +   bus: ACBus: BUS 2
          active_power: 0.1
          reactive_power: 0.032799999999999996
      -   active_power_coefficient: 0.0
      -   reactive_power_coefficient: 0.0
      +   α: 0.0
      +   β: 0.0
          base_power: 100.0
          max_active_power: 0.1
          max_reactive_power: 0.032799999999999996
          services: 0-element Vector{Service}
          dynamic_injector: nothing
          ext: Dict{String, Any}()
      -   time_series_container:
          InfrastructureSystems.SystemUnitsSettings:
             base_value: 100.0
      -      unit_system: UnitSystem.SYSTEM_BASE = 0

      Run a small-signal analysis

      We set up the Simulation. Since the droop model does not have a frequency state, we use a constant frequency reference frame for the network.

      julia> sim = Simulation(ResidualModel,
      +      unit_system: UnitSystem.SYSTEM_BASE = 0
      +   has_supplemental_attributes: false
      +   has_time_series: false

      Run a small-signal analysis

      We set up the Simulation. Since the droop model does not have a frequency state, we use a constant frequency reference frame for the network.

      julia> sim = Simulation(ResidualModel,
                              sys,
                              mktempdir(),
                              (0.0, 1.0),
      @@ -126,7 +130,7 @@
         13 │ generator-101-1 γq_ic      0.664033      -11.3893   0.0         100.0        1.81266
         14 │ generator-101-1 θ_oc       1.0           -0.0       0.0         NaN          0.0
         15 │ generator-101-1 ir_filter  0.94952       17272.3    0.0         -100.0       2748.98

      In this inverter model, the filter is modeled using differential equations, and as described in the literature, interfacing a RL filter against an algebraic constant power load usually results in unstable behavior as observed with the positive real part eigenvalue.

      Change to a constant impedance load model

      Since the load is an exponential load model we can change the exponent coefficients to 2.0 to behave as a constant impedance model:

      julia> # Update load coefficients to 2.0
      -       load = first(get_components(PSY.ExponentialLoad, sys));
      julia> PSY.set_active_power_coefficient!(load, 2.0);
      julia> PSY.set_reactive_power_coefficient!(load, 2.0);

      We then re-run the small-signal analysis:

      julia> sim = Simulation(ResidualModel,
      +       load = first(get_components(PSY.ExponentialLoad, sys));
      julia> PSY.set_α!(load, 2.0);
      julia> PSY.set_β!(load, 2.0);

      We then re-run the small-signal analysis:

      julia> sim = Simulation(ResidualModel,
                              sys,
                              mktempdir(),
                              (0.0, 1.0),
      @@ -197,7 +201,7 @@
                      base_power = 100.0,
                  )
              endactive_cpl (generic function with 1 method)

      We then attach the model to the system:

      julia> load = first(get_components(PSY.ExponentialLoad, sys));
      julia> dyn_load = active_cpl(load) -load1021 (ActiveConstantPowerLoad): +ActiveConstantPowerLoad: load1021: name: load1021 r_load: 1.8178670360110796 c_dc: 29.61400952076375 @@ -221,7 +225,9 @@ is_filter_differential: 1 states: [:θ_pll, :ϵ_pll, :η, :v_dc, :γd, :γq, :ir_cnv, :ii_cnv, :vr_filter, :vi_filter, :ir_filter, :ii_filter] n_states: 12 - internal: InfrastructureSystems.InfrastructureSystemsInternal
      julia> add_component!(sys, dyn_load, load)

      Finally, we set up the simulation:

      julia> sim = Simulation(ResidualModel,
      +   internal: InfrastructureSystems.InfrastructureSystemsInternal
      +   has_supplemental_attributes: false
      +   has_time_series: false
      julia> add_component!(sys, dyn_load, load)

      Finally, we set up the simulation:

      julia> sim = Simulation(ResidualModel,
                              sys,
                              mktempdir(),
                              (0.0, 1.0),
      @@ -267,4 +273,4 @@
         24 │ load1021 ϵ_pll             0.907233      -12.8266   0.0         100.0        2.04141
         25 │ generator-101-1 γd_ic      0.944549      -11.3935   0.0         100.0        1.81333
         26 │ generator-101-1 γq_ic      0.934217      -11.391    0.0         100.0        1.81294
      -  27 │ generator-101-1 θ_oc       1.0           -0.0       0.0         NaN          0.0

      Observe the new states of the active load model and that the system is small-signal stable.

      + 27 │ generator-101-1 θ_oc 1.0 -0.0 0.0 NaN 0.0

      Observe the new states of the active load model and that the system is small-signal stable.

      diff --git a/dev/tutorials/tutorial_continuation_pf/index.html b/dev/tutorials/tutorial_continuation_pf/index.html index 9a79ed306..ff6fe83fe 100644 --- a/dev/tutorials/tutorial_continuation_pf/index.html +++ b/dev/tutorials/tutorial_continuation_pf/index.html @@ -14,34 +14,35 @@ └───────────────────┴─────────────┘ Static Components -┌─────────────────┬───────┬────────────────────────┬───────────────┐ -│ Type │ Count │ Has Static Time Series │ Has Forecasts │ -├─────────────────┼───────┼────────────────────────┼───────────────┤ -│ ACBus │ 2 │ false │ false │ -│ Arc │ 1 │ false │ false │ -│ Area │ 1 │ false │ false │ -│ ExponentialLoad │ 1 │ false │ false │ -│ Line │ 1 │ false │ false │ -│ LoadZone │ 1 │ false │ false │ -│ ThermalStandard │ 1 │ false │ false │ -└─────────────────┴───────┴────────────────────────┴───────────────┘

      Note that this system contains an Exponential Load, but the parameters are set up to zero, so it behaves a Constant Power Load:

      julia> first(get_components(PSY.ExponentialLoad, sys_static))load1021 (PowerSystems.ExponentialLoad):
      +┌─────────────────┬───────┐
      +│ Type            │ Count │
      +├─────────────────┼───────┤
      +│ ACBus           │ 2     │
      +│ Arc             │ 1     │
      +│ Area            │ 1     │
      +│ ExponentialLoad │ 1     │
      +│ Line            │ 1     │
      +│ LoadZone        │ 1     │
      +│ ThermalStandard │ 1     │
      +└─────────────────┴───────┘

      Note that this system contains an Exponential Load, but the parameters are set up to zero, so it behaves a Constant Power Load:

      julia> first(get_components(PSY.ExponentialLoad, sys_static))ExponentialLoad: load1021:
          name: load1021
          available: true
      -   bus: BUS 2 (ACBus)
      +   bus: ACBus: BUS 2
          active_power: 0.1
          reactive_power: 0.032799999999999996
      -   active_power_coefficient: 0.0
      -   reactive_power_coefficient: 0.0
      +   α: 0.0
      +   β: 0.0
          base_power: 100.0
          max_active_power: 0.1
          max_reactive_power: 0.032799999999999996
          services: 0-element Vector{Service}
          dynamic_injector: nothing
          ext: Dict{String, Any}()
      -   time_series_container:
          InfrastructureSystems.SystemUnitsSettings:
             base_value: 100.0
      -      unit_system: UnitSystem.SYSTEM_BASE = 0

      Create a P-V curve

      The next step is to run multiple power flows and store the voltage at the load and the active power. For this example we will set up the power factor to be unitary (i.e. no reactive power at the load).

      julia> # Create a Power Range to change the power load active power
      +      unit_system: UnitSystem.SYSTEM_BASE = 0
      +   has_supplemental_attributes: false
      +   has_time_series: false

      Create a P-V curve

      The next step is to run multiple power flows and store the voltage at the load and the active power. For this example we will set up the power factor to be unitary (i.e. no reactive power at the load).

      julia> # Create a Power Range to change the power load active power
              P_range = 0.01:0.01:4.6;
              # Choose the power factor
      julia> load_pf = 1.0;

      Then create vectors to store the results

      julia> # PV Curve Results
              P_load_p = Vector{Float64}();
      julia> V_load_p = Vector{Float64}();

      Then, we run multiple power flows in a for loop by changing the active power of the load:

      julia> for p in P_range
      @@ -65,9 +66,9 @@
                  push!(V_load_p, Vm)
                  push!(P_load_p, power)
              end┌ Error: The powerflow solver returned convergence = false
      -└ @ PowerFlows ~/.julia/packages/PowerFlows/6nw6s/src/nlsolve_ac_powerflow.jl:153
      +└ @ PowerFlows ~/.julia/packages/PowerFlows/zesCE/src/nlsolve_ac_powerflow.jl:153
       ┌ Error: The powerflow solver returned convergence = false
      -└ @ PowerFlows ~/.julia/packages/PowerFlows/6nw6s/src/nlsolve_ac_powerflow.jl:52
      +└ @ PowerFlows ~/.julia/packages/PowerFlows/zesCE/src/nlsolve_ac_powerflow.jl:52
       Power Flow failed at p = 4.53

      The plot can be visualized with:

      julia> plot(P_load_p,
                   V_load_p,
                   label = "PV Curve",
      @@ -87,24 +88,25 @@
       └───────────────────┴─────────────┘
       
       Static Components
      -┌─────────────────┬───────┬────────────────────────┬───────────────┐
      -│ Type            │ Count │ Has Static Time Series │ Has Forecasts │
      -├─────────────────┼───────┼────────────────────────┼───────────────┤
      -│ ACBus           │ 2     │ false                  │ false         │
      -│ Arc             │ 1     │ false                  │ false         │
      -│ Area            │ 1     │ false                  │ false         │
      -│ ExponentialLoad │ 1     │ false                  │ false         │
      -│ Line            │ 1     │ false                  │ false         │
      -│ LoadZone        │ 1     │ false                  │ false         │
      -│ ThermalStandard │ 1     │ false                  │ false         │
      -└─────────────────┴───────┴────────────────────────┴───────────────┘
      +┌─────────────────┬───────┐
      +│ Type            │ Count │
      +├─────────────────┼───────┤
      +│ ACBus           │ 2     │
      +│ Arc             │ 1     │
      +│ Area            │ 1     │
      +│ ExponentialLoad │ 1     │
      +│ Line            │ 1     │
      +│ LoadZone        │ 1     │
      +│ ThermalStandard │ 1     │
      +└─────────────────┴───────┘
       
       Dynamic Components
      -┌──────────────────┬───────┐
      -│ Type             │ Count │
      -├──────────────────┼───────┤
      -│ DynamicGenerator │ 1     │
      -└──────────────────┴───────┘

      Here are the components of the generator:

      julia> first(get_components(DynamicGenerator, sys))generator-101-1 (DynamicGenerator{RoundRotorQuadratic, SingleMass, SEXS, SteamTurbineGov1, PSSFixed}):
      +┌───────────────────────────────────────────────────────────────────────────────
      +│ Type                                                                         ⋯
      +├───────────────────────────────────────────────────────────────────────────────
      +│ DynamicGenerator{RoundRotorQuadratic, SingleMass, SEXS, SteamTurbineGov1, PS ⋯
      +└───────────────────────────────────────────────────────────────────────────────
      +                                                               2 columns omitted

      Here are the components of the generator:

      julia> first(get_components(DynamicGenerator, sys))DynamicGenerator: generator-101-1:
          name: generator-101-1
          ω_ref: 1.0
          machine: RoundRotorQuadratic
      @@ -118,7 +120,9 @@
          ext: Dict{String, Any}()
          InfrastructureSystems.SystemUnitsSettings:
             base_value: 100.0
      -      unit_system: UnitSystem.SYSTEM_BASE = 0

      Besides the results of the P-V curve, we need to store if the system is small-signal stable or not by looking if there is a positive real part eigenvalue.

      julia> # Vectors to store stability using a boolean (true for stable).
      +      unit_system: UnitSystem.SYSTEM_BASE = 0
      +   has_supplemental_attributes: false
      +   has_time_series: false

      Besides the results of the P-V curve, we need to store if the system is small-signal stable or not by looking if there is a positive real part eigenvalue.

      julia> # Vectors to store stability using a boolean (true for stable).
              stable_vec = Vector{Bool}();
      julia> status_vec = Vector{Bool}(); # PV Curve Results
      julia> P_load_p = Vector{Float64}();
      julia> V_load_p = Vector{Float64}();

      We then run the main for loop by updating the load active power, but in addition we create a PowerSimulationsDynamics simulation on which we can run a small-signal analysis to check stability.

      julia> for p in P_range
      @@ -161,10 +165,10 @@
                      push!(status_vec, false)
                  end
              end┌ Error: The powerflow solver returned convergence = false
      -└ @ PowerFlows ~/.julia/packages/PowerFlows/6nw6s/src/nlsolve_ac_powerflow.jl:153
      +└ @ PowerFlows ~/.julia/packages/PowerFlows/zesCE/src/nlsolve_ac_powerflow.jl:153
       ┌ Error: The powerflow solver returned convergence = false
      -└ @ PowerFlows ~/.julia/packages/PowerFlows/6nw6s/src/nlsolve_ac_powerflow.jl:52
      +└ @ PowerFlows ~/.julia/packages/PowerFlows/zesCE/src/nlsolve_ac_powerflow.jl:52
       Power Flow failed at p = 4.53

      The following plot showcases the P-V curve, while also showcasing (in red) the regions on which the system is small-signal stable.

      julia> # Find where is stable and unstable
              dict_true_ixs_p = Vector();
      julia> dict_false_ixs_p = Vector();
      julia> dict_true_ixs_p = findall(x->x, stable_vec);
      julia> dict_false_ixs_p = findall(x->!x, stable_vec); - # Create plot
      julia> true_ixs = dict_true_ixs_p;
      julia> plot(P_load_p, V_load_p, color = :blue, label = "PV Curve", xlabel = "Load Power [pu]", ylabel = "Load Bus Voltage [pu]")Plot{Plots.GRBackend() n=1}
      julia> plot!(Plots.scatter!(P_load_p[true_ixs] , V_load_p[true_ixs], markerstrokewidth= 0, label = "GENROU SSA"))Plot{Plots.GRBackend() n=2}

      plot

      This results is consistent with most of the literature for dynamic generator models supplying constant power loads, on which by increasing the active power of the load, produce critical eigenvalues which cross the $j\omega$ axis at some point. This is called a Hopf Bifurcation, in this case a subcritical one since the limit cycles are unstable.

      + # Create plot
      julia> true_ixs = dict_true_ixs_p;
      julia> plot(P_load_p, V_load_p, color = :blue, label = "PV Curve", xlabel = "Load Power [pu]", ylabel = "Load Bus Voltage [pu]")Plot{Plots.GRBackend() n=1}
      julia> plot!(Plots.scatter!(P_load_p[true_ixs] , V_load_p[true_ixs], markerstrokewidth= 0, label = "GENROU SSA"))Plot{Plots.GRBackend() n=2}

      plot

      This results is consistent with most of the literature for dynamic generator models supplying constant power loads, on which by increasing the active power of the load, produce critical eigenvalues which cross the $j\omega$ axis at some point. This is called a Hopf Bifurcation, in this case a subcritical one since the limit cycles are unstable.

      diff --git a/dev/tutorials/tutorial_dynamic_data/index.html b/dev/tutorials/tutorial_dynamic_data/index.html index 768d8adca..143caf194 100644 --- a/dev/tutorials/tutorial_dynamic_data/index.html +++ b/dev/tutorials/tutorial_dynamic_data/index.html @@ -12,17 +12,17 @@ └───────────────────┴─────────────┘ Static Components -┌─────────────────┬───────┬────────────────────────┬───────────────┐ -│ Type │ Count │ Has Static Time Series │ Has Forecasts │ -├─────────────────┼───────┼────────────────────────┼───────────────┤ -│ ACBus │ 3 │ false │ false │ -│ Arc │ 3 │ false │ false │ -│ Area │ 1 │ false │ false │ -│ Line │ 3 │ false │ false │ -│ LoadZone │ 1 │ false │ false │ -│ StandardLoad │ 3 │ false │ false │ -│ ThermalStandard │ 2 │ false │ false │ -└─────────────────┴───────┴────────────────────────┴───────────────┘

      This system does not have an injection device in bus 1 (the reference bus). We can add a source with small impedance directly as follows:

      julia> slack_bus = [b for b in get_components(ACBus, sys) if get_bustype(b) == ACBusTypes.REF][1]BUS 1 (ACBus):
      +┌─────────────────┬───────┐
      +│ Type            │ Count │
      +├─────────────────┼───────┤
      +│ ACBus           │ 3     │
      +│ Arc             │ 3     │
      +│ Area            │ 1     │
      +│ Line            │ 3     │
      +│ LoadZone        │ 1     │
      +│ StandardLoad    │ 3     │
      +│ ThermalStandard │ 2     │
      +└─────────────────┴───────┘

      This system does not have an injection device in bus 1 (the reference bus). We can add a source with small impedance directly as follows:

      julia> slack_bus = [b for b in get_components(ACBus, sys) if get_bustype(b) == ACBusTypes.REF][1]ACBus: BUS 1:
          number: 101
          name: BUS 1
          bustype: ACBusTypes.REF = 3
      @@ -30,12 +30,14 @@
          magnitude: 1.02
          voltage_limits: (min = 0.9, max = 1.1)
          base_voltage: 138.0
      -   area: 1 (Area)
      -   load_zone: 1 (LoadZone)
      +   area: Area: 1
      +   load_zone: LoadZone: 1
          ext: Dict{String, Any}()
          InfrastructureSystems.SystemUnitsSettings:
             base_value: 100.0
      -      unit_system: UnitSystem.SYSTEM_BASE = 0
      julia> inf_source = Source( + unit_system: UnitSystem.SYSTEM_BASE = 0 + has_supplemental_attributes: false + has_time_series: false
      julia> inf_source = Source( name = "InfBus", #name available = true, #availability active_power = 0.0, @@ -44,10 +46,10 @@ R_th = 0.0, #Rth X_th = 5e-6, #Xth ) -InfBus (Source): +Source: InfBus: name: InfBus available: true - bus: BUS 1 (ACBus) + bus: ACBus: BUS 1 active_power: 0.0 reactive_power: 0.0 R_th: 0.0 @@ -57,7 +59,9 @@ dynamic_injector: nothing services: 0-element Vector{Service} ext: Dict{String, Any}() - internal: InfrastructureSystems.InfrastructureSystemsInternal
      julia> add_component!(sys, inf_source)

      We just added a infinite source with $X_{th} = 5\cdot 10^{-6}$ pu. The system can be explored directly using functions like:

      julia> show_components(sys, Source)Source
      +   internal: InfrastructureSystems.InfrastructureSystemsInternal
      +   has_supplemental_attributes: false
      +   has_time_series: false
      julia> add_component!(sys, inf_source)

      We just added a infinite source with $X_{th} = 5\cdot 10^{-6}$ pu. The system can be explored directly using functions like:

      julia> show_components(sys, Source)Source
       ┌────────┬───────────┐
       │ name   │ available │
       ├────────┼───────────┤
      @@ -84,18 +88,18 @@
              
              # *TG: No TG*avr_none (generic function with 1 method)
      julia> tg_none() = TGFixed(1.0) #efficiency - # *PSS: No PSS*tg_none (generic function with 1 method)
      julia> pss_none() = PSSFixed(0.0)pss_none (generic function with 1 method)

      The next lines receives a static generator name, and creates a DynamicGenerator based on that specific static generator, with the specific components defined previously. This is a classic machine model without AVR, Turbine Governor and PSS.

      julia> static_gen = get_component(Generator, sys, "generator-102-1")generator-102-1 (ThermalStandard):
      +       # *PSS: No PSS*tg_none (generic function with 1 method)
      julia> pss_none() = PSSFixed(0.0)pss_none (generic function with 1 method)

      The next lines receives a static generator name, and creates a DynamicGenerator based on that specific static generator, with the specific components defined previously. This is a classic machine model without AVR, Turbine Governor and PSS.

      julia> static_gen = get_component(Generator, sys, "generator-102-1")ThermalStandard: generator-102-1:
          name: generator-102-1
          available: true
          status: true
      -   bus: BUS 2 (ACBus)
      +   bus: ACBus: BUS 2
          active_power: 0.7
          reactive_power: 0.0
          rating: 3.333526661060325
          active_power_limits: (min = 0.0, max = 3.18)
          reactive_power_limits: (min = -1.0, max = 1.0)
          ramp_limits: (up = 3.18, down = 3.18)
      -   operation_cost: ThreePartCost
      +   operation_cost: ThermalGenerationCost composed of variable: CostCurve{QuadraticCurve}
          base_power: 100.0
          time_limits: nothing
          must_run: false
      @@ -105,10 +109,11 @@
          time_at_status: 10000.0
          dynamic_injector: nothing
          ext: Dict{String, Any}("z_source" => (r = 0.0, x = 1.0))
      -   time_series_container:
          InfrastructureSystems.SystemUnitsSettings:
             base_value: 100.0
      -      unit_system: UnitSystem.SYSTEM_BASE = 0
      julia> dyn_gen = DynamicGenerator( + unit_system: UnitSystem.SYSTEM_BASE = 0 + has_supplemental_attributes: false + has_time_series: false
      julia> dyn_gen = DynamicGenerator( name = get_name(static_gen), ω_ref = 1.0, machine = machine_classic(), @@ -117,7 +122,7 @@ prime_mover = tg_none(), pss = pss_none(), ) -generator-102-1 (DynamicGenerator{BaseMachine, SingleMass, AVRFixed, TGFixed, PSSFixed}): +DynamicGenerator: generator-102-1: name: generator-102-1 ω_ref: 1.0 machine: BaseMachine @@ -129,7 +134,9 @@ n_states: 2 states: [:δ, :ω] ext: Dict{String, Any}() - internal: InfrastructureSystems.InfrastructureSystemsInternal

      The dynamic generator is added to the system by specifying the dynamic and static generator

      julia> add_component!(sys, dyn_gen, static_gen)

      Then we can serialize our system data to a json file that can be later read as:


      julia> to_json(sys, joinpath(file_dir, "modified_sys.json"), force = true)

      Dynamic Lines case: Data creation

      We will now create a three bus system with one inverter and one generator. In order to do so, we will parse the following ThreebusInverter.raw network:

      julia> threebus_sys = build_system(PSIDSystems, "3 Bus Inverter Base")System
      +   internal: InfrastructureSystems.InfrastructureSystemsInternal
      +   has_supplemental_attributes: false
      +   has_time_series: false

      The dynamic generator is added to the system by specifying the dynamic and static generator

      julia> add_component!(sys, dyn_gen, static_gen)

      Then we can serialize our system data to a json file that can be later read as:


      julia> to_json(sys, joinpath(file_dir, "modified_sys.json"), force = true)

      Dynamic Lines case: Data creation

      We will now create a three bus system with one inverter and one generator. In order to do so, we will parse the following ThreebusInverter.raw network:

      julia> threebus_sys = build_system(PSIDSystems, "3 Bus Inverter Base")System
       ┌───────────────────┬─────────────┐
       │ Property          │ Value       │
       ├───────────────────┼─────────────┤
      @@ -142,17 +149,17 @@
       └───────────────────┴─────────────┘
       
       Static Components
      -┌─────────────────┬───────┬────────────────────────┬───────────────┐
      -│ Type            │ Count │ Has Static Time Series │ Has Forecasts │
      -├─────────────────┼───────┼────────────────────────┼───────────────┤
      -│ ACBus           │ 3     │ false                  │ false         │
      -│ Arc             │ 3     │ false                  │ false         │
      -│ Area            │ 1     │ false                  │ false         │
      -│ Line            │ 3     │ false                  │ false         │
      -│ LoadZone        │ 1     │ false                  │ false         │
      -│ StandardLoad    │ 3     │ false                  │ false         │
      -│ ThermalStandard │ 2     │ false                  │ false         │
      -└─────────────────┴───────┴────────────────────────┴───────────────┘
      julia> slack_bus = first(get_components(x -> get_bustype(x) == BusTypes.REF, Bus, threebus_sys))ERROR: UndefVarError: `BusTypes` not defined
      julia> inf_source = Source( +┌─────────────────┬───────┐ +│ Type │ Count │ +├─────────────────┼───────┤ +│ ACBus │ 3 │ +│ Arc │ 3 │ +│ Area │ 1 │ +│ Line │ 3 │ +│ LoadZone │ 1 │ +│ StandardLoad │ 3 │ +│ ThermalStandard │ 2 │ +└─────────────────┴───────┘
      julia> slack_bus = first(get_components(x -> get_bustype(x) == BusTypes.REF, Bus, threebus_sys))ERROR: UndefVarError: `BusTypes` not defined
      julia> inf_source = Source( name = "InfBus", #name available = true, #availability active_power = 0.0, @@ -161,10 +168,10 @@ R_th = 0.0, #Rth X_th = 5e-6, #Xth ) -InfBus (Source): +Source: InfBus: name: InfBus available: true - bus: BUS 1 (ACBus) + bus: ACBus: BUS 1 active_power: 0.0 reactive_power: 0.0 R_th: 0.0 @@ -174,7 +181,9 @@ dynamic_injector: nothing services: 0-element Vector{Service} ext: Dict{String, Any}() - internal: InfrastructureSystems.InfrastructureSystemsInternal
      julia> add_component!(threebus_sys, inf_source)

      We will connect a One-d-one-q machine at bus 102, and a Virtual Synchronous Generator Inverter at bus 103. An inverter is composed by a converter, outer control, inner control, dc source, frequency estimator and a filter.

      Dynamic Inverter definition

      We will create specific functions to create the components of the inverter as follows:

      julia> #Define converter as an AverageConverter
      +   internal: InfrastructureSystems.InfrastructureSystemsInternal
      +   has_supplemental_attributes: false
      +   has_time_series: false
      julia> add_component!(threebus_sys, inf_source)ERROR: ArgumentError: ACBus: BUS 1 is not attached to the system

      We will connect a One-d-one-q machine at bus 102, and a Virtual Synchronous Generator Inverter at bus 103. An inverter is composed by a converter, outer control, inner control, dc source, frequency estimator and a filter.

      Dynamic Inverter definition

      We will create specific functions to create the components of the inverter as follows:

      julia> #Define converter as an AverageConverter
              converter_high_power() = AverageConverter(
                  rated_voltage = 138.0,
                  rated_current = 100.0
      @@ -270,4 +279,4 @@
                      #Attach the dynamic inverter to the system
                      add_component!(threebus_sys, case_inv, g)
                  end
      -       end

      Save the system in a JSON file


      julia> to_json(threebus_sys, joinpath(file_dir, "threebus_sys.json"), force = true)
      + end

      Save the system in a JSON file


      julia> to_json(threebus_sys, joinpath(file_dir, "threebus_sys.json"), force = true)
      diff --git a/dev/tutorials/tutorial_dynamic_lines/index.html b/dev/tutorials/tutorial_dynamic_lines/index.html index 5db420c45..ec5ef8ac9 100644 --- a/dev/tutorials/tutorial_dynamic_lines/index.html +++ b/dev/tutorials/tutorial_dynamic_lines/index.html @@ -12,26 +12,27 @@ └───────────────────┴─────────────┘ Static Components -┌─────────────────┬───────┬────────────────────────┬───────────────┐ -│ Type │ Count │ Has Static Time Series │ Has Forecasts │ -├─────────────────┼───────┼────────────────────────┼───────────────┤ -│ ACBus │ 3 │ false │ false │ -│ Arc │ 3 │ false │ false │ -│ Area │ 1 │ false │ false │ -│ Line │ 3 │ false │ false │ -│ LoadZone │ 1 │ false │ false │ -│ Source │ 1 │ false │ false │ -│ StandardLoad │ 3 │ false │ false │ -│ ThermalStandard │ 2 │ false │ false │ -└─────────────────┴───────┴────────────────────────┴───────────────┘ +┌─────────────────┬───────┐ +│ Type │ Count │ +├─────────────────┼───────┤ +│ ACBus │ 3 │ +│ Arc │ 3 │ +│ Area │ 1 │ +│ Line │ 3 │ +│ LoadZone │ 1 │ +│ Source │ 1 │ +│ StandardLoad │ 3 │ +│ ThermalStandard │ 2 │ +└─────────────────┴───────┘ Dynamic Components -┌──────────────────┬───────┐ -│ Type │ Count │ -├──────────────────┼───────┤ -│ DynamicGenerator │ 1 │ -│ DynamicInverter │ 1 │ -└──────────────────┴───────┘

      In addition, we will create a new copy of the system on which we will simulate the same case, but will consider dynamic lines:

      julia> threebus_sys_dyn = deepcopy(threebus_sys);

      Step 3: Create the fault and simulation on the Static Lines system

      First, we construct the perturbation, by properly computing the new Ybus on the system:

      julia> #Make a copy of the original system
      +┌───────────────────────────────────────────────────────────────────────────────
      +│ Type                                                                         ⋯
      +├───────────────────────────────────────────────────────────────────────────────
      +│ DynamicGenerator{OneDOneQMachine, SingleMass, AVRTypeI, TGFixed, PSSFixed}   ⋯
      +│ DynamicInverter{AverageConverter, OuterControl{VirtualInertia, ReactivePower ⋯
      +└───────────────────────────────────────────────────────────────────────────────
      +                                                               2 columns omitted

      In addition, we will create a new copy of the system on which we will simulate the same case, but will consider dynamic lines:

      julia> threebus_sys_dyn = deepcopy(threebus_sys);

      Step 3: Create the fault and simulation on the Static Lines system

      First, we construct the perturbation, by properly computing the new Ybus on the system:

      julia> #Make a copy of the original system
              sys2 = deepcopy(threebus_sys)
              #Triplicates the impedance of the line named "BUS 1-BUS 3-i_1"System
       ┌───────────────────┬─────────────┐
      @@ -46,26 +47,27 @@
       └───────────────────┴─────────────┘
       
       Static Components
      -┌─────────────────┬───────┬────────────────────────┬───────────────┐
      -│ Type            │ Count │ Has Static Time Series │ Has Forecasts │
      -├─────────────────┼───────┼────────────────────────┼───────────────┤
      -│ ACBus           │ 3     │ false                  │ false         │
      -│ Arc             │ 3     │ false                  │ false         │
      -│ Area            │ 1     │ false                  │ false         │
      -│ Line            │ 3     │ false                  │ false         │
      -│ LoadZone        │ 1     │ false                  │ false         │
      -│ Source          │ 1     │ false                  │ false         │
      -│ StandardLoad    │ 3     │ false                  │ false         │
      -│ ThermalStandard │ 2     │ false                  │ false         │
      -└─────────────────┴───────┴────────────────────────┴───────────────┘
      +┌─────────────────┬───────┐
      +│ Type            │ Count │
      +├─────────────────┼───────┤
      +│ ACBus           │ 3     │
      +│ Arc             │ 3     │
      +│ Area            │ 1     │
      +│ Line            │ 3     │
      +│ LoadZone        │ 1     │
      +│ Source          │ 1     │
      +│ StandardLoad    │ 3     │
      +│ ThermalStandard │ 2     │
      +└─────────────────┴───────┘
       
       Dynamic Components
      -┌──────────────────┬───────┐
      -│ Type             │ Count │
      -├──────────────────┼───────┤
      -│ DynamicGenerator │ 1     │
      -│ DynamicInverter  │ 1     │
      -└──────────────────┴───────┘
      julia> fault_branches = get_components(ACBranch, sys2)ACBranch Counts: +┌─────────────────────────────────────────────────────────────────────────────── +│ Type ⋯ +├─────────────────────────────────────────────────────────────────────────────── +│ DynamicGenerator{OneDOneQMachine, SingleMass, AVRTypeI, TGFixed, PSSFixed} ⋯ +│ DynamicInverter{AverageConverter, OuterControl{VirtualInertia, ReactivePower ⋯ +└─────────────────────────────────────────────────────────────────────────────── + 2 columns omitted
      julia> fault_branches = get_components(ACBranch, sys2)ACBranch Counts: Line: 3
      julia> for br in fault_branches if get_name(br) == "BUS 1-BUS 3-i_1" br.r = 3 * br.r @@ -168,18 +170,20 @@ │ Time Span │ (0.0, 30.0) │ │ Total Time Steps │ 1607 │ │ Number of States │ 33 │ -│ Total solve time │ 2.554710211 │ -└────────────────────────────┴─────────────┘
      julia> series2 = get_voltage_magnitude_series(results, 102)([0.0, 0.001, 0.002, 0.004, 0.008, 0.016, 0.032, 0.052000000000000005, 0.07200000000000001, 0.09200000000000001 … 29.83954153464911, 29.85954153464911, 29.87954153464911, 29.89954153464911, 29.91954153464911, 29.93954153464911, 29.95954153464911, 29.97954153464911, 29.999541534649108, 30.0], [1.0142000000000002, 1.0142000000001268, 1.0142000000001326, 1.0142000000001927, 1.01420000000014, 1.014200000000125, 1.0142000000001052, 1.0142000000000875, 1.014200000000071, 1.0142000000000564 … 1.0140816770731866, 1.0140823112693007, 1.014082942782033, 1.0140835715610201, 1.014084197556437, 1.0140848207190878, 1.0140854410003357, 1.0140860583521254, 1.0140866727269917, 1.0140866867751974])
      julia> zoom = [ +│ Total solve time │ 2.474702427 │ +└────────────────────────────┴─────────────┘
      julia> series2 = get_voltage_magnitude_series(results, 102)([0.0, 0.001, 0.002, 0.004, 0.008, 0.016, 0.032, 0.052000000000000005, 0.07200000000000001, 0.09200000000000001 … 29.839541534695492, 29.85954153469549, 29.87954153469549, 29.89954153469549, 29.91954153469549, 29.93954153469549, 29.95954153469549, 29.97954153469549, 29.99954153469549, 30.0], [1.0142000000000002, 1.0142000000001268, 1.0142000000001326, 1.0142000000001927, 1.01420000000014, 1.014200000000125, 1.0142000000001052, 1.0142000000000875, 1.014200000000071, 1.0142000000000564 … 1.0140816770731862, 1.0140823112693074, 1.014082942782043, 1.0140835715610197, 1.014084197556442, 1.0140848207190936, 1.0140854410003397, 1.0140860583521298, 1.0140866727269955, 1.014086686775199])
      julia> zoom = [ (series2[1][ix], series2[2][ix]) for (ix, s) in enumerate(series2[1]) if (s > 0.90 && s < 1.6) ];

      Step 3.1: Create the fault and simulation on the Dynamic Lines system

      An important aspect to consider is that DynamicLines must not be considered in the computation of the Ybus. First we construct the Dynamic Line, by finding the Line named "BUS 2-BUS 3-i_1", and then adding it to the system.

      julia> # get component return the Branch on threebus_sys_dyn named "BUS 2-BUS 3-i_1"
              dyn_branch = DynamicBranch(get_component(Line, threebus_sys_dyn,"BUS 2-BUS 3-i_1"))
              # Adding a dynamic line will immediately remove the static line from the system.
      -BUS 2-BUS 3-i_1 (DynamicBranch):
      -   branch: BUS 2-BUS 3-i_1 (Line)
      +DynamicBranch: BUS 2-BUS 3-i_1:
      +   branch: Line: BUS 2-BUS 3-i_1
          n_states: 2
          states: [:Il_R, :Il_I]
      -   internal: InfrastructureSystems.InfrastructureSystemsInternal
      julia> add_component!(threebus_sys_dyn, dyn_branch)

      Similarly, we construct the Ybus fault by creating a copy of the original system, but removing the Line "BUS 2-BUS 3-i_1" to avoid considering it in the Ybus:

      julia> #Make a copy of the original system
      +   internal: InfrastructureSystems.InfrastructureSystemsInternal
      +   has_supplemental_attributes: false
      +   has_time_series: false
      julia> add_component!(threebus_sys_dyn, dyn_branch)

      Similarly, we construct the Ybus fault by creating a copy of the original system, but removing the Line "BUS 2-BUS 3-i_1" to avoid considering it in the Ybus:

      julia> #Make a copy of the original system
              sys3 = deepcopy(threebus_sys);
              #Remove Line "BUS 2-BUS 3-i_1"
      julia> remove_component!(Line, sys3, "BUS 2-BUS 3-i_1") #Triplicates the impedance of the line named "BUS 1-BUS 2-i_1"
      julia> fault_branches2 = get_components(Line, sys3)Line Counts: @@ -290,8 +294,8 @@ │ Time Span │ (0.0, 30.0) │ │ Total Time Steps │ 1721 │ │ Number of States │ 35 │ -│ Total solve time │ 2.340437946 │ +│ Total solve time │ 2.301532485 │ └────────────────────────────┴─────────────┘
      julia> series2_dyn = get_voltage_magnitude_series(results_dyn, 102);
      julia> zoom_dyn = [ (series2_dyn[1][ix], series2_dyn[2][ix]) for (ix, s) in enumerate(series2_dyn[1]) if (s > 0.90 && s < 1.6) - ];

      Step 6.1: Compare the solutions:

      We can observe the effect of Dynamic Lines

      julia> plot(series2_dyn, label = "V_gen_dyn");
      julia> plot!(series2, label = "V_gen_st", xlabel = "Time [s]", ylabel = "Voltage [pu]");

      plot

      that looks quite similar. The differences can be observed in the zoom plot:

      julia> plot(zoom_dyn, label = "V_gen_dyn");
      julia> plot!(zoom, label = "V_gen_st", xlabel = "Time [s]", ylabel = "Voltage [pu]");

      plot

      + ];

      Step 6.1: Compare the solutions:

      We can observe the effect of Dynamic Lines

      julia> plot(series2_dyn, label = "V_gen_dyn");
      julia> plot!(series2, label = "V_gen_st", xlabel = "Time [s]", ylabel = "Voltage [pu]");

      plot

      that looks quite similar. The differences can be observed in the zoom plot:

      julia> plot(zoom_dyn, label = "V_gen_dyn");
      julia> plot!(zoom, label = "V_gen_st", xlabel = "Time [s]", ylabel = "Voltage [pu]");

      plot

      diff --git a/dev/tutorials/tutorial_inverter_modeling/index.html b/dev/tutorials/tutorial_inverter_modeling/index.html index 3eda6c18a..e1764537c 100644 --- a/dev/tutorials/tutorial_inverter_modeling/index.html +++ b/dev/tutorials/tutorial_inverter_modeling/index.html @@ -12,27 +12,28 @@ └───────────────────┴─────────────┘ Static Components -┌─────────────────┬───────┬────────────────────────┬───────────────┐ -│ Type │ Count │ Has Static Time Series │ Has Forecasts │ -├─────────────────┼───────┼────────────────────────┼───────────────┤ -│ ACBus │ 14 │ false │ false │ -│ Arc │ 20 │ false │ false │ -│ Area │ 1 │ false │ false │ -│ Line │ 16 │ false │ false │ -│ LoadZone │ 1 │ false │ false │ -│ StandardLoad │ 11 │ false │ false │ -│ TapTransformer │ 3 │ false │ false │ -│ ThermalStandard │ 5 │ false │ false │ -│ Transformer2W │ 1 │ false │ false │ -└─────────────────┴───────┴────────────────────────┴───────────────┘ +┌─────────────────┬───────┐ +│ Type │ Count │ +├─────────────────┼───────┤ +│ ACBus │ 14 │ +│ Arc │ 20 │ +│ Area │ 1 │ +│ Line │ 16 │ +│ LoadZone │ 1 │ +│ StandardLoad │ 11 │ +│ TapTransformer │ 3 │ +│ ThermalStandard │ 5 │ +│ Transformer2W │ 1 │ +└─────────────────┴───────┘ Dynamic Components -┌──────────────────┬───────┐ -│ Type │ Count │ -├──────────────────┼───────┤ -│ DynamicGenerator │ 4 │ -│ DynamicGenerator │ 1 │ -└──────────────────┴───────┘

      PowerSystemCaseBuilder.jl is a helper library that makes it easier to reproduce examples in the documentation and tutorials. Normally you would pass your local files to create the system data.

      Define Simulation Problem with a 20 second simulation period and the branch trip at t = 1.0:

      julia> sim = Simulation(
      +┌───────────────────────────────────────────────────────────────────────────────
      +│ Type                                                                         ⋯
      +├───────────────────────────────────────────────────────────────────────────────
      +│ DynamicGenerator{RoundRotorQuadratic, SingleMass, ESAC1A, GasTG, PSSFixed}   ⋯
      +│ DynamicGenerator{RoundRotorQuadratic, SingleMass, ESAC1A, TGFixed, PSSFixed} ⋯
      +└───────────────────────────────────────────────────────────────────────────────
      +                                                                1 column omitted

      PowerSystemCaseBuilder.jl is a helper library that makes it easier to reproduce examples in the documentation and tutorials. Normally you would pass your local files to create the system data.

      Define Simulation Problem with a 20 second simulation period and the branch trip at t = 1.0:

      julia> sim = Simulation(
                  ResidualModel, #Type of model used
                  sys,         #system
                  mktempdir(),       #path for the simulation output
      @@ -211,7 +212,7 @@
       │ Time Span                  │ (0.0, 20.0) │
       │ Total Time Steps           │ 342         │
       │ Number of States           │ 86          │
      -│ Total solve time           │ 2.159769307 │
      +│ Total solve time           │ 2.101120727 │
       └────────────────────────────┴─────────────┘
      julia> p = plot();
      julia> for b in get_components(ACBus, sys) voltage_series = get_voltage_magnitude_series(result, get_number(b)) plot!( @@ -265,38 +266,39 @@ └───────────────────┴─────────────┘ Static Components -┌─────────────────┬───────┬────────────────────────┬───────────────┐ -│ Type │ Count │ Has Static Time Series │ Has Forecasts │ -├─────────────────┼───────┼────────────────────────┼───────────────┤ -│ ACBus │ 14 │ false │ false │ -│ Arc │ 20 │ false │ false │ -│ Area │ 1 │ false │ false │ -│ Line │ 16 │ false │ false │ -│ LoadZone │ 1 │ false │ false │ -│ StandardLoad │ 11 │ false │ false │ -│ TapTransformer │ 3 │ false │ false │ -│ ThermalStandard │ 5 │ false │ false │ -│ Transformer2W │ 1 │ false │ false │ -└─────────────────┴───────┴────────────────────────┴───────────────┘ +┌─────────────────┬───────┐ +│ Type │ Count │ +├─────────────────┼───────┤ +│ ACBus │ 14 │ +│ Arc │ 20 │ +│ Area │ 1 │ +│ Line │ 16 │ +│ LoadZone │ 1 │ +│ StandardLoad │ 11 │ +│ TapTransformer │ 3 │ +│ ThermalStandard │ 5 │ +│ Transformer2W │ 1 │ +└─────────────────┴───────┘ Dynamic Components -┌──────────────────┬───────┐ -│ Type │ Count │ -├──────────────────┼───────┤ -│ DynamicGenerator │ 4 │ -│ DynamicGenerator │ 1 │ -└──────────────────┴───────┘
      julia> thermal_gen = get_component(ThermalStandard, sys, "generator-6-1")generator-6-1 (ThermalStandard): +┌─────────────────────────────────────────────────────────────────────────────── +│ Type ⋯ +├─────────────────────────────────────────────────────────────────────────────── +│ DynamicGenerator{RoundRotorQuadratic, SingleMass, ESAC1A, GasTG, PSSFixed} ⋯ +│ DynamicGenerator{RoundRotorQuadratic, SingleMass, ESAC1A, TGFixed, PSSFixed} ⋯ +└─────────────────────────────────────────────────────────────────────────────── + 1 column omitted
      julia> thermal_gen = get_component(ThermalStandard, sys, "generator-6-1")ThermalStandard: generator-6-1: name: generator-6-1 available: true status: true - bus: BUS 06 (ACBus) + bus: ACBus: BUS 06 active_power: 0.15 reactive_power: 0.14800000000000002 rating: 99.99028802838804 active_power_limits: (min = -99.99, max = 99.99) reactive_power_limits: (min = -0.06, max = 0.24) ramp_limits: (up = 24.9975, down = 24.9975) - operation_cost: ThreePartCost + operation_cost: ThermalGenerationCost composed of variable: CostCurve{QuadraticCurve} base_power: 25.0 time_limits: nothing must_run: false @@ -304,12 +306,13 @@ fuel: ThermalFuels.OTHER = 14 services: 0-element Vector{Service} time_at_status: 10000.0 - dynamic_injector: generator-6-1 (DynamicGenerator{RoundRotorQuadratic, SingleMass, ESAC1A, TGFixed, PSSFixed}) + dynamic_injector: DynamicGenerator: generator-6-1 ext: Dict{String, Any}("z_source" => Dict{String, Any}("x" => 0.12, "r" => 0)) - time_series_container: InfrastructureSystems.SystemUnitsSettings: base_value: 100.0 - unit_system: UnitSystem.SYSTEM_BASE = 0
      julia> remove_component!(sys, get_dynamic_injector(thermal_gen))
      julia> remove_component!(sys, thermal_gen) + unit_system: UnitSystem.SYSTEM_BASE = 0 + has_supplemental_attributes: false + has_time_series: false
      julia> remove_component!(sys, get_dynamic_injector(thermal_gen))
      julia> remove_component!(sys, thermal_gen) # We can now define our storage device and add it to the system
      julia> storage = GenericBattery( name = "Battery", @@ -326,7 +329,7 @@ output_active_power_limits = (min = 0.0, max = 1.0), reactive_power_limits = (min = -1.0, max = 1.0), efficiency = (in = 0.80, out = 0.90), - )ERROR: UndefKeywordError: keyword argument `prime_mover_type` not assigned
      julia> add_component!(sys, storage)ERROR: UndefVarError: `storage` not defined

      A good sanity check it running a power flow on the system to make sure all the components are properly scaled and that the system is properly balanced. We can use PowerSystems to perform this check. We can get the results back and perform a sanity check.

      julia> res = solve_powerflow(ACPowerFlow(), sys)Dict{String, DataFrames.DataFrame} with 2 entries:
      +       )ERROR: UndefVarError: `GenericBattery` not defined
      julia> add_component!(sys, storage)ERROR: UndefVarError: `storage` not defined

      A good sanity check it running a power flow on the system to make sure all the components are properly scaled and that the system is properly balanced. We can use PowerSystems to perform this check. We can get the results back and perform a sanity check.

      julia> res = solve_powerflow(ACPowerFlow(), sys)Dict{String, DataFrames.DataFrame} with 2 entries:
         "flow_results" => 20×9 DataFrame…
         "bus_results"  => 14×9 DataFrame…
      julia> res["bus_results"]14×9 DataFrame Row │ bus_number Vm θ P_gen P_load P_net Q_gen ⋯ @@ -386,27 +389,28 @@ └───────────────────┴─────────────┘ Static Components -┌─────────────────┬───────┬────────────────────────┬───────────────┐ -│ Type │ Count │ Has Static Time Series │ Has Forecasts │ -├─────────────────┼───────┼────────────────────────┼───────────────┤ -│ ACBus │ 14 │ false │ false │ -│ Arc │ 20 │ false │ false │ -│ Area │ 1 │ false │ false │ -│ Line │ 16 │ false │ false │ -│ LoadZone │ 1 │ false │ false │ -│ StandardLoad │ 11 │ false │ false │ -│ TapTransformer │ 3 │ false │ false │ -│ ThermalStandard │ 4 │ false │ false │ -│ Transformer2W │ 1 │ false │ false │ -└─────────────────┴───────┴────────────────────────┴───────────────┘ +┌─────────────────┬───────┐ +│ Type │ Count │ +├─────────────────┼───────┤ +│ ACBus │ 14 │ +│ Arc │ 20 │ +│ Area │ 1 │ +│ Line │ 16 │ +│ LoadZone │ 1 │ +│ StandardLoad │ 11 │ +│ TapTransformer │ 3 │ +│ ThermalStandard │ 4 │ +│ Transformer2W │ 1 │ +└─────────────────┴───────┘ Dynamic Components -┌──────────────────┬───────┐ -│ Type │ Count │ -├──────────────────┼───────┤ -│ DynamicGenerator │ 3 │ -│ DynamicGenerator │ 1 │ -└──────────────────┴───────┘

      Define Simulation problem using the same parameters:

      julia> sim = Simulation(
      +┌───────────────────────────────────────────────────────────────────────────────
      +│ Type                                                                         ⋯
      +├───────────────────────────────────────────────────────────────────────────────
      +│ DynamicGenerator{RoundRotorQuadratic, SingleMass, ESAC1A, GasTG, PSSFixed}   ⋯
      +│ DynamicGenerator{RoundRotorQuadratic, SingleMass, ESAC1A, TGFixed, PSSFixed} ⋯
      +└───────────────────────────────────────────────────────────────────────────────
      +                                                                1 column omitted

      Define Simulation problem using the same parameters:

      julia> sim = Simulation(
                  ResidualModel, #Type of model used
                  sys,         #system
                  mktempdir(),       #path for the simulation output
      @@ -420,13 +424,13 @@
       │      [1] error(s::String)
       │        @ Base ./error.jl:35
       │      [2] _reactive_power_redistribution_pv(sys::System, Q_gen::Float64, bus::ACBus)
      -│        @ PowerFlows ~/.julia/packages/PowerFlows/6nw6s/src/post_processing.jl:310
      +│        @ PowerFlows ~/.julia/packages/PowerFlows/zesCE/src/post_processing.jl:310
       │      [3] write_powerflow_solution!(sys::System, result::Vector{Float64})
      -│        @ PowerFlows ~/.julia/packages/PowerFlows/6nw6s/src/post_processing.jl:447
      +│        @ PowerFlows ~/.julia/packages/PowerFlows/zesCE/src/post_processing.jl:447
       │      [4] solve_ac_powerflow!(system::System; kwargs::@Kwargs{})
      -│        @ PowerFlows ~/.julia/packages/PowerFlows/6nw6s/src/nlsolve_ac_powerflow.jl:46
      +│        @ PowerFlows ~/.julia/packages/PowerFlows/zesCE/src/nlsolve_ac_powerflow.jl:46
       │      [5] solve_ac_powerflow!
      -│        @ ~/.julia/packages/PowerFlows/6nw6s/src/nlsolve_ac_powerflow.jl:33 [inlined]
      +│        @ ~/.julia/packages/PowerFlows/zesCE/src/nlsolve_ac_powerflow.jl:33 [inlined]
       │      [6] power_flow_solution!(initial_guess::Vector{Float64}, sys::System, inputs::PowerSimulationsDynamics.SimulationInputs)
       │        @ PowerSimulationsDynamics ~/work/PowerSimulationsDynamics.jl/PowerSimulationsDynamics.jl/src/base/simulation_initialization.jl:14
       │      [7] macro expansion
      @@ -614,4 +618,4 @@
       
       Closest candidates are:
         get_state_series(!Matched::SimulationResults, ::Tuple{String, Symbol}; dt)
      -   @ PowerSimulationsDynamics ~/work/PowerSimulationsDynamics.jl/PowerSimulationsDynamics.jl/src/base/simulation_results.jl:310
      julia> plot!(p2, state_series; xlabel = "Time", ylabel = "Speed [pu]", label = "Battery - ω");ERROR: UndefVarError: `state_series` not defined

      plot

      + @ PowerSimulationsDynamics ~/work/PowerSimulationsDynamics.jl/PowerSimulationsDynamics.jl/src/base/simulation_results.jl:310
      julia> plot!(p2, state_series; xlabel = "Time", ylabel = "Speed [pu]", label = "Battery - ω");ERROR: UndefVarError: `state_series` not defined

      plot

      diff --git a/dev/tutorials/tutorial_omib/index.html b/dev/tutorials/tutorial_omib/index.html index 8ec0db71d..e6d67cfab 100644 --- a/dev/tutorials/tutorial_omib/index.html +++ b/dev/tutorials/tutorial_omib/index.html @@ -12,24 +12,25 @@ └───────────────────┴─────────────┘ Static Components -┌─────────────────┬───────┬────────────────────────┬───────────────┐ -│ Type │ Count │ Has Static Time Series │ Has Forecasts │ -├─────────────────┼───────┼────────────────────────┼───────────────┤ -│ ACBus │ 2 │ false │ false │ -│ Arc │ 1 │ false │ false │ -│ Area │ 1 │ false │ false │ -│ Line │ 2 │ false │ false │ -│ LoadZone │ 1 │ false │ false │ -│ Source │ 1 │ false │ false │ -│ ThermalStandard │ 1 │ false │ false │ -└─────────────────┴───────┴────────────────────────┴───────────────┘ +┌─────────────────┬───────┐ +│ Type │ Count │ +├─────────────────┼───────┤ +│ ACBus │ 2 │ +│ Arc │ 1 │ +│ Area │ 1 │ +│ Line │ 2 │ +│ LoadZone │ 1 │ +│ Source │ 1 │ +│ ThermalStandard │ 1 │ +└─────────────────┴───────┘ Dynamic Components -┌──────────────────┬───────┐ -│ Type │ Count │ -├──────────────────┼───────┤ -│ DynamicGenerator │ 1 │ -└──────────────────┴───────┘

      Build the simulation and initialize the problem

      The next step is to create the simulation structure. This will create the indexing of our system that will be used to formulate the differential-algebraic system of equations. To do so, it is required to specify the perturbation that will occur in the system. PowerSimulationsDynamics supports multiple types of perturbations. See Perturbations

      Here, we will use a Branch Trip perturbation, that is modeled by modifying the specifying which line we want to trip. In this case we disconnect one of the lines that connects BUS 1 and BUS 2, named "BUS 1-BUS 2-i_1".

      With this, we are ready to create our simulation structure:

      julia> time_span = (0.0, 30.0)(0.0, 30.0)
      julia> perturbation_trip = BranchTrip(1.0, Line, "BUS 1-BUS 2-i_1")BranchTrip(1.0, Line, "BUS 1-BUS 2-i_1")
      julia> sim = PSID.Simulation( +┌────────────────────────────────────────────────────────────────────────┬────── +│ Type │ Cou ⋯ +├────────────────────────────────────────────────────────────────────────┼────── +│ DynamicGenerator{BaseMachine, SingleMass, AVRFixed, TGFixed, PSSFixed} │ 1 ⋯ +└────────────────────────────────────────────────────────────────────────┴────── + 1 column omitted

      Build the simulation and initialize the problem

      The next step is to create the simulation structure. This will create the indexing of our system that will be used to formulate the differential-algebraic system of equations. To do so, it is required to specify the perturbation that will occur in the system. PowerSimulationsDynamics supports multiple types of perturbations. See Perturbations

      Here, we will use a Branch Trip perturbation, that is modeled by modifying the specifying which line we want to trip. In this case we disconnect one of the lines that connects BUS 1 and BUS 2, named "BUS 1-BUS 2-i_1".

      With this, we are ready to create our simulation structure:

      julia> time_span = (0.0, 30.0)(0.0, 30.0)
      julia> perturbation_trip = BranchTrip(1.0, Line, "BUS 1-BUS 2-i_1")BranchTrip(1.0, Line, "BUS 1-BUS 2-i_1")
      julia> sim = PSID.Simulation( ResidualModel, # Type of formulation omib_sys, # System mktempdir(), # Output directory @@ -76,7 +77,7 @@ │ Time Span │ (0.0, 30.0) │ │ Total Time Steps │ 1512 │ │ Number of States │ 6 │ -│ Total solve time │ 1.573398428 │ +│ Total solve time │ 1.519153527 │ └────────────────────────────┴─────────────┘

      PowerSimulationsDynamics has two functions to obtain different states of the solution:

      julia> angle = get_state_series(results, ("generator-102-1", :δ));
      julia> plot(angle, xlabel = "time", ylabel = "rotor angle [rad]", label = "rotor angle")Plot{Plots.GRBackend() n=1}

      plot

      julia> volt = get_voltage_magnitude_series(results, 102);
      julia> plot(volt, xlabel = "time", ylabel = "Voltage [pu]", label = "V_2")Plot{Plots.GRBackend() n=1}

      plot

      Optional: Small Signal Analysis

      PowerSimulationsDynamics uses automatic differentiation to compute the reduced Jacobian of the system for the differential states. This can be used to analyze the local stability of the linearized system. We need to re-initialize our simulation:

      julia> sim2 = Simulation(ResidualModel, omib_sys, mktempdir(), time_span)Simulation Summary
       ┌─────────────────────────┬────────────────┐
       │ Property                │ Value          │
      @@ -92,4 +93,4 @@
         0.0       376.991
        -0.466763   -0.317662

      and can also be used to report the eigenvalues of the reduced linearized system:

      julia> small_sig.eigenvalues2-element Vector{ComplexF64}:
        -0.15883100381194407 - 13.264252847627304im
      - -0.15883100381194407 + 13.264252847627304im
      + -0.15883100381194407 + 13.264252847627304im diff --git a/dev/tutorials_page/index.html b/dev/tutorials_page/index.html index 99aba60a0..0f247ec2b 100644 --- a/dev/tutorials_page/index.html +++ b/dev/tutorials_page/index.html @@ -1,2 +1,2 @@ -SIIP-Examples · PowerSimulationsDynamics.jl
      +SIIP-Examples · PowerSimulationsDynamics.jl