Tunable Parameters

About Tunable Parameters

Simulink® lets you change the values of many block parameters during simulation. Such parameters are called tunable parameters. In general, only parameters that represent mathematical variables, such as the Gain parameter of the Gain block, are tunable. Parameters that specify the appearance or structure of a block, e.g., the number of inputs of a Sum block, or when it is evaluated, e.g., a block's sample time or priority, are not tunable.

You can tell whether a particular parameter is tunable by examining its edit control in the block's dialog box or Model Explorer during simulation. If the control is disabled, the parameter is nontunable. You cannot tune inline parameters. See Inline Parameters for more information.

Tune a Block Parameter

You can use a block's dialog box or the Model Explorer to modify the tunable parameters of any block. To use the block's parameter dialog box, open the block's parameter dialog box, change the value displayed in the dialog box, and click the dialog box's OK or Apply button.

You can also tune a parameter at the MATLAB® command line, using either the set_param command or by assigning a new value to the MATLAB workspace variable that specifies the parameter's value. In either case, you must update the model's block diagram for the change to take effect (see Update a Block Diagram).

Was this topic helpful?