Fuel Price
E4ST.FuelPrice
— TypeFuelPrice(;file) <: Modification
FuelPrice is a Modification
allowing users to specify fuel prices for different fuels by region. If multiple steps and quantities are given, the fuel price for a given region will be computed endogenously.
modify_raw_data!(mod::FuelPrice, config, data)
modify_setup_data!(mod::FuelPrice, config, data)
modify_model!(mod::FuelPrice, config, data, model)
modify_results!(mod::FuelPrice, config, data)
To adjust price by hour or year, see AdjustHourly
or AdjustYearly
.
E4ST.modify_raw_data!
— Methodmodify_raw_data!(mod::FuelPrice, config, data)
Read table from mod.file
into data[:fuel_price]
E4ST.modify_setup_data!
— Methodmodify_setup_data!(mod::FuelPrice, config, data)
Zero out the fuel_price
column of the gen
table, as it will get overwritten later by this Modification. This is to avoid double-counting the fuel cost.
E4ST.modify_model!
— Methodmodify_model!(mod::FuelPrice, config, data, model)
- Make
data[:fuel_markets]
to keep track of each of the fuel markets - Add variable
fuel_sold[fuel_price_idx, yr_idx, hr_idx]
: total fuel sold at each price step for each time interval - Add expression
fuel_used[fuel_market_idx, yr_idx, hr_idx]
: total fuel used by generators for each market region for each time interval - Add expression
fuel_price_obj[fuel_market_idx, yr_idx, hr_idx]
: total cost of the fuel, added to the objective. - Add constraint
cons_fuel_sold[fuel_price_idx, yr_idx]
: constrain the totalfuel_sold
in each year to be ≤ yearly quantity - Add constraint
cons_fuel_bal[fuel_market_idx, yr_idx, hr_idx]
: constrain the amount of fuel sold in each market region to equal the amount of fuel used in each market region.
E4ST.modify_results!
— Methodmodify_results!(mod::FuelPrice, config, data)
- Calculate the clearing price for each market region for each fuel type.
- Equal to the shadow price of
cons_fuel_sold
for the cheapest fuel price step in the region plus the cheapest fuel price - Add it to
fuel_markets.clearing_price
column - Update
gen.fuel_price
column to use the clearing price (multiplied by theheat_rate
column)
- Equal to the shadow price of
E4ST.summarize_table
— Methodsummarize_table(::Val{:fuel_price})
column_name | data_type | unit | required | description |
---|---|---|---|---|
genfuel | String | E4ST.NA | true | The type of fuel that the price applies for. i.e. ng or coal |
area | String | E4ST.NA | true | The area that the price applies for i.e. country . Leave blank if grid-wide |
subarea | String | E4ST.NA | true | The subarea that the price applies for i.e. narnia . Leave blank if grid-wide |
filter_ | String | E4ST.NA | false | I.e. filter1 , filter2 , etc. Other filter conditions that the price applies for, see parse_comparison for ideas |
price | Float64 | E4ST.DollarsPerMMBtu | true | The price of 1 MMBtu of fuel |
quantity | Float64 | E4ST.MMBtu | true | The number of MMBtu of the fuel available at the price in each year. Set to Inf for unlimited. |