Hi there. I wanted to intagrate the fourier series for to get the fourier series for

So I thought making something like:

I know that

p is for the period.

Then

Now this is wrong, but I don't know why. What I get with this looks like x, I think that's because of the term . But I don't know what I'm doing wrong. Perhaps I have to do something else, but I don't know what, it actually doesn't look pretty much like a Fourier series.