tunableTF
Tunable transfer function with fixed number of poles and zeros
Description
Model object for creating tunable SISO transfer function models of fixed order.
tunableTF
lets you parameterize a transfer function of a given order
for parameter studies or for automatic tuning with tuning commands such as systune
or looptune
.
tunableTF
is part of the Control Design Block family of parametric models. Other
Control Design Blocks include tunablePID
, tunableSS
, and tunableGain
.
Creation
Description
creates the parametric SISO transfer function:blk
= tunableTF(name
,Nz
,Np
)
n =
Np
is the maximum number of
poles of blk
, and
m =
Nz
is the maximum number of zeros.
The tunable parameters are the numerator and denominator coefficients
a0, ..., am
and
b0, ..., bn–1.
The leading coefficient of the denominator is fixed to 1.
Input Arguments
name
— Parametric transfer function name
character vector
Parametric transfer function name, specified as a character vector such as
'filt'
or 'DM'
. See Properties.
Nz
— Number of zeros of parametric transfer function
nonnegative integer
Number of zeros of the parametric transfer function blk
,
specified as a nonnegative integer.
Np
— Number of poles of parametric transfer function
nonnegative integer
Number of poles of the parametric transfer function blk
,
specified as a nonnegative integer.
Ts
— Sample time
scalar
Sample time, specified as a scalar.
sys
— Model
tf
model
Model providing number of poles, number of zeros, sample time, and initial values
of the parameters of blk
, specified ad a tf
model.
Properties
Numerator, Denominator
— Parameterization of numerator and denominator coefficients
param.Continuous
objects
Parameterization of the numerator coefficients
am, ..., a0
and the denominator coefficients
1,bn–1, ..., b0
of the tunable transfer function blk
, stored as param.Continuous
objects. For general information about the
properties of these param.Continuous
objects, see the
param.Continuous
(Simulink Design Optimization) object reference page.
These fields of blk.Numerator
and
blk.Denominator
are used when you tune blk
using
hinfstruct
.
Field | Description |
---|---|
Value | Array of current values of the numerator
am, ..., a0
or the denominator coefficients
1,bn–1, ..., b0.
By default, the coefficients initialize to values that yield a
stable, strictly proper transfer function. Use the input
|
Free | Array of logical values determining whether the coefficients are fixed or tunable. For example:
Default: |
Minimum | Minimum value of the parameter. This property places a lower bound on
the tuned value of the parameter. For example, setting
Default:
|
Maximum | Maximum value of the parameter. This property places an upper bound
on the tuned value of the parameter. For example, setting
Default:
|
Ts
— Sample time
0
(continuous time) (default) | scalar
Sample time, stored as a scalar. For continuous-time models, Ts =
0
. For discrete-time models, Ts
is a positive scalar
representing the sampling period. This value is expressed in the unit specified by the
TimeUnit
property of the model. To denote a discrete-time model
with unspecified sample time, set Ts = -1
.
Changing this property does not discretize or resample the model.
TimeUnit
— Units for the time variable, sample time, and time delays
'seconds'
(default) | 'nanoseconds'
| 'microseconds'
| 'milliseconds'
| 'minutes'
| 'hours'
| 'days'
| 'weeks'
| 'months'
| 'years'
Units for the time variable, the sample time Ts
, and any time
delays in the model, stored as one of these values:
'nanoseconds'
'microseconds'
'milliseconds'
'seconds'
'minutes'
'hours'
'days'
'weeks'
'months'
'years'
Changing this property has no effect on other properties, and therefore changes the
overall system behavior. Use chgTimeUnit
to convert between time units
without modifying system behavior.
InputName
— Input channel names
''
for all input channels (default) | character vector | cell array of character vectors
Input channel names, stored as a character vector or a cell array of character vector.
Character vector — For single-input models, for example,
'controls'
.Cell array of character vectors — For multi-input models.
Alternatively, use automatic vector expansion to assign input names for multi-input
models. For example, if sys
is a two-input model, enter:
sys.InputName = 'controls';
The input names automatically expand to
{'controls(1)';'controls(2)'}
.
You can use the shorthand notation u
to refer to the
InputName
property. For example, sys.u
is
equivalent to sys.InputName
.
Input channel names have several uses, including:
Identifying channels on model display and plots
Extracting subsystems of MIMO systems
Specifying connection points when interconnecting models
InputUnit
— Input channel units
''
for all input channels (default) | character vector | cell array of character vectors
Input channel units, stored as a character vector or a cell array of character vector.
Character vector — For single-input models, for example,
'seconds'
.Cell array of character vectors — For multi-input models.
Use InputUnit
to keep track of input signal units.
InputUnit
has no effect on system behavior.
InputGroup
— Input channel groups
structure with no fields (default) | structure
Input channel groups, stored as a structure. The InputGroup
property lets you assign the input channels of MIMO systems into groups and refer to
each group by name. In this structure, field names are the group names, and field values
are the input channels belonging to each group. For example,
sys.InputGroup.controls = [1 2]; sys.InputGroup.noise = [3 5];
creates input groups named controls
and noise
that include input channels 1, 2 and 3, 5, respectively. You can then extract the
subsystem from the controls
inputs to all outputs using:
sys(:,'controls')
OutputName
— Output channel names
''
for all output channels (default) | character vector | cell array of character vectors
Output channel names, stored as a character vector or a cell array of character vector.
Character vector — For single-output models. For example,
'measurements'
.Cell array of character vectors — For multi-output models.
Alternatively, use automatic vector expansion to assign output names for
multi-output models. For example, if sys
is a two-output model,
enter:
sys.OutputName = 'measurements';
The output names automatically expand to
{'measurements(1)';'measurements(2)'}
.
You can use the shorthand notation y
to refer to the
OutputName
property. For example, sys.y
is
equivalent to sys.OutputName
.
Output channel names have several uses, including:
Identifying channels on model display and plots
Extracting subsystems of MIMO systems
Specifying connection points when interconnecting models
OutputUnit
— Output channel units
''
for all output channels (default) | character vector | cell array of character vectors
Output channel units, stored as a character vector or a cell array of character vector.
Character vector — For single-output models. For example,
'seconds'
.Cell array of character vectors — For multi-output models.
Use OutputUnit
to keep track of output signal units.
OutputUnit
has no effect on system behavior.
OutputGroup
— Output channel groups
structure with no fields (default) | structure
Output channel groups, stored as a structure. The OutputGroup
property lets you assign the output channels of MIMO systems into groups and refer to
each group by name. In this structure, field names are the group names, and field values
are the output channels belonging to each group. For example,
sys.OutputGroup.temperature = [1]; sys.OutputGroup.measurement = [3 5];
creates output groups named temperature
and
measurement
that include output channels 1, and 3, 5, respectively.
You can then extract the subsystem from all inputs to the measurement
outputs using:
sys('measurement',:)
Name
— System name
''
(default) | character vector
System name, stored as a character vector. For example,
'system_1'
.
Notes
— Text to associate with system
[0×1 string]
(default) | string | cell array of character vectors
Text to associate with the system, stored as a string or a cell array of character
vectors. The property stores whichever data type you provide. For instance, if
sys1
and sys2
are dynamic system models, you can
set their Notes
properties as follows:
sys1.Notes = "sys1 has a string."; sys2.Notes = 'sys2 has a character vector.'; sys1.Notes sys2.Notes
ans = "sys1 has a string." ans = 'sys2 has a character vector.'
UserData
— Data type to associate with system
[]
(default) | MATLAB® data type
Data type to associate with the system, specified as any MATLAB data type.
Object Functions
systune | Tune fixed-structure control systems modeled in MATLAB |
looptune | Tune fixed-structure feedback loops |
genss | Generalized state-space model |
hinfstruct (Robust Control Toolbox) | H∞ tuning of fixed-structure controllers |
Examples
Create Parametric SISO Transfer Function
Create a parametric SISO transfer function with two zeros, four poles, and at least one integrator.
A transfer function with an integrator includes a factor of 1/s. Therefore, to ensure that a parameterized transfer function has at least one integrator regardless of the parameter values, fix the lowest-order coefficient of the denominator to zero.
blk = tunableTF('tfblock',2,4); % two zeros, four poles blk.Denominator.Value(end) = 0; % set last denominator entry to zero blk.Denominator.Free(end) = 0; % fix it to zero
Assign Input and Output Names
Create a parametric transfer function, and assign names to the input and output.
blk = tunableTF('tfblock',2,3); blk.InputName = {'error'}; % assign input name blk.OutputName = {'control'}; % assign output name
Tips
Version History
Introduced in R2016aR2016a: Name changed from ltiblock.tf
Prior to R2016a, tunableTF
was called
ltiblock.tf
.
See Also
Objects
tunablePID
|tunableSS
|tunablePID2
|tunableGain
|genss
Functions
systune
|looptune
|hinfstruct
(Robust Control Toolbox)
MATLAB Command
You clicked a link that corresponds to this MATLAB command:
Run the command by entering it in the MATLAB Command Window. Web browsers do not support MATLAB commands.
Select a Web Site
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list
How to Get Best Site Performance
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Americas
- América Latina (Español)
- Canada (English)
- United States (English)
Europe
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- United Kingdom (English)
Asia Pacific
- Australia (English)
- India (English)
- New Zealand (English)
- 中国
- 日本Japanese (日本語)
- 한국Korean (한국어)