Вы находитесь на странице: 1из 25

Homework # 1

Ch.2 # 21, 23, 28, 30, 32, 33, 35, 38, 40

Dr. Ray Kwok


SJSU
Fall 2013
2.21
A discrete-time signal x[n] is shown here.
Sketch and label carefully each of the following signals.

(a) x[n-2]

shift 2 to the right

(b) x[4-n]

flip about the 0-axis and shift 4 to the right

(c) x[2n]

shrink by a factor of 2

(d) x[n]u[2-n]

cut off n>2


(e) x[n-1][n-3]

x[2] when n=3, x[n]=0 for all other n.

Dr. Ray Kwok Homework # 1 2


2.23
For each of the following systems, determine whether the system is (1) stable, (2) causal, (3) linear,
and (4) time invariant.
(a) y[ n ]. T ( x[ n]) = cos(n) x[ n]

Stable x[n] is defined and cosine is finite.

Causal y[n] only depends on present value of n.

Linear. y1[n] T ( x1[n]) = cos(n) x1[n]


y2 [n] T ( x2 [n]) = cos(n) x2 [ n]
ay1[ n] + by2 [ n] = cos(n) (ax1[ n] + bx2 [n]) = T ( ax1[n] + bx2 [n])

Its NOT time invariant.

cos(n) = ( 1)
n

y[n] = T ( x[n]) = cos(n) x[n] = ( 1) x[n]


n

y[n 1] = ( 1) x[n 1] ( 1) x[n 1]


n 1 n

Dr. Ray Kwok Homework # 1 3


2.23
(b) T ( x[n]) = x[n 2 ]
Stable x[n] is defined and so is x[n2].

It is NOT causal y[n] only depends on future value of n2.

Linear. y1[n] T ( x1[n]) = x1[n 2 ]


y2 [n] T ( x2 [n]) = x2 [ n 2 ]
ay1[n] + by2 [ n] = ax1[ n 2 ] + bx2 [n 2 ] = T (ax1[n] + bx2 [ n])

Its NOT time invariant.

y[n] = T ( x[n]) = x[n 2 ]


y[n no ] = x[(n no ) ] x[n 2 no ]
2

Dr. Ray Kwok Homework # 1 4


2.23
(c) T ( x[ n]) = x[n] [n k ]
k =0
Stable x[n] is defined and so is the delta function.

Causal y[n] only depends on present value of n.

Linear.
y1[n] T ( x1[ n]) = x1[n] [ n k ]
k =0

y2 [n] T ( x2 [n]) = x2 [n] [n k ]
k =0

ay1[ n] + by2 [n] = (ax1[n] + bx2 [ n]) [n k ] = T ( ax1[n] + bx2 [ n])
k =0

Its NOT time invariant.


y[n] = T ( x[n]) = x[n] [n k ]
k =0

y[n no ] = x[n no ] [n no k ] x[n no ] [ n k ]
k =0 k =0

Dr. Ray Kwok Homework # 1 5


2.23
(d) T ( x[n]) = x[k ]
k = n 1
NOT stable the infinite sum can diverge easily.

NOT Causal it sums all future k > n.

Linear.
y1[n] T ( x1[ n]) = x [k ]
k = n 1
1


y2 [n] T ( x2 [n]) = x [k ]
k = n 1
2


ay1[ n] + by2 [ n] = (ax [k ] + bx [k ]) = T (ax [n] + bx [n])
k = n 1
1 2 1 2

Its time invariant.



y[n] = T ( x[n]) = x[k ]
k = n 1

y[n no ] = x[k ] = x[k n ] = x[q]
k = n no 1 k = n 1
o
q = n 1 no

Dr. Ray Kwok Homework # 1 6


2.28
Four input-output pairs of a particular system S are specified in Fig.

(a) Can system S be time-invariant? Explain.

No. x4 = [ n ]
y4 = [n] + [n 1]
x3 = [n 1] +
y3 = [n 1] + But it doesnt.

or
x4 = [ n ]
y4 = [n] + [n 1]
x2 = [ n ] +
y2 = [n] + But it doesnt.

Dr. Ray Kwok Homework # 1 7


2.28
(b) Can system S be linear? Explain.

No, its not linear.

See for example,

x1 + x2 = 2( x3 + x4 )
but y1 + y2 2( y3 + y4 )

Dr. Ray Kwok Homework # 1 8


2.28
(c) Suppose (2) & (3) are input-output pairs of a
particular system S2, and the system is
known to be LTI. What is h[n], the impulse
response of the system?

One can construct a [n] by

x3 [n + 1] x3 [n] + x2 [n]
= [ n]
2
The output h[n] would then be y3[n + 1] y3[n] + y2 [n]
h[n] =
2
h[n] =
( [n 1] [n 5]) + y2 [n]
2
2 [n 1] + 2 [n 3]
h[n] =
2
h[n] = [n 1] + [n 3]

Dr. Ray Kwok Homework # 1 9


2.28
(d) Suppose (1) is the input-output pair of an LTI system S3.
What is the output of this system for the input in the Figure?

The input x[n] can be construct by

