Chapter 2 Discrete-Time Signals and Systems

Σχετικά έγγραφα
IIT JEE (2013) (Trigonomtery 1) Solutions

Ψηφιακή Επεξεργασία Εικόνας

CHAPTER 103 EVEN AND ODD FUNCTIONS AND HALF-RANGE FOURIER SERIES

Biorthogonal Wavelets and Filter Banks via PFFS. Multiresolution Analysis (MRA) subspaces V j, and wavelet subspaces W j. f X n f, τ n φ τ n φ.

1. For each of the following power series, find the interval of convergence and the radius of convergence:

Solve the difference equation


Homework for 1/27 Due 2/5

α β

Introduction of Numerical Analysis #03 TAGAMI, Daisuke (IMI, Kyushu University)

Last Lecture. Biostatistics Statistical Inference Lecture 19 Likelihood Ratio Test. Example of Hypothesis Testing.

3.4 SUM AND DIFFERENCE FORMULAS. NOTE: cos(α+β) cos α + cos β cos(α-β) cos α -cos β

Homework 4.1 Solutions Math 5110/6830

Fourier Series. Fourier Series

Homework 3 Solutions

FREE VIBRATION OF A SINGLE-DEGREE-OF-FREEDOM SYSTEM Revision B

Presentation of complex number in Cartesian and polar coordinate system

1. Matrix Algebra and Linear Economic Models

SUPERPOSITION, MEASUREMENT, NORMALIZATION, EXPECTATION VALUES. Reading: QM course packet Ch 5 up to 5.6

2 Composition. Invertible Mappings

Chapter 6: Systems of Linear Differential. be continuous functions on the interval

Solutions: Homework 3

EE512: Error Control Coding

p n r

EN40: Dynamics and Vibrations

ECE 308 SIGNALS AND SYSTEMS FALL 2017 Answers to selected problems on prior years examinations

CHAPTER 25 SOLVING EQUATIONS BY ITERATIVE METHODS

Assignment 1 Solutions Complex Sinusoids

DESIGN OF MACHINERY SOLUTION MANUAL h in h 4 0.

Probability and Random Processes (Part II)

Outline. M/M/1 Queue (infinite buffer) M/M/1/N (finite buffer) Networks of M/M/1 Queues M/G/1 Priority Queue

The Heisenberg Uncertainty Principle

n r f ( n-r ) () x g () r () x (1.1) = Σ g() x = Σ n f < -n+ r> g () r -n + r dx r dx n + ( -n,m) dx -n n+1 1 -n -1 + ( -n,n+1)

MATH 38061/MATH48061/MATH68061: MULTIVARIATE STATISTICS Solutions to Problems on Matrix Algebra

Outline. Detection Theory. Background. Background (Cont.)

Math221: HW# 1 solutions

Homework 8 Model Solution Section

CHAPTER 101 FOURIER SERIES FOR PERIODIC FUNCTIONS OF PERIOD

Other Test Constructions: Likelihood Ratio & Bayes Tests

Digital Signal Processing: A Computer-Based Approach

Bessel function for complex variable

Fourier Series. constant. The ;east value of T>0 is called the period of f(x). f(x) is well defined and single valued periodic function

Degenerate Perturbation Theory

Second Order RLC Filters

Second Order Partial Differential Equations

Reminders: linear functions

Example Sheet 3 Solutions

Differentiation exercise show differential equation

Πανεπιστήµιο Κύπρου Πολυτεχνική Σχολή

Fourier Series. MATH 211, Calculus II. J. Robert Buchanan. Spring Department of Mathematics

Matrices and Determinants

Inverse trigonometric functions & General Solution of Trigonometric Equations

Chapter 6: Systems of Linear Differential. be continuous functions on the interval

Supplemental Material: Scaling Up Sparse Support Vector Machines by Simultaneous Feature and Sample Reduction

Srednicki Chapter 55

LAD Estimation for Time Series Models With Finite and Infinite Variance

DERIVATION OF MILES EQUATION Revision D

Στα επόμενα θεωρούμε ότι όλα συμβαίνουν σε ένα χώρο πιθανότητας ( Ω,,P) Modes of convergence: Οι τρόποι σύγκλισης μιας ακολουθίας τ.μ.

Απόκριση σε Μοναδιαία Ωστική Δύναμη (Unit Impulse) Απόκριση σε Δυνάμεις Αυθαίρετα Μεταβαλλόμενες με το Χρόνο. Απόστολος Σ.

Παραμετρικές εξισώσεις καμπύλων. ΗΥ111 Απειροστικός Λογισμός ΙΙ

Econ 2110: Fall 2008 Suggested Solutions to Problem Set 8 questions or comments to Dan Fetter 1

( ) 2 and compare to M.

Section 8.3 Trigonometric Equations

B.A. (PROGRAMME) 1 YEAR

b. Use the parametrization from (a) to compute the area of S a as S a ds. Be sure to substitute for ds!

MATHEMATICS. 1. If A and B are square matrices of order 3 such that A = -1, B =3, then 3AB = 1) -9 2) -27 3) -81 4) 81

w o = R 1 p. (1) R = p =. = 1

Answers - Worksheet A ALGEBRA PMT. 1 a = 7 b = 11 c = 1 3. e = 0.1 f = 0.3 g = 2 h = 10 i = 3 j = d = k = 3 1. = 1 or 0.5 l =

