1d_results.gms 13.6 KB
Newer Older
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
$ontext
This file is part of Backbone.

Backbone is free software: you can redistribute it and/or modify
it under the terms of the GNU Lesser General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

Backbone is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU Lesser General Public License for more details.

You should have received a copy of the GNU Lesser General Public License
along with Backbone.  If not, see <http://www.gnu.org/licenses/>.
$offtext

18
19
20
21
* =============================================================================
* --- Model Results Arrays ----------------------------------------------------
* =============================================================================

22
Parameters
23
24
25
26

* --- Cost Results ------------------------------------------------------------

    // Total Objective Function
27
    r_totalObj(t) "Total accumulated value of the objective function over all solves"
28

Topi Rasku's avatar
Topi Rasku committed
29
    // Unit Operational Cost Components
Topi Rasku's avatar
Topi Rasku committed
30
    r_gnuVOMCost(grid, node, unit, f, t) "Variable O&M costs for energy outputs (MEUR)"
Topi Rasku's avatar
Topi Rasku committed
31
    r_gnuTotalVOMCost(grid, node, unit) "Total gnu VOM costs over the simulation (MEUR)"
32
33
    r_uFuelEmissionCost(node, unit, f, t) "Unit fuel & emission costs for normal operation (MEUR)"
    r_uTotalFuelEmissionCost(commodity, unit) "Total unit fuel & emission costs over the simulation for normal operation (MEUR)"
Topi Rasku's avatar
Topi Rasku committed
34
    r_uStartupCost(unit, f, t) "Unit startup VOM, fuel, & emission costs (MEUR)"
35
    r_uShutdownCost(unit, f, t) "Unit startup VOM, fuel, & emission costs (MEUR)"
Topi Rasku's avatar
Topi Rasku committed
36
37
38
39
    r_uTotalStartupCost(unit) "Total unit startup costs over the simulation (MEUR)"

    // Nodal Cost Components
    r_gnStateSlackCost(grid, node, f, t) "Costs for states requiring slack (MEUR)"
Topi Rasku's avatar
Topi Rasku committed
40
    r_gnTotalStateSlackCost(grid, node) "Total costs for state slacks over the simulation (MEUR)"
Topi Rasku's avatar
Topi Rasku committed
41
    r_gnStorageValueChange(grid, node) "Change in storage values over the simulation (MEUR)"
42
43
    r_gnnVariableTransCost(grid, node_,node, f, t) "Variable Transfer costs (MEUR)"
    r_gnnTotalVariableTransCost(grid, node_, node) "Total Variable Transfer costs over the simulation (MEUR)"
Topi Rasku's avatar
Topi Rasku committed
44

Niina Helistö's avatar
Niina Helistö committed
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
    // Investment and Fixed Operation and Maintenance Cost Components
    r_gnuFOMCost(grid, node, unit) "Total gnu fixed O&M costs over the simulation (MEUR)"
    r_gnuUnitInvestmentCost(grid, node, unit) "Total unit investment costs over the simulation (MEUR)"
    r_gnnLinkInvestmentCost(grid, node, node) "Total transfer link investment costs over the simulation (MEUR)"

    // Realized System Operating Costs
    r_gnRealizedOperatingCost(grid, node, f, t) "Realized system operating costs in gn for each t (MEUR)"
    r_gnTotalRealizedOperatingCost(grid, node) "Total realized system operating costs in gn over the simulation (MEUR)"
    r_gnTotalRealizedOperatingCostShare(grid, node) "Total realized system operating cost gn/g shares over the simulation"
    r_gnTotalRealizedNetOperatingCost(grid, node) "Total realized system operating costs in gn over the simulation, minus the increase in storage values (MEUR)"
    r_gTotalRealizedOperatingCost(grid) "Total realized system operating costs in g over the simulation (MEUR)"
    r_gTotalRealizedNetOperatingCost(grid) "Total realized system operating costs in g over the simulation, minus the increase in storage values (MEUR)"
    r_totalRealizedOperatingCost "Total realized system operating costs over the simulation (MEUR)" / 0 /
    r_totalRealizedNetOperatingCost "Total realized system operating costs over the simulation (MEUR)" / 0 /

