Skip to content

Commit

Permalink
afc/added and tested fix value ff for 2T HVDC
Browse files Browse the repository at this point in the history
  • Loading branch information
alefcastelli committed Dec 2, 2023
1 parent 43585c7 commit 7624278
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 5 deletions.
2 changes: 2 additions & 0 deletions src/devices_models/device_constructors/branch_constructor.jl
Original file line number Diff line number Diff line change
Expand Up @@ -635,6 +635,7 @@ function construct_device!(
model,
network_model,
)
add_feedforward_arguments!(container, model, devices)
return
end

Expand Down Expand Up @@ -668,6 +669,7 @@ function construct_device!(
add_constraints!(container, HVDCPowerBalance, devices, model, network_model)
add_constraints!(container, HVDCDirection, devices, model, network_model)
add_constraint_dual!(container, sys, model)
add_feedforward_constraints!(container, model, devices)
return
end

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -61,8 +61,4 @@ function construct_device!(
model::DeviceModel{PSY.TModelHVDCLine, LossLessLine},
::NetworkModel{<:PM.AbstractActivePowerModel},
)
devices = get_available_components(PSY.TModelHVDCLine, sys)
add_feedforward_constraints!(container, model, devices)
objective_function!(container, devices, model, get_network_formulation(network_model))
add_constraint_dual!(container, sys, model)
end
2 changes: 1 addition & 1 deletion src/devices_models/devices/AC_branches.jl
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ get_variable_binary(::FlowActivePowerVariable, ::Type{<:PSY.ACBranch}, ::Abstrac
get_variable_binary(::PhaseShifterAngle, ::Type{PSY.PhaseShiftingTransformer}, ::AbstractBranchFormulation,) = false

get_parameter_multiplier(::FixValueParameter, ::PSY.ACBranch, ::StaticBranch) = 1.0
get_variable_multiplier(::PhaseShifterAngle, d::PSY.PhaseShiftingTransformer, ::PhaseAngleControl) = 1.0/PSY.get_x(d)
get_variable_multiplier(::PhaseShifterAngle, ::PSY.PhaseShiftingTransformer, ::PhaseAngleControl) = 1.0/PSY.get_x(d)

get_initial_conditions_device_model(::OperationModel, ::DeviceModel{T, <:AbstractBranchFormulation}) where {T <: PSY.ACBranch} = DeviceModel(T, StaticBranch)
get_initial_conditions_device_model(::OperationModel, ::DeviceModel{T, <:AbstractBranchFormulation},) where {T <: PSY.MonitoredLine} = DeviceModel(T, StaticBranchUnbounded)
Expand Down
1 change: 1 addition & 0 deletions src/devices_models/devices/TwoTerminalDC_branches.jl
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ get_variable_binary(

get_variable_multiplier(::FlowActivePowerVariable, ::Type{<:PSY.TwoTerminalHVDCLine}, _) =
NaN
get_parameter_multiplier(::FixValueParameter, ::PSY.TwoTerminalHVDCLine, ::AbstractTwoTerminalDCLineFormulation) = 1.0

get_variable_multiplier(
::FlowActivePowerFromToVariable,
Expand Down

0 comments on commit 7624278

Please sign in to comment.