PARTIAL NOTES for 6.1 Trigonometric Identities

CRASH COURSE IN PRECALCULUS

Tired Waiting in Queues? Then get in line now to learn more about Queuing!

F19MC2 Solutions 9 Complex Analysis

Binet Type Formula For The Sequence of Tetranacci Numbers by Alternate Methods

= λ 1 1 e. = λ 1 =12. has the properties e 1. e 3,V(Y

Quadratic Expressions

Solution Series 9. i=1 x i and i=1 x i.

INTEGRATION OF THE NORMAL DISTRIBUTION CURVE

Tridiagonal matrices. Gérard MEURANT. October, 2008

derivation of the Laplacian from rectangular to spherical coordinates

Phys460.nb Solution for the t-dependent Schrodinger s equation How did we find the solution? (not required)

The Simply Typed Lambda Calculus

HMY 429: Εισαγωγή στην Επεξεργασία Ψηφιακών

Areas and Lengths in Polar Coordinates

Fractional Colorings and Zykov Products of graphs

ΗΜΥ 220: ΣΗΜΑΤΑ ΚΑΙ ΣΥΣΤΗΜΑΤΑ Ι Ακαδημαϊκό έτος Εαρινό Εξάμηνο Κατ οίκον εργασία αρ. 2

Exercises 10. Find a fundamental matrix of the given system of equations. Also find the fundamental matrix Φ(t) satisfying Φ(0) = I. 1.

Lecture 17: Minimum Variance Unbiased (MVUB) Estimators

Section 7.6 Double and Half Angle Formulas

Problem Set 3: Solutions

ΚΥΠΡΙΑΚΗ ΕΤΑΙΡΕΙΑ ΠΛΗΡΟΦΟΡΙΚΗΣ CYPRUS COMPUTER SOCIETY ΠΑΓΚΥΠΡΙΟΣ ΜΑΘΗΤΙΚΟΣ ΔΙΑΓΩΝΙΣΜΟΣ ΠΛΗΡΟΦΟΡΙΚΗΣ 24/3/2007

DERIVATION OF MILES EQUATION FOR AN APPLIED FORCE Revision C

Καταχώρηση τιµής σε µια µεταβλητή.

Statistical Inference I Locally most powerful tests

1. A fully continuous 20-payment years, 30-year term life insurance of 2000 is issued to (35). You are given n A 1

New bounds for spherical two-distance sets and equiangular lines

Practice Exam 2. Conceptual Questions. 1. State a Basic identity and then verify it. (a) Identity: Solution: One identity is csc(θ) = 1

«Χρήσεις γης, αξίες γης και κυκλοφοριακές ρυθμίσεις στο Δήμο Χαλκιδέων. Η μεταξύ τους σχέση και εξέλιξη.»

Forced Pendulum Numerical approach

Ordinal Arithmetic: Addition, Multiplication, Exponentiation and Limit

HOMEWORK 4 = G. In order to plot the stress versus the stretch we define a normalized stretch:

Transcript:

P.: Chapter Discrete-Time Sigals ad Systems (a) ( ) ( ) δ ( ) δ ( ) x = m+ m m, 5. m= clear; close all; Hf_ = figure( Uits, ormalized, positio,[.,.,.8,.8], color,[,,]); set(hf_, NumberTitle, off, Name, P.ac ); % % x() = sum_{m=}^{} (m+)*[delta(-*m)-delta(-*m-)] = [:5]; x = zeros(,legth()); for m = : x = x + (m+)*(impseq(*m,,5) - impseq(*m+,,5)); ed subplot(,,); stem(,x); axis([mi()-,max()+,mi(x)-,max(x)+]); xlabel( ); ylabel( x() ); title( Sequece x() ); tick = [():(legth())]; set(gca, XTickMode, maual, XTick,tick, FotSize,) Sequece x() 5 x() -5-3 4 5 6 7 8 9 3 4 5 6 7 8 9 3 4 5 (b) x ( ) = u( + ) u( ) + δ ( ) + ( ) u( ) u( ) 5 6.5 4. clear; close all; Hf_ = figure( Uits, ormalized, positio,[.,.,.8,.8], color,[,,]); set(hf_, NumberTitle, off, Name, P.be ); % % (b) x() = (^)*[u(+5)-u(-6)]+*delta()+*(.5)ˆ*[u(-4)-u(-)] = -5:; % Overall support of x() x = (. ^).*(stepseq(-5,-5,)-stepseq(6,-5,))+*impseq(,-5,)+... *((.5).^).*(stepseq(4,-5,)-stepseq(,-5,)); subplot(,,); stem(,x); axis([mi()-,max()+,mi(x)-,max(x)+]); xlabel( ); ylabel( x() ); title( Sequece x() ); tick = [():(legth())]; set(gca, XTickMode, maual, XTick,tick, FotSize,)

Sequece x() 5 x() 5 5-5 -4-3 - - 3 4 5 6 7 8 9 (c) ( ) ( ) ( π π ) x3 =.9 cos. + / 3,. % x3() = (.9)^*cos(.*pi*+pi/3); <=<= 3 = [:]; x3 = ((.9).^3).*cos(.*pi*3+pi/3); subplot(,,); stem(3,x3); axis([mi(3)-,max(3)+,-,]); xlabel( ); ylabel( x3() ); title( Sequece x3() ); tick = [3():3(legth(3))]; set(gca, XTickMode, maual, XTick,tick, FotSize,) Sequece x3().5 x3() -.5-3 4 5 6 7 8 9 3 4 5 6 7 8 9 (d) ( ) ( π ) ( ) x4 = cos.8 + w, where w() is a radom sequece uiformly distributed betwee [-, ]. clear; close all; % (d) x4() = *cos(.8*pi*.^)+w(); <= <= ; w()^uiform[-,] w = *(rad(,)-.5); 4 = [:]; x4 = *cos(.8*pi*4.^)+w; subplot(,,); stem(4,x4); axis([mi(4)-,max(4)+,mi(x4)-,max(x4)+]); xlabel( ); ylabel( x4() ); title( Sequece x4() ); tick = [4()::4(legth(4))]; set(gca, XTickMode, maual, XTick,tick, FotSize,) The plot of x4() is show i Figure. from which we observe that it is a oisy siusoid with icreasig frequecy (or a oisy chirp sigal).

Sequece x4() 5 x4() -5-3 4 5 6 7 8 9 (e) x ( ) = { } 5...,,,3,,,,3,,,.... Plot 5 periods. % (e) x5() = {...,,,3,,,,3,,,...}periodic. 5 periods 5 = [-8:]; x5 = [,,,3]; x5 = x5 *oes(,5); x5 = (x5(:)) ; subplot(,,); stem(5,x5); axis([mi(5)-,max(5)+,,4]); xlabel( ); ylabel( x5() ); title( Sequece x5() ); tick = [5():5(legth(5))]; set(gca, XTickMode, maual, XTick,tick, FotSize,) 4 Sequece x5() 3 x5() -8-7 -6-5 -4-3 - - 3 4 5 6 7 8 9 P.: The sequece x() = f;;4;6;5;8;g is give. (a) x ( ) = 3x( + ) + x( 4) x( ). clear; close all; Hf_ = figure( Uits, ormalized, positio,[.,.,.8,.8], color,[,,]); set(hf_, NumberTitle, off, Name, P.ab ); = [-4:]; x = [,-,4,6,-5,8,]; % give seq x() % % (a) x() = 3*x(+) + x(-4) - *x() [x,] = sigshift(3*x,,-); % shift by - ad scale by 3 [x,] = sigshift(x,,4); % shift x() by 4 [x3,3] = sigadd(x,,x,); % add two sequeces at time [x,] = sigadd(x3,3,*x,); % add two sequeces

subplot(,,); stem(,x); axis([mi()-,max()+,mi(x)-,max(x)+]); xlabel( ); ylabel( x() ); title( Sequece x() ); tick = [()::(legth())]; set(gca, XTickMode, maual, XTick,tick, FotSize,); Sequece x() 3 x() -6-5 -4-3 - - 3 4 5 6 (b) x ( ) = x( + ) + x( + ) + x( ) 5 5 4 4 3. % (b) x() = 5*x(5+) + 4*x(+4) +3*x() [x,] = sigshift(5*x,,-5); [x,] = sigshift(4*x,,-4); [x3,3] = sigadd(x,,x,); [x,] = sigadd(x3,3,3*x,); subplot(,,); stem(,x); axis([mi()-,max()+,mi(x)-.5,max(x)+.5]); xlabel( ); ylabel( x() ); title( Sequece x() ); tick = [()::(legth())]; set(gca, XTickMode, maual, XTick,tick, FotSize,) Sequece x() 6 x() 4-9 -8-7 -6-5 -4-3 - - (c) x ( ) = x( + ) x( ) + x( ) x( ) 3 4. clear; close all; Hf_ = figure( Uits, ormalized, positio,[.,.,.8,.8], color,[,,]); set(hf_, NumberTitle, off, Name, P.cd ); = [-4:]; x = [,-,4,6,-5,8,]; % give seq x() % % (c) x3() = x(+4)*x(-) + x(-)*x() [x3,3] = sigshift(x,,-4); % shift x() by -4

[x3,3] = sigshift(x,,); % shift x() by [x33,33] = sigmult(x3,3,x3,3); % multiply two sequeces [x34,34] = sigfold(x,); % fold x() [x34,34] = sigshift(x34,34,); % shift x(-) y [x34,34] = sigmult(x34,34,x,); % shift x(-) y [x3,3] = sigadd(x33,33,x34,34); % add two sequeces subplot(,,); stem(3,x3); axis([mi(3)-,max(3)+,mi(x3)-,max(x3)+]); xlabel( ); ylabel( x3() ); title( Sequece x3() ); tick = [3()::3(legth(3))]; set(gca, XTickMode, maual, XTick,tick, FotSize,); 6 Sequece x3() 4 x3() - -4-8 -7-6 -5-4 -3 - - 3 4 5 6.5 (d) ( ) ( ) ( π ) ( ) x4 = e x + cos. x +,. % (d) x4() = *exp(.5*)*x()+cos(.*pi*)*x(+); - <= <= 4 = [-:]; x4 = *exp(.5*4); x4 = cos(.*pi*4); [x4,4] = sigmult(x4,4,x,); [x43,43] = sigshift(x,,-); [x44,44] = sigmult(x4,4,x43,43); [x4,4] = sigadd(x4,4,x44,44); subplot(,,); stem(4,x4); axis([mi(4)-,max(4)+,mi(x4)-.5,max(x4)+.5]); xlabel( ); ylabel( x4() ); title( Sequece x4() ); tick = [4()::4(legth(4))]; set(gca, XTickMode, maual, XTick,tick, FotSize,) Sequece x4() 4 x4() - -9-8 -7-6 -5-4 -3 - - 3 4 5 6 7 8 9

5 (e) x5 ( ) = x( k ) where x( ){ } k =,, 4,6, 5,8,. clear; close all; = [-4:]; x = [,-,4,6,-5,8,]; % give seq x() % (e) x5() = sum_{k=}ˆ{5}*x(-k); [x5,5] = sigshift(x,,); [x5,5] = sigshift(x,,); [x5,5] = sigadd(x5,5,x5,5); [x53,53] = sigshift(x,,3); [x5,5] = sigadd(x5,5,x53,53); [x54,54] = sigshift(x,,4); [x5,5] = sigadd(x5,5,x54,54); [x55,55] = sigshift(x,,5); [x5,5] = sigadd(x5,5,x55,55); [x5,5] = sigmult(x5,5,5,5); subplot(,,); stem(5,x5); axis([mi(5)-,max(5)+,mi(x5)-,max(x5)+]); xlabel( ); ylabel( x5() ); title( Sequece x5() ); tick = [5()::5(legth(5))]; set(gca, XTickMode, maual, XTick,tick, FotSize,); Sequece x5() x5() 5-3 - - 3 4 5 6 7 P.3: A sequece x() is periodic if x( + N) = x( ) for all. Cosider a complex expoetial jω jπ f sequece e = e. (a) Aalytical proof: The above sequece is periodic if jπ f ( + N) jπ f e = e or jπ fn e = = f = K (a iteger) which proves the result. x = cos.3 π,. % (b) x() = cos(.3*pi*) x = cos(.3*pi*); subplot(,,); stem(,x); axis([mi()-,max()+,-.,.]); ylabel( x() ); title( Sequece cos(.3*pi*) ); tick = [():5:(legth())]; set(gca, XTickMode, maual, XTick,tick, FotSize,); Sice f =.3/ = 3/ the sequece is periodic. From the plot i Figure.7 we see that i oe period of x exhibits three cycles. This is true wheever K ad N are relatively prime. (b) ( ) ( ) Samples ( )

x = cos.3,. % (b) x() = cos(.3*) x = cos(.3*); subplot(,,); stem(,x); axis([mi()-,max()+,-.,.]); ylabel( x() ); title( Sequece cos(.3*) ); tick = [():5:(legth())]; set(gca, XTickMode, maual, XTick,tick, FotSize,); I this case f is ot a ratioal umber ad hece the sequece x () is ot periodic. (c) ( ) ( ).5 Sequece cos(.3*pi*) x() -.5 - - -5 - -5 5 5 Sequece cos(.3*).5 x() -.5 - - -5 - -5 5 5 P.4 A: x()=3x(+)+x(-4)-x() =-4:;x=[,-,4,6,-5,8,]; [x,]=sigshift(x,,-); [x,]=sigshift(x,,4); [x3,3]=sigshift(x,,); [x,]=sigadd(3*x,,x,); [x,]=sigadd(x,,-*x3,3); [xe,xo,m]=eveodd(x,); subplot(,,);stem(,x);title('rectagularpulse') xlabel('');ylabel('x');%axis([mi()-,max()+,mi(x)-,max(x)+]) subplot(,,);stem(m,xe);title('eve part') xlabel('');ylabel('xe()');%axis([mi()-,max()+,mi(x)-,max(x)+]) subplot(,,4);stem(m,xo);title('odd part') xlabel('');ylabel('xo()');%axis([mi()-,max()+,mi(x)-,max(x)+])

rectagularpulse 6 eve part 5 4 x xe() -5 - -5 5 - - -5 5 odd part xo() B: x()=5x(5+)+4x(+4)+3x() =-4:;x=[,-,4,6,-5,8,]; [x,]=sigshift(x,,-5); [x,]=sigshift(x,,-4); [x3,3]=sigshift(x,,); [x,]=sigadd(5*x,,4*x,); [x,]=sigadd(x,,3*x3,3); [xe,xo,m]=eveodd(x,); subplot(,,);stem(,x);title('rectagularpulse') xlabel('');ylabel('x');%axis([-,,,]) subplot(,,);stem(m,xe);title('eve part') xlabel('');ylabel('xe()');%axis([-,,,]) subplot(,,4);stem(m,xo);title('odd part') xlabel('');ylabel('xo()');%axis([-,,,]) - A: x()=3x(+)+x(-4)-x() - - -5 5

rectagularpulse 6 eve part 5 4 x xe() -5 - -5 5 - - -5 5 odd part 4 xo() - -4 - -5 5 B: x()=5x(5+)+4x(+4)+3x() C: x3()=x(+4)x(-)+x(-)x(); =-4:;x=[,-,4,6,-5,8,]; [x3,3]=sigshift(x,,-4); [x3,3]=sigshift(x,,); [x3,3]=sigfold(x,); [x33,33]=sigshift(x3,3,); [x,]=sigmult(x33,33,x,); [x,]=sigmult(x3,3,x3,3); [x3,3]=sigadd(x,,x,); [xe,xo,m]=eveodd(x3,3); subplot(,,);stem(3,x3);title('rectagularpulse') xlabel('3');ylabel('x3');%axis([-,,,]) subplot(,,);stem(m,xe);title('eve part') xlabel('3');ylabel('xe(3)');%axis([-,,,]) subplot(,,4);stem(m,xo);title('odd part') xlabel('3');ylabel('xo(3)');%axis([-,,,])

rectagularpulse 5 eve part 5 x3 xe(3) -5-5 - -5 5 3 - - -5 5 3 odd part 4 xo(3) D: x4()= e.5 x()+cos(.π )x(+), -<=<=; 4=-:;x=[,-,4,6,-5,8,];=-4:; x4=*exp(.5*4); x4=cos(.*pi*4); [x4,4]=sigmult(x4,4,x,); [x43,43]=sigshift(x,,-); [x44,44]=sigmult(x4,4,x43,43); [x,]=sigadd(x4,4,x44,44); [xe,xo,m]=eveodd(x,); subplot(,,);stem(,x);title('rectagular') xlabel('');ylabel('x') subplot(,,);stem(,xe);title('eve part'); xlabel('');ylabel('xe') subplot(,,4);stem(,xo);title('odd part'); xlabel('');ylabel('xo'); - -4 - -5 5 3 C: x3()=x(+4)x(-)+x(-)x();

6 rectagular 3 eve part 4 x xe - - -5 5 - - -5 5 odd part 4 xo E: x5()= 5 k = - -4 - -5 5.5 D: x4()= x()+cos(.π )x(+), -<=<=; x x( k) a + a e x x=[,-,4,6,-5,8,];=-4:; [x,]=sigshift(x,,); [x,]=sigshift(x,,); [x3,3]=sigshift(x,,3); [x4,4]=sigshift(x,,4); [x5,5]=sigshift(x,,4); [x5,5]=sigadd(x,,x,); [x5,5]=sigadd(x3,3,x5,5); [x5,5]=sigadd(x4,4,x5,5); [x,]=sigadd(x5,5,x5,5); [x,]=sigmult(x,,,); [xe,xo,m]=eveodd(x,); subplot(,,);stem(,x);title('rectagular') xlabel('');ylabel('x') subplot(,,);stem(m,xe);title('eve part') xlabel('');ylabel('xe') subplot(,,4);stem(m,xo);title('odd part') xlabel('');ylabel('xo');

5 rectagular eve part 5 x 5 xe -5-5 5-5 - -5 5 odd part 5 xo -5 E: x5()= 5 k = x( k) - - -5 5 5 k = x( k) P.5: Eve-odd decompositio of complex-valued sequeces. (a) MATLAB fuctio eveodd: fuctio [xe, xo, m] = eveodd(x,) % Complex-valued sigal decompositio ito eve ad odd parts % ----------------------------------------------------------- % [xe, xo, m] = eveodd(x,) % [xc,c] = sigfold(coj(x),); [xe,m] = sigadd(.5*x,,.5*xc,c); [xo,m] = sigadd(.5*x,,-.5*xc,c); (.4π ) x = e,. = :; x = *exp(-.4*pi*); (b) Eve-odd decompositio of ( ) [xe,xo,eo] = eveodd(x,); Re_xe = real(xe); Im_xe = imag(xe); Re_xo = real(xo); Im_xo = imag(xo); % Plots of the sequeces subplot(,,); stem(eo,re_xe); ylabel( Re{xe()} ); title( Real part of Eve Seq. ); subplot(,,3); stem(eo,im_xe); xlabel( ); ylabel( Im{xe()} ); title( Imag part of Eve Seq. ); subplot(,,); stem(eo,re_xo); ylabel( Re{xo()} ); title( Real part of Odd Seq. ); subplot(,,4); stem(eo,im_xo); xlabel( ); ylabel( Im{xo()} ); title( Imag part of Odd Seq. );

The MATLAB verificatio plots are show i Figure.8. Real part of Eve Seq. 4 Real part of Odd Seq. Rexe() 5 Rexo() - -5-4 - 4-4 -4-4 Imag part of Eve Seq. Imag part of Odd Seq..5.5 Imxe() Imxo() -.5 -.5 - -4-4 - -4-4 P.6 a) fuctio y=dsample(x,m) =:legth(x); y=[x() x(fid(mod(,m)==)+)]; b) >> =-5:5; >> x=si(.5*pi.*); >> y=dsample(x,4); >> subplot(,,);stem(,x);title('x()'); >> subplot(,,);stem(y);title('y()');

