Quantcast

Documentation Center

  • Trial Software
  • Product Updates

Contents

linearizeOptions

Set options for linearization

Syntax

options = linearizeOptions
options = linearizeOptions(Name,Value)

Alternatives

As an alternative to linearizeOptions function, set options for linearization in the Linear Analysis Tool.

Description

options = linearizeOptions returns the default linearization options.

options = linearizeOptions(Name,Value) returns an option set with additional options specified by one or more Name,Value pair arguments. Use this option set to specify options for commands that perform linearization, including linearize, slLinearize, slTuner, ulinearize, and linlft.

Input Arguments

Name-Value Pair Arguments

Specify optional comma-separated pairs of Name,Value arguments. Name is the argument name and Value is the corresponding value. Name must appear inside single quotes (' '). You can specify several name and value pair arguments in any order as Name1,Value1,...,NameN,ValueN.

For example, 'RateConversionMethod','tustin' sets the 'RateConversionMethod' option to the value 'tustin'.

linearizeOptions takes the following Name arguments:

'LinearizationAlgorithm'

Algorithm used for linearization, specified as either 'blockbyblock' or 'numericalpert'.

  • 'blockbyblock' — Individually linearize each block in the model and combine the results to produce the linearization of the specified system.

  • 'numericalpert' — Full-model numerical-perturbation linearization in which root-level inports and states are numerically perturbed. This algorithm ignores linear analysis points set in the model and uses root-level inports and outports instead.

Block-by-block linearization has several advantages over full-model numerical perturbation:

  • Many Simulink® blocks have preprogrammed linearization that provides an exact linearization of the block.

  • You can use linear analysis points to specify a portion of the model to linearize.

  • You can configure blocks to use custom linearizations without affecting your model simulation.

  • Nonminimal states are automatically removed.

  • You can specify that linearization include uncertainty (requires Robust Control Toolbox™ software).

Default: 'blockbyblock'

'SampleTime'

The interval of time at which the signal is sampled, specified as a scalar value:

  • –1 to use the longest sample time that contributes to the linearized model

  • 0 for continuous-time systems

  • Positive scalar value for discrete-time systems

Default: –1

'UseFullBlockNameLabels'

Flag indicating whether to truncate names of I/Os and states in the linearized model, specified as either 'off' or 'on'.

  • 'off' — Use truncated names for the I/Os and states in the linearized model.

  • 'on' — Use the full block path to name the I/Os and states in the linearized model.

Default: 'off'

'UseBusSignalLabels'

Flag indicating whether to use bus signal channel numbers or names to label the I/Os in the linearized model, specified as either 'off' or 'on'.

  • 'off' — Use bus signal channel number to label I/Os on bus signals in your linearization results.

  • 'on' — Use bus signal names to label I/Os on bus signals in your linearization results. Bus signal names appear in the results when the I/O points are located at the output of the following blocks:

    • Root-level inport block containing a bus object

    • Bus creator block

    • Subsystem block whose source traces back to the output of a bus creator block

    • Subsystem block whose source traces back to a root-level inport by passing through only virtual or nonvirtual subsystem boundaries

    Note:   You cannot use this option when your model has mux/bus mixtures. For information on how to avoid buses used as muxes, see Prevent Bus and Mux Mixtures in the Simulink documentation.

Default: 'off'

'BlockReduction'

Flag indicating whether to omit blocks that are not in the linearization path, specified as either 'off' or 'on'. This flag is ignored when 'LinearizationAlgorithm' is 'numericalpert'.

Set 'BlockReduction' to 'on' (default) to eliminate from the linearized model those blocks that are not in the path of the linearization. Block reduction eliminates the states of blocks in dead linearization paths from your linearization results. Some examples of dead linearization paths are linearization paths that include:

  • Blocks that linearize to zero

  • Switch blocks that are not active along the path

  • Disabled subsystems

  • Signals marked as open-loop linearization points

For example, with this flag set to 'on', the linearization result of the model shown in the following figure includes only two states. It does not include states from the two blocks outside the linearization path. These states do not appear because these blocks are on a dead linearization path with a block that linearizes to zero (the zero gain block).

