Class Strategist

    • Field Detail

      • ERR_USE_MERIT_ORDER_FORECAST

        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
      • ERR_UNKNOWN_UPDATE_TYPE

        protected static final String ERR_UNKNOWN_UPDATE_TYPE
        Error message if used Strategist.ForecastUpdateType is not implemented
        See Also:
        Constant Field Values
      • OPERATION_PERIOD

        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
      • forecastUpdateTypeParam

        public static final de.dlr.gitlab.fame.agent.input.ParameterBuilder forecastUpdateTypeParam
        Strategist input parameter: forecast update type
    • 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
        Parameters:
        input - parameters associated with strategists
        Throws:
        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
        Parameters:
        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
        Parameters:
        firstTime - first time period to be covered by a created schedule
        Returns:
        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 are requested for schedule planning
        Parameters:
        map - to be inspected for existing TimeSegment keys
        firstTime - first time period to be covered by a created schedule
        Returns:
        List of TimeStamps at which entries are requested
      • 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
        Parameters:
        timePeriod - associated with the forecast data
        supplyForecast - forecasted supply OrderBook
        demandForecast - forecasted demand OrderBook
      • callOnSensitivity

        protected void callOnSensitivity​(MeritOrderSensitivity sensitivity,
                                         de.dlr.gitlab.fame.time.TimePeriod timePeriod)
        optional action called on given MeritOrderSensitivities
        Parameters:
        sensitivity - to be modified
        timePeriod - that the sensitivity is valid for
      • 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
        Parameters:
        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
        Parameters:
        timePeriod - to search for associated MeritOrderSensitivity
        Returns:
        MeritOrderSensitivity associated with the given TimePeriod
      • createSchedule

        public DispatchSchedule createSchedule​(de.dlr.gitlab.fame.time.TimePeriod timePeriod)
        Creates a DispatchSchedule for the connected flexibility
        Parameters:
        timePeriod - first TimePeriod element of the schedule to be created
        Returns:
        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
        Parameters:
        timePeriod - first period of the schedule to be created
      • getInternalEnergySchedule

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