x().5 -.5 - -5-4 -3 - - 3 4 5 y().5 -.5-5 5 5 3 >> =-5:5; >> x=si(.5*pi.*); >> y=dsample(x,4); >> subplot(,,);stem(,x);title('x()'); >> subplot(,,);stem(y);title('y()');

x().5 -.5 - -5-4 -3 - - 3 4 5 x -4 y().5 -.5 5 5 5 3 P.7 Matlab Script: () The sequece (l) is: r xy = [:];x = (.9).^; x = [:];x = (.9).^x; y = [-:];y = (.8).^y;[y,y] = sigfold(y,y); [rxy,xy] = cov_m(x,x,y,y) rxy = Colums through 8..5 3.4975 5.9 7.3 9.387.574 5.8 Colums 9 through 6.85 5.63 3.3649 4.77 5.449 64.33 8.666.9767 Colums 7 through 4 6.46 58.744 97.868 47.473 39.4594 78.44 5.469 5.3 Colums 5 through 3.478 8.963 63.433 46.673 3.4833 7.688 5.993 93.573 Colums 33 through 4 8.9395 73.533 63.7576 54.894 46.947 37.7779 9.49.58 Colum 4.545 xy = Colums through 4 3 4 5 6 7 8 9 3 Colums 5 through 8 4 5 6 7 8 9 3 4 5 6 7

