NREL-Sienna / PowerSystems.jl

Data structures in Julia to enable power systems analysis. Part of the Scalable Integrated Infrastructure Planning Initiative at the National Renewable Energy Lab.
https://www.nrel.gov/analysis/sienna.html
BSD 3-Clause "New" or "Revised" License
299 stars 71 forks source link

Fuel Cost Interface, Including Time Series #1101

Closed GabrielKS closed 2 months ago

GabrielKS commented 2 months ago

This PR implements an interface to get at the fuel cost fields within the new cost structs. I took inspiration from the existing variable cost time series interface for MarketBidCost. Depends on https://github.com/NREL-Sienna/PowerSystems.jl/pull/1100, that should be merged first.

GabrielKS commented 2 months ago

@jd-lara the existing get_variable_cost function in cost_function_timeseries.jl for MarketBidCost calls get_time_series_array, whereas it makes more sense to me to just return the time series itself, since that's what the user must pass to the setter. I have copied this interface for the fuel cost interface, but if you agree we can change both getters to return the time series.

jd-lara commented 2 months ago

@jd-lara the existing get_variable_cost function in cost_function_timeseries.jl for MarketBidCost calls get_time_series_array, whereas it makes more sense to me to just return the time series itself, since that's what the user must pass to the setter. I have copied this interface for the fuel cost interface, but if you agree we can change both getters to return the time series.

What do you mean the time series itself?

GabrielKS commented 2 months ago

What do you mean the time series itself?

A (subtype of) TimeSeriesData rather than a TimeArray.

After our DM discussion, I think the best course of action is to keep this as it is (asymmetric but convenient interface) for now and then when I update the market bid cost time series interface I can make a more informed decision. If it ends up making sense to make that one symmetric, I'll change this one to match.

jd-lara commented 2 months ago

What do you mean the time series itself?

A (subtype of) TimeSeriesData rather than a TimeArray.

After our DM discussion, I think the best course of action is to keep this as it is (asymmetric but convenient interface) for now and then when I update the market bid cost time series interface I can make a more informed decision. If it ends up making sense to make that one symmetric, I'll change this one to match.

Lets add this to the list of pending items