Class ElectrolyzerStrategist

    • Field Detail

      • scheduledChargedHydrogenTotal

        protected double[] scheduledChargedHydrogenTotal
        Planned production schedule for hydrogen in thermal MWh
      • actualProducedHydrogen

        protected double actualProducedHydrogen
        total actual hydrogen produced in thermal MWH
      • electricityPriceForecasts

        protected double[] electricityPriceForecasts
        Electricity price forecasts for planning horizon
      • hydrogenSaleOpportunityCostsPerElectricMWH

        protected double[] hydrogenSaleOpportunityCostsPerElectricMWH
        Maximum willingness to pay for electricity compared to selling hydrogen
      • electricDemandOfElectrolysisInMW

        protected double[] electricDemandOfElectrolysisInMW
        Electric power dedicated to electrolysis unit
      • stepTimes

        protected de.dlr.gitlab.fame.time.TimeStamp[] stepTimes
        Time stamps at the beginning of each scheduling period
      • electrolyzer

        protected Electrolyzer electrolyzer
        The associated electrolysis unit
      • schedule

        protected DispatchSchedule schedule
        The Dispatch schedule controlled / created by this Strategist
      • parameters

        public static final de.dlr.gitlab.fame.agent.input.Tree parameters
        Input parameters of ElectrolyzerStrategist
    • Constructor Detail

      • ElectrolyzerStrategist

        protected ElectrolyzerStrategist​(de.dlr.gitlab.fame.agent.input.ParameterData input)
                                  throws de.dlr.gitlab.fame.agent.input.ParameterData.MissingDataException
        Parameters:
        input - parameters associated with strategists
        Throws:
        de.dlr.gitlab.fame.agent.input.ParameterData.MissingDataException - if any required input is missing
    • Method Detail

      • newStrategist

        public static ElectrolyzerStrategist newStrategist​(de.dlr.gitlab.fame.agent.input.ParameterData input,
                                                           Electrolyzer electrolyzer)
                                                    throws de.dlr.gitlab.fame.agent.input.ParameterData.MissingDataException
        Creates new electrolysis Strategist based on its associated input group
        Parameters:
        input - parameters associated with electrolysis strategists
        electrolyzer - to be assigned to the new strategist
        Returns:
        new Strategist created from the given input
        Throws:
        de.dlr.gitlab.fame.agent.input.ParameterData.MissingDataException - if any required input is missing
      • setElectrolyzer

        protected final void setElectrolyzer​(Electrolyzer electrolyzer)
        sets the ElectrolyzerStrategist's electrolyzer to the given one
        Parameters:
        electrolyzer - to be assigned to this strategist
      • updateElectricityPriceForecasts

        protected void updateElectricityPriceForecasts​(de.dlr.gitlab.fame.time.TimePeriod startTime)
        copies forecasted prices from sensitivities
        Parameters:
        startTime - first time period that update is done for
      • updateOpportunityCosts

        protected void updateOpportunityCosts​(de.dlr.gitlab.fame.time.TimePeriod startTime)
        calculates electricity price equivalent of opportunity costs for selling hydrogen with expected prices
        Parameters:
        startTime - first time period that update is done for
      • updateStepTimes

        protected void updateStepTimes​(de.dlr.gitlab.fame.time.TimePeriod startTime)
        set start time of each hour in forecast interval
        Parameters:
        startTime - first time period that update is done for
      • getElectricDemandForecastInMW

        public double getElectricDemandForecastInMW​(de.dlr.gitlab.fame.time.TimeStamp targetTime)
        Provides forecast for electricity demand at given time;
        only available to FileDispatcher is it doesn't use forecasts themselves
        Parameters:
        targetTime - to calculate the forecast for
        Returns:
        forecasted electricity demand
        Throws:
        RuntimeException - if given Strategist cannot provide forecasts
      • getValidSchedule

        public DispatchSchedule getValidSchedule​(de.dlr.gitlab.fame.time.TimeStamp targetTime)
        Returns a valid schedule for the given target time
        Parameters:
        targetTime - to return a valid schedule for
        Returns:
        the previous schedule (if still valid) or a newly created one
      • getInternalEnergySchedule

        protected double[] getInternalEnergySchedule()
        Specified by:
        getInternalEnergySchedule in class Strategist
        Returns:
        array representing the expected internal energy state of the controlled flexibility
      • updateProducedHydrogenTotal

        public void updateProducedHydrogenTotal​(double producedHydrogenInMWH)
        Updates produced hydrogen total by adding the given amount
        Parameters:
        producedHydrogenInMWH - amount of produced hydrogen to add to the total
      • getMissingHydrogenPriceForecastsTimes

        public ArrayList<de.dlr.gitlab.fame.time.TimeStamp> getMissingHydrogenPriceForecastsTimes​(de.dlr.gitlab.fame.time.TimePeriod firstTime)
        Returns list of times at which hydrogen 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 hydrogen prices is not yet defined
      • storeHydrogenPriceForecast

        public void storeHydrogenPriceForecast​(de.dlr.gitlab.fame.time.TimePeriod timePeriod,
                                               double priceForecastInEURperThermalMWH)
        Stores given hydrogen price forecast for the associated TimePeriod: price-forecasting method
        Parameters:
        timePeriod - associated with the forecast data
        priceForecastInEURperThermalMWH - forecast for the hydrogen price in EUR per thermal MWh
      • getHydrogenPriceForPeriod

        protected double getHydrogenPriceForPeriod​(de.dlr.gitlab.fame.time.TimePeriod timePeriod)
        Returns hydrogen price forecast associated with given TimePeriod
        Parameters:
        timePeriod - to search for associated hydrogen price
        Returns:
        hydrogen price forecast in EUR per thermal MWh or, if not present, Double.MAX_VALUE
      • getHourWithHighestEconomicPotential

        protected int getHourWithHighestEconomicPotential​(int endOfHorizon)
        Parameters:
        endOfHorizon - last step of planning horizon
        Returns:
        Hour with highest economic potential among those with remaining production capabilities; -1 of no capability left in any hour
      • getRemainingPowerInMW

        protected double getRemainingPowerInMW​(int hour)
        Parameters:
        hour - to evaluate
        Returns:
        remaining (unused) electrolyzer electric capacity in MW for given hour
      • getEconomicHydrogenPotential

        protected double getEconomicHydrogenPotential​(int hour)
        Parameters:
        hour - to evaluate
        Returns:
        Economic potential in given hour to purchase electricity and sell hydrogen