Colums 9 through 4 8 9 3 3 3 33 34 35 36 37 38 39 4 (): The sequece (l) is r yx = [:];x = (.9).^; x = [:];x = (.9).^x; y = [-:];y = (.8).^y;[y,y] = sigfold(y,y); [ryx,yx] = cov_m(y,y,x,x) ryx = Colums through 8..5 3.4975 5.9 7.3 9.387.574 5.8 Colums 9 through 6.85 5.63 3.3649 4.77 5.449 64.33 8.666.9767 Colums 7 through 4 6.46 58.744 97.868 47.473 39.4594 78.44 5.469 5.3 Colums 5 through 3.478 8.963 63.433 46.673 3.4833 7.688 5.993 93.573 Colums 33 through 4 8.9395 73.533 63.7576 54.894 46.947 37.7779 9.49.58 Colum 4.545 yx = Colums through 4 3 4 5 6 7 8 9 3 Colums 5 through 8 4 5 6 7 8 9 3 4 5 6 7 Colums 9 through 4 8 9 3 3 3 33 34 35 36 37 38 39 4 We ca fid that r yx (l) ad (l) is same. P.8 r xy a) r () ( ) ( ) + xx l = x x = x( ) x( l) = r yy ( l) = y( ) y( ) = [ x( ) + α x( k) ] [ x( ) + αx( k) ] = x( ) x( ) + x( ) x( k) + αx( k) x( ) + α x( k ) x( k = rxx () l + α rxx ( l + k) + αrxx ( l k) + α rxx ( l) = + α r l + α[ r l + k + r l k ] α ) ( ) () ( ) ( ) xx xx xx b) >> =:99; >> x=cos(.*pi.*)+.5.*cos(.6*pi.*); >> [y,y]=sigshift(x,,5); >> [y,y]=sigadd(x,,..*y,y); >> subplot(,,);stem(y,y);xlabel('');ylabel('y()');title('sequece y()'); >> [yl,l]=sigfold(y,y); >> [y,y]=cov_m(y,y,yl,l); >> subplot(,,);stem(y,y);xlabel('l');ylabel('y(l)');title('autocorrelatio sequece y(l)');

