6
Sampling and Discretization
Foundations on sampled-data systems, sampling and discretization are provided. Key learn-
ing elements of this chapter are the connections between discrete-time and continuous-time
systems in presence of a zero-order hold, the sampling theorem and guidelines for choosing
sampling rates.
Experimental data is the vital ingredient for identification. The introductory chapter taught us
that an identification experiment consists of three basic steps, (1) designing the discrete-time input,
(2) exciting the process with an approximate continuous-time input and (3) sampling (measuring)
the resulting output. This chapter discusses the mathematical concepts related to the latter two steps,
while reserving the first one for §22.3.
This chapter begins by presenting concepts of discretization in order to establish the mapping
between a sampled-data system and the underlying continuous-time process. Understanding this
mapping crucially aids in formulating practical guidelines for selecting sampling rates in identifica-
tion experiments and discovering the model for the underlying continuous-time process. We shall,
however, only discuss the former problem. Developing continuous-time models from sampled data
is beyond the purview of this text.
6.1 DISCRETIZATION
We begin with the definition of discretization.
Discretization is the act of obtaining a discrete-time system (or a model) from a
continuous-time system (or a model), under a suitable sampling-and-hold scheme.
Discretized models are usually derived from continuous-time, first principles models. Consequently,
the structure and parameters of these models can be related to the geometrical and physico-chemical
properties of the underlying process. These models are therefore naturally useful in grey-box mod-
elling, where the model structure is governed by a discretized version of the continuous-time model.
It should be remarked that discretization as such has a wider appeal. For instance, in digital con-
trol, it is used to arrive at equivalent digital controllers from analog controllers. Other applications
include numerical dierentiation and integration that are at the heart of all modern simulators and
numerical solvers.
Remarks: A large class of processes naturally operate in discrete domain, for which, there are no correspond-
ing continuous-time counterparts. Monthly wages, rainfall, population growth are prominent examples of such
processes.
Methods for discretization can be classified into two categories:
i. Approximate discretization: These methods derive discrete-time models using approximations
of continuous-time functions. Arriving at approximate dierence equations from dierential
equations is a classical example of this approach.
Example 6.1: Approximation of First-Order System
A first-order continuous-time dynamic system is described by the ODE:
τ
p
dy
dt
+ y(t) = K
p
u(t) (6.1)
129
130 Principles of System Identification: Theory and Practice
An approximate discrete-time model can be obtained using a backward or a forward
difference approximation of the derivative.
Backward difference approximation yields
τ
p
y(t) y (t T
s
)
T
s
+ y(t) K
p
u(t)
where T
s
is the sampling step.
Setting t := kT
s
, y[k] y(kT
s
) and α = T
s
p
, we obtain
y[k] +
1
1 + α
y[k 1] =
K
p
α
1 + α
u[k] (6.2)
While the forward difference approximation produces
y[k] (1 + α)y[k 1] = K
p
αu[k 1] (6.3)
Observe the differences in the two approximate difference equations.
The second approximation produces a strictly causal, but a less stable model than its
backward differencing counterpart (reference).
ii. Exact discretization: These methods produce discretized models that are exact, i.e., they match
the analytical solution of the dierential equations, but under a given set of conditions. The tax-
onomy can be misleading since these models are also approximations of the continuous-time
system when the conditions for exactness are not met. This aspect becomes clearer in the discus-
sions to follow. The underlying idea is explained with an example below.
Example 6.2: Exact Discretization of a First-Order System
Consider the same first-order system as discussed above:
τ
p
dy
dt
+ y(t) = K
p
u(t) (6.4)
From calculus, the analytical solution to this equation is
y(t
2
) = y(t
1
)e
(t
2
t
1
)
p
+
K
p
τ
p
e
t
2
p
Z
t
2
t
1
e
t
0
p
u(t
0
) dt
0
The particular solution (second term on the RHS) depends on the input u(t
0
) during the
time interval (t
1
,t
2
).
The simplest of cases is when u(t) is a piecewise constant signal, changing only at the
sampling instants
u(t) = u((k 1)T
s
), (k 1)T
s
t < kT
s
Selecting t
2
:= (k + 1)T
s
and t
1
:= kT
s
, we obtain the difference equation
y[k] = e
α
y[k 1] + K
p
(1 e
α
)u[k 1] (6.5)
where α = T
s
p
as before.
Observe that there is no approximation involved in this approach other than the piecewise
constant approximation of the input. This discretization is exact, meaning the solutions to
the difference equation and the differential equation are identical as long as the continuous-
time and discrete-time inputs are identical.
It is interesting to note that the approximate model obtained by forward dierencing in (6.3) is in
fact a first-order approximation of the model in (6.5).

Get Principles of System Identification now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.