%% Create Discrete-Time State-Space Model
% Create a state-space model with a sample time of 0.25 seconds and the following state-space matrices:
% A = \left[ {\begin{array}{*{20}{c}}
% 0&1\\
% { - 5}&{ - 2}
% \end{array}} \right]\quad B = \left[ {\begin{array}{*{20}{c}}
% 0\\
% 3
% \end{array}} \right]\quad C = \left[ {{\kern 1pt} \begin{array}{*{20}{c}}
% 0&1
% \end{array}}]\quad D = \left[ {{\kern 1pt} 0{\kern 1pt} }]
% Specify the state-space matrices.

A = [0 1;-5 -2];
B = [0;3];
C = [0 1];
D = 0;

%
% Specify the sample time.

Ts = 0.25;

%
% Create the state-space model.

sys = ss(A,B,C,D,Ts);

% Copyright 2012 The MathWorks, Inc.