Class ArbitrageStrategist
- java.lang.Object
-
- agents.flexibility.Strategist
-
- agents.storage.arbitrageStrategists.ArbitrageStrategist
-
- Direct Known Subclasses:
DynamicProgrammingStrategist
,FileDispatcher
,MultiAgentMedian
public abstract class ArbitrageStrategist extends Strategist
Creates arbitrage strategies for storage devices based on forecasts for merit-order or electricity prices- Author:
- Christoph Schimeczek
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
ArbitrageStrategist.StrategistType
Types of Strategists for storage operators
-
Field Summary
Fields Modifier and Type Field Description protected static org.slf4j.Logger
logger
Logs errors for this class and its subclassesstatic de.dlr.gitlab.fame.agent.input.Tree
parameters
Specific input parameters for storage strategistsprotected double[]
scheduledInitialInternalEnergyInMWH
Expected initial energy levels of the associated storage for each operation periodprotected Device
storage
The associated storage device this strategists plans forstatic de.dlr.gitlab.fame.agent.input.ParameterBuilder
StrategistTypeParam
General input parameter of storage strategists to determine its type-
Fields inherited from class agents.flexibility.Strategist
bidToleranceParam, demandScheduleInMWH, ERR_PROVIDE_FORECAST, ERR_UNKNOWN_STRATEGIST, ERR_UNKNOWN_UPDATE_TYPE, ERR_USE_MERIT_ORDER_FORECAST, ERR_USE_PRICE_FORECAST, forecastPeriodParam, forecastSteps, forecastUpdateTypeParam, OPERATION_PERIOD, priceScheduleInEURperMWH, scheduledBidPricesInEURperMWH, scheduleDurationParam, scheduleDurationPeriods
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
ArbitrageStrategist(de.dlr.gitlab.fame.agent.input.ParameterData input, Device storage)
CreateArbitrageStrategist
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected int
calcNumberOfEnergyStates(int numberOfTransitionStates)
Calculates number of energy states based on the storage capacity, its energy to power ratio and the number of discretisation steps used for internal energy changes.protected void
callOnSensitivity(MeritOrderSensitivity sensitivity, de.dlr.gitlab.fame.time.TimePeriod __)
optional action called on given MeritOrderSensitivitiesstatic ArbitrageStrategist
createStrategist(de.dlr.gitlab.fame.agent.input.ParameterData input, Device storage)
Create anArbitrageStrategist
- its actual type is determined based on the givenprotected double
ensureWithinEnergyBounds(double internalEnergyInMWH)
Corrects given internal energy value if it is below Zero or above maximum capacity.abstract double
getChargingPowerForecastInMW(de.dlr.gitlab.fame.time.TimeStamp targetTime)
Returns forecasted external charging power, if possible - otherwise throws a RuntimeEceptionprotected double[]
getInternalEnergySchedule()
-
Methods inherited from class agents.flexibility.Strategist
clearSensitivitiesBefore, createBlankSensitivity, createSchedule, getMissingForecastTimes, getSensitivityForPeriod, getTimesMissingElectricityForecasts, storeElectricityPriceForecast, storeMeritOrderForesight, updateBidSchedule, updateSchedule
-
-
-
-
Field Detail
-
parameters
public static final de.dlr.gitlab.fame.agent.input.Tree parameters
Specific input parameters for storage strategists
-
StrategistTypeParam
public static final de.dlr.gitlab.fame.agent.input.ParameterBuilder StrategistTypeParam
General input parameter of storage strategists to determine its type
-
logger
protected static org.slf4j.Logger logger
Logs errors for this class and its subclasses
-
scheduledInitialInternalEnergyInMWH
protected double[] scheduledInitialInternalEnergyInMWH
Expected initial energy levels of the associated storage for each operation period
-
storage
protected Device storage
The associated storage device this strategists plans for
-
-
Constructor Detail
-
ArbitrageStrategist
protected ArbitrageStrategist(de.dlr.gitlab.fame.agent.input.ParameterData input, Device storage) throws de.dlr.gitlab.fame.agent.input.ParameterData.MissingDataException
CreateArbitrageStrategist
- Parameters:
input
- parameters associated with strategistsstorage
- Device for which schedules are to be created- Throws:
de.dlr.gitlab.fame.agent.input.ParameterData.MissingDataException
- if any required input is missing
-
-
Method Detail
-
createStrategist
public static ArbitrageStrategist createStrategist(de.dlr.gitlab.fame.agent.input.ParameterData input, Device storage) throws de.dlr.gitlab.fame.agent.input.ParameterData.MissingDataException
Create anArbitrageStrategist
- its actual type is determined based on the given- Parameters:
input
- all parameters associated with strategistsstorage
- Device for which schedules are to be created- Returns:
- newly instantiated
ArbitrageStrategist
based on the given input - Throws:
de.dlr.gitlab.fame.agent.input.ParameterData.MissingDataException
- if any required input is missing
-
callOnSensitivity
protected void callOnSensitivity(MeritOrderSensitivity sensitivity, de.dlr.gitlab.fame.time.TimePeriod __)
Description copied from class:Strategist
optional action called on given MeritOrderSensitivities- Overrides:
callOnSensitivity
in classStrategist
- Parameters:
sensitivity
- to be modified__
- that the sensitivity is valid for
-
getInternalEnergySchedule
protected double[] getInternalEnergySchedule()
- Specified by:
getInternalEnergySchedule
in classStrategist
- Returns:
- array representing the expected internal energy state of the controlled flexibility
-
getChargingPowerForecastInMW
public abstract double getChargingPowerForecastInMW(de.dlr.gitlab.fame.time.TimeStamp targetTime)
Returns forecasted external charging power, if possible - otherwise throws a RuntimeEception- Parameters:
targetTime
- for which to provide the forecast- Returns:
- forecasted external charging power in MW
- Throws:
RuntimeException
- if this strategist cannot provide forecasts
-
calcNumberOfEnergyStates
protected int calcNumberOfEnergyStates(int numberOfTransitionStates)
Calculates number of energy states based on the storage capacity, its energy to power ratio and the number of discretisation steps used for internal energy changes. Logs warning if the discretised total capacity of the storage significantly deviates from its parameterised value.- Parameters:
numberOfTransitionStates
- number of states the (dis-)charging power is discretised with- Returns:
- numberOfTransitionStates (rounded to closest integer)
-
ensureWithinEnergyBounds
protected double ensureWithinEnergyBounds(double internalEnergyInMWH)
Corrects given internal energy value if it is below Zero or above maximum capacity.- Parameters:
internalEnergyInMWH
- to be corrected (if necessary)- Returns:
- internal energy value that is secured to lie within storage bounds
-
-