Fourier series - trig and complex not matching?

In summary, the complex Fourier series representation of a signal is correct, however when calculating the exponential Fourier series, the amplitude is halved.
  • #1
haydez98
9
0
fourier series - trig and complex not matching?

i am given a signal which can be written as:
s(t) = -1 {-1 < t < 0}, 1 {0 < t < 1}, 0 {1 < t < 2} [it's a pulse train]
the period, T, is 3.
i have calculated the trig. Fourier series representation, which in MATLAB turns out to be correct, yet when i calculate the exponentical fsr, i get a version of the trig. fsr which has its amplitude halved.

for the trig fsr:

s(t) = 2/(pi * n) * (1 - cos((2 * pi * n)/3)) * sin((2 * pi * n * t)/3);


for the exp fsr:

s(t) = -1/(i * pi * n) * (cos((2 * pi * n)/3) - 1) * exp((i * 2 * pi * n * t)/3)


i also tried

c_n = 0.5 (a_n - i * b_n) = -0.5 * i * ( 2/(pi * n) * (1 - cos((2 * pi * n)/3))



either case, my complex fsr was a scaled amplitude version of my trig fsr...when i get rid of the 0.5 it turns out to be right, but why would i get rid of the 0.5?


thanks in advance
 
Physics news on Phys.org
  • #2


Hint:
[tex] \sin x = \frac{e^x - e^{-x}}{2 i}[/tex]
 
  • #3


okay i'll show you my working out...
[tex]
c_{n}=\frac{1}{T}\int_{0}^{T}s(t)e^{\frac{-j2\pi nt}{T}}dt[/tex]
[tex]=\frac{1}{T}\left [\int_{-T/3}^{0}-1e^{\frac{-j2\pi nt}{T}}dt + \int_{0}^{T/3}1e^{\frac{-j2\pi nt}{T}}dt \right ][/tex]
[tex]=\frac{1}{T} \left[\left[\frac{T}{j2\pi n}e^{\frac{-j2\pi nt}{T}} \right]_{-T/3}^{0} +\left[\frac{-T}{j2\pi n}e^{\frac{-j2\pi nt}{T}} \right]_{0}^{T/3}\right][/tex]
[tex]=\frac{1}{j2\pi n}\left[1 - e^{\frac{j2\pi n}{3}}+e^{\frac{-j2\pi n}{3}}+1\right][/tex]
[tex]=\frac{1}{j2\pi n}\left[2-2cos(\frac{2\pi n}{3})\right][/tex]
[tex]=\frac{1}{j\pi n}\left[1-cos(\frac{2 \pi n}{3})\right]
[/tex]

(note: i used the cosine identity)

Therefore:
[tex]
s(t)= \frac{1}{j\pi n}(1-cos(\frac{2 \pi n}{3}))e^{\frac{j\pi nt}{3}}
[/tex]

However, when I put this into matlab, it doesn't satisfy the trig fsr.
 
Last edited:
  • #4


Almost everything looks fine. Except, well, you still got to sum over n... ;)

So:
[tex]s(t) = \sum_{n=-\infty,\neq 0}^{\infty} c_n e^{j\pi n t / 3}[/tex]
where
[tex] c_n = \frac{1}{j\pi n}(1-\cos \frac{2\pi n}{3})[/tex]
Note also that [tex]c_0[/tex] is left out (in other words, [tex]c_0=0[/tex], do you see why?)

Now we see that
[tex]c_{-n} = -c_n[/tex]
so the sum can be rewritten as:
[tex]s(t) = \sum_{n=1}^{\infty} c_n e^{j\pi n t / 3}+c_{-n}e^{-j\pi n t / 3}
= \sum_{n=1}^{\infty} c_n e^{j\pi n t / 3}-c_{n}e^{-j\pi n t / 3}
=\sum_{n=1}^{\infty} c_n \left(e^{j\pi n t / 3}-e^{-j\pi n t / 3}\right)
=\sum_{n=1}^{\infty} 2i c_n\sin{j\pi n t / 3} [/tex]

Which is the trig fsr.
 
Last edited:
  • #5


ah coolness. i didn't know about having to put c_-n in it too

thanks so much
 

1. What is a Fourier series?

A Fourier series is a mathematical representation of a periodic function as a sum of sine and cosine functions with different amplitudes and frequencies. It is used to decompose a complex signal into simpler components, making it easier to analyze and manipulate.

2. How is trigonometric Fourier series different from complex Fourier series?

Trigonometric Fourier series represents a periodic function using only sine and cosine functions, while complex Fourier series uses complex exponential functions. The complex Fourier series is often preferred as it simplifies the mathematical calculations and provides a more elegant representation of the function.

3. Why might the trigonometric and complex Fourier series not match?

The trigonometric and complex Fourier series may not match due to the different ways of representing a function. Trigonometric series only uses sine and cosine functions, while complex series uses a combination of complex exponential functions. This can result in different coefficients and thus, different representations of the same function.

4. How can we determine which Fourier series is the most accurate?

The accuracy of a Fourier series can be determined by comparing it to the original function. The series with smaller errors or deviations from the original function is considered to be more accurate. This can be done by calculating the mean square error or using other methods of comparison.

5. Are there any applications of Fourier series in real-life?

Fourier series has many applications in various fields, including electrical engineering, signal processing, and physics. It is used to analyze and manipulate signals in communication systems, image and audio processing, and quantum mechanics. It also has applications in solving differential equations and modeling periodic phenomena in nature.

Similar threads

  • Calculus and Beyond Homework Help
Replies
1
Views
95
  • Calculus and Beyond Homework Help
Replies
16
Views
474
  • Calculus and Beyond Homework Help
Replies
1
Views
491
  • Calculus and Beyond Homework Help
Replies
2
Views
322
  • Calculus and Beyond Homework Help
Replies
1
Views
252
  • Calculus and Beyond Homework Help
Replies
5
Views
220
  • Calculus and Beyond Homework Help
Replies
3
Views
163
  • Calculus and Beyond Homework Help
Replies
3
Views
355
  • Calculus and Beyond Homework Help
Replies
2
Views
1K
  • Calculus and Beyond Homework Help
Replies
6
Views
129
Back
Top