A team at my work works with Dymola and is using it to simulate a quite complex model for quite a long time.
They end up with large output files (.mat) of around 150gb and therefore have issues post processing it.
I am in IT and have graduated as an engineer so I have enough experience with typical softwares to know that they could reduce the output frequency or the amount of data stored (e.g. choosing less variables to output). But for some reason, they can’t or don’t want.
Now I don’t know dymola enough to identify another possibility and that is why I am asking the community : is there another way to have the same accuracy, complexity and amount of data while having smaller output files?
Is there a way in Dymola to cut a simulation into multiple time-domains for example ? So one file for 0-500s, another for 500-1000s and so on? They told me it’s possible but complicated. Is that true? Isn’t there a way to do this in Dymola ?
Thanks in advance
CodePudding user response:
Please refer to this claytex blog https://www.claytex.com/blog/how-to-restart-a-simulation/. The blog explains two methods: one is using the continue
feature in Dymola, next is the manual way of reinitialization
automated using batch script.
In your case, the second method can be utilised since you need to restart the simulations with reinitialised states
and also create separate chunks of result files.
Note: dsin.txt
file has the initial values of all variables including the state variables and dsfinal.txt
has the final values of all variables for a single complete simulation. You can find these files in the working directory after the first simulation preferably with a smaller stopTime
CodePudding user response:
You might also re-consider if you need the same amount of data during the entire simulation.
Since Dymola 2021 you can change the output interval during the simulation, it is described as "Variable frequency of output points" in the release notes:
By setting the flag:
Advanced.Simulation.VariableInterval=true;
And in the model use
when time>=… then
Dymola.Simulation.SetOutputInterval(…);
end when;
the frequency can be controlled from the model.