60
61
62
63
64
65
    // Realized System Fixed Costs
    r_gnTotalRealizedFixedCost(grid, node) "Total realized system fixed costs in gn over the simulation (MEUR)"
    r_gnTotalRealizedFixedCostShare(grid, node) "Total realized system fixed cost gn/g shares over the simulation"
    r_gTotalRealizedFixedCost(grid) "Total realized system fixed costs in g over the simulation (MEUR)"
    r_totalRealizedFixedCost "Total realized system fixed costs over the simulation (MEUR)" / 0 /

66
67
68
    // Realized System Costs
    r_gnTotalRealizedCost(grid, node) "Total realized system costs in gn over the simulation (MEUR)"
    r_gnTotalRealizedCostShare(grid, node) "Total realized system cost gn/g shares over the simulation"
69
    r_gnTotalRealizedNetCost(grid, node) "Total realized system costs in gn over the simulation, minus the increase in storage values (MEUR)"
70
    r_gTotalRealizedCost(grid) "Total realized system costs in g over the simulation (MEUR)"
71
    r_gTotalRealizedNetCost(grid) "Total realized system costs in g over the simulation, minus the increase in storage values (MEUR)"
72
    r_totalRealizedCost "Total realized system costs over the simulation (MEUR)" / 0 /
73
    r_totalRealizedNetCost "Total realized system costs over the simulation (MEUR)" / 0 /
74
75
76
77

* --- Node Results ------------------------------------------------------------

    // State variable results, required for model structure
78
    r_state(grid, node, f, t) "Node state at time step t"
79
    // State variable slack values
80
    r_stateSlack(grid, node, slack, f, t) "Note state slack at time step t"
81

82
    // Energy transfer and spill variable results
83
    r_transfer(grid, from_node, to_node, f, t) "Energy transfer (MW)"
84
85
    r_transferRightward(grid, from_node, to_node, f, t) "Energy transfer from first node to second node (MW)"
    r_transferLeftward(grid, to_node, from_node, f, t) "Energy transfer from second node to first node (MW)"
86
    r_spill(grid, node, f, t) "Spill of energy from storage node during time interval (MWh)"
87
88

    // Interesting node related results
89
    r_balanceMarginal(grid, node, f, t) "Marginal values of the q_balance equation"
90
91
92
93
    r_gnnTotalTransfer(grid, node, node) "Total amount of energy transferred between gnn over the simulation (MWh)"
    r_gnTotalSpill(grid, node) "Total spilled energy from gn over the simulation (MWh)"
    r_gnTotalSpillShare(grid, node) "Total spilled energy gn/g share"
    r_gTotalSpill(grid) "Total spilled energy from gn over the simulation (MWh)"
94

95
96
97
98
* --- Energy Generation/Consumption Results -----------------------------------

    // Results required for model structure
    r_gen(grid, node, unit, f, t) "Energy generation for a unit (MW)"
99
    r_gen_gnUnittype(grid, node, unittype) "Energy generation for each unittype in each node (MWh)"
100
101

    // Fuel use results
102
    r_fuelUse(node, unit, f, t) "Fuel use of units"
103
    r_genFuel(grid, node, *, f, t) "Energy generation/consumption based on fuels / flows (MW)"
104
    r_genUnittype(grid, node, unittype, f, t) "Energy generation/consumption for each unittype (MW)"
105
106
107
108
    r_gnTotalGenFuel(grid, node, commodity) "Total energy generation in gn per fuel over the simulation (MWh)"
    r_gnTotalGenFuelShare(grid, node, commodity) "Total energy generation fuel consumption gn/g share"
    r_gTotalGenFuel(grid, commodity) "Total energy generation in g per fuel over the simulation (MWh)"
    r_totalGenFuel(commodity) "Total overall energy generation/consumption per fuel over the simulation (MWh)"
