Cannot allocate sufficient memory for log variable

조회 수: 16 (최근 30일)
Ana Souza
Ana Souza 2020년 5월 18일
이동: Sabin 2025년 8월 5일
Hi, guys!
I'm running a pretty long simulation in Simulink and in the end of it I have to save some variables. I am using the block to workspace, but before get anything saved I have the following error:
Data logging exceeded available memory
Cannot allocate sufficient memory for log variable. Consider disabling logging or reducing the length of the simulation.
Does anyone know how to deal with it? Is there a way to divide the data into two different variables in Simulink to avoid this situation?
Thanks!

답변 (1개)

Walter Roberson
Walter Roberson 2020년 5월 18일
이동: Sabin 2025년 8월 5일
The problem is not with any one variable getting too large: the problem is with the total size getting too large. You are logging to memory, and running out of available memory between the total of everything that is getting logged.
You can be more selective about what you log. For example perhaps you could use a Rate Transition https://www.mathworks.com/help/simulink/slref/ratetransition.html to sample a signal.

카테고리

Help CenterFile Exchange에서 Prepare Model Inputs and Outputs에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by