Uh oh!
There was an error while loading. Please reload this page.
DR revenue calculator - #59
Draft
arao53 wants to merge 4 commits into
Draft
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for freeto join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
EECO will be responsible for demand response constraint building + revenue calculations for flex-pse. This PR focuses on building the Pyomo support for DR constraints and revenue calculations on a model given a set of events, a payment function, and a power consumption baseline/variable.
To be merged, will need to be extended to refine the approach for pyomo/numpy support and add CVXPy support.
Build/calculate DR Revenue
Functions to build DR revenue from events, calculate DR revenue given events and power consumption trajectory, and supporting functions to build, monitor, and evaluate events, with or without models.
Baselining:
BaselineMethod: Creates a way to do standard baselining based on historic and modeled power consumption and a few different strategies. This base class can be extended to represent a wide variety of strategies by specific utility or aggregator programs. The default is to average the last N similar weekdays, then scale by a day-of adjustment based on the hours right before the event. Defaults match PG&E's Capacity Bidding Program (10 days, 3-hour adjustment).TopUsageDaysBaseline: Pick the highest-usage days instead of the most recent ones.FixedLevelBaseline: Ignore historic power, just use an agreed upon constant baseline.UnilateralInterruptionBaseline: Limit the load to a pre-determined a set levelPayment
PaymentStructure: This class creates a modeling abstraction to bridge baseline power, facility power consumption, and DR revenue. The default is a piecewise-linear payment based on the fraction of the bid actually delivered. Regions are plain dicts, so a schedule can express real tariff shapes — a penalty for under-delivery, a cap where extra reduction earns nothing.CapacityEnergyPayment: adds a flat $/kWh payment to the amount of energy shed + the default power-based revenue.MarketIndexedPayment: looks the capacity price up at calculation time (market or index prices are not known when the event is defined)All baselining and payment classes/subclasses pair with one another.