I’d like to find the Fourier coefficients of
$$ x(t)=|A \cos(2 \pi f_0 t )| $$ The period is $ T_0 / 2 $ so i applied the definition $$\frac{1}{T}\int_{0}^{L} |A \cos(2\pi f_0 t )| \cos \left(\frac{k \pi t }{T}\right)dt $$
Now i applied the Euler formulas and I transformed cos into exp
$$ \frac{|A|}{4T}\int_{-T/4}^{T/4} |(e^{i2\pi f_0 t} + e^{-2i\pi f_0 t})|(e^{\frac{ik\pi t}{T}}+e^{-\frac{ik\pi t}{T}}) $$
Can you now please help me with the calculation. The result should be $ \frac{-2A}{\pi}\frac{(-1)^k}{4k^2 -1 } $ But the solution I obtained is always wrong
Thank you !
The solution can be obtained directly from the definition, but I'd suggest revising the one you provided to be a bit more precise: $$a_k=\frac{1}{T_0/2}\int_{-T_0/4}^{T_0/4}A\cos(2\pi f_0t)\cos(2\pi k2f_0t)dt.$$
Note that the fundamental ($k=1$) basis function here is twice the frequency of $x(t)$. From here, there are a couple ideas than can be tricky to spot. In the order you need them, they are:
Give it another go, and if you're still having trouble provide your MWE so we can do a better job of helping.
Also, see this excellent YouTube video from Darryl Morrell showing a much more elegant way to get to your required answer.