109

110
111
112
113
114
115
116
117
118
119
120
    // Interesting energy generation results
    r_gnuTotalGen(grid, node, unit) "Total energy generation in gnu over the simulation (MWh)"
    r_gnuTotalGenShare(grid, node, unit) "Total energy generation gnu/gn share"
    r_gnTotalGen(grid, node) "Total energy generation in gn over the simulation (MWh)"
    r_gnTotalGenShare(grid, node) "Total energy generation gn/g share"
    r_gTotalGen(grid) "Total energy generation in g over the simulation (MWh)"

    // Approximate utilization rates
    r_gnuUtilizationRate(grid, node, unit) "Approximate utilization rates of gnus over the simulation"

    // Interesting energy consumption results
121
122
    r_gnConsumption(grid, node, f, t) "Consumption of energy in gn for each t (MWh)"
    r_gnTotalConsumption(grid, node) "Total consumption of energy in gn over the simulation (MWh)"
123
    r_gnTotalConsumptionShare(grid, node) "Total consumption gn/g share"
124
    r_gTotalConsumption(grid) "Total consumption of energy in g over the simulation (MWh)"
125

126
127
128
129
130
131
132

* --- Emissions Results -------------------------------------------------------

    // Unit level emissions
    r_emissions (node, emission, unit, f, t) "Emissions from units (tCO2)"

    // Emission sums
133
134
135
136
    r_nuTotalEmissions (node, unit, emission) "node unit total emissions (tCO2)"
    r_nTotalEmissions(node, emission) "node total emissions (tCO2)"
    r_uTotalEmissions(unit, emission) "unit total emissions (tCO2)"
    r_totalEmissions (emission) "Total emissions (tCO2)"
137
138


139
140
141
* --- Unit Online State Results -----------------------------------------------

    // Online results required for model structure
142
143
144
    r_online(unit, f, t) "Sub-units online"
    r_startup(unit, starttype, f, t) "Sub-units started up"
    r_shutdown(unit, f, t) "Sub-units shut down"
145
146
147

    // Interesting unit online results
    r_uTotalOnline(unit) "Total online sub-unit-hours of units over the simulation"
148
    r_uTotalOnlinePerUnit(unit) "Total unit online hours per sub-unit over the simulation"
149

150
151
152
153
    // Interesting unit startup and shutdown results
    r_uTotalStartup(unit, starttype) "Number of sub-unit startups over the simulation"
    r_uTotalShutdown(unit) "Number of sub-unit shutdowns over the simulation"

154
155
156
* --- Reserve Provision Results -----------------------------------------------

    // Reserve provision results required for model structure
157
158
159
160
    r_reserve(restype, up_down, grid, node, unit, f, t) "Unit capacity reserved for providing reserve of specific type (MW)"
    r_resTransferRightward(restype, up_down, grid, node, node, f, t) "Electricity transmission capacity from the first node to the second node reserved for providing reserves (MW)"
    r_resTransferLeftward(restype, up_down, grid, node, node, f, t) "Electricity transmission capacity from the second node to the first node reserved for providing reserves (MW)"
    r_reserve2Reserve(restype, up_down, grid, node, unit, restype, f, t) "Reserve provided for another reserve category (MW) (also included in r_reserve - this is just for debugging)"
161
162

    // Interesting reserve results
163
    r_resDemandMarginal(restype, up_down, group, f, t) "Marginal values of the q_resDemand equation"
164
165
166
167
    r_gnuTotalReserve(restype, up_down, grid, node, unit) "Total gnu reserve provision over the simulation (MW*h)"
    r_gnuTotalReserveShare(restype, up_down, grid, node, unit) "Total gnu/group reserve provision share over the simulation"
    r_groupTotalReserve(restype, up_down, group) "Total reserve provisions in groups over the simulation (MW*h)"
    r_resDemandLargestInfeedUnit(restype, up_down, group, f, t) "Reserve Demand from the loss of largest infeed unit"
