Set Simulation Parameters
Before executing a simulation, you can define parameters for simulation time, zero-crossing and solvers.
Set Simulation Time
Define the time parameters for your simulation requirements.
For parameter | Do this |
---|---|
Initial time | Enter a value to start the simulation. |
Final time | Enter a value to end the simulation. Tip: You can also
define Final Time by adding an End block to your diagram. The End
block includes a parameterized simulation time.
|
Real time scaling | Enter a value to scale and insert a delay into the simulation time. For example, if you enter 0 (zero), the real time is ignored and the simulation runs as fast as possible; if you enter 1, one unit of the simulation time = 1 second; if you enter 10, one unit = 10 seconds. |
Tolerence on time | Enter a value to define the acceptable error between event times.
The value for the tolerance on time lets the Simulator ignore the very
small time differences between event times. This is an advanced
parameter that lets you compare two time quantities and detect for
example:
The tolerance-on-time value is computed dynamically as a function of the current simulation time and the machine’s epsilon. If this value is very low or very high, simulation problems can occur. Changing the value depends on the model and requested error tolerance. Generally, if you choose a loose error tolerance, the zero-crossing surfaces need not be precisely detected. If the value is set to auto, and the simulation fails, enter a low value such as 1e-14, and then gradually increase the value as required. |
Set Zero Crossing
Define this advanced parameter to handle discontinuities or generate events.
Specify a Solver
Choose a solver and define solver parameters for your simulation requirements.