How to graph an entire simulink scope plot without the scope plot slowly ticking through the simulation.
8 views (last 30 days)
I am attempting to model a battery discharging with constant current. I run the simulaton by pressing the continue button in simulink. Matlab is able to quickly compile my block diagram with the battery and the controlled current source, however it then begins ticking through the compiled simulation. When I double click the scope block for the state of charge (SOC) it produces a live plot that is slowly plotting the discharge of my battery. Since my simulation is for 360s it takes around a 360s time period to get a whole plot of SOC. I would like to know how to get the simulink scope plot without having to wait for the simulation to run. I have seen videos on youtube of people compiling code and the simulation does not run, they are then able to click on scope and it produces an entire plot instantly. How do I do this?
Joel Van Sickel on 22 Dec 2021
there is no way to get a plot without running the simulation as without the simulation, there is no data. You are probably seeing someone open a scope showing data from a previous run or their simulaiton just completed very quickly such that you couldn't see that it was run. Once you start a new run, the scpoe gets cleared, but it is still there before you click the run button if a simulaiton was run previously.