pub fn add_asset_constraints(
problem: &mut RowProblem,
variables: &VariableMap,
model: &Model,
assets: &AssetPool,
year: u32,
) -> (Vec<(CommodityID, RegionID, TimeSliceSelection)>, Vec<(AssetID, TimeSliceID)>)
Expand description
Add asset-level constraints
Note: the ordering of constraints is important, as the dual values of the constraints must later be retrieved to calculate commodity prices.
§Arguments:
problem
- The optimisation problemvariables
- The variables in the problemmodel
- The modelassets
- The asset poolyear
- Current milestone year
§Returns:
- A vector of keys for commodity balance constraints
- A vector of keys for capacity constraints