sequece y() y() - - 5 5 5 - - -5 - -5 - -5 5 5 5 l P.9: x ( ) x ( ) x ( ) + x ( ) a. () T [ X ( ) ] + T [ X ( ) ] = + ; T [ X ( ) + X ( ) ] = x( ) We ca fid that the two are ot equal, so T [ X ( ) ] = is t liear. T [ X ( ) ] + T [ X ( ) ] = 3x( ) + 3x ( ) + 8 T [ X ( ) + X ( ) ] = 3X ( ) + 3X ( ) + 4 We ca fid that the two are ot equal, so T [ X ( ) ] = 3x( ) + 4 is t liear. (3) T3 [ X ( ) ] + T3[ X ( ) ] = x ( ) + x ( ) + x ( ) + x ( ) x ( ) x ( ) T3 [ X ( ) + X ( ) ] = x( ) + x ( ) + x ( ) + x ( ) x ( ) x ( ) the two are equal, so T [ X ( ) ] = x( ) + x( ) x( ) is liear. 3 b. >> x = rad(,);x = rad(,); = :; >> alpha = ;beta =3; >> x3 = x+x; >> t =.^x3; >> t =.^x;t3 =.^x;t4 = t+t; >> error = max(abs(t-t4)) error =. 9775 it is t liear >> x = rad(,);x = rad(,); = :;

