Creating and Manipulating Models    

Discretization of Systems with Delays

You can also use c2d to discretize SISO or MIMO continuous-time models with time delays. If Ts is the sampling period used for discretization:

For example, to discretize the transfer function

using zero-order hold on the input, and a 10 Hz sampling rate, type

This produces the discrete-time transfer function

Here the input delay in amounts to 2.5 times the sampling period of 0.1 seconds. Accordingly, the discretized model hd inherits an input delay of two sampling periods, as confirmed by the value of hd.inputdelay. The residual half-period delay is factored into the coefficients of hd by the discretization algorithm.

The step responses of the continuous and discretized models are compared in the figure below. This plot was produced by the command


  Matched Poles and Zeros Resampling of Discrete-Time Models