Run Individual Simulations
Simulating a model gives you results of the algorithms that you build through the process of modeling. You can interact with the simulations by pacing the simulation, tuning model parameters, stopping or pausing the simulation, and displaying port values to evaluate the design of your model. Simulations help you understand the design and behavior of your model.
Simulate a model interactively by clicking the Run
button in the Simulink Toolstrip, or programmatically using functions like
set_param in the
MATLAB Command Window or a MATLAB script.
For information about running parallel and batch simulations, see Run Multiple Simulations.
Specify External Inputs, Initial State, and State Logging
|Input||Option to load external input data for simulation using top-level input ports|
|Initial state||Option to specify initial model state or operating point for simulation|
|Final states||Option to log final state values|
|Save final operating point||Option to save complete model operating point when simulation is paused or stopped (Since R2019a)|
Configure Diagnostic Behavior
|Operating point object from a different release||Diagnostic behavior when loading initial operating point generated in different release (Since R2019a)|
|Operating point restore interface checksum mismatch||Diagnostic behavior when interface checksum does not match between initial operating point and model (Since R2019a)|
|Simulation Pacing Options||Slow simulation to a specified ratio of simulation time to wall clock time|
Run and Configure Simulations
Simulate from Initial State or Operating Point
Analyze Simulation Outputs and Metadata
|Query and access properties on |
|Access simulation results in |
|Access simulation metadata in |
|Remove property from |
|Add data to metadata in |
|Add string to metadata in |
|Get names of editable properties on |
Configure Simulation Inputs and Access Simulation Output
|Access simulation outputs and metadata|
|Access metadata of simulation runs|
|Complete information that represents model operating point in simulation (Since R2019a)|
Run Basic Simulations
- Simulation Phases in Dynamic Systems
Discover how the Simulink software simulates a dynamic system.
- Choosing a Simulation Mode
Based on your simulation needs, choose to run your simulation in normal, accelerator, or rapid accelerator mode.
- Simulate a Model Interactively
Start, suspend, and stop a simulation interactively.
- Run Simulations Programmatically
Run simulations programmatically by writing scripts or by issuing commands in the MATLAB Command Window.
- Use Model Operating Point for Faster Simulation Workflow
Reduce the time required to run a set of simulations by simulating from an initial operating point.
- How Stepping Through Simulation Works
Learn how simulation snapshots work.
- Debug Simulation Using Signal Breakpoints
Set breakpoints to pause simulation then step through simulation block by block.
- View Signal Values Using Port Value Labels
View signal values in the block diagram during simulation to understand, analyze, and debug your model.