ok so i had to find the fourier series of cos(ax) with period 2 pi where a is not an integer.

So i came to the correct answer iam pretty sure, then they asked me to sub in x =pi into the series to get

i)

ii)now i have to integrate both sides form a =0 to a=theta to obtain

but this is where it gets hard for me,

integrating the left hand side of i) i get

but when calculating from a=0 isnt it undefined?

I dont even know where to start on the right hand side of the equation so any help with that would be greatly appreciated.