tf
Create or convert to transfer function model.
Inputs
LTI model to be converted to transfer function.
Gain matrix to be converted to static transfer function.
Numerator or cell of numerators. Each numerator must be a row vector containing the coefficients of the polynomial in descending powers of the transfer function variable. num{i,j} contains the numerator polynomial from input j to output i. In the SISO case, a single vector is accepted as well.
Denominator or cell of denominators. Each denominator must be a row vector containing the coefficients of the polynomial in descending powers of the transfer function variable. den{i,j} contains the denominator polynomial from input j to output i. In the SISO case, a single vector is accepted as well.
Sampling time in seconds. If tsam is not specified, a continuous-time model is assumed.
Optional pairs of properties and values.
Type set (tf)
for more information.
Outputs
Transfer function model.
Option Keys and Values
Numerator. See ’Inputs’ for details.
Denominator. See ’Inputs’ for details.
String containing the transfer function variable.
Logical. True for negative powers of the transfer function variable.
Sampling time. See ’Inputs’ for details.
The name of the input channels in sys.
Cell vector of length m containing strings.
Default names are {'u1', 'u2', ...}
The name of the output channels in sys.
Cell vector of length p containing strings.
Default names are {'y1', 'y2', ...}
Struct with input group names as field names and vectors of input indices as field values. Default is an empty struct.
Struct with output group names as field names and vectors of output indices as field values. Default is an empty struct.
String containing the name of the model.
String or cell of string containing comments.
Any data type.
Example
octave:1> s = tf ('s'); octave:2> G = 1/(s+1) Transfer function 'G' from input 'u1' to output ... 1 y1: ----- s + 1 Continuous-time model. octave:3> z = tf ('z', 0.2); octave:4> H = 0.095/(z-0.9) Transfer function 'H' from input 'u1' to output ... 0.095 y1: ------- z - 0.9 Sampling time: 0.2 s Discrete-time model. octave:5> num = {[1, 5, 7], [1]; [1, 7], [1, 5, 5]}; octave:6> den = {[1, 5, 6], [1, 2]; [1, 8, 6], [1, 3, 2]}; octave:7> sys = tf (num, den) Transfer function 'sys' from input 'u1' to output ... s^2 + 5 s + 7 y1: ------------- s^2 + 5 s + 6 s + 7 y2: ------------- s^2 + 8 s + 6 Transfer function 'sys' from input 'u2' to output ... 1 y1: ----- s + 2 s^2 + 5 s + 5 y2: ------------- s^2 + 3 s + 2 Continuous-time model. octave:8> |
Source Code: tf
tf
Create or convert to transfer function model.
Inputs
LTI model to be converted to transfer function.
Gain matrix to be converted to static transfer function.
Numerator or cell of numerators. Each numerator must be a row vector containing the coefficients of the polynomial in descending powers of the transfer function variable. num{i,j} contains the numerator polynomial from input j to output i. In the SISO case, a single vector is accepted as well.
Denominator or cell of denominators. Each denominator must be a row vector containing the coefficients of the polynomial in descending powers of the transfer function variable. den{i,j} contains the denominator polynomial from input j to output i. In the SISO case, a single vector is accepted as well.
Sampling time in seconds. If tsam is not specified, a continuous-time model is assumed.
Optional pairs of properties and values.
Type set (tf)
for more information.
Outputs
Transfer function model.
Option Keys and Values
Numerator. See ’Inputs’ for details.
Denominator. See ’Inputs’ for details.
String containing the transfer function variable.
Logical. True for negative powers of the transfer function variable.
Sampling time. See ’Inputs’ for details.
The name of the input channels in sys.
Cell vector of length m containing strings.
Default names are {'u1', 'u2', ...}
The name of the output channels in sys.
Cell vector of length p containing strings.
Default names are {'y1', 'y2', ...}
Struct with input group names as field names and vectors of input indices as field values. Default is an empty struct.
Struct with output group names as field names and vectors of output indices as field values. Default is an empty struct.
String containing the name of the model.
String or cell of string containing comments.
Any data type.
Example
octave:1> s = tf ('s'); octave:2> G = 1/(s+1) Transfer function 'G' from input 'u1' to output ... 1 y1: ----- s + 1 Continuous-time model. octave:3> z = tf ('z', 0.2); octave:4> H = 0.095/(z-0.9) Transfer function 'H' from input 'u1' to output ... 0.095 y1: ------- z - 0.9 Sampling time: 0.2 s Discrete-time model. octave:5> num = {[1, 5, 7], [1]; [1, 7], [1, 5, 5]}; octave:6> den = {[1, 5, 6], [1, 2]; [1, 8, 6], [1, 3, 2]}; octave:7> sys = tf (num, den) Transfer function 'sys' from input 'u1' to output ... s^2 + 5 s + 7 y1: ------------- s^2 + 5 s + 6 s + 7 y2: ------------- s^2 + 8 s + 6 Transfer function 'sys' from input 'u2' to output ... 1 y1: ----- s + 2 s^2 + 5 s + 5 y2: ------------- s^2 + 3 s + 2 Continuous-time model. octave:8> |