Speed up compilation time Matlab simulink/simscape

4 visualizaciones (últimos 30 días)
Felix Hoffmann
Felix Hoffmann el 16 de Abr. de 2020
Editada: Aabha el 7 de Feb. de 2025
Hello everybody,
i am modeling an electrical machine using simulink/simscape. More precisely, I am observing the thermal behavior. Thus, using the thermal domain of Simscape.
However, the compilation time is very long compared to the simulation time and takes about 99% of the whole simulation time.
Is there any option to speed up the compilation time? For example a pre-compilation of the block that no compilation is needed if parameters are changed.
I think using Rapid Accelerator mode just speeds up the simulation itself. At least it has no influence for my model.
Best regards
Felix

Respuestas (1)

Aabha
Aabha el 7 de Feb. de 2025
Editada: Aabha el 7 de Feb. de 2025
I understand that you are trying to reduce the compilation time for your Simscape model. To achieve this, Simscape has run-time parameters, which are MATLAB variables or Simulink.Parameter objects that are run-time configurable. These parameters allow to skip recompiling the model when parameter values are changed. Simscape supports run-time configurability for most parameters that need a numerical value input. To determine whether a parameter is run-time configurable, you can review the settings for the parameter in the block property inspector. If a parameter is run-time configurable, you will see the property inspector set to the default setting, “Compile-time”. This can be changed to “Run-time” if necessary.
Please refer to the following documentation to understand more about run-time parameters.
There are a few other ways in which you can speed up the compilation of a Simscape model in general. You can use optimization techniques such as scalable compilation, incremental compilation, and memory or disk caching for model compilation.
Please refer to the following documentation to understand more about techniques for improving compilation performance.

Categorías

Más información sobre Run-Time Parameters en Help Center y File Exchange.

Productos


Versión

R2019a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by