|
|
@ -12,15 +12,15 @@ import GZip
|
|
|
|
mutable struct Bus
|
|
|
|
mutable struct Bus
|
|
|
|
name::String
|
|
|
|
name::String
|
|
|
|
offset::Int
|
|
|
|
offset::Int
|
|
|
|
load::Array{Float64}
|
|
|
|
load::Vector{Float64}
|
|
|
|
units::Array
|
|
|
|
units::Array
|
|
|
|
price_sensitive_loads::Array
|
|
|
|
price_sensitive_loads::Array
|
|
|
|
end
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
mutable struct CostSegment
|
|
|
|
mutable struct CostSegment
|
|
|
|
mw::Array{Float64}
|
|
|
|
mw::Vector{Float64}
|
|
|
|
cost::Array{Float64}
|
|
|
|
cost::Vector{Float64}
|
|
|
|
end
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@ -33,11 +33,11 @@ end
|
|
|
|
mutable struct Unit
|
|
|
|
mutable struct Unit
|
|
|
|
name::String
|
|
|
|
name::String
|
|
|
|
bus::Bus
|
|
|
|
bus::Bus
|
|
|
|
max_power::Array{Float64}
|
|
|
|
max_power::Vector{Float64}
|
|
|
|
min_power::Array{Float64}
|
|
|
|
min_power::Vector{Float64}
|
|
|
|
must_run::Array{Bool}
|
|
|
|
must_run::Vector{Bool}
|
|
|
|
min_power_cost::Array{Float64}
|
|
|
|
min_power_cost::Vector{Float64}
|
|
|
|
cost_segments::Array{CostSegment}
|
|
|
|
cost_segments::Vector{CostSegment}
|
|
|
|
min_uptime::Int
|
|
|
|
min_uptime::Int
|
|
|
|
min_downtime::Int
|
|
|
|
min_downtime::Int
|
|
|
|
ramp_up_limit::Float64
|
|
|
|
ramp_up_limit::Float64
|
|
|
@ -46,8 +46,8 @@ mutable struct Unit
|
|
|
|
shutdown_limit::Float64
|
|
|
|
shutdown_limit::Float64
|
|
|
|
initial_status::Union{Int,Nothing}
|
|
|
|
initial_status::Union{Int,Nothing}
|
|
|
|
initial_power::Union{Float64,Nothing}
|
|
|
|
initial_power::Union{Float64,Nothing}
|
|
|
|
provides_spinning_reserves::Array{Bool}
|
|
|
|
provides_spinning_reserves::Vector{Bool}
|
|
|
|
startup_categories::Array{StartupCategory}
|
|
|
|
startup_categories::Vector{StartupCategory}
|
|
|
|
end
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@ -58,41 +58,41 @@ mutable struct TransmissionLine
|
|
|
|
target::Bus
|
|
|
|
target::Bus
|
|
|
|
reactance::Float64
|
|
|
|
reactance::Float64
|
|
|
|
susceptance::Float64
|
|
|
|
susceptance::Float64
|
|
|
|
normal_flow_limit::Array{Float64}
|
|
|
|
normal_flow_limit::Vector{Float64}
|
|
|
|
emergency_flow_limit::Array{Float64}
|
|
|
|
emergency_flow_limit::Vector{Float64}
|
|
|
|
flow_limit_penalty::Array{Float64}
|
|
|
|
flow_limit_penalty::Vector{Float64}
|
|
|
|
end
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
mutable struct Reserves
|
|
|
|
mutable struct Reserves
|
|
|
|
spinning::Array{Float64}
|
|
|
|
spinning::Vector{Float64}
|
|
|
|
end
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
mutable struct Contingency
|
|
|
|
mutable struct Contingency
|
|
|
|
name::String
|
|
|
|
name::String
|
|
|
|
lines::Array{TransmissionLine}
|
|
|
|
lines::Vector{TransmissionLine}
|
|
|
|
units::Array{Unit}
|
|
|
|
units::Vector{Unit}
|
|
|
|
end
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
mutable struct PriceSensitiveLoad
|
|
|
|
mutable struct PriceSensitiveLoad
|
|
|
|
name::String
|
|
|
|
name::String
|
|
|
|
bus::Bus
|
|
|
|
bus::Bus
|
|
|
|
demand::Array{Float64}
|
|
|
|
demand::Vector{Float64}
|
|
|
|
revenue::Array{Float64}
|
|
|
|
revenue::Vector{Float64}
|
|
|
|
end
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
mutable struct UnitCommitmentInstance
|
|
|
|
mutable struct UnitCommitmentInstance
|
|
|
|
time::Int
|
|
|
|
time::Int
|
|
|
|
power_balance_penalty::Array{Float64}
|
|
|
|
power_balance_penalty::Vector{Float64}
|
|
|
|
units::Array{Unit}
|
|
|
|
units::Vector{Unit}
|
|
|
|
buses::Array{Bus}
|
|
|
|
buses::Vector{Bus}
|
|
|
|
lines::Array{TransmissionLine}
|
|
|
|
lines::Vector{TransmissionLine}
|
|
|
|
reserves::Reserves
|
|
|
|
reserves::Reserves
|
|
|
|
contingencies::Array{Contingency}
|
|
|
|
contingencies::Vector{Contingency}
|
|
|
|
price_sensitive_loads::Array{PriceSensitiveLoad}
|
|
|
|
price_sensitive_loads::Vector{PriceSensitiveLoad}
|
|
|
|
end
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|