x[n] = x1[n] + x1[n 2]


So the output should be

y[n] = y1[n] + y1[n 2]

y[n] = [n] + [n 2] + [n 3] + [n 4] + [n 5] + [n 6]
y[n] = [n] + u[n 2] u[n 6]

Dr. Ray Kwok Homework # 1 10


2.30
Consider the cascade connection of two LTI systems in the figure
(a) Determine and sketch w[n] if x[n]=(-1)nu[n]. Also determine the overall output y[n].

y[n] = w[n] h2 [n] = w[n k ]h [k ]
k =
2

y[n < 3] = 0
y[3] = 1
y[2] = 1
y[1] = 2

y[0] = 2
w[n] = x[n] h1[n] = x[k ]h [n k ]
k =
1 y[1] = 1
y[2] = 1
w[n < 0] = 0 y[n > 2] = 0
w[0] = 1
w[1] = 0
w[2] = 1
w[n 3] = 0

Dr. Ray Kwok Homework # 1 11


2.30
(b) Determine and sketch the overall impulse
response of the cascade system. i.e., plot
the output y[n] = h[n] (when x[n] = [n]).


h[ n] = h1[n] h2 [n] = h [n k ]h [k ]
k =
1 2

h[n < 3] = 0
h[3] = 1
h[2] = 2
h[1] = 3
h[0] = 4
h[1] = 3
h[2] = 2
h[3] = 1
h[n > 3] = 0

Dr. Ray Kwok Homework # 1 12


2.30
(c) Now consider the input x[n] = 2[n] + 4[n-4] 2[n-12]. Sketch w[n].


w[n] = x[n] h1[n] = x[k ]h [n k ]
k =
1


w[n] = (2 [k ] + 4 [k 4] 2 [k 12])h [n k ]
k =
1

w[n] = 2h1[n] + 4h1[n 4] 2h1[n 12]

Dr. Ray Kwok Homework # 1 13


2.30
(d) For the input in part (c), write an expression for the output y[n] in terms of the overall impulse
response h[n] as defined in part (b). Make a carefully labeled sketch of your answer.


y[ n] = x[n] h[n] = x[k ]h[n k ]
k =

y[ n] = 2h[n] + 4h[n 4] 2h[n 12]

Dr. Ray Kwok Homework # 1 14


2.32 (This is the Example 2.21 in the textbook.)

For ( )
X e j =
1
1 ae j
with -1 < a < 0, determine and sketch the following as a function of :

1
(a) .
[ ( )] [ ( )
1
Re X e j = X e j + X * e j =
2
( )] 1
+
1
2 1 a (cos j sin ) 1 a(cos + j sin )
1 a cos 1 a cos
[ ( )]
Re X e j = =
(1 a cos ) + a 2 sin 2 1 2a cos + a 2
2

1
(b)
[ ( )]
Im. X e j =
1
2j
[ ( )
X e j X * e j = ( )] 1

1
2 j 1 a (cos j sin ) 1 a (cos + j sin )
a sin
[ ( )]
Im X e j =
1 2a cos + a 2


(c) ( ) ( ) ( )
X. e j = X e j X * e j =
1

1

1 a(cos j sin ) 1 a(cos + j sin )

( )
X e j =
1
1 2a cos + a 2

( )
.X e j 1
= tan
[ ( )] = tan
Im X e j 1 a sin

(d)
[ ( )]
Re X e
j
1 a cos

Dr. Ray Kwok Homework # 1 15


2.33
Consider an LTI system defined by the difference equation y[n] = -2x[n] + 4x[n-1] 2x[n-2]
(a) Determine the impulse response of this system.

h[n] = 2 [n] + 4 [n 1] 2 [n 2]

(b) Determine the frequency response of this system. Express your answer in the form of

H (e j ) = A(e j )e jnd
where A(ej) is a real function of . Explicity specify A(ej) and the delay of nd of this system.

h[n] = 2 [n] + 4 [n 1] 2 [n 2]
H (e j ) = 2 + 4e j 2e j 2
H (e j ) = 2e j (e j 2 + e j ) = 2e j (2 cos 2) = 4e j (1 cos ) = 4e j (2 sin 2 ( / 2))
H (e j ) = 8e j sin 2 ( / 2)

Delay nd = 1

Dr. Ray Kwok Homework # 1 16


2.33
(c) Sketch a plot of the magnitude |H(ej)| and a plot of the phase

H (e j ) = 8e j sin 2 ( / 2)

H (e j ) = 8 sin 2 ( / 2)

H (e j ) =

Dr. Ray Kwok Homework # 1 17


2.33 j 0.5n
(d) Suppose that the input to the system is x1[n] = 1 + e
Use the frequency response function to determine the corresponding output y1[n].

See section 2.9.6 in the textbook.

If x[n] = e jn
y[ n] = H (e j )e jn

Here x1[ n] = 1 + e j 0.5n = e j 0 n + e j 0.5n


y1[n] = H (e j 0 )e j 0 n + H (e j 0.5 )e j 0.5n

with H (e j ) = 8e j sin 2 ( / 2)
y1[n] = 0 + 8e j / 2 sin 2 ( / 4)e jn / 2
y1[n] = 4e j ( n 1) / 2

