diff --git a/CHANGELOG.md b/CHANGELOG.md index e70d92361a..909f8a14cd 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -33,6 +33,8 @@ the charging capacity of the storage component in VRE_STOR (#770). with Julia v1.11 (#785). - Fixed cost calculation in `write_costs.jl` when no resources are present in a zone. (#796) +- Added `eTotalCMaxCapSlack` to calculation of `cUnmetPolicyPenalty` in +`write_costs.jl` (#806). ## [0.4.1] - 2024-08-20 diff --git a/src/write_outputs/write_costs.jl b/src/write_outputs/write_costs.jl index 70bda8516e..9193865911 100644 --- a/src/write_outputs/write_costs.jl +++ b/src/write_outputs/write_costs.jl @@ -127,6 +127,10 @@ function write_costs(path::AbstractString, inputs::Dict, setup::Dict, EP::Model) dfCost[9, 2] += value(EP[:eTotalCMinCapSlack]) end + if haskey(inputs, "MaxCapPriceCap") + dfCost[9, 2] += value(EP[:eTotalCMaxCapSlack]) + end + if haskey(inputs, "H2DemandPriceCap") dfCost[9, 2] += value(EP[:eTotalCH2DemandSlack]) end