Specify Parameters for Estimation

Choosing Which Parameters to Estimate First

Simulink® Design Optimization™ software lets you estimate scalar, vector, and matrix parameters. You can take an iterative approach to estimating model parameters. For example, if you have a large number of parameters to estimate, start by estimating those that most influence the output. After you estimate a subset of parameters and validate the estimated parameters, you can select the remaining parameters for estimation.

Specify Parameters for Estimation

You can specify the parameters for estimation experiments using the Estimated Parameters editor. In the Parameter Estimation tool, on the Parameter Estimation tab, click Select Parameters.

To select parameters for all experiments, click Select Parameters in the Parameters Tuned for all Experiments panel. This opens the Select model variables dialog. Here you can select the parameters you want to estimate by clicking the check box next to it or specifying an expression. For more information see Select Parameters Using Select Model Variables Dialog Box.

The editor looks like

For this example, select freq1, freq2, freq3, gain1, gain2, gain3 and mean_speed for estimation. You do not need to estimate the parameters all at once. You can first select all the parameters you are interested in, and then later select a subset to estimate. By default, all the parameters are selected for estimation. To deselect the ones you do not want to estimate, clear the Estimate check box for a parameter. For this example, only estimate gain1, gain2, gain3 and mean_speed. Set their initial values 10, 100, 50, and 500, respectively, and then click OK. The Edit: Estimated Parameters dialog box looks like

To learn how to specify initial values and upper and lower bounds of the parameters, see Specifying Initial Guesses and Upper/Lower Bounds.

Select Parameters to Estimate for a Specific Experiment

To select the parameters to estimate in a specific experiment, first, select the experiment for estimation as described in Specify Experiments for Estimation. Then, you can use the Edit:Estimated Parameters dialog to select parameters to estimate for that experiment. Select the experiment name from the Experiment: combo box in the Parameters and Initial States Tuned per Experiment panel. Then click Edit experiment to launch the experiment editor for the experiment you select.

Alternatively, you can right click the experiment name in the Experiments list and select Edit.... In the experiment editor, click the Select parameters button in the Parameters panel. In the Select model variables dialog, you can select the parameters you want to estimate in this experiment by checking the box next to it or specifying an expression. For more information see Select Parameters Using Select Model Variables Dialog Box.

Select Parameters Using Select Model Variables Dialog Box

Use this dialog box to specify parameters to estimate. The table lists all the variables in the model workspace and the MATLAB® workspace that the model uses, whether tunable or not. Select the parameters to estimate by clicking the check box next to each variable. If your model contains a large number of variables, filter the list by typing in the Filter by variable name field.

The Used By column lists the blocks in the model where each variable is used. When a parameter is used in more than one block, all blocks are listed. To locate blocks in which a parameter is used, click the block name to highlight the block in the model.

If the parameter is not a scalar variable, click Specify expression indexing if necessary and enter an expression that resolves to a numeric scalar value.

Non-scalar variables include:

  • Simulink software parameter object

    Example: For a Simulink parameter object k, enter k.value.

  • Structure

    Example: For a structure S, enter S.fieldname, where fieldname is the name of the field that contains the parameter.

  • Cell array

    Example: Type C{1} to select the first element of a cell array C.

  • MATLAB array

    Example: Type a(2) to select the second element of an array a.

You cannot use mathematical expressions such as a + b. Sometimes, models have parameters that are not explicitly defined in the model itself. For example, a gain k could be defined in the MATLAB workspace as k = a + b, where a and b are not defined in the model but k is used. To add these independent parameters, such as k, to the Select Parameters dialog box, see Specify Independent Parameters to Estimate.

Specifying Initial Guesses and Upper/Lower Bounds

After you select parameters, you can specify

  • Initial guess — The value the estimation uses to start the process.

  • Minimum — The smallest allowable parameter value. The default is -Inf.

  • Maximum — The largest allowable parameter value. The default is +Inf.

    You can enter the initial value in the dialog box below the parameter name. You can specify the minimum and maximum value fields by clicking the arrow . The default minimum and maximum values are -Inf and +Inf, respectively, but you can select any range you want.

    If you believe a parameter lies within a finite range, it is best not to use the default minimum and maximum values. Often, there are computational advantages in specifying finite bounds. It can be very important to specify lower and upper bounds. For example, if a parameter specifies the weight of a part, be sure to specify 0 as the absolute lower bound if better information is unavailable.

      Note:   When you specify the minimum and maximum values for the parameters, it does not affect your settings in the Parameters list under Data Browser pane. You make these choices for each experiment.

  • Scale — Scale is used for normalization, in situations, for example, when parameters are in different units.

Related Examples

More About

Was this topic helpful?