You are on page 1of 5

EE3054 - Quiz 1 - Solutions

1. The system is given to be


y[n] = ex[n−1] + nx[n + 2].
(a) The system is nonlinear due to the presence of the ex[n−1] term.
To prove that the system is nonlinear, consider a signal x[n] which
when applied as the input signal to the system produces the output
signal y[n]. Then, the output signal of the system when the input
signal αx[n] is applied is
yα [n] = eαx[n−1] + nαx[n + 2]. (1)
which is not equal to αy[n]. Hence, the system is nonlinear.
(b) The system is noncausal due to the x[n + 2] term which involves
future values of the input signal, i.e., the value of the output signal
at time n0 depends on values of the input signal for times n > n0 .
(c) The system is time varying. To verify this, consider a signal x[n]
which when applied as the input signal to the system produces the
output signal y[n]. Then, the output signal of the system when
the input signal x[n − n0 ] is applied is
yn0 [n] = ex[n−n0 −1] + nx[n − n0 + 2]. (2)
which is not equal to y[n − n0 ]. Hence, the system is time varying.
2. The system is given to be
y[n] = −y[n − 1] + x[n].
Two methods to evaluate the impulse response h[n] of the system are
given below:
Method 1: Iteratively compute h[n] for n = 0, 1, 2, . . .. By definition,
the impulse response is the output signal when the unit impulse is
applied as the input signal. Hence,
h[0] = −h[−1] + δ[0] = 0 + 1 = 1
h[1] = −h[0] + δ[1] = −1 + 0 = −1
h[2] = −h[1] + δ[2] = −(−1) + 0 = 1
..
. (3)

1
Hence, h[n] is 0 for n < 0, 1 for even nonnegative n and −1 for odd
nonnegative n, i.e.,

 1 if n even and n ≥ 0

h[n] = −1 if n odd and n ≥ 0 (4)
0 if n < 0.

In other words, h[n] = (−1)n u[n].


Method 2: The impulse response can be computed using the z-
transform. Taking the z-transform of both sides, we obtain
Y (z) 1
H(z) = = . (5)
X(z) 1 + z −1
1
We know the general result that the z-transform of αn u[n] is 1−αz −1 .

Hence, the function H(z) shown in (5) is the z-transform of h[n] =


(−1)n u[n].

(a) The system is linear and time invariant (LTI). However, it is


not FIR since, as shown above, the impulse response is h[n] =
(−1)n u[n] which is not of finite length.
(b) As shown above, the impulse response of the system is h[n] =
(−1)n u[n].
1
(c) From the general result that the z-transform of αn u[n] is 1−αz −1 ,
n
we obtain the z-transform of the impulse response h[n] = (−1) u[n]
to be
1
H(z) = . (6)
1 + z −1
Since h[n] = 0 for n < 0, it is a causal signal so that the region of
convergence is the exterior of the circle with center at the origin
of the complex plane and radius 1.
(d) Given the input signal x[n] = u[n], the output signal y[n] can be
computed using two methods:
Method 1: Iteratively, compute y[n] for n = 0, 1, 2, . . .. We
obtain

y[0] = −y[−1] + u[0] = 0 + 1 = 1

2
y[1] = −y[0] + u[1] = −1 + 1 = 0
y[2] = −y[1] + u[2] = −0 + 1 = 1
..
. (7)
In general, y[n] is 0 for n < 0, 1 for even nonnegative n and 0 for
odd nonnegative n, i.e.,

 1 if n even and n ≥ 0

y[n] =  0 if n odd and n ≥ 0 (8)

0 if n < 0.

Method 2: The output signal y[n] can be computed using the


one-sided z-transform. We know that z{u[n]} = 1−z1 −1 . Hence,
1
Y (z) = −z −1 Y (z) + . (9)
1 − z −1
Since the initial condition is y[−1] = 0, we do not get any term
depending on the initial conditions in (9). Simplifying (9),
1
Y (z) =
(1 − z −1 )(1
+ z −1 )
0.5 0.5
= + . (10)
1−z −1 1 + z −1
Note that y[n] is a causal signal since it is the output signal of
the causal system (3) when the causal input signal x[n] = u[n] is
applied. We also know the general result that the z-transform of
1
αn u[n] is 1−αz −1 . Hence, from (10)

y[n] = 0.5(1)n u[n] + 0.5(−1)n u[n]. (11)


The first and second terms of (11) cancel out if n is odd. Hence,
y[n] is 0 for n < 0, 1 for even nonnegative n and 0 for odd non-
negative n.
(e) The plot of the signal y[n] is shown in Figure 1.

3. (a) The input x[n] is the number of extra chicken (the part not de-
pendent on y) added in the nth month, i.e., the chicken given to
Mr. Goose by his brother in the nth month. Hence, x[n] = 10u[n].
The output y[n] is the number of chicken in the nth month.

3
1

0.9

0.8

0.7

0.6

0.5
y[n]

0.4

0.3

0.2

0.1

0
−10 −8 −6 −4 −2 0 2 4 6 8 10
n

Figure 1: Problem 2(e): Output signal y[n].

(b) At time n, the following factors contribute to change in the number


of chicken from y[n − 1] to y[n]:
• The chicken bought by Mr. Goose from the proceeds of the
sale of eggs: The number of eggs is r eggs/chicken/month
×y[n − 1] chicken × 1 month = ry[n − 1] eggs. The amount
of money that Mr. Goose gets by selling the eggs is ry[n − 1]
eggs ×0.5 $/egg = 0.5ry[n − 1] $. Hence, the number of
chicken that Mr. Goose buys = 0.5ry[n − 1] $ ×1 chicken/$
= 0.5ry[n − 1] chicken.
• The chicken that die at time n: This number is the number
of chicken that were alive at time n − 2, i.e., y[n − 2] chicken
die at time n.
• The chicken given to Mr. Goose by his brother = x[n] chicken.
Hence, combining together the effects of the above factors,

y[n] = y[n − 1] + 0.5ry[n − 1] − y[n − 2] + x[n]. (12)

(c) To check stability, we need to look at the poles of the system which

4
can be found from
Y (z) 1
H(z) = = . (13)
X(z) 1 − (1 + 0.5r)z −1 + z −2

By solving the quadratic equation

z 2 − (1 + 0.5r)z + 1 = 0, (14)

it can be shown that one of the roots always lies out of the unit
circle for any r. This can also be seen more easily by noting that
given any quadratic equation

z 2 − az + b = 0, (15)

the sum of the roots is a and the product of the roots is b. In this
case, from (14), we find that the product of the roots of (14) must
be 1. Hence, it is impossible for both the roots to lie inside the unit
circle (because given any two complex numbers with magnitudes
less than 1, their product has to be less than 1). Therefore, the
system is not BIBO stable for any r.

You might also like