>> alpha = ;beta =3; >> x3 = x+x; >> t = 3*x+4;t = 3*x+4;t3 = 3*x3+4;t4 =t+t; >> error = max(abs(t3-t4)); >> error = max(abs(t3-t4)) error = 4. it is t liear 3 >> x = rad(,);x = rad(,); = :; alpha = ;beta =3; x3 = x+x;[x4,4] = sigshift(x,,);[x5,5] = sigshift(x,,);[x9,9] = sigshift(x3,,); [x6,6] = sigshift(x,,);[x7,7] = sigshift(x,,);[x8,8] = sigshift(x3,,); t = x+*x6-x4;t = x+*x7-x5;t3 = x3+*x8-x9;t4 = t+t; >> error = max(abs(t3-t3)) error = it is liear P. For each system let it system respose is ( ) Let the iput x( ) = x( ) y y. the the system respose: ( ) T [ x( ) ] = x( k) y ( ) = x( k ) = y( ) = So the system T is time_ivariat system y + + = ) ( ) T [ x( ) ] = x( k y ( ) = x( k) = y( ) So the system T is tie_ivariat system y = T x = x y = x ( ) [ ( )] ( ) ( ) ( ) y( ) 3 3 So the system T3 is ot time_ivariat system Verificatio: >> =:; >> x=.*rad(size()); >> x=sum(x(:)) x = -4.798 >> x=sigshift(x,,); >> x=sum(x(:)) x = -4.798 Hece system T is time_ivariat >> x=[zeros(,) x(:9)]; >> sum(x(:)) as =

-.86 >> x=sigshift(x,,); >> sum(x(:)) as = -.86 Hece system T is time_ivariat >> [h,]=sigfold(x,); >> [x3,]=sigshift(x3,,); >> x3=cov(x3,h); >> [h,]=sigshift(h,,); >> diff=sum(x3(:))-sum(h(:)) diff = 5.5568 Hece system T3 is ot time_ivariat. ( ) To P.9: The value of T X ( ) = x is oly related to x ( ). Whe ( ) ( ) value of T X ( ) = x x is fiite, the is also fiite, so the system is stable. The output at time is oly decided by the iput at time ad before time, so the system is causal. The value of T [ X ( ) ] = 3x( ) + 4 is oly related to x ( ). Whe ( ) T [ X ( ) ] = 3x( ) + 4 is fiite, so the system is stable. The output at time the iput at time ad before time, so the system is causal. The value of 3[ X ( ) ] = x( ) + x( ) x( ) fiite, the value of 3[ X ( ) ] = x( ) + x( ) x( ) x is fiite, the value of is oly decided by x ( ) ( ) T is oly related to. Whe x is T is fiite, so the system is stable. The output at time is oly decided by the iput at time ad before time, so the system is causal. To P.: The value of T [ X ( ) ] = x( k) is oly related to x ( ). Whe x( ) is fiite, the value of T [ X ( ) ] = x( k) is fiite, so the system is stable. The output at time is oly decided by the iput at time ad before time, so the system is causal. The value of + [ ( )] ( ) + [ ( )] ( ) T X = x k is oly related to ( ) x. Whe ( ) T X = x k is fiite, so the system is stable. The output at time x is fiite, the value of is ot oly decided by the iput at time ad before time, so the system is ucausal. The value of T3 [ X ( ) ] = x( ) is oly related to x ( ). Whe x ( ) is fiite, the value of T X = x is fiite, so the system is stable. The output at time is ot oly decided by [ ( )] ( 3 ) the iput at time ad before time, so the system is ucausal. P.: (a) Commutatio:

x ( ) x ( ) = x ( k) x k = x ( m) x ( m) k= = m m= m= = x m x m = x x ( ) ( ) ( ) ( ) Associatio: x x x3 x k x k x3 k = ( ) ( ) ( ) = ( ) ( ) ( ) Distributio: m= k= k = ( ) ( ) ( ) = x k x m k x m 3 = x( k) x m k x3( m) k= m= l = x( k) x( l) x3( k l) k= m= ( ) ( ) ( ) ( ) ( ) ( ) = x k x k x3 k = x x x3 ( ) ( ) + ( ) = ( ) ( ) + ( ) 3 3 k= x x x x k x k x k Idetity: k= ( ) ( ) ( ) ( ) = x k x k + x k x k 3 k= ( ) ( ) ( ) ( ) = x x + x x 3 ( ) δ ( ) = ( ) δ ( ) = ( ) x x k k x k = ( ) sice δ k = for k = ad zero elsewhere. (b) Verificatio usig MATLAB: = -:; x = ; = :3; x = cos(.*pi*); 3 = -5:; x3 = (.).ˆ3; % Commutative Property [y,y] = cov_m(x,,x,); [y,y] = cov_m(x,,x,); ydiff = max(abs(y-y)) ydiff = 4.633e-4 diff = max(abs(y-y)) diff = % Associative Property

[y,y] = cov_m(x,,x,); [y,y] = cov_m(y,y,x3,3); [y,y] = cov_m(x,,x3,3); [y,y] = cov_m(x,,y,y); ydiff = max(abs(y-y)) ydiff = 6.8e-3 diff = max(abs(y-y)) diff = % Distributive Property [y,y] = sigadd(x,,x3,3); [y,y] = cov_m(x,,y,y); [y,y] = cov_m(x,,x,); [y3,y3] = cov_m(x,,x3,3); [y,y] = sigadd(y,y,y3,y3); ydiff = max(abs(y-y)) ydiff =.753e-3 diff = max(abs(y-y)) diff = % Idetity Property = fix(*(rad(,)-.5)); [dl,dl] = impseq(,,); [y,y] = cov_m(x,,dl,dl); [y,y] = sigshift(x,,); ydiff = max(abs(y-y)) ydiff = diff = max(abs(y-y)) diff = P.3: Liear covolutio as a matrix-vector multiplicatio. (a) The liear covolutio of the above two sequeces is y = 3,8,4,,,4 ( ) { } (b) The vector represetatio of the above operatio is: 3 3 8 3 4 3 = 3 3 4 4 x y (c) Note that the matrix H has a iterestig structure. Each diagoal of H cotais the same umber. Such a matrix is called a Toeplitz matrix. It is characterized by the followig property H = [ ] [ ] H i, j i j H

which is similar to the defiitio of time-ivariace. (d) Note carefully that the first colum of H cotais the impulse respose vector h() followed by umber of zeros equal to the umber of x() values mius oe. The first row cotais the first elemet of h() followed by the same umber of zeros as i the first colum. Usig this iformatio ad the above property we ca geerate the whole Topelitz matrix. P.4: (a) The MATLAB fuctio cov tp: fuctio [y,h]=cov_tp(h,x) % Liear Covolutio usig Toeplitz Matrix % ---------------------------------------- % [y,h] = cov_tp(h,x) % y = output sequece i colum vector form % H = Toeplitz matrix correspodig to sequece h so that y = Hx % h = Impulse respose sequece i colum vector form % x = iput sequece i colum vector form % Nx = legth(x); Nh = legth(h); hc = [h; zeros(nx-, )]; hr = [h(),zeros(,nx-)]; H = toeplitz(hc,hr); y = H*x; (b) MATLAB verificatio: x = [,,3,4] ; h = [3,,] ; [y,h] = cov_tp(h,x); y = y, H y = 3 8 4 4 H = 3 3 3 3 P.5: (a) Covolutio y( ) = x( ) x( ) k k ( ) ( ) ( ) = (.8) (.8) ( ) y x k x k u k k= k= k k k (.8) (.8) (.8) u( ) (.8) ( 8/8) u( ) = = k= k= (.8) ( ) u( ) ( )(.8) u( ) = + = + clear; close all; Hf_ = figure( Uits, ormalized, positio,[.,.,.8,.8], color,[,,]); set(hf_, NumberTitle, off, Name, P.5 ); % (a) aalytical solutio: y() = (+)*(.8)ˆ(+)*u() a = [:5]; ya = (a+).*(.8).ˆ(a); subplot(,,); stem(a,ya); axis([-,5,-,3]); xlabel( ); ylabel( ya() ); title( Aalytical computatio );

(b) To use the MATLAB s filter futio we have to represet oe of the x() sequece by coefficiets a equivalet differece equatio. See Example. o page 3 for this procedure. MATLAB solutio usig the filter fuctio: % (b) use of the filter fuctio b = [:5]; x = (.8).ˆb; yb = filter(,[, -.8],x); subplot(,,); stem(b,yb); axis([-,5,-,3]) xlabel( ); ylabel( yb() ); title( Filter output ); % error = max(abs(ya-yb)) error = 4.449e-6 % % Super Title suptitle( Problem P.5 ); The aalytical solutio to the covolutio i (8a) is the exact aswer. I the filter fuctio approach of (8b), the ifiite-duratio sequece x() is exactly represeted by coefficiets of a equivalet filter. Therefore, the filter solutio should be exact except that it is evaluated up to the legth of the iput sequece. The plots of this solutio are show i Figure.9. 3 Aalytical computatio ya() - 5 5 5 3 35 4 45 5 3 Filter output yb() - 5 5 5 3 35 4 45 5 P.6 a) >> a=[,-.5,.5]; >> z=roots(a); >> magz=abs(z)

