Commit ee281454 authored by Niina Helistö's avatar Niina Helistö
Browse files

Removing q_resDemandLargestInfeedTransferUp and...

Removing q_resDemandLargestInfeedTransferUp and q_resDemandLargestInfeedTransferDown, as q_resDemandLargestInfeedTransfer can handle both.
parent 266858a8
......@@ -26,8 +26,6 @@ Model building /
* q_resDemandLargestInfeedUnit
* q_rateOfChangeOfFrequencyUnit
* q_rateOfChangeOfFrequencyTransfer
* q_resDemandLargestInfeedTransferUp // Could we remove this contraint?
* q_resDemandLargestInfeedTransferDown // Could we remove this contraint?
* q_resDemandLargestInfeedTransfer
// Unit Operation
......
......@@ -26,8 +26,6 @@ Model invest /
q_resDemandLargestInfeedUnit // Use with extra caution if there are several sub-units
q_rateOfChangeOfFrequencyUnit // Use with extra caution if there are several sub-units
q_rateOfChangeOfFrequencyTransfer
* q_resDemandLargestInfeedTransferUp // Could we remove this contraint?
* q_resDemandLargestInfeedTransferDown // Could we remove this contraint?
q_resDemandLargestInfeedTransfer
// Unit Operation
......
......@@ -26,8 +26,6 @@ Model schedule /
q_resDemandLargestInfeedUnit // Use with extra caution if there are several sub-units
q_rateOfChangeOfFrequencyUnit // Use with extra caution if there are several sub-units
q_rateOfChangeOfFrequencyTransfer
* q_resDemandLargestInfeedTransferUp // Could we remove this contraint?
* q_resDemandLargestInfeedTransferDown // Could we remove this contraint?
q_resDemandLargestInfeedTransfer
// Unit Operation
......
......@@ -99,6 +99,10 @@ v_help_inc
q_obj
q_balance
q_resDemand
q_resDemandLargestInfeedUnit
q_rateOfChangeOfFrequencyUnit
q_rateOfChangeOfFrequencyTransfer
q_resDemandLargestInfeedTransfer
// Unit Operation
q_maxDownward
......
......@@ -57,8 +57,6 @@ equations
q_resDemandLargestInfeedUnit(restype, up_down, group, unit, s, f, t) "N-1 reserve for units"
q_rateOfChangeOfFrequencyUnit(group, unit, s, f, t) "N-1 unit contingency with ROCOF"
q_rateOfChangeOfFrequencyTransfer(group, grid, node, node, s, f, t) "N-1 transmission line contingency with ROCOF"
q_resDemandLargestInfeedTransferUp(restype, up_down, group, grid, node, node, s, f, t) "N-1 up reserve for transmission lines"
q_resDemandLargestInfeedTransferDown(restype, up_down, group, grid, node, node, s, f, t) "N-1 down reserve for transmission lines"
q_resDemandLargestInfeedTransfer(restype, up_down, group, grid, node, node, s, f, t) "N-1 up/down reserve for transmission lines"
// Unit Operation
q_maxDownward(grid, node, unit, mType, s, f, t) "Downward commitments (v_gen and online v_reserve) will not undercut minimum (online) production capacity (+) or maximum (online) consumption capacity (-)"
......
......@@ -342,188 +342,6 @@ q_rateOfChangeOfFrequencyTransfer(group, gn2n(grid, node_, node_fail), sft(s, f,
] // END * p_groupPolicy
;
* --- N-1 Upward reserve demand due to a possibility that an interconnector that is transferring power to the node group fails -------------------------------------------------
// NOTE! Currently, there are multiple identical instances of the reserve balance equation being generated for each forecast branch even when the reserves are committed and identical between the forecasts.
// NOTE! This could be solved by formulating a new "ft_reserves" set to cover only the relevant forecast-time steps, but it would possibly make the reserves even more confusing.
q_resDemandLargestInfeedTransferUp(restypeDirectionGroup(restype, 'up', group), gn2n(grid, node_, node_fail), sft(s, f, t))
${ ord(t) < tSolveFirst + p_groupReserves(group, restype, 'reserve_length')
and not [ restypeReleasedForRealization(restype)
and sft_realized(s, f, t)]
and gn2n_directional(grid, node_, node_fail)
and [ (gnGroup(grid, node_, group) and not gnGroup(grid, node_fail, group)) // only interconnectors where one end is 'inside the group'
or (gnGroup(grid, node_fail, group) and not gnGroup(grid, node_, group)) // and the other end is 'outside the group'
]
and [ p_gnn(grid, node_, node_fail, 'portion_of_transfer_to_reserve')
or p_gnn(grid, node_fail, node_, 'portion_of_transfer_to_reserve')
]
and p_groupReserves3D(group, restype, 'up', 'LossOfTrans')
} ..
// Reserve provision by capable units on this group
+ sum(gnuft(grid, node, unit, f, t)${ gnGroup(grid, node, group)
and gnuRescapable(restype, 'up', grid, node, unit)
},
+ v_reserve(restype, 'up', grid, node, unit, s, f+df_reserves(grid, node, restype, f, t), t)
* [ // Account for reliability of reserves
+ 1${sft_realized(s, f+df_reserves(grid, node, restype, f, t), t)} // reserveReliability limits the reliability of reserves locked ahead of time.
+ p_gnuReserves(grid, node, unit, restype, 'reserveReliability')${not sft_realized(s, f+df_reserves(grid, node, restype, f, t), t)}
] // END * v_reserve
) // END sum(gnuft)
// Reserve provision from other reserve categories when they can be shared
+ sum((gnuft(grid, node, unit, f, t), restype_)${ gnGroup(grid, node, group)
and p_gnuRes2Res(grid, node, unit, restype_, 'up', restype)
},
+ v_reserve(restype_, 'up', grid, node, unit, s, f+df_reserves(grid, node, restype_, f, t), t)
* p_gnuRes2Res(grid, node, unit, restype_, 'up', restype)
* [ // Account for reliability of reserves
+ 1${sft_realized(s, f+df_reserves(grid, node, restype, f, t), t)} // reserveReliability limits the reliability of reserves locked ahead of time.
+ p_gnuReserves(grid, node, unit, restype, 'reserveReliability')${not sft_realized(s, f+df_reserves(grid, node, restype, f, t), t)}
* p_gnuReserves(grid, node, unit, restype_, 'reserveReliability')
] // END * v_reserve
) // END sum(gnuft)
// Reserve provision to this group via transfer links
+ sum(gn2n_directional(grid, from_node, to_node)${ gnGroup(grid, to_node, group)
and not gnGroup(grid, from_node, group)
and not (from_node(node_) and to_node(node_fail)) // excluding the failing link
and restypeDirectionGridNodeNode(restype, 'up', grid, from_node, to_node)
},
+ (1 - p_gnn(grid, from_node, to_node, 'transferLoss') )
* v_resTransferRightward(restype, 'up', grid, from_node, to_node, s, f+df_reserves(grid, from_node, restype, f, t), t)
) // END sum(gn2n_directional)
+ sum(gn2n_directional(grid, to_node, from_node)${ gnGroup(grid, to_node, group)
and not gnGroup(grid, from_node, group)
and not (to_node(node_) and from_node(node_fail)) // excluding the failing link
and restypeDirectionGridNodeNode(restype, 'up', grid, from_node, to_node)
},
+ (1 - p_gnn(grid, to_node, from_node, 'transferLoss') )
* v_resTransferLeftward(restype, 'up', grid, to_node, from_node, s, f+df_reserves(grid, from_node, restype, f, t), t)
) // END sum(gn2n_directional)
=G=
// Demand for upward reserve due to potential interconnector failures (sudden loss of import)
+ p_gnn(grid, node_, node_fail, 'portion_of_transfer_to_reserve')${gnGroup(grid, node_fail, group)}
* v_transferRightward(grid, node_, node_fail, s, f, t) // multiply with efficiency?
+ p_gnn(grid, node_fail, node_, 'portion_of_transfer_to_reserve')${gnGroup(grid, node_, group)}
* v_transferLeftward(grid, node_, node_fail, s, f, t) // multiply with efficiency?
// Reserve provisions to other groups via transfer links
+ sum(gn2n_directional(grid, from_node, to_node)${ gnGroup(grid, from_node, group)
and not gnGroup(grid, to_node, group)
and not (from_node(node_) and to_node(node_fail)) // excluding the failing link
and restypeDirectionGridNodeNode(restype, 'up', grid, from_node, to_node)
},
// Reserve transfers to other nodes increase the reserve need of the present node
+ v_resTransferRightward(restype, 'up', grid, from_node, to_node, s, f+df_reserves(grid, from_node, restype, f, t), t)
) // END sum(gn2n_directional)
+ sum(gn2n_directional(grid, to_node, from_node)${ gnGroup(grid, from_node, group)
and not gnGroup(grid, to_node, group)
and not (to_node(node_) and from_node(node_fail)) // excluding the failing link
and restypeDirectionGridNodeNode(restype, 'up', grid, from_node, to_node)
},
// Reserve transfers to other nodes increase the reserve need of the present node
+ v_resTransferLeftward(restype, 'up', grid, to_node, from_node, s, f+df_reserves(grid, from_node, restype, f, t), t)
) // END sum(gn2n_directional)
// Reserve demand feasibility dummy variables
- vq_resDemand(restype, 'up', group, s, f+df_reservesGroup(group, restype, f, t), t)
- vq_resMissing(restype, 'up', group, s, f+df_reservesGroup(group, restype, f, t), t)${ft_reservesFixed(group, restype, f+df_reservesGroup(group, restype, f, t), t)}
;
* --- N-1 Downward reserve demand due to a possibility that an interconnector that is transferring power from the node group fails -------------------------------------------------
// NOTE! Currently, there are multiple identical instances of the reserve balance equation being generated for each forecast branch even when the reserves are committed and identical between the forecasts.
// NOTE! This could be solved by formulating a new "ft_reserves" set to cover only the relevant forecast-time steps, but it would possibly make the reserves even more confusing.
q_resDemandLargestInfeedTransferDown(restypeDirectionGroup(restype, 'down', group), gn2n(grid, node_, node_fail), sft(s, f, t))
${ ord(t) < tSolveFirst + p_groupReserves(group, restype, 'reserve_length')
and not [ restypeReleasedForRealization(restype)
and sft_realized(s, f, t)]
and gn2n_directional(grid, node_, node_fail)
and [ (gnGroup(grid, node_, group) and not gnGroup(grid, node_fail, group)) // only interconnectors where one end is 'inside the group'
or (gnGroup(grid, node_fail, group) and not gnGroup(grid, node_, group)) // and the other end is 'outside the group'
]
and [ p_gnn(grid, node_, node_fail, 'portion_of_transfer_to_reserve')
or p_gnn(grid, node_fail, node_, 'portion_of_transfer_to_reserve')
]
and p_groupReserves3D(group, restype, 'down', 'LossOfTrans')
} ..
// Reserve provision by capable units on this group
+ sum(gnuft(grid, node, unit, f, t)${ gnGroup(grid, node, group)
and gnuRescapable(restype, 'down', grid, node, unit)
},
+ v_reserve(restype, 'down', grid, node, unit, s, f+df_reserves(grid, node, restype, f, t), t)
* [ // Account for reliability of reserves
+ 1${sft_realized(s, f+df_reserves(grid, node, restype, f, t), t)} // reserveReliability limits the reliability of reserves locked ahead of time.
+ p_gnuReserves(grid, node, unit, restype, 'reserveReliability')${not sft_realized(s, f+df_reserves(grid, node, restype, f, t), t)}
] // END * v_reserve
) // END sum(gnuft)
// Reserve provision from other reserve categories when they can be shared
+ sum((gnuft(grid, node, unit, f, t), restype_)${ gnGroup(grid, node, group)
and p_gnuRes2Res(grid, node, unit, restype_, 'down', restype)
},
+ v_reserve(restype_, 'down', grid, node, unit, s, f+df_reserves(grid, node, restype_, f, t), t)
* p_gnuRes2Res(grid, node, unit, restype_, 'down', restype)
* [ // Account for reliability of reserves
+ 1${sft_realized(s, f+df_reserves(grid, node, restype, f, t), t)} // reserveReliability limits the reliability of reserves locked ahead of time.
+ p_gnuReserves(grid, node, unit, restype, 'reserveReliability')${not sft_realized(s, f+df_reserves(grid, node, restype, f, t), t)}
* p_gnuReserves(grid, node, unit, restype_, 'reserveReliability')
] // END * v_reserve
) // END sum(gnuft)
// Reserve provision to this group via transfer links
+ sum(gn2n_directional(grid, from_node, to_node)${ gnGroup(grid, to_node, group)
and not gnGroup(grid, from_node, group)
and not (from_node(node_) and to_node(node_fail)) // excluding the failing link
and restypeDirectionGridNodeNode(restype, 'down', grid, from_node, to_node)
},
+ (1 - p_gnn(grid, from_node, to_node, 'transferLoss') )
* v_resTransferRightward(restype, 'down', grid, from_node, to_node, s, f+df_reserves(grid, from_node, restype, f, t), t)
) // END sum(gn2n_directional)
+ sum(gn2n_directional(grid, to_node, from_node)${ gnGroup(grid, to_node, group)
and not gnGroup(grid, from_node, group)
and not (to_node(node_) and from_node(node_fail)) // excluding the failing link
and restypeDirectionGridNodeNode(restype, 'down', grid, from_node, to_node)
},
+ (1 - p_gnn(grid, to_node, from_node, 'transferLoss') )
* v_resTransferLeftward(restype, 'down', grid, to_node, from_node, s, f+df_reserves(grid, from_node, restype, f, t), t)
) // END sum(gn2n_directional)
=G=
// Demand for downward reserve due to potential interconnector failures (sudden loss of export)
+ p_gnn(grid, node_, node_fail, 'portion_of_transfer_to_reserve')${gnGroup(grid, node_, group)}
* v_transferRightward(grid, node_, node_fail, s, f, t)
+ p_gnn(grid, node_fail, node_, 'portion_of_transfer_to_reserve')${gnGroup(grid, node_fail, group)}
* v_transferLeftward(grid, node_, node_fail, s, f, t)
// Reserve provisions to other groups via transfer links
+ sum(gn2n_directional(grid, from_node, to_node)${ gnGroup(grid, from_node, group)
and not gnGroup(grid, to_node, group)
and not (from_node(node_) and to_node(node_fail)) // excluding the failing link
and restypeDirectionGridNodeNode(restype, 'down', grid, from_node, to_node)
},
// Reserve transfers to other nodes increase the reserve need of the present node
+ v_resTransferRightward(restype, 'down', grid, from_node, to_node, s, f+df_reserves(grid, from_node, restype, f, t), t)
) // END sum(gn2n_directional)
+ sum(gn2n_directional(grid, to_node, from_node)${ gnGroup(grid, from_node, group)
and not gnGroup(grid, to_node, group)
and not (to_node(node_) and from_node(node_fail)) // excluding the failing link
and restypeDirectionGridNodeNode(restype, 'down', grid, from_node, to_node)
},
// Reserve transfers to other nodes increase the reserve need of the present node
+ v_resTransferLeftward(restype, 'down', grid, to_node, from_node, s, f+df_reserves(grid, from_node, restype, f, t), t)
) // END sum(gn2n_directional)
// Reserve demand feasibility dummy variables
- vq_resDemand(restype, 'down', group, s, f+df_reservesGroup(group, restype, f, t), t)
- vq_resMissing(restype, 'down', group, s, f+df_reservesGroup(group, restype, f, t), t)${ft_reservesFixed(group, restype, f+df_reservesGroup(group, restype, f, t), t)}
;
* --- N-1 reserve demand due to a possibility that an interconnector that is transferring power to/from the node group fails -------------------------------------------------
// NOTE! Currently, there are multiple identical instances of the reserve balance equation being generated for each forecast branch even when the reserves are committed and identical between the forecasts.
// NOTE! This could be solved by formulating a new "ft_reserves" set to cover only the relevant forecast-time steps, but it would possibly make the reserves even more confusing.
......
......@@ -67,8 +67,6 @@ Option clear = q_resDemand;
Option clear = q_resDemandLargestInfeedUnit;
Option clear = q_rateOfChangeOfFrequencyUnit;
Option clear = q_rateOfChangeOfFrequencyTransfer;
Option clear = q_resDemandLargestInfeedTransferUp;
Option clear = q_resDemandLargestInfeedTransferDown;
Option clear = q_resDemandLargestInfeedTransfer;
// Unit Operation
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment