Introduction to Fourier Transform - Linear Systems
Transcript of Introduction to Fourier Transform - Linear Systems
Image Processing - Lesson 4
• Linear Systems
• Definitions & Properties
• Shift Invariant Linear Systems
• Linear Systems and Convolutions
• Linear Systems and sinusoids
• Complex Numbers and Complex Exponentials
• Linear Systems - Frequency Response
Introduction to Fourier Transform - Linear Systems
Linear Systems
• A linear system T gets an input f(t)and produces an output g(t):
• In the discrete caes:– input : f[n] , n = 0,1,2,…– output: g[n] , n = 0,1,2,…
Tf(t) g(t)
( ){ }tfTtg =)(
[ ] )](f[g nTn =
T
Linear System Properties
• A linear system must satisfy two conditions:
– Homogeneity:
– Additivity:
[ ]{ } [ ]{ }nfTanfaT =
[ ] [ ]{ } [ ]{ } [ ]{ }nfTnfTnfnfT 2121 +=+
T
T
T
Homogeneity
Additivity
T
Linear System - Example
• Contrast change by grayscale stretching around 0:
– Homogeneity:
– Additivity:
T{bf(x)} = abf(x) = baf(x) = bT{f(x)}
T{f(x)} = af(x)
T{f1(x)+f2(x)} = a(f1(x)+f2(x)) = af1(x)+af2(x)= T{f1(x)}+ T{f2(x)}
Linear System - Example
• Convolution:
– Homogeneity:
– Additivity:
T{bf(x)} = (bf)*a = b(f*a) = bT{f(x)}
T{f(x)} = f*a
T{f1(x)+f2(x)} = (f1+f2)*a = f1*a+f2*a= T{f1(x)}+ T{f2(x)}
Shift-Invariant Linear System
• Assume T is a linear system satisfying
• T is a shift-invariant linear system iff:
T
Shift Invariant
( ){ }tfTtg =)(
( ){ }00 )( ttfTttg −=−
T
Shift-Invariant Linear System - Example
• Contrast change by grayscale stretching around 0:
– Shift Invariant:
• Convolution:
– Shift Invariant:
T{f(x-x0)} = af(x-x0) =g(x-x0)
T{f(x)} = af(x) = g(x)
T{f(x-x0)} = f(x-x0)*a
T{f(x)} = f(x)*a =g(x)
∑ −−∑ =−−=j
0i
0 )xjx(a)j(f)ix(a)xi(f
= g(x-x0)
Matrix Multiplication as a Linear System
• Assume f is an input vector and T is a matrix multiplying f:
• g is an output vector. • Claim: A matrix multiplication is a
linear system:
– Homogeneity– Additivity
• Note that a matrix multiplication is not necessarily shift-invariant.
Tfg =
( ) 2121 TfTfffT +=+( ) aTfafT =
Impulse Sequence
• An impulse signal is defined as follows:
• Any signal can be represented as a linear sum of scales and shifted impulses:
[ ]
=≠
=−knwhereknwhere
kn1
0d
[ ] [ ] [ ]jnjfnfj
−= ∑∞
−∞=
δ
= + +
Shift-Invariant Linear System is a Convolution
Proof: – f[n] input sequence– g[n] output sequence– h[n] the system impulse response:
h[n]=T{δ[n]}
[ ] [ ]{ } [ ] [ ]
[ ] [ ]{ }
[ ] [ ]
hf
nariancceshiftfromjnhjf
linearityfromjnTjf
jnjfTnfTng
j
j
j
∗=
−−=
−=
−==
∑
∑
∑
∞
−∞=
∞
−∞=
∞
−∞=
)i(
)(δ
δ
The output is a sum of scaled and shifted copies of impulse responses.
Convolution as a Matrix Multiplication
• The convolution (wrap around):
can be represented as a matrix multiplication:
– The matrix rows are flipped and shifted copies of the impulse response.
– The matrix columns are shifted copies of the impulse response.
[ ] [ ] [ ]283256123210021 −−−=∗−−
−−−
=
−−
283256
210021
210003321000032100003210000321100032
CirculantMatrix
Convolution Properties
• Commutative:
– Only shift-invariant systems are commutative.– Only circulant matrices are commutative.
• Associative:
– Any linear system is associative.
• Distributive:
– Any linear system is distributive.
fTTfTT ∗∗=∗∗ 1221
( ) ( )fTTfTT ∗∗=∗∗ 2121
( )( ) 2121
2121
fTfTffTandfTfTfTT∗+∗=+∗
∗+∗=∗+
Complex Numbers
The Complex Plane
Real
Imaginary
(a,b)
a
b
• Two kind of representations for a point (a,b) in the complex plane
– The Cartesian representation:
12 −=+= iwherebiaZ– The Polar representation:
θiZ Re=
R
θ
• Conversions:
– Polar to Cartesian:
– Cartesian to Polar
( ) ( )θθθ sincosRe iRRi +=( )abiebabia /tan22 1−
+=+
(Complex exponential)
• Conjugate of Z is Z*:
– Cartesian rep.
– Polar rep.
( ) ibaiba −=+ ∗
( ) θθ ii −∗= ReRe
Reala
b
θ
-θ
-b
θibia Re=+
θibia −=− Re
R
R
Imaginary
Algebraic operations:
• addition/subtraction:
• multiplication:
• Norm:
)()()()( dbicaidciba +++=+++
( )( ) ( ) ( )adbcibdacidciba ++−=++
( )ßaßa += iii ABeBeAe
( ) ( ) 222 baibaibaiba +=++=+ ∗
( ) 22ReReReReRe Riiiii === −∗ θθθθθ
• The (Co-)Sinusoid as complex exponential:
Or
( )2eexcos
ixix −+=
( )i2eexsin
ixix −−=
The (Co-) Sinusoid
( ) ( )ixex Realcos =
( ) ( )ixex Imagsin =
x1
1
cos(x)
sin(x)eix
x
( )xπω2sin
ω
– The wavelength of is .
– The frequency is .
1
x1
1
cos(x)
sin(x)eix
The (Co-) Sinusoid- function
( )xπω2sinω1
x
( )xA πω2sin
A
– Changing Amplitude:
– Changing Phase:
x
( )ϕπω +xA 2sin
( ) )(Imag2sin 2 xii eAexA πωϕϕπω =+
Scaling and shifting can be represented as a multiplication with ϕiAe
Frequency Analysis• If a function f(x) can be expressed as a
linear sum of scaled and shifted sinusoids:
it is possible to predict the system response to f(x):
• The Fourier Transform:It is possible to express any signal as a sum of shifted and scaled sinusoids at different frequencies.
( ) xieFxf πω
ω
ω 2)( ∑=
( ){ } ( ) ( ) xieFHxfTxg πω
ω
ωω 2)( ∑==
( )∑= xieFxf πωω 2)(
( ) ωωω
πω deFxf xi∫= 2)(Or
3 sin(x)
+ 1 sin(3x)
+ 0.8 sin(5x)
+ 0.4 sin(7x)
=
Every function equals a sum of scaled and shifted Sines
+
+
+
Linear System Logic
Input Signal
Express as sum of scaled
and shifted impulses
Express as sum of scaled
and shifted sinusoids
Calculate the response to
each impulse
Calculate the response to
each sinusoid
Sum the impulse
responses to determine the
output
Sum the sinusoidal
responses to determine the
output
Frequency Method
space/time Method
)()()( xhxfxg ∗=)()()( ωωω HFG =