magz =.5.5 Sice the magitudes of both roots are less tha oe, hece the system is stable b) the impulse respose of the system over >> b=[ ];a=[ -.5.5]; >> =:;x=impseq(,,); >> y=filter(b,a,x); >> stem(,y);xlabel('');ylabel('y()');title('the impulse respose'); >> sum(abs(y)) as = 5.857.5 the impulse respose.5 y().5 -.5 3 4 5 6 7 8 9 c) Cosider the iput x( ) [ 5 + 3cos(.π ) + 4si(. 6π) ] u( ) =, the output is: >> b=[ ];a=[ -.5.5]; >> =:;x=(5+3.*cos(.*pi.*)+4.*si(.6*pi.*)).*stepseq(,,); >> y=filter(b,a,x); >> stem(,y);xlabel('');ylabel('y()');title('the output');

45 the output 4 35 3 5 y() 5 5 4 6 8 4 6 8 P.7 a. =:;[x,] =stepseq(,,);[x,] =stepseq(,,); x3 =5*(x-x); b =[,-];a = [];h = filter(b,a,x3); subplot(,,);stem(,h); title('output of a'); xlabel('');ylabel('h()'); b. >> [x,] =stepseq(,,);[x,] =stepseq(,,);[x3,3] =stepseq(,,); =:;x4 =;x5 =x-x;[x5,5] =sigmult(x4,,x5,); x6 =-;x7 =x-x3;[x8,8] =sigmult(x6,,x7,); [x9,9] =sigadd(x5,5,x8,8); b =[,-];a = [];h = filter(b,a,x9); subplot(3,,);stem(,h); title('output of b'); xlabel('');ylabel('h()'); c. >> b =[,-];a = [];[x3,3] =stepseq(,,); =:; [x3,3] =stepseq(,,);[x33,33]=sigadd(x3,3,(-)*x3,3); x34 =si(pi*/5);[x35,35] =sigmult(x33,33,x34,); b =[,-];a = [];h = filter(b,a,x35); subplot(,,);stem(,h); title('output of c'); xlabel('');ylabel('h()');

5 output of a h() -5 3 4 5 6 7 8 9 output of b h() - 3 4 5 6 7 8 9. output of c. h() -. -. 4 6 8 4 6 8