call

The call.mos files contains the terminal code for running a simulation model. Within the call.mos file, the modules and superModels are imported and the simulation setup - e.g. simulation time, steps, etc. - can be defined.

Especially the last line of this file is of interest. The preceding lines are for importing all models. In case you did not add any additional modules, they are not in your interest.

 1loadModel(Modelica);
 2cd("../simulation_models");
 3loadFile("source_superModel.mo");
 4loadFile("source.mo");
 5
 6loadFile("sink_superModel.mo");
 7loadFile("sink.mo");
 8
 9loadFile("bottling_superModel.mo");
10loadFile("bottling_partial.mo");
11
12loadFile("mixer_superModel.mo");
13loadFile("mixer_partial.mo");
14
15loadFile("filter_superModel.mo");
16loadFile("filter_partial.mo");
17
18loadFile("still_superModel.mo");
19loadFile("still_partial.mo");
20
21loadFile("evaporator.mo");
22loadFile("process_plant.mo");
23
24cd("../datasets");
25cd("ds4");
26simulate(process_plant, startTime = 0, stopTime=4000, numberOfIntervals=40000, outputFormat="csv", simflags="-maxIntegrationOrder=1");
Within the last lines you can set the simulation hyperparameters like:
  • startTime

    Indicating the time from which the simulation is going to generate data. (Standard value: 0)

  • stopTime

    Indicating the time the simulation will be stopped. (Standard value: 4000)

  • numberOfIntervalls

    Indicating the number of intervals that will be simulated, or indirectly the sampling rate. (Standard value: 40000)

  • outputFormat

    Format of output file (standard value: “csv”)