Digital Image Analysis and Processing CPE 0907544 Filtering in the Frequency Domain – Part I Introduction Chapter 4 Sections : 4.1-4.6 Dr. Iyad Jafar
Outline Background Preliminary Concepts Sampling The 1D Discrete Fourier Transform The 2D Discrete Fourier Transform Essential Properties of the 2D Fourier Transform 2
Background In 1807, the French mathematician Jean Fourier proposed that any periodic function that satisfies some mild mathematical conditions can be expressed as the sum of sines and/or cosines of different frequencies and amplitudes Now, we know this as Fourier series Even aperiodic functions that have finite energy can be represented as an integral of sines and/or cosines multiplied weighting function. This formulation is known as Fourier transform Both formulations have an important feature A function represented in Fourier series or transform can be fully reconstructed into its original form without any loss of information 3
Background The use of Fourier analysis was in the field of heat diffusion. The usefulness of Fourier transform is of greater importance and applicability in many fields The availability of digital computers and the discovery of the Fast Fourier Transform (FFT) revolutionized the field of signal processing Our focus in this course will be on Fourier Transform as we will be working with images of finite duration (energy). Specifically, we will use Fourier transform as a tool to study filtering in the frequency domain 4
Preliminaries Complex Numbers A complex number C is represented by C = R + jI Real Imaginary Complex numbers can be viewed as a point in the complex plane Representation of complex number in polar coordinates C = |C|e j θ = |C| (cos θ + j sin θ ) where |C| = (R 2 +I 2 ) 1/2 Magnitude θ = tan -1 (I/R) Phase 5
Preliminaries Impulses A unit impulse of continuous variable located at t=t 0 is defined as , t t 0 δ(t t ) 0 0 , t t 0 constrained to δ(t t )dt = 1 0 Sifting property f (t )δ(t t )dt = f(t ) 0 0 6
Preliminaries Impulses In the discrete domain 1 , t t 0 δ(t t ) 0 0 , t t 0 constrained to δ(t t ) = 1 0 and sifting property becomes f (t )δ(t t ) = f(t ) 0 0 7
Preliminaries Impulses Impulse Train A set of infinite, periodic impulses that are ∆T apart s (t ) = δ(t n T ) T n 8
Preliminaries The Fourier Series of Periodic Functions The Fourier series of a continuous periodic function f(t) with period T is 2 πn j t T f (t ) = c e n n where T / 2 2 πn 1 j t T c = f (t ) e dt , n = 0, 1, 2,... n T T / 2 9
Preliminaries The Fourier Transform of Functions of One ContinuousVariable The Fourier transform of a continuous function f(t) of a continuous variable t j πμt 2 f (t ) = F(μ) = f (t ) e dt We can reconstruct f(t) back using 1 j πμt 2 F( μ) = f (t ) = F( μ) e dμ 10
Preliminaries The Fourier Transform of One Continuous Variable Example 4.1. Compute the Fourier transform of the function f(t) shown below 11
Preliminaries The Fourier Transform of One Continuous Variable Example 4.1 – continued sin(πμW ) F(μ) = AW = AW sinc(πμW ) πμW Usually we work with the magnitude of F(u) sin(πμW ) F(μ) = AW = AW sinc(πμW ) πμW 12
Preliminaries The Fourier Transform of One Continuous Variable Example 4.2. Compute the Fourier transform of the unit impulse located at t=0 δ(t ) j πμt 2 δ(t ) = F(μ) = δ(t ) e dt 1 13
Preliminaries The Fourier Transform of One Continuous Variable Example 4.3. Compute the Fourier transform of the unit impulse located at t=t0 δ(t t ) 0 j π μ t 2 j π μ t 2 0 δ(t t ) = F(μ) = δ(t t ) e dt e 0 0 j π au 2 δ(t a ) e 14
Preliminaries The Fourier Transform of One Continuous Variable Example 4.4. Compute the inverse Fourier transform of the following function F( μ) = δ( μ a) 1 j π μ t 2 j π a t 2 F( μ) = δ( μ a ) e dμ = e j π a t 2 e δ( μ a) 15
Preliminaries The Fourier Transform of One Continuous Variable Example 4.5. Compute the Fourier transform of sin(2 π at) and cos(2 π at) 1 sin(2 πat) δ(μ a ) δ(μ a ) 2 j 1 cos(2 πat) δ(μ a ) δ(μ a ) 2 16
Preliminaries The Fourier Transform of One Continuous Variable Example 4.6. Compute the Fourier transform of the impulse train with period ∆T s (t ) = δ(t n T ) T n 1 n S (t ) = S(μ) = δ( μ ) T T T n 17
Preliminaries ConvolutionTheorem The convolution of two continuous functions f(t) and h(t) where t is a continuous variable is given by f (t) h(t) = f (τ ) h(t-τ )dτ It can be easily shown that convolution in the spatial/time domain is equivalent to multiplying the Fourier transforms of the two functions in the frequency domain f(t) h(t) F(μ) H(μ) 18
Preliminaries ConvolutionTheorem – cont’d Similarly, convolving two functions in the frequency domain is defined as F(μ) H(μ) = F(τ ) H(μ-τ )dτ It can be easily shown that convolution in the frequency domain is equivalent to multiplying the two functions in the original domain f(t) h(t) F(μ) H(μ) 19
Sampling Sampling is required to convert continuous signals into discrete form Collecting samples of a signal/function f(t) that are spaced by ∆T can be viewed as multiplying the signal by an impulse train s ∆T (t) with period ∆T ~ f(t ) f(t ) s (t ) Δ T x = f(t )δ(t n T ) Δ n 20
Sampling The value of each sample f k can be computed by integration f f ( t ) δ(t-n T)dt = f (k T ) Δ Δ k 21
Sampling The Fourier Transform of Sampled Function Let F(u) denotes the Fourier transform of f(t), then according to convolution theorem, the Fourier transform is the convolution between F(u) and the Fourier transform of s ∆T (t) ~ ~ F( μ ) f ( t ) f ( t )s ( t ) = F( μ ) S( μ ) Δ T where 1 n s (t ) = S(μ) = δ( μ ) T T T n 22
Sampling The Fourier Transform of Sampled Function Carrying out convolution in frequency domain ~ F( μ ) F( μ ) S( μ ) F( τ )S( μ τ )dτ 1 n = F( τ ) δ( μ τ )dτ Δ T T n 1 n = F( τ )δ( μ τ )dτ Δ T T n 1 n = F( μ ) Δ T T 23 n
Sampling The Fourier Transform of Sampled Function The previous formulation implies that the Fourier transform of a sampled function is simply an infinite, periodic sequence of copies of F(u)that are centered at multiples of 1/∆T Sampling 24
Sampling The Sampling Theorem If f(t) represents a function whose Fourier transform F(u) is band-limited, i.e. F(u) = 0 , u >= |u max |, then the original spectrum can be recovered from the sampled spectrum if the sampling rate is at least twice the maximum frequency in F(u) 1 2μ max T We have three different cases Under-sampling (1/∆T < 2 u max ) Critically sampling; sampling at Nyquest rate (1/∆T = 2 u max ) Over-sampling (1/∆T > 2 u max ) 25
Sampling The Sampling Theorem Over-Sampling Critical-Sampling Under-Sampling 26
Sampling Recovering f(t) from its SampledVersion To recover f(t) we can multiply the sampled spectrum with a function T , -μ Δ μ μ max max H( μ) 0 , otherwise Accordingly ~ F(u ) F( μ)H( μ) And f(t) can be computed using the inverse Fourier transform 1 j πμt 2 f (t ) = F( μ) = F( μ) e dμ 27
Sampling Recovering f(t) from its Sampled Version 28
Sampling Aliasing When we sample with a rate less than the Nyquest rate , the replicas of the function transform will overlap. This affects the recovery of the original function. 29
Recommend
More recommend