Professional Documents
Culture Documents
Periodic Functions
Fig. 1 Example of a periodic function 𝑓(𝑥) wherein its values repeat at 𝑇 intervals
(Kreyszig, E. (2011). Advanced Engineering Mathematics. (10th ed.))
A period is a measure of interval for the value of a function to repeat. This is the
amount it takes for one cycle to complete such as the case of the 24-hour period in a
day or 365-day period in a year. But period is not just restricted to time. They can also
describe the interval of the change in shape of ocean waves or vibration of a string.
Periodic functions have an extensive role not just in mathematics but as well as in
science and engineering and a valuable key to unlock our study of nature and the
universe.
Fig. 2 The unit circle with the position of the radial arm at (cos 𝜃 , sin 𝜃)
(https://www.geeksforgeeks.org/how-to-use-the-unit-circle-in-trigonometry/)
The sine and cosine functions are the fundamental of all trigonometric
functions. Their graph holds the properties of sinusoidal waves we usually encounter
in nature, and which is the frequent object of study on periodic occurrences. The
equivalent graph of the sine and cosine function can be illustrated in the following
figures:
Fig. 3 Graph of the sine function derived from the vertical side of a triangle formed by the radial arm and the positive x-axis in
the unit circle (https://mathbitsnotebook.com/Algebra2/TrigGraphs/unitcircleMBa.jpg)
Fig. 4 Graph of the cosine function derived from the horizontal side of a triangle formed by the radial arm and the positive x-axis
in the unit circle (https://mathbitsnotebook.com/Algebra2/TrigGraphs/unitcircleMB2a.jpg)
Symmetry of Functions
Functions are said to be symmetrical if their graph is the same even if their
orientation is changed. For the first kind of symmetry, when the graph of the function
is flipped about the y-axis, the image is the same. We call these functions as even
functions. The second is when it is rotated about the origin will result to the same
image. We call them odd functions.
Fig. 5 The graph of the even function on the left and the odd function on the right
(https://courses.lumenlearning.com/calculus1/chapter/symmetry-of-functions/
Without the aids of graphs, we could determine if the function is even or odd by
making use of the following test in which we substitute the value of 𝑥 with −𝑥:
𝑒𝑣𝑒𝑛 𝑓𝑢𝑛𝑐𝑡𝑖𝑜𝑛
𝑓(−𝑥) = 𝑓(𝑥)
𝑜𝑑𝑑 𝑓𝑢𝑛𝑐𝑡𝑖𝑜𝑛
𝑓(−𝑥) = −𝑓(𝑥)
Even functions will always have the same value even if we substitute 𝑥 with its
negative value while odd functions will have a negative result for a negative value of
𝑥. The most common example are the sine and cosine functions where cosine function
is an even function while sine function is odd:
𝑐𝑜𝑠𝑖𝑛𝑒 𝑓𝑢𝑛𝑐𝑡𝑖𝑜𝑛 (𝑒𝑣𝑒𝑛)
cos (−𝜃) = cos (𝜃)
𝑠𝑖𝑛𝑒 𝑓𝑢𝑛𝑐𝑡𝑖𝑜𝑛 (𝑜𝑑𝑑)
sin (−𝜃) = −sin (𝜃)
Using this property, we can deduce the definite integrals of the above functions
as:
𝑐𝑜𝑠𝑖𝑛𝑒 𝑓𝑢𝑛𝑐𝑡𝑖𝑜𝑛 (𝑒𝑣𝑒𝑛)
0 𝑎 0 𝑎
∫ cos (−𝜃) 𝑑𝜃 = ∫ cos (−𝜃) 𝑑𝜃 = ∫ cos (𝜃) 𝑑𝜃 = ∫ cos (𝜃) 𝑑𝜃
−𝑎 0 −𝑎 0
𝑎 𝑎 𝑎
∫ cos (𝜃) 𝑑𝜃 = ∫ cos (−𝜃) 𝑑𝜃 = 2 ∫ cos (𝜃) 𝑑𝜃
−𝑎 −𝑎 0
Generally, we can say of even and odd functions as having the following
integrals:
𝑒𝑣𝑒𝑛 𝑓𝑢𝑛𝑐𝑡𝑖𝑜𝑛𝑠
𝑎 𝑎
∫ 𝑓(𝑥) 𝑑𝑥 = 2 ∫ 𝑓(𝑥) 𝑑𝑥
−𝑎 0
𝑜𝑑𝑑 𝑓𝑢𝑛𝑐𝑡𝑖𝑜𝑛𝑠
𝑎
∫ 𝑓(𝑥) 𝑑𝑥 = 0
−𝑎
Orthogonality of Functions
Two functions 𝑓(𝑥) and 𝑔(𝑥) are said to be orthogonal on 𝑎 ≤ 𝑥 ≤ 𝑏 if the
integral of their product over an interval (𝑎, 𝑏) is equal to zero.
𝑏
∫ 𝑓(𝑥)𝑔(𝑥) 𝑑𝑥 = 0
𝑎
Example
a. Determine if 𝑓(𝑥) = 𝑥 2 and 𝑔(𝑥) = 𝑥 3 is orthogonal over an interval (−1, 1)
1
∫ (𝑥 2 )(𝑥 3 ) 𝑑𝑥
−1
𝑑𝑢
We let 𝑢 = 𝑠𝑖𝑛 𝜃 and = 𝑐𝑜𝑠 𝜃 with 𝑑𝑢 = 𝑐𝑜𝑠 𝜃 𝑑𝜃
𝑑𝜃
Substituting u and du to the above integral, we get:
𝜋 𝜋 𝜋
𝑢2 (sin 𝜃)2 (sin 𝜋)2 (sin (−𝜋))2 (0)2 (0)2
∫ 𝑢 𝑑𝑢 = | = | =[ − ]=[ − ]=0
−𝜋 2 −𝜋 2 −𝜋
2 2 2 2
Case 1: 𝑛 ≠ 𝑚
1
Using the identity: sin 𝐴 sin 𝐵 = 2 [cos (𝐴 − 𝐵) − cos (𝐴 + 𝐵)] we simplify into
𝐿 𝐿
𝑛𝜋𝑥 𝑚𝜋𝑥 1 𝑛𝜋𝑥 𝑚𝜋𝑥 𝑛𝜋𝑥 𝑚𝜋𝑥
∫ sin sin 𝑑𝑥 = ∫ [cos ( − ) − cos ( + )] 𝑑𝑥
−𝐿 𝐿 𝐿 −𝐿 2 𝐿 𝐿 𝐿 𝐿
1 𝐿 𝑛𝜋𝑥 𝑚𝜋𝑥 1 𝐿 𝑛𝜋𝑥 𝑚𝜋𝑥
= ∫ cos ( − ) 𝑑𝑥 − ∫ cos ( + ) 𝑑𝑥
2 −𝐿 𝐿 𝐿 2 −𝐿 𝐿 𝐿
1 𝐿 𝑛𝜋𝑥 𝑚𝜋𝑥 1 𝐿 𝑛𝜋𝑥 𝑚𝜋𝑥
= ∫ cos ( − ) 𝑑𝑥 − ∫ cos ( + ) 𝑑𝑥
2 −𝐿 𝐿 𝐿 2 −𝐿 𝐿 𝐿
1 1 1 1
= (𝑛𝜋 𝑚𝜋) [sin (𝑛𝜋 − 𝑚𝜋) − sin (−𝑛𝜋 + 𝑚𝜋)] − (𝑛𝜋 𝑚𝜋) [sin (𝑛𝜋 + 𝑚𝜋) − sin (−𝑛𝜋 − 𝑚𝜋)]
2 − 2 +
𝐿 𝐿 𝐿 𝐿
1 1 1 1
= (𝑛𝜋 𝑚𝜋) [sin (𝑛𝜋 − 𝑚𝜋) + sin (𝑛𝜋 − 𝑚𝜋)] − (𝑛𝜋 𝑚𝜋) [sin (𝑛𝜋 + 𝑚𝜋) + sin (𝑛𝜋 + 𝑚𝜋)]
2 − 2 +
𝐿 𝐿 𝐿 𝐿
1 1 1 1
= (𝑛𝜋 𝑚𝜋) [2 sin (𝑛𝜋 − 𝑚𝜋)] − (𝑛𝜋 𝑚𝜋) [2 sin (𝑛𝜋 + 𝑚𝜋)]
2 2
𝐿 − 𝐿 𝐿 + 𝐿
sin (𝑛𝜋 − 𝑚𝜋) sin (𝑛𝜋 + 𝑚𝜋) 𝐿 sin (𝑛𝜋 − 𝑚𝜋) 𝐿 sin (𝑛𝜋 + 𝑚𝜋)
= 𝑛𝜋 𝑚𝜋 − 𝑛𝜋 𝑚𝜋 = −
− + 𝑛𝜋 − 𝑚𝜋 𝑛𝜋 + 𝑚𝜋
𝐿 𝐿 𝐿 𝐿
since n and m are integer values, this makes the integer multiples of π cause
sin (𝑛𝜋 − 𝑚𝜋) and sin (𝑛𝜋 + 𝑚𝜋) to be equals to zero hence
𝐿 sin (𝑛𝜋 − 𝑚𝜋) 𝐿 sin (𝑛𝜋 + 𝑚𝜋) 𝐿(0) 𝐿(0)
= − = − =0
𝑛𝜋 − 𝑚𝜋 𝑛𝜋 + 𝑚𝜋 𝑛𝜋 − 𝑚𝜋 𝑛𝜋 + 𝑚𝜋
Case 2: 𝑛 = 𝑚
𝐿 𝐿
𝑛𝜋𝑥 𝑛𝜋𝑥 𝑛𝜋𝑥
∫ sin sin 𝑑𝑥 = ∫ sin2 𝑑𝑥
−𝐿 𝐿 𝐿 −𝐿 𝐿
1
Using the identity: sin2 𝐴 = 2 [1 − cos (2𝐴)]
𝐿 𝐿
𝑛𝜋𝑥 1 𝑛𝜋𝑥 1 𝐿 𝑛𝜋𝑥
∫ sin2 𝑑𝑥 = ∫ [1 − cos (2 )] 𝑑𝑥 = ∫ [1 − cos (2 )] 𝑑𝑥
−𝐿 𝐿 −𝐿 2 𝐿 2 −𝐿 𝐿
1 𝐿 2𝑛𝜋𝑥 𝐿 1 𝐿 2𝑛𝜋𝐿 𝐿 2𝑛𝜋(−𝐿)
= [𝑥 − sin ( )]| = [(𝐿 − sin ( )) − ((−𝐿) − sin ( ))]
2 2𝑛𝜋 𝐿 −𝐿 2 2𝑛𝜋 𝐿 2𝑛𝜋 𝐿
1 𝐿 𝐿 1 𝐿 𝐿
= [𝐿 − sin (2𝑛𝜋) + 𝐿 + sin (−2𝑛𝜋)] = [2𝐿 − sin (2𝑛𝜋) − sin (2𝑛𝜋)]
2 2𝑛𝜋 2𝑛𝜋 2 2𝑛𝜋 2𝑛𝜋
1 2𝐿 𝐿 𝐿
= [2𝐿 − sin (2𝑛𝜋)] = 𝐿 − sin (2𝑛𝜋) = 𝐿 − (0) = 𝐿
2 2𝑛𝜋 2𝑛𝜋 2𝑛𝜋
Using the same process for both cases from the above example, we can verify
the following as orthogonal sets:
𝑛𝜋𝑥 ∞
{sin } 𝑎𝑡 − 𝐿 ≤ 𝑥 ≤ 𝐿 𝑎𝑛𝑑 0 ≤ 𝑥 ≤ 𝐿
𝐿 𝑛=1
𝑛𝜋𝑥 ∞
{cos } 𝑎𝑡 − 𝐿 ≤ 𝑥 ≤ 𝐿 𝑎𝑛𝑑 0 ≤ 𝑥 ≤ 𝐿
𝐿 𝑛=0
𝑛𝜋𝑥 𝑚𝜋𝑥 ∞
{sin cos } 𝑎𝑡 − 𝐿 ≤ 𝑥 ≤ 𝐿 (𝑁𝑜𝑡𝑒: 𝑁𝑜𝑡 𝑜𝑟𝑡ℎ𝑜𝑔𝑜𝑛𝑎𝑙 𝑜𝑛 0 ≤ 𝑥 ≤ 𝐿)
𝐿 𝐿 𝑚,𝑛=0
Using the concept of orthogonality, we could further generalize for the following
integrals:
𝐿 2𝐿 𝑖𝑓 𝑛 = 𝑚 = 0 𝐿 𝐿 𝑖𝑓 𝑛 = 𝑚 = 0
𝑛𝜋𝑥 𝑚𝜋𝑥 𝑛𝜋𝑥 𝑚𝜋𝑥
∫ cos cos 𝑑𝑥 = { 𝐿 𝑖𝑓 𝑛 = 𝑚 ≠ 0 ∫ cos cos 𝑑𝑥 = {𝐿/2 𝑖𝑓 𝑛 = 𝑚 ≠ 0
𝐿 𝐿 0 𝐿 𝐿
−𝐿 0 𝑖𝑓 𝑛 ≠ 𝑚 0 𝑖𝑓 𝑛 ≠ 𝑚
𝐿 𝐿
𝑛𝜋𝑥 𝑚𝜋𝑥 𝐿 𝑖𝑓 𝑛 = 𝑚 𝑛𝜋𝑥 𝑚𝜋𝑥 𝐿/2 𝑖𝑓 𝑛 = 𝑚
∫ sin sin 𝑑𝑥 = { ∫ sin sin 𝑑𝑥 = {
−𝐿 𝐿 𝐿 0 𝑖𝑓 𝑛 ≠ 𝑚 0 𝐿 𝐿 0 𝑖𝑓 𝑛 ≠ 𝑚
𝐿
𝑛𝜋𝑥 𝑚𝜋𝑥
∫ sin cos 𝑑𝑥 = 0
−𝐿 𝐿 𝐿
Fourier Series
We have learnt in the previous laboratory that convergent infinite series can be
made to represent certain functions. One example of that is the power series which
takes the sum of infinite terms with complex variables raised to the nth power. However,
there is another kind of infinite series that we could use to represent periodic functions.
It merely takes the infinite sum of sines and cosines until it converges into the given
function with period 𝑇 = 2𝐿. We call these kinds of series as Fourier series and is
represented by the formula:
∞
𝑛𝜋𝑥 𝑛𝜋𝑥
𝑓(𝑥) = 𝑎0 + ∑ (𝑎𝑛 cos + 𝑏𝑛 sin )
𝐿 𝐿
𝑛=1
1 𝐿
𝑎0 = ∫ 𝑓(𝑥) 𝑑𝑥
2𝐿 −𝐿
1 𝐿 𝑛𝜋𝑥
𝑎𝑛 = ∫ 𝑓(𝑥) cos 𝑑𝑥
𝐿 −𝐿 𝐿
1 𝐿 𝑛𝜋𝑥
𝑏𝑛 = ∫ 𝑓(𝑥) sin 𝑑𝑥
𝐿 −𝐿 𝐿
𝑎0 , 𝑎𝑛 and 𝑏𝑛 are called the Fourier coefficients.
Example
a. Determine the Fourier series expansion of 𝑓(𝑥) = 𝑥 at −𝜋 ≤ 𝑥 ≤ 𝜋 with period 2𝜋.
Given period 𝑇 = 2𝐿 = 2𝜋 hence 𝐿 = 𝜋 and the graph of the function is shown as:
1 𝐿 𝑛𝜋𝑥 1 𝜋 𝑛𝜋𝑥 1 𝜋
𝑎𝑛 = ∫ 𝑓(𝑥) cos 𝑑𝑥 = ∫ 𝑥 cos 𝑑𝑥 = ∫ 𝑥 cos 𝑛𝑥 𝑑𝑥
𝐿 −𝐿 𝐿 𝜋 −𝜋 𝜋 𝜋 −𝜋
Integrating by parts, we simplify it into
1 𝜋 𝑥 sin 𝑛𝑥 1 𝜋 sin 𝑛𝑥 𝑥 sin 𝑛𝑥 cos 𝑛𝑥 𝜋
∫ 𝑥 cos 𝑛𝑥 𝑑𝑥 = − ∫ 𝑑𝑥 = ( + )|
𝜋 −𝜋 𝜋𝑛 𝜋 −𝜋 𝑛 𝜋𝑛 𝜋𝑛2 −𝜋
𝜋 sin 𝑛𝜋 cos 𝑛𝜋 (−𝜋) sin 𝑛(−𝜋) cos 𝑛(−𝜋)
= [( + 2
)−( + )]
𝜋𝑛 𝜋𝑛 𝜋𝑛 𝜋𝑛2
sin 𝑛𝜋 cos 𝑛𝜋 sin 𝑛𝜋 cos 𝑛𝜋
𝑎𝑛 = [ + − − ]=0
𝑛 𝜋𝑛2 𝑛 𝜋𝑛2
For solving 𝑏𝑛
1 𝐿 𝑛𝜋𝑥 1 𝜋 𝑛𝜋𝑥 1 𝜋
𝑏𝑛 = ∫ 𝑓(𝑥) sin 𝑑𝑥 = ∫ 𝑥 sin 𝑑𝑥 = ∫ 𝑥 sin 𝑛𝑥 𝑑𝑥
𝐿 −𝐿 𝐿 𝜋 −𝜋 𝜋 𝜋 −𝜋
Fourier Transform
Fourier series is very useful method for representing periodic functions and has
various applications. However, most of the functions we deal with in mathematics are
nonperiodic. Analyzing them requires another method wherein they are represented
not as series but integral of their frequency components 𝐹(𝜔). In this case we extend
the concept of the Fourier series to nonperiodic functions to derive this integral.
Recalling the formula of the Fourier series, what we are familiarly looking at is its
trigonometric form.
∞
𝑛𝜋𝑥 𝑛𝜋𝑥
𝑓(𝑥) = 𝑎0 + ∑ (𝑎𝑛 cos + 𝑏𝑛 sin )
𝐿 𝐿
𝑛=1
𝑗𝑛𝜋𝑥 −𝑗𝑛𝜋𝑥
𝑛𝜋𝑥 𝑒 𝐿 +𝑒 𝐿
However, making use of the complex exponential identity of cos = and
𝐿 2
𝑗𝑛𝜋𝑥 −𝑗𝑛𝜋𝑥
𝑛𝜋𝑥 𝑒 𝐿 −𝑒 𝐿
sin = , we can rearrange the above formula into its more compact
𝐿 𝑗2
exponential form
∞
−𝑗𝑛𝜋𝑥
𝑓(𝑥) = ∑ 𝑐𝑛 𝑒 𝐿
𝑛=−∞
1 𝐿 𝑗𝑛𝜋𝑥
𝑐𝑛 = ∫ 𝑓(𝑥)𝑒 𝐿 𝑑𝑥
2𝐿 −𝐿
𝑛𝜋 𝜋 𝜋
When we let 𝜔 = and Δ𝜔 = 𝐿 , then 𝐿 = Δ𝜔. Substituting them in the formula for 𝑐𝑛
𝐿
𝐿
1 𝑗𝜔𝑥
Δ𝜔 𝐿
𝑐𝑛 = 𝜋 ∫ 𝑓(𝑥)𝑒 𝑑𝑥 = ∫ 𝑓(𝑥)𝑒 𝑗𝜔𝑥 𝑑𝑥
2 (Δ𝜔) −𝐿 2𝜋 −𝐿
Substituting the value of 𝑐𝑛 to the Fourier series of 𝑓(𝑥) and rearranging the terms
∞ ∞
Δ𝜔 𝐿 𝑗𝜔𝑥 −𝑗𝜔𝑥
1 𝐿
∑ [ ∫ 𝑓(𝑥)𝑒 𝑑𝑥] 𝑒 = ∑ [ ∫ 𝑓(𝑥)𝑒 𝑗𝜔𝑥 𝑑𝑥] 𝑒 −𝑗𝜔𝑥 Δ𝜔
2𝜋 −𝐿 2𝜋 −𝐿
𝑛=−∞ 𝑛=−∞
𝑒 −(∞)(1+𝑗𝜔) 𝑒 −(0)(1+𝑗𝜔) 0 1 1
[(− ) − (− )] = [(− ) − (− )] =
1 + 𝑗𝜔 1 + 𝑗𝜔 1 + 𝑗𝜔 1 + 𝑗𝜔 1 + 𝑗𝜔
1 𝑓𝑜𝑟 − 1 ≤ 𝑥 ≤ 1
b. Determine the Fourier Transform of the function 𝑓(𝑥) = {
0 𝑜𝑡ℎ𝑒𝑟𝑤𝑖𝑠𝑒
∞ 1 1
−𝑗𝜔𝑥 −𝑗𝜔𝑥
𝑒 −𝑗𝜔𝑥
𝐹(𝜔) = ∫ 𝑓(𝑥)𝑒 𝑑𝑥 = ∫ (1)𝑒 𝑑𝑥 == − |
−∞ −1 𝑗𝜔 −1
𝑒 −𝑗𝜔(1) 𝑒 −𝑗𝜔(−1) 𝑒 −𝑗𝜔 𝑒 𝑗𝜔 𝑒 𝑗𝜔 − 𝑒 −𝑗𝜔 2 sin 𝜔
= [(− ) − (− )] = [− + ]=[ ]=
𝑗𝜔 𝑗𝜔 𝑗𝜔 𝑗𝜔 𝑗𝜔 𝜔
∞ 𝑓𝑜𝑟 𝜔 = 1, −1
c. Determine the Inverse Fourier Transform of the function 𝐹(𝜔) = {
0 𝑜𝑡ℎ𝑒𝑟𝑤𝑖𝑠𝑒
∞ 𝑓𝑜𝑟 𝑥 = 𝑎
The function 𝑓(𝑥) = { is an impulse function expressed in another way
0 𝑜𝑡ℎ𝑒𝑟𝑤𝑖𝑠𝑒 ∞
as 𝛿(𝑥 − 𝑎) and holds the property ∫−∞ 𝛿(𝑥 − 𝑎)𝑓(𝑥) 𝑑𝑥 = 𝑓(𝑎). Using this property,
we solve for the Inverse Fourier Transform of 𝐹(𝜔) = 𝛿(𝜔 − 1) + 𝛿(𝜔 + 1) as
1 ∞ 1 ∞
𝑓(𝑥) = ∫ 𝐹(𝜔)𝑒 𝑗𝜔𝑥 𝑑𝜔 = [∫ (𝛿(𝜔 − 1) + 𝛿(𝜔 + 1))𝑒 𝑗𝜔𝑥 𝑑𝜔]
2𝜋 −∞ 2𝜋 −∞
∞ ∞
1
= [∫ 𝛿(𝜔 − 1)𝑒 𝑗𝜔𝑥 𝑑𝜔 + ∫ 𝛿(𝜔 + 1)𝑒 𝑗𝜔𝑥 𝑑𝜔]
2𝜋 −∞ −∞
1 𝑗(1)𝑥 1 𝑒 𝑗𝑥 + 𝑒 −𝑗𝑥 1
= [𝑒 + 𝑒 𝑗(−1)𝑥 ] = [ ] = cos 𝑥
2𝜋 𝜋 2 𝜋
−1 {2𝜋
𝑗𝑒 𝑗𝑥
ℱ 𝑢(1 − 𝜔)} = 𝜋𝛿(𝑥) −
𝑥
1 𝑗𝑒 𝑗𝑥
ℱ −1 {𝑢(1 − 𝜔)} = (𝜋𝛿(𝑥) − )
2𝜋 𝑥
𝛿(𝑥) 𝑗𝑒 𝑗𝑥
ℱ −1 {𝑢(1 − 𝜔)} = −
2 2𝜋𝑥
Discrete Fourier Transform
The formula shown below is being used for solving Fourier Transform of
continuous functions 𝑓(𝑥).
∞
𝐹(𝜔) = ∫ 𝑓(𝑥)𝑒 −𝑗𝜔𝑥 𝑑𝑥
−∞
Finally, the formula for the individual values of the Discrete Fourier Transform of 𝑓(𝑥𝑛 )
is given as
𝑁−1
−𝑗2𝜋𝑘𝑛
𝐹[𝑘] = ∑ 𝑓[𝑛]𝑒 𝑁
𝑛=0
𝑓𝑜𝑟 𝑘, 𝑛 = 0, 1, 2, . . . , 𝑁 − 1
with {𝐹[𝑘]} as the set of values of the Discrete Fourier Transform of {𝑓[𝑛]}. Meanwhile,
the Inverse Discrete Fourier Transform is given as
𝑁−1
1 𝑗2𝜋𝑘𝑛
𝑓[𝑛] = ∑ 𝐹[𝑘]𝑒 𝑁
𝑁
𝑛=0
𝑓𝑜𝑟 𝑘, 𝑛 = 0, 1, 2, . . . , 𝑁 − 1
Example
a. Find the DFT (Discrete Fourier Transform) of the values 𝑓(𝑥𝑛 ) = {1, −3, 0, 5, 7}
We determine that the size of the set is 𝑁 = 5. To obtain the DFT, we use the formula
and plug in the values of 𝑓(𝑥𝑛 ).
5−1 4 4
−𝑗2𝜋(0)𝑛
𝑘 = 0, 𝐹[0] = ∑ 𝑓[𝑛]𝑒 5 = ∑ 𝑓[𝑛]𝑒 0 = ∑ 𝑓[𝑛] = 1 + (−3) + (0) + 5 + 7 = 10
𝑛=0 𝑛=0 𝑛=0
5−1 4
−𝑗2𝜋(1)𝑛 −𝑗2𝜋𝑛 −𝑗2𝜋(1) −𝑗2𝜋(3) −𝑗2𝜋(4)
𝑘 = 1, 𝐹[1] = ∑ 𝑓[𝑛]𝑒 5 = ∑ 𝑓[𝑛]𝑒 5 = (1)𝑒 0 + (−3)𝑒 5 + (0) + 5𝑒 5 + 7𝑒 5 = 12.58𝑒 𝑗1.7151
𝑛=0 𝑛=0
5−1 4
−𝑗2𝜋(2)𝑛 −𝑗4𝜋𝑛 −𝑗4𝜋(1) −𝑗4𝜋(3) −𝑗4𝜋(4)
𝑘 = 2, 𝐹[2] = ∑ 𝑓[𝑛]𝑒 5 = ∑ 𝑓[𝑛]𝑒 5 = (1)𝑒 0 + (−3)𝑒 5 + (0) + 5𝑒 5 + 7𝑒 5 = 1.32𝑒 𝑗2.1226
𝑛=0 𝑛=0
5−1 4
−𝑗2𝜋(3)𝑛 −𝑗6𝜋𝑛 −𝑗6𝜋(1) −𝑗6𝜋(3) −𝑗6𝜋(4)
𝑘 = 3, 𝐹[3] = ∑ 𝑓[𝑛]𝑒 5 = ∑ 𝑓[𝑛]𝑒 5 = (1)𝑒 0 + (−3)𝑒 5 + (0) + 5𝑒 5 + 7𝑒 5 = 1.32𝑒 −𝑗2.1226
𝑛=0 𝑛=0
5−1 4
−𝑗2𝜋(4)𝑛 −𝑗8𝜋𝑛 −𝑗8𝜋 −𝑗8𝜋(3) −𝑗8𝜋(4)
𝑘 = 4, 𝐹[4] = ∑ 𝑓[𝑛]𝑒 5 = ∑ 𝑓[𝑛]𝑒 5 = (1)𝑒 0 + (−3)𝑒 5 + (0) + 5𝑒 5 + 7𝑒 5 = 12.58𝑒 −𝑗1.7151
𝑛=0 𝑛=0
{𝐹[𝑘]} = {10, 12.58𝑒 𝑗1.7151 , 1.32𝑒 𝑗2.1226 , 1.32𝑒 −𝑗2.1226 , 12.58𝑒 −𝑗1.7151 }
From the result, we obtain the magnitude of the frequencies at {𝑘} = {0, 1, 2, 3, 4} from
the moduli of the exponential complex numbers {𝐹[𝑘]}.
{|𝐹[𝑘]|} = {10, 12.58, 1.32, 1.32, 12.58}
b. Find the DFT of the values 𝑓(𝑥𝑛 ) sampled from the function 𝑓(𝑥) = 1 −
𝜋 1
2 cos (𝜋𝑥 − 2 ) + 4 sin(2𝜋𝑥) with a sampling interval of ∆𝑥 = 4 from 0 ≤ 𝑥 < 2
1
We first determine the values of {𝑓(𝑥𝑛 )} by making use of the sampling interval ∆𝑥 = 4
from 0 ≤ 𝑥 < 2
𝑛 𝑥𝑛 = 𝑛∆𝑥 𝑓(𝑥𝑛 )
𝜋
= 1 − 2 cos (𝜋(0) − ) + 4 sin(2𝜋(0))
2
𝜋
0 0 = 1 − 2 cos (− ) + 4 sin(0)
2
= 1 − 2(0) + 4(0)
=1
1 1
1 1( ) = 5 − √2 = 3.5858
4 4
1 1
2 2( ) = −1
4 2
3
3 −3 − √2 = −4.4142
4
4 1 1
5
5 5 + √2 = 6.4142
4
3
6 3
2
7
7 −3 + √2 = −1.5858
4
You may notice that there are frequency components 𝐹[6] and 𝐹[7]. Note that these
are not valid frequencies of the samples and are just the consequence of the error
called aliasing in which higher frequencies mistakenly fits with the sample. However,
𝑁
the practice is that DFT values at 𝑘 > 2 will be discarded leaving us with only half of
the frequency components.