Escolar Documentos
Profissional Documentos
Cultura Documentos
1
a = 1 a , a < 1
n
n =0
a k
an = 1 a , a < 1
n=k
N m N +1
a a
= 1 a , a 1
a n
n=m
N 1
1 a N
n , a 1
a = 1 a
n =0 N , a =1
Digital Signal Processing, 2007 Robi Polikar, Rowan University
Convolution Example
n<N1
x[n] = a n u[n]
1 N1 n N 2
h[n] =
0 otherwise
N1<n<N2
0 n < N1
1 a n N1 +1
y[n] = N1 n < N 2
1 a
n N 1 a N 2 N1 +1
a 2 n N2
1 a
n>N2
n=-3:7;
x=0.55.^(n+3);
h=[1 1 1 1 1 1 1 1 1 1 1];
y=conv(x,h);
subplot(311)
stem(x)
title(Original signal)
subplot(312)
stem(h) % Use stem for discrete sequences
title(Impulse response / second signal)
subplot(313)
stem(y)
title( convolution result)
rxy [l ] = x[n] y[n l ]
n =
(note the difference with convolution)
and for the time reversed cross correlation sequence it can easily
be shown that it is related to the original sequence as:
ryx [l ] = y[n]x[n l ] =
n = m =
y[m + l ]x[m] = rxy [l ]
Correlation
autocorrelation is a cross correlation sequence of a series with
itself:
rxx [l ] = x[n]x[n l ]
n =
note that the zero lag term of the autocorrelation sequence is just
the total enery of the signal:
rxx [0] = x [ n] =
n =
2
x
rxx [l ] = rxx [l ]
The Frequency Domain
Time domain operation are often not very informative and/or efficient
in signal processing
An alternative representation and characterization of signals and
systems can be made in transform domain
Much more can be said, much more information can be extracted from a signal in
the transform / frequency domain.
Many operations that are complicated in time domain become rather simple
algebraic expressions in transform domain
Most signal processing algorithms and operations become more intuitive in
frequency domain, once the basic concepts of the frequency domain are
understood.
500
RP
0
-500 -400 -300 -200 -100 0 100 200 300 400 500
Frequency, Hz.
500
RP
0
-500 -400 -300 -200 -100 0 100 200 300 400 500
Frequency, Hz.
subplot(211)
0
plot(t(1001:1200),x(1:200))
grid -5
title('Sin(2\pi20t)+4Cos(2\pi50t)+2Sin(2\pi100t)')
-10
xlabel('Time, s') 0 0.02 0.04 0.06 0.08 0.1 0.12 0.14 0.16 0.18 0.2
Time, s
subplot(212)
Frequency domain representation of Sin(220t)+4Cos(250t)+2Sin(2100t)
X=abs(fft(x)); 4000
X2=fftshift(X);
3000
f=-499.9:1000/2001:500;
plot(f,X2); 2000
grid
1000
title(' Frequency domain representation of
Sin(2\pi20t)+4Cos(2\pi50t)+2Sin(2\pi100t)')
RP
0
-500 -400 -300 -200 -100 0 100 200 300 400 500
xlabel('Frequency, Hz.') Frequency, Hz.
Magnitude spectrum
j 2kt / N 1 N 1
F [k ] = f (t )e dt f (t ) = F [k ]e j 2kt / N
2 i = 0
Became famous with his other previous work on math, assigned as chair of Ecole Polytechnique
Napoleon took him along to conquer Egypt
Return back after several years
Barely escaped Giyotin!
After 15 years, following several attempts and disappointments and frustration, he published
his results in Theorie Analytique de la Chaleur in 1822 (Analytical Theory of Heat).
In 1829, Dirichlet proved Fouriers claim with very few and non-restricting conditions.
Next 150 years: His ideas expanded and generalized. 1965: Cooley and Tukey--> Fast
Fourier Transform Computational simplicity King of all transforms Countless
number of applications engineering, finance, applied mathematics, etc.
Note that each complex exponential that makes up the sum is an integer multiple
of 0, the fundamental frequency
Hence, the complex exponentials are harmonically related
The coefficients ck , aka Fourier (series) coefficients, are possibly complex
Fourier series (and all other types of Fourier transforms) are complex valued ! That is,
there is a magnitude and phase (angle) term to the Fourier transform!
1 t0 T0 jk0t
The limits of the integral can be chosen to
ck x (t ) e dt cover any interval of T0, for example,
T0 t0 [-T0/2 T0/2] or [0 T0] or [-T0 0].
ck
k=0 =0 rad/s
1/2 1/2 1/2j k=1 =2 rad/s
k=2 =4 rad/s
-3 -2 -1 0 1 2 3
k k=3 =6 rad/s
-1/2j
t=0:0.001:0.5; 0
x=cos(2*pi*2*t)+2*cos(2*pi*8*t);
w0=2*pi*2;
-5
K=5; 0 0.05 0.1 0.15 0.2 0.25 0.3 0.35 0.4 0.45 0.5
[X x_recon]=fourier_series(x,K,t,w0); Fourier Series Magnitude Coefficients
4
0
-5 -4 -3 -2 -1 0 1 2 3 4 5
Reconstructed Signal
10
p.s. fourier_series() is not
a standard Matlab function. 0
You will be writing this function
as part of next lab.
-10
0 0.05 0.1 0.15 0.2 0.25 0.3 0.35 0.4 0.45 0.5
Phase angles
and
1
x [ n ]=
2
X e jn d
X ( + 2 k ) = x [n ] e
n=
j ( + 2 k ) n
= x [n ] e
n=
jn
e j2kn
= x [n ] e
n=
j n
= X ( ) k
n=
( ) = [n ] e
n=
j n
=1
n
x [ n] = e ; X ( ) = 2 ( + 2k )
j0
0
k=
X (e j0 n ) + X (e j0 n )
=
2
x [ n] = [ n]
n
( ( ) < 1) ; X ( ) =
0
1
j0
1 e
X ( ) = [n ] e
n j n
= n e j n
n= n= 0
( e )
j n 1
= =
n= 0 1 e j
n
x [ n] = e ; X ( ) = 2 ( + 2k )
j0
0
k=
dX ( )
nx [ n ] j
d
x [ n n0 ] e X ()
jn0
n
x [ n ] X ( 0 )
j0
e
1
General form: g [ n] .h
[ n] = G ( ) .H
( ) d
n= 2
1
g [ n] .g
[ n] = G ( ) .G
( ) d= g
n= 2
Properties of
Fourier Transform
x(t) X()