%% Convert Transfer Function to State-Space Form
% Consider the system described by the transfer function
%
% H(s)=\frac{\left[\begin{array}{c}2s+3\\s^2+2s+1\end{array}\right]}
%        {s^2+0.4s+1}.
% Convert it to state-space form using tf2ss.

b = [0 2 3; 1 2 1];
a = [1 0.4 1];
[A,B,C,D] = tf2ss(b,a)

% Copyright 2015 The MathWorks, Inc.