Set 'BlockReduction' to 'off' to return a linearized model that includes all of the states of the model.

Default: 'on'

'IgnoreDiscreteStates'

Flag indicating whether to remove discrete-time states from the linearization, specified as either 'off' or 'on'. This flag is ignored when 'LinearizationAlgorithm' is 'numericalpert'.

  • 'off' — Always include discrete-time states.

  • 'on' — Remove discrete states from the linearization. Use this option when performing continuous-time linearization ('SampleTime' = 0) to accept the D value for all blocks with discrete-time states.

Default: 'off'

'RateConversionMethod'

Method used for rate conversion when linearizing a multirate system, specified as one of the following strings:

  • 'zoh' — Zero-order hold rate conversion method.

  • 'tustin' — Tustin (bilinear) method.

  • 'prewarp' — Tustin method with frequency prewarp. When you use this method, set the 'PreWarpFreq' option to the desired prewarp frequency.

  • 'upsampling_zoh' — Upsample discrete states when possible, and use 'zoh' otherwise.

  • 'upsampling_tustin' — Upsample discrete states when possible, and use 'tustin' otherwise.

  • 'upsampling_prewarp' — Upsample discrete states when possible, and use 'prewarp' otherwise. When you use this method, set the 'PreWarpFreq' option to the desired prewarp frequency.

For more information, and examples, on methods and algorithms for rate conversions and linearization of multirate models, see:

This option is ignored when 'LinearizationAlgorithm' is 'numericalpert'.

Default: 'zoh'

'PreWarpFreq'

Prewarp frequency in rad/s, specified as a nonnegative scalar.

Default: 0 (no prewarp)

'UseExactDelayModel'

Flag indicating whether to compute linearization with an exact delay representation, specified as either 'off' or 'on'. This flag is ignored when 'LinearizationAlgorithm' is 'numericalpert'.

  • 'off' — Return a model with approximate delays.

  • 'on' — Return a linear model with an exact delay representation.

Default: 'off'

'AreParamsTunable'

Flag indicating whether to recompile the model when parameter values are varied for linearization, specified as either 'true' or 'false'. This flag is applicable when you specify parameter value variations in your call to linearize. This flag is also applicable when you use an slLinearizer or slTuner interface that specifies parameter value variations.

  • 'true' — Model is not recompiled when the software varies the parameter values for linearization.

  • 'false' — Model is recompiled each time the software applies a parameter value variation for linearization. Use this option when you vary the value of a nontunable parameter.

Default: 'true'

'NumericalPertRel'

Perturbation level for obtaining the linear model by numerical perturbation, specified as a positive scalar. This option is ignored unless 'LinearizationAlgorithm' is 'numericalpert'. The perturbation of the system's states is specified by:

The perturbation of the system's inputs is specified by:

Default: 1e-5

'NumericalXPert'

Perturbation levels for the system's states, specified as an operating point object.

To set individual perturbation levels for each of the system's states:

  1. Use the operpoint command to create an operating point object for the model.

  2. Set the state values in the operating point object to the desired perturbation levels.

  3. Set the value of the 'NumericalXPert' option to the operating point object.

'NumericalUPert'

Perturbation levels for the system's inputs, specified as an operating point object.

To set individual perturbation levels for each of the system's inputs:

  1. Use the operpoint command to create an operating point object for the model.

  2. Set the input values in the operating point object to the desired perturbation levels.

  3. Set the value of the 'NumericalUPert' option to the operating point object.

Output Arguments

options

Option set containing the specified options for linearization.

Examples

expand all

Create Options Set for Linearization

Create an options set for linearization that specifies prewarp rate conversion at a frequency of 10 rad/s. Additionally, instruct the linearization not to omit blocks outside the linearization path.

options = linearizeOptions('RateConversionMethod','prewarp',...
                           'PreWarpFreq',10,...
                           'BlockReduction','off');
                       

Alternatively, use dot notation to set the values of options.

options = linearizeOptions;
options.RateConversionMethod = 'prewarp';
options.PreWarpFreq = 10;
options.BlockReduction = 'off';

See Also

| | | |

Was this topic helpful?