Azzera filtri
Azzera filtri

I'm experiencing matlab crashes on my model how do I find out the cause?

27 visualizzazioni (ultimi 30 giorni)
I have a rather complex simulink model that uses simevents, I created a block that saves the packets (simevents entities) in the matlab workspace, this is done by calling a simulink function with a toWorkspace block inside it.
The problem is that by inserting one of these blocks into the model everything works correctly, but if I insert 2 matlab freezes and then closes without showing any error message. It's not a "same name in the toWorkspace block" issue because it would give me a compilation error and instead it starts simulating and then crash.
The most absurd thing is that by creating a very simplified model I managed to make these 2 blocks work correctly but in the large model I'm working on it doesn't work. However, by removing the part related to saving in the workspace there are no problems.

Risposte (1)

akshatsood
akshatsood il 21 Mag 2024
Modificato: akshatsood il 21 Mag 2024
I see you are encountering crash with MATLAB when attempting to use multiple " To Workspace" blocks for saving packets into the MATLAB workspace. Considering that your complex model operates correctly with a single instance of the "To Workspace" block, it leads me to suspect that the underlying cause of the crash might be related to memory exhaustion. For a more detailed analysis of the problem, could you please share the crash logs? These logs are crucial for understanding the specifics of what occurred at the time of the crash. If you need assistance in locating the crash logs on your system, please refer to the MATLAB Answer for guidance.
I recommend exploring the following potential workarounds to address the problem of memory exhaustion:
  • Reduce the Volume of Logged Data: Adjusting the amount of data you are logging can significantly impact memory usage. For detailed guidance on how to limit the size of logged data, please refer to the following
  • Log Data to a File: Instead of logging data directly into workspace, which can quickly consume available memory, consider logging data to persistent storage. This approach can be more efficient and less taxing on system resources. For instructions on how to log data to a file, please consult the following documentation
I hope this helps.

Categorie

Scopri di più su Discrete-Event Simulation in Help Center e File Exchange

Prodotti


Release

R2022b

Community Treasure Hunt

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

Start Hunting!

Translated by