spectral%20analysis - PowerPoint PPT Presentation

About This Presentation
Title:

spectral%20analysis

Description:

So what's the Fourier Transform of a boxcar of length, T? -T/2 T/2 1 exp(-iwt) dt ... function that has more desirable properties than a boxcar ... Need ... – PowerPoint PPT presentation

Number of Views:43
Avg rating:3.0/5.0
Slides: 42
Provided by: billm7
Category:

less

Transcript and Presenter's Notes

Title: spectral%20analysis


1
  • Lecture 17
  • spectral analysis
  • and
  • power spectra

2
Part 1
What does a filter do to the spectrum of a time
series?
3
  • Consider a filter f(t), such that y(t) f(t)
    x(t)
  • In the frequency domain, convolution becomes
    multiplication
  • y(w) f(w) x(w) and thus y(w)2 f(w)2
    x(w)2
  • frequency bands of x(w) are amplified when
    f(w)2gt1
  • frequency bands of x(w) are attenuated when
    f(w)2lt1

4
x(w)2
w
f(w)2
w
y(w)2
w
5
So how do we tell if a filter will amplify or
attenuate a given range of frequencies?
6
Obviously, we could plot its spectrum however,
a more rigorous analysis of really simple filters
offers some insight into whats going on
7
Lets examine the DFT formula
  • Ck Sn0N-1 Tn exp(-2pikn/N ) with k0,
    N-1
  • or since DwDt2p/N
  • Ck Sn0N-1 Tn exp(-ikDwDt )n with k0,
    N-1
  • now let z exp(-ikDwDt ) exp(-iwDt )
  • Ck Sn0N-1 Tn zn with k0, N-1
  • but thats the z-transform of T
  • So the discrete fourier transform Ck of a
    timeseries T is its z-transform evaluated at z
    exp(-ikDwDt ).

8
The discrete fourier transform Ck of a timeseries
T is its z-transform evaluated at zexp(-ikDwDt
)exp(-2pik/N ) Note that z 1, regardless of
the value of k As you evaluate the coefficients,
Ck, k varies from 0 to (N-1), z varies from 0 to
2p along a circle in the complex plane
imag z
real z
z
9
The discrete Fourier transform Ck of a timeseries
T is its z-transform evaluated at zexp(-ikDwDt
)exp(-2pik/N ) As you evaluate the
coefficients, Ck, k varies from 0 to (N-1), z
varies from 0 to 2p along a circle in the complex
plane Hence the coefficients Ck are going to be
very sensitive to the locations of poles and
zeros of T(z), especially when they are close to
the unit circle
imag z
big Ck here
pole
real z
zero
small Ck here
10
Example ff1, f2T 1, -1.1T
  • f(z)f1f2z so has zero at z-f1/f2

f1, 1.1T
zero
11
High Pass Filter
f(wn)2
n
nny
12
Example ff1, f2T 1, 1.1T
zero
13
Low Pass Filter
f(wn)2
nny
n
14
Example
f1, 1.1iT1, -1.1iT
zeros
15
Suppress mid-range
f(wn)2
n
nny
16
Example fginv with g1, 0.6(1-1.1i)T 1,
0.6(11.1i)T
poles
17
Narrow bandpass filter
f(wn)2
n
nny
18
Example
f 1, 0.9iT 1, -0.9iT inv(1, 0.8iT)
inv(1, -0.8iT)
poles
zeros
19
notch filter
f(wn)2
n
nny
20
upshot
You can design really short filters that do
simple but useful thing to the spectrum of a time
series
21
Part 2
Computing spectra of indefinitely long timeseries
22
Suppose you cut a section out of a long
timeseries, x(t)
t
section
How similar is the spectrum of the section to the
spectrum of the whole thing?
23
Lingo Stationary Time Series
  • When the statistical properties of an
    indefinitely long time series dont change with
    time, the time series is said to be
  • stationary

24
Power spectrum
  • The standard FT formula
  • C(w) ?-?? T(t) exp(-iwt) dt
  • is not well defined when T(t) wiggles on forever,
    since T(t) has infinite energy. We need to adapt
    it.

25
Power spectrum
  • C(w) ?-T/2T/2 T(t) exp(-iwt) dt
  • S(w) limT?? T-1 C(w)2
  • S(w) is called the power spectral density, the
    spectrum normalized by the length of the time
    series.
  • Whenever I say spectrum in the context of an
    indefinitely long stationary time series, I
    really mean power spectral density

26
Relationship of power spectral density to DFT
  • To compute the Fourier transform, C(w), you
    multiply the DFT coefficients, Ck, by Dt.
  • So to get power spectal density
  • T-1 C(w)2
  • (NDt)-1 Dt Ck2
  • (Dt/N) Ck2
  • You multiply the DFT spectrum, Ck2, by Dt/N.

27
Back to the question
t
section
You use convolution theorem to analyze the
problem(but written backward)
28
Convolution theorem
Last weeks way
todays way
  • The transform of the convolution of two
    timeseries
  • is the product of their
  • transforms

The product of two timeseries Is the convolution
of their two Fourier transforms
Swapping the roles of time and frequency are
allowed because the Fourier Transform is
symmetrical in time and frequency
29
timeseries
t
?
boxcar
t

t
windowed time series
30
So whats the Fourier Transform of a boxcar of
length, T?
  • ?-T/2T/2 1 exp(-iwt) dt
  • ?-T/2T/2 cos(wt) i sin(wt) dt
  • 2 ?0T/2 cos(wt) dt (2/w) sin(wt)0T/2
  • T sin(wT/2) / (wT/2) T sinc( wT/2 )

31
recap
  • Fourier transform of long timeseries
  • convolved with a sinc function
  • is Fourier transform of windowed timeseries

32
small T
  • T sinc(wT/2)

big T
T sinc( wT/2 )
w
33
As window length T increases
  • Central lobe gets narrower good
  • Side lobes gets narrower good
  • and closer to origin
  • Side lobes get no smaller bad
  • and never go away

34
Example sinusoidal timeseries
long time series
boxcar
windowed times series
time, t
35
Spectrum of long time series
Spectrum of window
Spectrum of windowed time series
Yuck!
w
36
What to do ?
  • Choose a windowing function that has more
    desirable properties than a boxcar
  • Need finite length in time
  • narrow central lobe in frequency
  • no (or smallish) frequency side
    lobes

37
Example truncated Gaussian
long time series
truncated gaussian
2s
windowed times series
time, t
38
Spectrum of long time series
Spectrum of window
Spectrum of windowed time series
peaks a bit wider than with sinc
w
39
Example Hamming Taper0.54 - 0.46 cos2pn/(N-1)
long time series
Hamming taper
windowed times series
time, t
40
Spectrum of long time series
Spectrum of window
Spectrum of windowed time series
w
41
upshot
  • 1. You cant win. Ringing trades off with width
    of the central peak. But you can choose how you
    lose.
  • 2. The spectrum of the windows time series is a
    smoothed version of the true spectrum. The
    smoothing is being done by the convolution. Thus
    the error estimates for the windowed spectrum are
    different from (and generally better than) the
    error estimates for an unwindowed spectrum
Write a Comment
User Comments (0)
About PowerShow.com