Professional Documents
Culture Documents
Chapter 1
A signal is defined as any physical quantity that conveys information. It may be represented
in many ways; often mathematically as a function of one or more independent variables. The
independent variable(s) type and nature depends on the information represented. Time is
often the independent variable in the mathematical representation of many signals. There are,
however, cases where a functional representation for the signal may not be possible. For
example, a speech signal cannot be described mathematically. Other examples of a natural
signals include an electrocardiogram (ECG) which provides information on the operation of
the heart and an electroencephalogram (EEG) which provides information about the electrical
activity of the brain over a short period of time. These are information-bearing signals that
can be represented as functions of time.
Depending on the nature of the signal and the representation desired, the independent variable
may be continuous or discrete. Continuous-time signals are defined for all points in time over
a finite or infinite interval (the independent variable time is continuous). Discrete-time signals
are defined at discrete times over a finite or infinite interval (the independent variable time
assumes discrete values). Discrete-time signals may thus be represented as sequences of
numbers. Any signal, if certain conditions hold, may have either a continuous- or a discrete-
variable representation, these representations are entirely equivalent. In both cases, the signal
amplitude may be continuous or discrete. Digital signals are, however, those for which both
the amplitude and the independent variable are discrete.
A system may be defined as a physical device that performs an operation on a signal, called
an input signal. A filter that is used to reduce noise and interference from a desired
information-bearing signal is an example of a signal processing system. We may also broaden
the system definition to include software realizations of operations on a signal. In such cases
the operations performed on a signal consist of a number of mathematical operations as
specified by a software program. This represents system implementation in software, i.e., a
signal processing system realized in software.
Signal processing systems may be classified along the same lines as signals. Continuous-time
systems are those for which both the input and output are continuous-time signals, and
discrete-time systems are those for which both the input and output are discrete-time signals.
Similarly, a digital system is one for which both the input and output are digital signals.
Discrete-time signal processing, then, deals with the study of discrete-time systems that
2. Introduction to Discrete-time Signals Processing
perform discrete-time signal transformation. Thus, the principal focus in this Chapter is on
basic time- and frequency-domain representation and analysis of discrete-time signals and
systems.
Discrete-time signal processing systems have many attractive features and may be realized
with great flexibility in a variety of technologies such as general purpose computers,
microcomputers, and special purpose DSP chips. Discrete-time systems can be used to
simulate analog systems or, more important, to realize signal transformations that cannot be
implemented with continuous-time hardware. Thus, discrete-time representations of signals
are often desirable when sophisticated and flexible signal processing is required. We will
consider the fundamental concepts of discrete-time signals and linear time-invariant discrete-
time signal processing systems in this Chapter.
Discrete-time signals are represented as sequences of numbers in which the nth number in the
sequence is denoted by x(n). It is only defined for integral values of n, and x(n) is not defined
for non-integral values of n. If x(n) is obtained from sampling an analog signal xa(t), then x(n)
= xa(nT), where T is the sampling interval and its reciprocal is the sampling frequency.
x ( n) 1 , 4, 1, 0, 0, , infinite sequence
n 0
x ( n) 1 , 4, 1, 0, 0 , finite sequence
n 0
Chapter 1 - Discrete-time Signals and Systems 3
( )= 1, −0.3, ⏟
1 , −1, 0.5 ,
Unit sample sequence:- Unlike the continuous-time impulse the unit sample sequence
(discrete-time impulse) has a precise mathematical representation, given by:
1, =0
( ) = 1 δ(n)
0, ≠0
A more general mathematical representation -2 -1 0 1 2 3 4 n
is given by
1, ( )=0
( ( )) =
0, ( ) Ζ≠0
where g(n) is any well defined, finite-valued
discrete-time signal. Some examples δ(n-3) 1
commonly encountered are
1, n 3 0, i. e., n 3 -2 -1 0 1 2 3 4 n
(n 3)
0, n 3 0, i. e., n 3
1, n 2 0, i. e., n 2 1 δ(n+2)
(n 2)
0, n 2 0, i. e., n 2
-2 -1 0 1 2 3 4 n
1, (n 3) 0, i. e., n 3
( (n 3)) (n 3) n 3
0, (n 3) 0, i. e., n 3
The unit sample sequence is sometimes called the discrete-time impulse, or simply as
an impulse. It plays the same role for discrete-time signals and systems that the unit
impulse function (Dirac delta function) does for continuous-time signals and systems.
The discrete-time impulse has simple and precise mathematical definition as opposed
4. Introduction to Discrete-time Signals Processing
to that of the continuous-time impulse. One of the important uses of the impulse
sequence is that it can be used to express any sequence as a sum of scaled and delayed
impulses, as follows
( ) = ( ) ( − )
= ⋯+ + + + ⋯
We will make use of this property in the representation of linear discrete-time signal
and systems.
1 n 0 u(n) 1
u( n) •••
0, n 0 • •
-2 -1 0 1 2 3 4 n
u(n+2) 1
•••
1, n 2 0, i. e., n 2
u(n 2) • •
0, n 2 0, i. e., n 2 -4 - 3 -2 -1 0 1 2 3 4 n
1 u(-(n+3))
•••
1, (n 3) 0, i. e., n 3
u( (n 3)) • • • •
0, (n 3) 0, i. e., n 3 -7 -6 - 5 -4 -3 -2 -1 0 1 n
The unit step sequence may also be written as an infinite sum of delayed impulses as
Chapter 1 - Discrete-time Signals and Systems 5
u (n ) 1 , 1, 1, 1, 1, 1,
n 0
(n) (n 1) (n 2) (n 3)
i.e., u ( n) (n k )
k0
The unit step sequence at time index n may also be expressed as the accumulated sum
of the impulse at index n and all previous values of the impulse sequence, i.e.,
n
u ( n) (k)
k
Conversely, the impulse sequence can be expressed as the first backward difference of
the unit step sequence, i.e.,
( n) u(n) u(n 1)
1, = 0+ , k integer
= 4
0, otherwise
1, = 4 , k integer
=
0, ℎ
x(n)
1
••• •••
••• ••• ••• ••• ••• ••• ••• ••• •••
-8 -4 0 4 8 12 16 20 n
Exponential sequence:
Exponential sequences are extremely important in linear time-invariant system (LTI)
and signal analysis and representation. The general form of an exponential sequence is
x (n) an , for all n
6. Introduction to Discrete-time Signals Processing
where the parameter ‘a’ may be real or complex. We may consider several forms of
x(n) with ‘a’ real and complex.
1) Case when ‘a’ is real:- Consider the case when ‘a’ is real in ( ) =
all n. The exponential sequence takes either of the following four forms
0 10 20 30 0 10 20 30
n n
1
x (n) , -1 < a < 0 x (n) , a < -1
-1
x (n) Aa n , all n
n
x ( n) Aa n A e j a e j 0n
n
A a e j ( 0 n )
n n
A a cos( 0 n ) j A a sin( 0 n )
Im{x(n)}, 0<a<1
Re{x(n)}, 0<a<1
0 20 n 0 10 30 n
30
••• •••
Im{x(n)}, |a| > 1
0 20 n
0 20 n 0 10 30 n
Alternatively, the complex exponential sequence x(n) may be represented in the polar
(magnitude and phase form) as
n
x ( n) A a e j ( 0 n )
x (n ) e j ( 0 n )
8. Introduction to Discrete-time Signals Processing
n
where x (n) A a is the magnitude function and (n) 0 n is the
phase function of x(n). For this particular case the phase function is linear with n, and
may be plotted as a function of n.
e j 0 ( n N ) e j 0 n
Consequently, complex exponential and sinusoidal sequences may not necessarily be
periodic. For example, for ω0 = 3π/4 the smallest value of N is 8, obtained with k = 3.
On the other hand, ( ) cannot be periodic for ω0 = 1, since N = 2πk can never be an
integer for k an integer.
The concept of high and low frequencies is somewhat different for discrete-time
sinusoidal and complex exponential signals from their continuous-time counterparts.
A continuous-time sinusoidal signal x (t ) A cos( 0 t ) oscillates more and
Chapter 1 - Discrete-time Signals and Systems 9
x(n), a = 1, ω0 = 0, N =∞
••• •••
0 10 20 30 35 n
x(n), |a| = 1, ω0 = π/8, x(n), |a| = 1, ω0 = π/4,
N = 16 N=8
0 20 30 n 0 10 30 n
0 20 n 0 10 34 n
) ( ), ) ( − 2) , ) ( + 2) , ) (− ), ) (3 − ), ) (2 ),
) , ℎ) ( ) .
2
Solution: The plots of the manipulated sequences of the sequence x(n) is shown
below.
1.5 1.5
a) x(n) b) x(n-2)
1 1 1 1
-2 0 2 4 6 n -1 0 2 4 6 8 n
-0.5 -0.5
-2 -2
1.5 1.5
c) x(n+2) d) x(-n)
1 1 1 1
-4 -2 0 2 4 n -6 -4 -2 0 2 n
-0.5 -0.5
-2 -2
1.5 1.5
e) x(3-n) f) x(2n)
1 1 1
-2 0 2 4 6 n -2 -1 0 1 2 3 n
-0.5 -0.5
-2
1.5
g) x(n/2) h) δ(x(n))
1 1 1 1 1 1 1 1 1
••• •••
• • • • 0 • • •4 • • •8 • • •12
•-4 n
•
-2
•0 • •
2 4 6 n
-0.5
-2
Chapter 1 - Discrete-time Signals and Systems 11
There are a number of ways that discrete-time signals may be classified. In this section, only
some major classifications that depend on major signal characteristics will be indicated.
4 1 35
3 8 24
Since E is finite, x(n) is an energy signal.
Since the sum is not finite the unit step sequence, u(n), is not an energy signal.
Signals that have non-finite energy, however, may have finite average power. The average
power of a discrete-time signal x(n) is defined as
N
1 2
P lim
N 2 N 1 n N
x(n )
If E is finite, then the average power P = 0. If, on the other hand, E is infinite, then the
average power P may be either finite or infinite. The signal is called a power signal if the
average power is finite.
Example 1.3.2: i) Consider the unit step sequence. We have seen that it is not an energy
signal. The average power of the unit step sequence is
N
1 N1 1
P lim u 2 ( n)
N 2 N 1 n N
lim
N 2 N 1
2
Since the average power of the unit step sequence is finite u(n) is a power signal.
The total signal energy, over all time, is infinite. Hence, the unit ramp signal is
not an energy signal. The average power of the signal is
1 N ( N 1)
P lim EN lim
N 2 N 1 N 6
which clearly is also infinite. Since this signal has infinite energy and infinite
power it is neither an energy signal nor a power signal.
As seen earlier, a discrete-time signal x(n) is periodic, with period N, if and only if
x(n + N) = x(n), for all n.
The smallest integral value of N for which this condition holds is called the fundamental
period. If there is no value N that satisfies the above condition, then the signal x(n) is non-
periodic or aperiodic. We have already observed that the sinusoidal signal
2f 0
x (n ) sin( n) sin( 0 n)
fs
is periodic when f0 is a rational number multiplied by the sampling rate, fs, i.e., if f0 can be
expressed as
2
= , ( = =2 )
where k and N are integers. For periodic signals the signal energy is specified over one
period, over the interval 0 ≤ ≤ − 1. For finite-valued signals this energy will be finite.
The average power of a periodic signal is equal to the average power over a single period.
Thus, the average power of a finite-valued periodic signal x(n), with fundamental period N, is
N 1
1 2
P
N
n0
x ( n)
The average power of such signals is finite. Consequently, finite-valued periodic signals are
power signals.
14. Introduction to Discrete-time Signals Processing
The sum and product of two periodic signals is also a periodic signal. Let ( ) be a
sequence with period and ( ) be another sequence with period . Then
( ) = ( )+ ( )
and
( ) = ( ) ( )
are always periodic with fundamental period N, where
=
gcd ( , )
where gcd( , ) is the greatest common divisor of and .
ii) x(n) complex:- A complex-valued signal x(n) is called conjugate symmetric (real part
even and imaginary part odd) if
Chapter 1 - Discrete-time Signals and Systems 15
( )= [ ( )], ( ) ⎯⎯⎯⎯⎯⎯⎯⎯⎯ ( )
x(n) H y(n)
input sequence output sequence
The symbol H denotes the transformation or rule used for computing the output sequence
values, ( ), from the input sequence values, ( ). This transformation describes the
characteristics of the system and may be used to classify discrete-time systems.
Among the various ways used to describe the characteristics of the system and the operations
it performs on ( ) to produce ( ), the input/output description will be discussed first. At
this point we will look at the time domain characterization of systems. The input/output
description gives a mathematical expression which explicitly defines the relationship between
the input and output signals. The exact internal structure of the system is not important, or is
ignored. Some examples of the input/output description for discrete-time systems are given
below.
16. Introduction to Discrete-time Signals Processing
This system computes the nth sample of the output sequence as the average of
(M1 + M2 + 1) samples of the input sequence around the nth-sample. A similar
system which gives as output a weighted average of three input samples, for
example, is the following
( ) = 2 ( ) + 3 ( − 1) + 4 ( − 2) = ℎ ( − )
At each instant n, the system must remember the previous input samples x(n-1)
and x(n-2).
c) An accumulator is defined by
n n 1
y ( n)
k
x( k ) x( k )
k
x (n)
The system computes the current value of the output by adding (accumulating)
the current value of the input to the previous value of the output. Note that all
effects of previous inputs have been remembered by the previous output y(n-1).
d) The second example in (b) may also be represented in a compact matrix form
for a finite input sequence x = [x0, x1, x2, x3] as
y0 2 0 0 0
y 3 2 0 0 x 0
1
y2 4 3 2 0 x1
y Hx
y3 0 4 3 2 x2
y4 0
0 4 3 x 3
y5 0 0 0 4
As we shall see later this is a linear transformation representation of the system
which is important in the block processing operation of the input to produce the
Chapter 1 - Discrete-time Signals and Systems 17
e) if we introduce state variables w1(n) and w2(n) defined as x(n-1) = w1(n) and
x(n-2) = w2(n), then the second example above (b) may also be represented in a
different form (state variable representation) by the following system of three
equations:
y (n) 2 x (n) 3w1 (n) 4 w2 (n)
w2 (n 1) w1 (n)
w1 (n 1) x ( n)
i.e.,
w1 (n 1) 0 0 w1 (n) 1
w (n 1) 1 0 w ( n ) 0 x ( n )
2 2
w
1 ( n )
y ( n)
3 4 2 x ( n)
w 2 (n )
i.e.,
( + 1) = ( ) + ( )
( ) = ( )+ ( )
n
y ( n) x( )
2
This operation inserts a zero sample value in between the samples of the input
sequence x(n) for every odd value of n. This general operation of up-sampling is
called interpolation.
The representations above give input/output (I/O) description of systems. A block diagram
may also be used to represent discrete-time systems. The basic building blocks of discrete-
time systems for this representation are: an adder, a constant multiplier, a unit delay element,
and a signal multiplier. The block diagram representation is nothing but a realization of the
input/output rule described above. As we shall see in a later chapter, this realization is not
unique, i.e., there are a number of different realizations for a system described by a given I/O
rule. These different realizations (structures) are all realized using the same basic building
blocks.
An adder:- This basic unit (elementary system) performs the addition of two sequences x1(n)
and x2(n) to form another sequence (the sum) y(n). This unit is memory less, i.e., none of the
sequences are stored to perform the operation.
x2(n)
A scalar multiplier:- This operation multiplies the sequence by a scalar. This operation is
also memory less.
a
x(n) y(n) = ax (n)
A unit delay: This unit simply delays the sequence by one sample. If the input sequence is
x(n), then the output sequence is x(n-1). In fact, the sample x(n-1) can be taken to be stored in
memory at time n-1 and recalled from memory at time n to form the output y(n) = x(n-1).
This basic unit requires memory. In the block diagram representation the unit delay is
represented by z-1 and the unit advance is represented by z. This convention will be apparent
when we look at the z-transform.
A signal multiplier: This unit multiplies two sequences sample by sample. It is a memory less
system.
Chapter 1 - Discrete-time Signals and Systems 19
x2(n)
A general classification of discrete-time systems will be given below. There are a variety of
ways in which systems may be classified according to the general properties that they satisfy.
Linear systems
A linear system is one that satisfies the superposition principle. The superposition principle
requires that the response of a system to a weighted sum of signals be equal to the
corresponding weighted sum of the responses of the system to each of the individual input
signals, i.e.,
H
If x1 (n) y1 (n)
H
and x 2 (n)
y 2 (n)
H
then ai xi (n)
ai yi (n)
H
and x1 (n) x 2 (n)
y1 (n) y 2 (n)
where the ai’s, i = 1, 2, are arbitrary constants. The first property is called the homogeneity or
scaling property and the second one is called the additivity property. These two properties are
combined into the principle of superposition, stated as
H
a1 x1 (n) a 2 x 2 (n) a1 y1 (n) a 2 y 2 (n)
By using the definition of the principle of superposition, we see that some of the systems of
Example 1.4.1 are linear systems ((b) & (c) for instance). If the system does not obey the
principle of superposition, then the system is said to nonlinear. The systems considered in
this text will all be assumed to be linear.
Example 1.4.2: Test the following systems for time-invariance (backward difference system).
a ) y (n) x (n) x (n 1)
b) y (n) nx (n)
a) Let the input be delayed by some value n o = D samples, i.e., ( ) = ( −
). Then the corresponding output, using the input output equation,
y (n ) x (n) x (n 1)
is
y D ( n) x D (n) x D (n 1)
x(n D) x (n D 1)
Delaying the output y(n) by D samples gives
y ( n D) x (n D) x (n D 1)
i.e.,
y ( n D) y D ( n)
Thus, the differentiator realized as a backward difference system is a time-
invariant system.
Causal Systems
A system is causal if for every integer n o the output sequence value at n = no depends only on
the input sequence values for ≤ . In other words, the output of the system at any time n
depends only on present and past values of the input (i.e., x(n), x(n-1), x(n-2), ...), but does
not depend on future inputs [i.e., x(n+1), x(n+2), x(n+3), ...]. That is, the system is non-
anticipative, it does not anticipate a future input and respond now. Mathematically, the output
of a causal system is some function of the present and past input values, i.e.,
is causal.
Stable systems
A system is stable in the bounded-input bounded-output (BIBO) sense if and only if every
bounded input sequence produces a bounded output sequence. An input x(n) is bounded if
there exists a fixed positive finite value Bx such that
x ( n) B x , all n
Stability requires that for every bounded input there exists a fixed positive finite value By
such that
y (n) B y , all n
If for some bounded input x(n) the output is unbounded (infinite), then the system is
classified as unstable.
Consider the accumulator with a bounded input x(n) = u(n). The output of the accumulator to
the unit step input is
n n
y ( n) u( k )
k
1
k
n1
The response of the accumulator is finite for n finite. It is, however, unbounded, i.e., there is
no fixed positive finite value By such that ( + 1 ≤ < ∞) for all n.
Note that the existence of inputs that satisfy the stability property does not mean that the
system is stable. The stability property has to hold true for all inputs for the system to be
stable. An unstable system may have some bounded inputs for which the output is bounded,
but for the system to have the property of stability, it must be true that for all bounded inputs
the output is bounded.
Stability is an important property that must be considered in the study and implementation of
systems. The general study of stability will not be dealt within this book. Other stability
criteria have also been developed. The above condition will be explored further later on.
Consider a discrete-time linear time-invariant system. Let the input be an impulse x(n) = δ(n).
Chapter 1 - Discrete-time Signals and Systems 23
The response of the system to this input is called the impulse response, denoted by h(n), i.e.,
H
x (n ) (n) y (n) h( n)
i.e.,
1, 0, 0, 0,
H
h0 , h1 , h2 , h3 ,
and using the time-invariance property, we get
H
(n D) h(n D)
i.e., say for D = 3,
0, 0, 0, 1, 0, 0, 0,
H
0, 0, 0, h , h , h , h ,
0 1 2 3
In general, the output y(n) of a linear time-invariant (LTI) system for an input x(n) is given as
This expression is discrete-time convolution or convolution sum. Since this is derived using
LTI properties of a system, it is referred to as the LTI form of convolution. Alternatively, it
may be expressed as
y (n ) h
m
m x (n m), direct form of convolution
two sequences x(m) and h(n-m) are multiplied sample-by-sample for - ∞ < m < ∞ and the
products are summed to compute the output sample, at time n, y(n). This is repeated for each
shift n. The convolution sum may be carried out numerically or analytically. The following
example illustrates discrete-time convolution evaluated analytically.
y ( n) x(m) h(n m)
m
where h(n-m) and x(m) are plotted as shown below on the same axes, for N=6 and
n=-3. The convolutional equation will be plotted for various possible values of n.
These plots are shown below.
h(n-m), N = 6, n=-3
1
x(m)
•••
-10 0 10 20 m
n-(N-1) n = -3
= -8
i) For positive values of n, h(n-m) is shifted right and it is shifted left for negative
values of n. The sample by sample product x(m)h(n-m) is zero when there is no
overlap. Thus, for this example, x(n) and h(n-m) do not overlap when n < 0.
Hence, the output for n < 0 is
y ( n) 0, n 0
ii) For n 0 and n 5 0, i. e., 0 n 5 we see that there is some overlap between
h(n-m) and x(m) and
Chapter 1 - Discrete-time Signals and Systems 25
x(m)
-10 -5 0 5 10 15 20 m
n-(N-1) n=3
= -2
h(n-m), N = 6, n = 14
1
x(m)
•••
-10 -5 0 5 10 15 20 m
n-(N-1) n = 14
= 9
y(n)
•••
-5 0 5 10 15 20 25 30 n
Finally, since all linear time-invariant systems are described by the convolution sum, the
properties of this class of systems are defined by the properties of discrete-time convolution.
General properties of the class of linear time-invariant systems can be found by considering
properties of the convolution operation, which may be obtained from the defining sum.
Linearity and time-invariance define a class of systems with very special properties. Stability
and causality represent additional properties. It was noted earlier that a stable system is one
for which every bounded input produces a bounded output. A necessary and sufficient
condition for stability of linear time-invariant system is that the impulse response be
absolutely summable, i.e.,
S h(m)
m
Causality of linear time-invariant systems imposes a condition on the impulse response of the
Chapter 1 - Discrete-time Signals and Systems 27
system, i.e.,
h(n) = 0, n < 0.
Consequently we may refer sequences that are zero for n < 0 as causal sequences.
1.6. Finite Impulse Response (FIR) and Infinite Impulse Response (IIR) Filters
The impulse response of LTI systems may be used to classify LTI systems into finite-duration
impulse response (FIR) and infinite-duration impulse response (IIR) systems depending on
whether the duration of the impulse response is finite or infinite, respectively.
FIR systems have finite-duration impulse response and hence are always stable (i.e., S < ∞ ).
Let h(n), nonzero over 0 n M and zero for n M , be the impulse response of a causal
FIR filter, i.e.,
The response of an FIR filter to an input x(n) may be computed using the convolution sum.
Taking the direct form of convolution, and assuming a causal FIR impulse response, the
output becomes
M
y ( n) h(m) x(n m),
m 0
FIR filtering equation
h0 x (n) h1 x(n 1) h2 x (n 2) hM x (n M )
This is the I/O equation of the FIR filter and is referred to as the FIR filtering equation. Thus,
the I/O equation is obtained as a weighted sum of the present input sequence value, ( ), and
the past M input sequence values, ( − 1), ( − 2), ( − 3), . . . , ( − ). Given an I/O
equation finding the impulse response is straight forward.
A causal IIR filter has an impulse response h(n) of infinite duration. Thus, the I/O equation
has an infinite number of terms, i.e.,
y ( n) h(m) x(n m),
m 0
IIR filtering equation
h0 x (n) h1 x (n 1) h2 x (n 2)
This form of the I/O equation is not computationally feasible since we cannot deal with an
infinite number of terms. This type of filter has an infinite number of filter coefficients {h 0,
h1, h2, h3, . . .}. We will consider a subclass of IIR filters for which the infinite number of
filter coefficients is coupled to each other through constant-coefficient linear difference
equations. The filter coefficients in such cases are recursively related to each other. Thus, IIR
filters of this subclass are referred to as recursive digital filters in the literature.
Example 1.6.2:- i) Determine the I/O difference equation of the causal IIR system whose
impulse response coefficients are coupled to each other by the difference equation
Assume causality, i.e., h(-1) = 0. Thus, from the coupled difference equation we get
h(0) = h0 = 0 + 1 = 1
h(1) = h1 = h0 + 0 = 1
h(2) = h2 = h1 + 0 = 1
. .
. .
. .
h(n) = hn = hn-1 + 0 = 1
= ℎ( ) ( − ) = ( − )
= + + +⋯
Note also that the previous output at n = n-1 becomes
yn 1 xn 1 x n 2 x n 3 xn 4
= +
This equation represents an accumulator or discrete-time integrator. Note that the
form of the coupled equation for h(n) is the same as that of the difference equation.
This is normally the case.
Get an analytical form for h(n) to be used in the convolutional form, as follows:
ℎ = ℎ + = .0+1 = 1
ℎ = ℎ + = .1 +0 =
ℎ = ℎ + = . +0 =
ℎ = ℎ + = . +0=
⋮
Thus, we see that the impulse response may be represented by the expression
an , n 0
h ( n) hn a n u( n)
0, n 0
yn x n axn 1 a 2 x n 2 a 3 xn 3
x n a[ x n 1 ax n 2 a 2 x n 3 ]
x n ay n 1
yn ay n1 xn
iii) Determine the convolutional form and the (causal) impulse response of the IIR filter
described by the following difference equation.
yn 0.8 yn 1 xn
hn 0.8hn1 n
30. Introduction to Discrete-time Signals Processing
Assuming causal initial condition, h(-1) = 0 and iterating for a few values of n, we
get
(−0.8) ≥0
ℎ = (−0.8) ( )=
0, ≤ −1
Inserting this in the convolutional equation gives
= (−0.8) ( − )
= ( ) + (−0.8) ( − 1) + (−0.8) ( − 2) + ⋯
= −0.8 + ( )
iv) Determine the I/O difference equation of the IIR filter that has the following causal
periodic impulse response.
h(n) = {2, 3, 4, 5, 2, 3, 4, 5, 2, 3, 4, 5, . . . }
Note that the period of this signal is N = 4. Delay the impulse response by one period,
i.e.,
h(n-4) = { 0, 0, 0, 0, 2, 3, 4, 5, 2, 3, 4, 5, 2, 3, 4, 5, . . . }
Thus,
h(n) - h(n-4) = 2 δ(n) + 3 δ(n-1) + 4 δ(n-2) + 5 δ(n-3)
i.e.,
h(n) = h(n-4) + 2 δ(n) + 3 δ(n-1) + 4 δ(n-2) + 5 δ(n-3)
2
xn + yn
z-1 3 z-1
xn-1 yn-1
-1
z-1 z
4 yn-2
xn-2
z-1
z-1
5 yn-3
xn-3 z-1
yn-4
In general, the IIR filters we shall consider will have impulse responses, h(n), that satisfy
constant-coefficient difference equations of the general type:
M L
h ( n) a
k 1
k h( n k ) a (n k )
k 0
k
The corresponding convolutional form can be expressed as the difference equation of the
general type:
M L
y ( n) a
k 1
k y (n k ) a
k 0
k x (n k )
where the first sum is the recursive term and the second sum is the non-recursive term.
Other equivalent descriptions of FIR and IIR filters or LTI discrete-time systems are:
i) I/O difference equation
ii) Convolutional equation
iii) Impulse response, h(n)
iv) Transfer function, H(z)
v) Frequency response, H(ω)
vi) Pole-zero pattern
vii) Block diagram realization and sample processing algorithm.
We will look at most of these equivalent descriptions in subsequent chapters. Since we use
the difference equation description in the analysis of systems we need to look at the time-
domain solution of difference equations in the next section.
( )= ( − )+ ( − )
or
( − ) = ( − ), = 1.
The information is complete given the initial state of the system. The form of the solution
will also depend on the initial state and the second term of the difference equation. When the
second term is zero the resulting equation is a homogeneous equation and the response is the
homogeneous response or the zero-input response. The zero-input response is a characteristic
response of the system and it is also known as the natural response or free response of the
system. The zero-input response is due to the initial state of the system. On the other hand, if
the system is initially relaxed and an input is applied, then the response is called the zero-
state response or forced response. The zero-state response depends on the nature of the
system and the input signal.
Homogeneous Equation and the Zero-Input Response:- Consider the linear constant-
coefficient homogeneous equation:
N
a
k 0
k y(n k ) 0, a0 1.
a k n k n a1n 1 a2 n 2 a N n N 0
k 0
i.e.,
n N { N a1 N 1 a 2 N 2 a N } 0
The expression inside the parenthesis is the characteristic polynomial. The characteristic
equation will have N roots, { }, i = 1, 2, 3, 4, . . ., N, which may be real or complex. If the
coefficients {ai} are real, then complex roots appear in complex conjugate pairs. The roots
may be distinct or repeated.
i) Distinct roots case:- the form of the most general solution will be a linear combination of
those for each characteristic root, i.e.,
yh (n) c11n c2 n2 c3 3n c N nN
Chapter 1 - Discrete-time Signals and Systems 33
where the coefficients {ci} are determined from the initial conditions specified for the system.
Since x(n) = 0, the above solution is the zero-input response.
Example 1.7.1:- Determine the zero-input response of the system described by the difference
equation
y(n) a1 y (n 1) 0
Assume
y (n) n
Then
+ = 0
( + ) = 0
= −
Hence, the homogeneous solution is
yh (n) cn c( a1 ) n
The zero-input response may be obtained for a given initial condition. From the
difference equation, we have
y (0) a1 y ( 1)
And from the homogeneous solution we get
y h (0) c
Hence, the zero-input response of the system is
y zi (n) a1 y (1)( a1 ) n
y ( 1)( a1 ) n1
y h (n) n
Substitute this in the difference equation and solve for the characteristic roots. The
characteristic equation is
2 3 4 0
The characteristic roots are λ = -1 and λ = 4. The form of the general homogeneous
solution is
yh (n) c11n c2 n2 c1 ( 1) n c2 4 n
34. Introduction to Discrete-time Signals Processing
To determine the zero-input response, we need to be given the initial conditions y(-1)
and y(-2). Use the initial condition to solve for unique values for c1 and c2. Thus, for
y(-2) = 0 and y(-1) = 5, we get
yh (n) ( 1) n 1 4 n 2
ii) Repeated roots:- If some of the roots of the characteristic equation are repeated, then the
form of the solution will be modified. Assume that λ1 is a root of multiplicity m of the
characteristic equation. Then, the form of the homogeneous solution is
y h (n) c11 1n c12 n1n c13 n 2 1n c1m n m11n c2 n2 c N nN
where the coefficients, {ci, cij}, are solved using the specified initial conditions of the system.
The technique used to determine the particular solution is to assume that the response will
have the same form as the input itself to within a multiplier constant. Thus, assume a
particular solution to have the same form as the input. This will be demonstrated with an
example.
where K is a constant whose value will have to be determined from the difference
equation. Substitute the assumed solution in the difference equation and determine the
value of K. Thus,
Ku(n) a1 Ku(n 1) u(n)
Chapter 1 - Discrete-time Signals and Systems 35
For n ≥ 1, we get
K a1 K 1
1
i.e., K
1 a1
Thus, the particular solution to the difference equation is
1
y p ( n) u( n)
1 a1
and together with the homogeneous solution constitute the general solution of the
difference equation, i.e.,
y (n ) y h (n) y p ( n)
as stated before.
In general, the form of the particular solution depends on the type of the input and on the
nature of the characteristic roots in relation with the input signal. The form of the general
solution for some input signals is summarized below for your reference.
A(n)p K0 n p K1n p 1 K p
Annp An ( K 0 n p K1n p 1 K p )
Acos(ωn) K1 cos(n) K2 sin(n)
Asin(ωn)
5 1
K 2 n u( n) K 2 n1 u(n 1) K 2 n 2 u( n 2 ) 2 n u( n)
6 6
To determine K, evaluate this equation for any ≥ 2, where none of the terms vanish
or divide the equation by 2 n. Thus,
5 1
4K (2 K ) K 4
6 6
i.e.,
8
K .
5
Thus,
8 n
y p ( n) (2 ), n0
5
The total solution becomes
y ( n) y h ( n) y p (n).
6 n
y ( n) c1 ( 1) n c2 4 n n4 u(n), n 0.
5
Note:- when the input is an impulse, and a relaxed system assumed, the particular solution is
zero, since x(n) = 0 for n > 0. Thus, the response of a system to an impulse consists of the
solution to the homogeneous equation.
Example 1.7.6 : Determine the impulse response, h(n), of the system described by
( ) − 3 ( − 1) − 4 ( − 2) = ( ) + 2 ( − 1)
Note that, from our previous result (Example 1.7.5.), the homogeneous solution is
( )= (−1) + 4 , ≥ 0.
Since the particular solution is zero when the input is an impulse, the above solution
is the total solution. Since the solution is applicable for n ≥ 0, we must derive an
equivalent set of initial conditions for y(0) and y(1) by evaluating the difference
equation at n = 0 and n = 1, with x(n) = δ(n). Thus we get, assuming the system is
initially relaxed, i.e., y(-1) = y(-2) = 0,
y(0) = 1, y(1) = 5.
Put these values in the homogeneous solution to get
( 0) = 1 = ( 1) + ( 1)
( 1) = 5 = (−1) + (4)
Solving the above set of equations, we get
1 6
c1 and c2
5 5
Thus,
1 6
( ) = ℎ( ) = − (−1) + (4) ( ).
5 5
systems theory.
=
= ( )
Thus, the frequency response of an ideal delay system is
( )=
Alternatively, the frequency response may be obtained from
H ( ) h( n) e j n
n
where h(.) is the impulse response of the system. Note that ℎ( ) = ( − ) and
thus, for an ideal delay system
( )= ( − ) =
The concept of the frequency response of linear time-invariant systems is essentially the same
for continuous-time and discrete-time systems. However, the frequency response of discrete-
time linear time-invariant systems is always a periodic function of the frequency variable ω,
Chapter 1 - Discrete-time Signals and Systems 39
H ( )
and, in general, for any integer k, we get
( +2 )= ( )
i.e., ( ) is periodic with period 2π. Since ( ) is periodic with period 2π, and since
frequencies ω and ω + 2π are indistinguishable, it follows that we need only specify ( )
over any convenient interval of length 2π, i.e., − < ≤ or 0 ≤ < 2 . In general,
it is more convenient to specify ( ) over the interval − < ≤ . With respect to this
interval, the low frequencies are frequencies around zero, while the high frequencies are those
close to ± π. In general, the low frequencies are those that are close to an even multiple of π,
while the high frequencies are those that are odd multiples of π.
As an example, consider the class of ideal frequency-selective linear time-invariant filters for
which the frequency response is unity over a certain range of frequencies and zero over the
remaining frequencies.
Hlp(ω)
1
a)
Hlp(ω)
1
-π -ωc 0 ωc π ω
b)
Fig. 1.1. Ideal lowpass filter showing (a) periodicity of the frequency response
b) one period of the frequency response.
40. Introduction to Discrete-time Signals Processing
Note that the synthesis integral represents x(n) as a superposition of infinitesimally small
complex sinusoids of the form
1
X ( )e j n d
2
with X(ω) determining the relative amount of each complex sinusoidal component.
The frequency response of a linear time-invariant system is simply the Fourier transform of
the impulse response. Hence, the impulse response and the frequency response are Fourier
transform pairs, i.e.,
1
h ( n)
2
H ( )e
j n
d ,
and
H ( ) h (n ) e j n
.
n
Note that the frequency response H(ω) is a periodic function of ω, with period 2π. It is
beneficial to compare this pair with that of the Fourier series representation of continuous-
time signals, since many Fourier series properties may be applied to the Fourier transform,
with appropriate interpretation. From convergence requirements at every ω of the infinite
series, H(ω), a sufficient condition for existence of the Fourier transform is that the sequence
x(n) be absolutely summable, i.e.,
| ( )| ≤ | ( )| < ∞.
Example 1.8.2: Determine the impulse response of the ideal lowpass filter, defined by
1, c
H ( )
0, c | |
The impulse response is obtained using the synthesis formula
Chapter 1 - Discrete-time Signals and Systems 41
1 sin ( )
ℎ ( ) = 1. = , −∞< <∞
2
Note that hlp(n) is nonzero for n < 0, i.e., the ideal lowpass filter is noncausal. Also,
hlp(n) is not absolutely summable and thus ( )
sin( ) sin ( )
( )= = lim = lim ( ),
→ →
does not converge uniformly for all values of . The convergence property of
( )is shown below for several values of M. Uniform convergence requires that
for every value of ω we get
lim | ( )− ( ) | = 0.
→
HM(ω)
M = 19
ideal case M =7
1
Hlp(ω) M =3
M =1
0.5
-π -ωc 0 ωc π ω
FT
If x(n) X ( )
then for the time-shifted sequence,
FT
x(n N) e j N X ( )
and for the frequency-shifted Fourier transform,
FT
e j 0n x(n) X ( 0 )
3. Time Reversal
FT
If x(n) X ( )
then the time reversed sequence
FT
x( n) X ( )
If x(n) is real, this theorem reduces to
FT
x( n) X * ( )
4. Differentiation in Frequency
FT
If x(n) X ( )
FT d
then nx(n) j X ( )
d
5. Parseval’s Theorem
FT
If x(n) X ( )
1 2 2
then E
n
x ( n)
2
X ( ) d
The function | ( )| is called the energy density spectrum. It defines how signal energy is
distributed with frequency and is defined for energy signals only.
then Y() X ( ) H ( )
This is periodic convolution of two periodic functions with the limits of integration extending
over only one period.
2. x (n N ) e jN X ( )
3. e j 0n x (n) X ( 0 )
4. x(-n) X(-ω)
d
5. nx(n) j X ( )
d
6. x(n)*y(n) X ( )Y ( )
1
7. x(n)y(n)
2 X ( )Y ( )d
2 1
8. E
n
x ( n)
2
| ( )|
2 ( 0 2k )
k
11. cos( 0 n )
[e (
k
j
0 2k ) e j ( 0 2k )]
The student is advised to try the proofs of these theorems or refer to the proofs elsewhere. We
will encounter the Fourier transform at various places in this book. The above theorems and
some basic transform pairs are summarized here for easy reference only. Some examples will
be given towards the end of this section.
a 5 e j 5
1 ae j
We could have used Theorems 1 and 2 to express the transform by considering the
fact that we could have represented the sequence x(n) as
x ( n) a 5a n 5 u(n 5)
Example 1.8.4: Determine the impulse response of the stable linear time-invariant system
for which the input x(n) and output y(n) satisfy the linear constant-coefficient
difference equation
Chapter 1 - Discrete-time Signals and Systems 45
1 1
y ( n) y (n 1) x ( n) x (n 1)
2 4
To find the impulse response, set x (n) (n) . Then, the impulse response of the
system becomes
1 1
h ( n) h(n 1) ( n) (n 1)
2 4
Applying the Fourier transform to both sides, we get
1 j 1 j
H ( ) e H ( ) 1 e
2 4
i.e.,
1 j
1 e
H ( ) 4
1
1 e j
2
To obtain h(n), we need to determine the inverse Fourier transform of H(ω). To do
this, we need to represent H(ω) in a partial fraction expansion, i.e.,
1 j
1 e
H ( ) 4
1 1
1 e j 1 e j
2 2
Using Fourier transform pairs, we get
n n1
1 1 1
h ( n) u( n ) u(n 1)
2 4 2
46. Introduction to Discrete-time Signals Processing
Problems
a) ( ) = (4 − )
b) ( ) = (2 − 3)
c) ( ) = (8 − 3 )
d) ( ) = ( 2 − 3)
e) ( )= ( − 2 + 1)
1.2. Find the conjugate symmetric and conjugate antisymmetric parts of the following
signals:
a) ( )= ( )
b) ( )= ( ), = 0.5 + 0.5.
( )= / ( )
c)
( )= (− )
a) Is x(n) absolutely summable? If so find the absolute sum of x(n).
b) Compute the power in x(n).
c) If x(n) is input to a system defined by
( )= ( ),
find the power in the output signal.
1.4. Express
( )= ( ) + 2 ( − 1) + 3 ( − 2)
as a sum of scaled and shifted unit step sequences.
1.5. Each of the following systems have x(n) as input and y(n) as output. Determine
whether the system is i) stable, ii) causal, iii) linear, and iv) time-invariant.
a) ( )= ( ) + 3 ( + 1)
b) ( ) = 6 ( + 2 ) + 4 ( + 1) + 2 ( ) + 1
c) ( ) = log ( )
( )= ( )
d)
Chapter 1 - Discrete-time Signals and Systems 47
e) ( )= (− )
1.6. Use convolution principles to determine the response of a system whose impulse
response is
ℎ( ) = (0.5) ( )
to the input
1
( )= ( )− ( − 1)
2
This can be done easily since convolving any sequence with an impulse is the signal
itself placed at the location of the impulse.
1.7. By direct evaluation of the convolution sum, determine the step response of a linear
time-invariant system whose impulse response is given by
ℎ( ) = (− ), 0< < 1.
1.8. If the response of a linear shift-invariant system to a unit step is
1
( )= ( ),
2
find the impulse h(n) response of the system.
1.9. Find
( ) = ( ) ∗ ℎ( )
given
ℎ( ) = { ( ) − ( − 11)}
and
( )= ( ) − ( − 6)
( )= ( )⋆ ( ) = ( )ℎ( + ).
Note that we use a star ⋆ to denote correlation and an asterisk ∗ to denote convolution.
a) Find and plot the correlation (often known as the cross correlation function)
between the sequence
( )= ( ) − ( − 6)
and
ℎ( ) = ( − 2) − ( − 5) .
48. Introduction to Discrete-time Signals Processing
1.11. A commonly used numerical approximation called the first backward difference is
defined as
( )= ∇ ( ) = ( ) − ( − 1)
where x(n) is the input and y(n) is the output of the first-difference system.
a) Show that this system is linear and time-invariant.
b) Find the impulse response of this system.
c) Find and sketch the frequency response (magnitude and phase).
d) Implement this differentiator on the sequence x(n) and plot the results.
( ) = 5{ ( ) − ( − 20)}
Comment on the appropriateness of this simple differentiator.
1.12. For the system shown, determine the output y(n) when the input ( ) = ( ) and
( ) is an ideal lowpass filter, i.e.,
1, | |< ,
( )=
0, <| |≤ .
n
(-1) w(n)
×
w(n) n
x(n) ( ) (-1) + y(n)
( ) = ⋯ , −2, 4, ⏟
3 , −6, 5, −1, 8, ⋯
↑
( ) = ⋯ , −2, ⏟
3 , 5, 8, ⋯
↑
1.15. Let X(ω) denote the Fourier transform of the signal x(n) shown below. Perform the
following calculations without explicitly evaluating X(ω).
a) Evaluate X(ω) at ω = 0.
b) Find ∢ ( ).
c) Evaluate
( ) .
2 2
1 1
-5 0 5 10 15 n
-1 -1
50. Introduction to Discrete-time Signals Processing