168

169
170
171
* --- Investment Results ------------------------------------------------------

    // Interesting investment results
172
    r_invest(unit) "Number/amount of invested sub-units"
Niina Helistö's avatar
Niina Helistö committed
173
    r_investTransfer(grid, node, node, t) "Amount of invested transfer link capacity"
174

175
176
177
178
179
* --- Group results -----------------------------------------------------------

    // gnTotalgen in units that belong to gnuGroups over the simulation
    r_gnTotalGenGnuGroup(grid, node, group) "gnTotalGen in units that belong to gnuGroup (MWh)"

180
181
182
183
* --- Dummy Variable Results --------------------------------------------------

    // Results regarding solution feasibility
    r_qGen(inc_dec, grid, node, f, t) "Dummy energy generation (increase) or consumption (generation decrease) to ensure equation feasibility (MW)"
184
185
    r_gnTotalqGen(inc_dec, grid, node) "Total dummy energy generation/consumption in gn over the simulation (MWh)."
    r_gTotalqGen(inc_dec, grid) "Total dummy energy generation/consumption in g over the simulation (MWh)."
186
187
    r_qResDemand(restype, up_down, group, f, t) "Dummy to decrease demand for a reserve (MW) before reserve commitment"
    r_qResMissing(restype, up_down, group, f, t) "Dummy to decrease demand for a reserve (MW) after reserve commitment"
188
    r_groupTotalqResDemand(restype, up_down, group) "Total dummy reserve provisions in the group over the simulation"
189
    r_qCapacity(grid, node, f, t) "Dummy capacity to ensure capacity margin equation feasibility (MW)"
190
191
    r_solveStatus(t, solve_info) "Information about the solve"

Topi Rasku's avatar
Topi Rasku committed
192
; // END PARAMETER DECLARATION
193

194
195
Scalar r_realizedLast "Order of last realised time step";

196
197
* --- Initialize a few of the results arrays, required by model structure -----

198
Option clear = r_totalObj;
199
200
Option clear = r_state;
Option clear = r_online;
201
Option clear = r_reserve;
202
203
Option clear = r_resTransferRightward;
Option clear = r_resTransferLeftward;
204
205
Option clear = r_gen;
Option clear = r_realizedLast;
Niina Helistö's avatar
Niina Helistö committed
206
207
Option clear = r_startup;
Option clear = r_shutdown;
Niina Helistö's avatar
Niina Helistö committed
208
209
Option clear = r_invest;
Option clear = r_investTransfer;
210
Option clear = r_qResDemand;
211
Option clear = r_resDemandLargestInfeedUnit;
212

213
214
215
216
* =============================================================================
* --- Diagnostics Results Arrays ----------------------------------------------
* =============================================================================

217
218
// Only include these if '--diag=yes' given as a command line argument
$iftheni.diag '%diag%' == yes
219
Parameters
220
221
    d_cop(unit, f, t) "Coefficients of performance of conversion units"
    d_eff(unit, f, t) "Efficiency of generation units using fuel"
222
    d_capacityFactor(flow, node, s, f, t) "Diagnostic capacity factors (accounting for GAMS plotting error)"
223
    d_nodeState(grid, node, param_gnBoundaryTypes, s, f, t) "Diagnostic temperature forecasts (accounting for GAMS plotting error)"
224
    d_influx(grid, node, s, f, t) "Diagnostic influx forecasts (accounting for GAMS plotting error)"
225
    d_state(grid, node, scenario, f, t) "Diagnostic state results in each scenario"
226
    d_ts_scenarios(timeseries, *, node, scenario, f, t) "Diagnostic time series values in scenarios"
227
;
228
$endif.diag