Class ArrivalRateGenerator

java.lang.Object
tools.descartes.dlim.exporter.utils.ArrivalRateGenerator

public final class ArrivalRateGenerator extends Object
Generates an arrival rate file and chart by sampling a Descartes Load Intensity Model using a given ModelEvaluator.
  • Method Details

    • generateArrivalRates

      public static List<ArrivalRateTuple> generateArrivalRates(ModelEvaluator evaluator, double step)
      Run the ArrivalRateGenerator.
      Parameters:
      evaluator - the evaluator
      step - The width of the sampling interval.
      Returns:
      A list of ArrivalRateTuples (Time-stamps and arrival rates) sampled from the model.
    • writeArrivalRates

      public static void writeArrivalRates(List<ArrivalRateTuple> arrRates, String projectPath, String modelName, String endOfLineCharacter, String fileSuffix)
      Run the ArrivalRateGenerator and write the results to a .txt file and an arrival rate plot.
      Parameters:
      arrRates - the arr rates
      projectPath - the project path
      modelName - the model name
      endOfLineCharacter - The character before the end of a line in the output file. Note: the "\n" is always printed after this character. It does not have to be included here.
      fileSuffix - The file suffix ("txt","csv" ...)