Variables in Simulink.SimulationInput
objects
The Simulink.Simulation.Variables
object specifies the variable and its
value used by the Simulink.SimulationInput
object during simulation. By
default, this object overrides variables that already exist in the base workspace or the data
dictionary.
In most cases, there is no need to create an object of this class directly. To add a
variable to the Simulink.SimulationInput
object use the
setVariable
method on the Simulink.SimulationInput
object.
var =
Simulink.Simulation.Variable('
creates a variableName
'Value
)Simulink.Simulation.Variables
object, var
,
that specifies the variable and its value.
var =
Simulink.Simulation.Variable('
creates a
variableName
'Value
,
'Workspace', 'WorkspaceName
')Simulink.Simulation.Variables
object, var
, that
specifies the variable defined in the specified workspace, WorksapceName
and its value. Workspace can either be a model's name to indicate that the variable is in a
model workspace or 'global-workspace' to indicate that it is either in the base workspace or
in a data dictionary.
applyToModel
| loadVariablesFromMATFile
| parsim
| setExternalInput
| setInitialState
| setModelParameter
| setPostSimFcn
| setPreSimFcn
| setVariable
| Simulation
Manager
| Simulink.SimulationInput
| validate