Simulink.SimulationInput
创建 Simulink.SimulationInput
对象以对多个或单个仿真的模型进行更改
说明
Simulink.SimulationInput
对象允许您更改模型,并对包含更改的模型运行仿真。这些更改将暂时应用于模型。使用 Simulink.SimulationInput
对象,您可以更改初始状态、模型参数、模块参数、外部输入和变量。通过 Simulink.SimulationInput
对象,您还可以使用 setPreSimFcn
函数和 setPostSimFcn
指定在每个仿真的开始和结束时运行的 MATLAB® 函数。
创建对象
描述
输入参量
属性
对象函数
applyToModel | Apply configuration in SimulationIntput object to
model |
getVariantConfiguration | Get name of variant configuration from SimulationInput
object |
loadVariablesFromExternalSource | Load variables from a custom file into Simulink.SimulationInput
object |
loadVariablesFromMATFile | Load variables from MAT file into Simulink.SimulationInput
object |
removeVariable | Remove variable from SimulationInput or
Simulation object |
setBlockParameter | Set block parameter values for simulation using
SimulationInput or Simulation
object |
setExternalInput | Specify external input data for top-level input ports using
SimulationInput or Simulation
object |
setInitialState | Specify initial state for simulation using
SimulationInput or Simulation
object |
setPostSimFcn | Set MATLAB function to run after each simulation |
setPreSimFcn | Specify MATLAB function to run before start of each simulation on
Simulink.SimulationInput object |
setModelParameter | Set model parameter values for simulation using
SimulationInput or Simulation
object |
setVariable | 使用 SimulationInput 或 Simulation 对象为仿真设置变量值 |
setVariantConfiguration | Set variant configuration for simulation using SimulationInput
object |
showContents | View summary of specification in SimulationInput or
Simulation object |
validate | Validate contents of SimulationInput
object |