Class Strategist

  • Direct Known Subclasses:
    ArbitrageStrategist, ElectrolyzerStrategist

    public abstract class Strategist
    extends Object
    Base class for strategists that operate some kind of flexibility, e.g., an energy storage or flexible electrolysis
    Christoph Schimeczek
    • Field Detail


        protected static final String ERR_USE_MERIT_ORDER_FORECAST
        Error message if used Strategist type cannot process merit order forecast
        See Also:
        Constant Field Values

        public static final de.dlr.gitlab.fame.time.TimeSpan OPERATION_PERIOD
        Hard coded time granularity of Strategist
      • forecastSteps

        protected final int forecastSteps
        number of time steps of available forecasts
      • scheduleDurationPeriods

        protected final int scheduleDurationPeriods
        number of time steps of the created schedules
      • demandScheduleInMWH

        protected double[] demandScheduleInMWH
        schedule for the electricity demand (or charging) schedule
      • priceScheduleInEURperMWH

        protected double[] priceScheduleInEURperMWH
        schedule for the expected electricity prices
      • scheduledBidPricesInEURperMWH

        protected double[] scheduledBidPricesInEURperMWH
        schedule for the electricity bid prices
      • forecastPeriodParam

        public static final de.dlr.gitlab.fame.agent.input.ParameterBuilder forecastPeriodParam
        Strategist input parameter: number of time steps of the used forecast
      • scheduleDurationParam

        public static final de.dlr.gitlab.fame.agent.input.ParameterBuilder scheduleDurationParam
        Strategist input parameter: number of time steps of the created schedules
      • bidToleranceParam

        public static final de.dlr.gitlab.fame.agent.input.ParameterBuilder bidToleranceParam
        Strategist input parameter: safety margin at bidding
    • Constructor Detail

      • Strategist

        protected Strategist​(de.dlr.gitlab.fame.agent.input.ParameterData input)
                      throws de.dlr.gitlab.fame.agent.input.ParameterData.MissingDataException
        Creates new Strategist based on the given input
        input - parameters associated with strategists
        de.dlr.gitlab.fame.agent.input.ParameterData.MissingDataException - if any required input is missing
    • Method Detail

      • clearSensitivitiesBefore

        public void clearSensitivitiesBefore​(de.dlr.gitlab.fame.time.TimeStamp time)
        Removes any stored MeritOrderSensitivity whose associated TimePeriod ends before the given time
        time - limiting TimeStamp - earlier events to be deleted
      • getTimesMissingElectricityForecasts

        public ArrayList<de.dlr.gitlab.fame.time.TimeStamp> getTimesMissingElectricityForecasts​(de.dlr.gitlab.fame.time.TimePeriod firstTime)
        Returns list of times at which electricity price forecasts are missing needed for schedule planning
        firstTime - first time period to be covered by a created schedule
        List of TimeStamps at which MeritOrderSensitivity is not yet defined
      • getMissingForecastTimes

        protected ArrayList<de.dlr.gitlab.fame.time.TimeStamp> getMissingForecastTimes​(TreeMap<de.dlr.gitlab.fame.time.TimePeriod,​?> map,
                                                                                       de.dlr.gitlab.fame.time.TimePeriod firstTime)
        Returns list of times at which given TreeMap misses entries needed for schedule planning
        map - to be inspected for existing TimeSegment keys
        firstTime - first time period to be covered by a created schedule
        List of TimeStamps at which given map misses entries
      • storeMeritOrderForesight

        public void storeMeritOrderForesight​(de.dlr.gitlab.fame.time.TimePeriod timePeriod,
                                             SupplyOrderBook supplyForecast,
                                             DemandOrderBook demandForecast)
        Stores given supply and demand bid forecasts for the associated TimePeriod: merit-order forecasting method
        timePeriod - associated with the forecast data
        supplyForecast - forecasted supply OrderBook
        demandForecast - forecasted demand OrderBook
      • callOnSensitivity

        protected void callOnSensitivity​(MeritOrderSensitivity sensitivity)
        optional action called on given MeritOrderSensitivities
        sensitivity - to be modified
      • storeElectricityPriceForecast

        public void storeElectricityPriceForecast​(de.dlr.gitlab.fame.time.TimePeriod timePeriod,
                                                  double electricityPriceForecastInEURperMWH)
        Stores given electricity price forecast for the associated TimePeriod: price-forecasting method
        timePeriod - associated with the forecast data
        electricityPriceForecastInEURperMWH - forecast for the electricity price in EUR per MWh
      • getSensitivityForPeriod

        protected MeritOrderSensitivity getSensitivityForPeriod​(de.dlr.gitlab.fame.time.TimePeriod timePeriod)
        Returns MeritOrderSensitivity associated with the given TimePeriod
        timePeriod - to search for associated MeritOrderSensitivity
        MeritOrderSensitivity associated with the given TimePeriod
      • createSchedule

        public DispatchSchedule createSchedule​(de.dlr.gitlab.fame.time.TimePeriod timePeriod)
        Creates a DispatchSchedule for the connected flexibility
        timePeriod - first TimePeriod element of the schedule to be created
        created DispatchSchedule for the specified TimePeriod
      • updateBidSchedule

        protected void updateBidSchedule()
        Updates the bid schedules considering safety margins for the bid prices and market price limits
      • updateSchedule

        protected abstract void updateSchedule​(de.dlr.gitlab.fame.time.TimePeriod timePeriod)
        Updates schedule arrays starting at the given TimePeriod with the given initial energy level
        timePeriod - first period of the schedule to be created
      • getInternalEnergySchedule

        protected abstract double[] getInternalEnergySchedule()
        array representing the expected internal energy state of the controlled flexibility