Dr. Ray Kwok Homework # 1 18


2.33
(d) Now suppose that the input to the system is x2 [n] = 1 + e u[n] ( j 0.5n
)
Use the defining difference equation or discrete convolution to determine the corresponding
output y2[n]. Compare y1[n] and y2[n]. They should be equal for certain values of n. Over what
range of values of n are they equal?

h[k ]x [n k ] = h[k ](1 + e )u[n k ] = h[k ](1 + e )


n
j ( n k ) / 2 j ( n k ) / 2
y 2 [ n] = 2
k = k = k =

( )
n
For a causal system, h[n]=0 if n<0. So, n >=0 and y2 [n] = h[k ] 1 + e j ( n k ) / 2
k =0

y2 [n] = 2 + 4 2 2 e jk / 2 + 4 e jk / 2e j / 2 2 e jk / 2 e j
n
1 e jn / 2
y 2 [ n] = 4 j e jk / 2
= 4 j j / 2

k =0 1 e

(
y2 [n] = h[k ] 1 + e j ( n k ) / 2 ) h[k ](1 + e j ( n k ) / 2
)
k =0 k = n +1

y2 [n] = h[k ] + h[k ]e jk / 2
e jn / 2
h[k ](1 + e j ( n k ) / 2
)
k =0 k =0 k = n +1 h[n] = 2 [n] + 4 [n 1] 2 [n 2]

y2 [n] = H (e j 0 ) + H (e j / 2 )e jn / 2 h[k ](1 + e
k = n +1
j ( n k ) / 2
) h[n > 2] = 0

y2 [ n] = y1[n] for n>2
y2 [n] = y1[n] h[k ](1 + e
k = n +1
j ( n k ) / 2
)

Dr. Ray Kwok Homework # 1 19


2.35
An LTI system has the input and impulse response given by the following plots:

(a) Use discrete convolution to determine the output of the system y[n] = x[n]*h[n] for the above input.
Give your answer as a carefully labeled sketch of y[n] over a range sufficient to define it completely.

y[n] = x[n] h[ n] = x[k ]h[n k ]
k =

y[n<0]=0
y[0] = 1
y[1] = 0
y[2] = 1
y[3] = 0
y[4] = 5
y[5] = 0
y[6] = 1
y[7] = 0
y[8] = 1
y[n>8] = 0

Dr. Ray Kwok Homework # 1 20


2.35
b) The deterministic autocorrelation of a signal x[n] is defined in Eq.(2.188) as cxx[n] = x[n]*x[-n].
The system defined by figures above is a matched filter for the input shown. Noting that h[n] =
x[-(n-4)], express the output in part (a) in terms of cxx[n].


chh [l] h[k ]h[l + k ]
k =

h[n] = x[(n 4)]



y[n] = x[n] h[n] = x[k ]h[n k ] = x[k ]x[((n k ) 4)]
k = k =

y[n] = x[k ]x[(4 n) + k ] = c
k =
xx [ 4 n]

Dr. Ray Kwok Homework # 1 21


2.35
c) Determine the output of the system whose impulse
response is h[n] when the input is
x[n] = u[n+2]. Sketch your answer.


y[n] = x[ n] h[n] = x[k ]h[n k ] = u[k + 2]h[n k ]
k = k =

y[n<-2]=0
y[-2] = 1
y[-1] = 2
y[0] = 3
y[1] = 2
y[2] = 3
y[n>2] = 3

Dr. Ray Kwok Homework # 1 22


2.38
Consider the cascade of two LTI systems in the figure

The impulse responses of the two systems are: h1[n] = u[n 5]


1, 0 n 4
h2 [n] =
0, otherwise

(a) Make a sketch showing both h2[k] and h1[n-k] (for some arbitrary n<0) as function of k.

Dr. Ray Kwok Homework # 1 23


2.38
b) Determine h[n] = h1[k]*h2[n] , the impulse response of the overall system. Give your answer as
an equation (or set of equations) that define h[n] for < n <
or as a carefully labeled plot of h[n] over a range sufficient to define it completely.

h[n] = h1[n] h2 [n] = h [k ]h [n k ]
k =
1 2

y[n<5]=0
y[5] = 1
y[6] = 2
y[7] = 3
y[8] = 4
y[9] = 5
y[n>9] = 5

Dr. Ray Kwok Homework # 1 24


2.40
Determine which of the following signals is periodic. If a signal is periodic, determine its period.

(a)
x[n] = e j (2n / 5 ) Periodic. x[n + N ] = e j 2 ( n + N ) / 5 = x[n]
2N
= 2
5
N =5


(b) x[n] = sin(n / 19) Periodic.
x[n + N ] = sin (n + N ) = x[n]
19
N
= 2
19
N = 38

(c) x[n] = ne jn Not periodic because of the n in front of the exponential.

(c)
x[n] = e jn Not periodic. x[n + N ] = e j ( n + N ) = x[ n]
N = 2 which is not an integer.

Dr. Ray Kwok Homework # 1 25

Вам также может понравиться