ss2tf

Converts a state-space model to a transfer function.

Category: Mathematics > Fourier Analysis and Filtering

Syntax

[num, den] = ss2tf(A, B, C, D)

Transfer function from the first input.

[num, den] = ss2tf(A, B, C, D, iu)

Transfer function from input number iu.

Description

For the system x' = A*x + B*u, y = C*x + D*u, the transfer function is C*(s*I - A)^(-1)*B + D. The denominator is poly(A) and the numerator is built from the same polynomial so that all outputs share it.

The result is a rational function in descending powers of s; a numerator row such as [0 0 1] means a constant numerator 1.

Input arguments

A, B, C, D
State-space matrices: A is n-by-n, B is n-by-m, C is p-by-n, D is p-by-m.
iu
Index of the input to use, for systems with several inputs.

Output arguments

num
Numerator coefficients, one row per output, in descending powers of s.
den
Denominator coefficients: the characteristic polynomial of A.

Example

Second-order system

A = [0 1; -2 -3];
B = [0; 1];
C = [1 0];
D = 0;
[num, den] = ss2tf(A, B, C, D)
Output
num = 1×3

         0         0    1.0000
den = 1×3

     1     3     2

This is the transfer function 1/(s^2 + 3s + 2).

See also

poly roots eig