I am learning Fourier series, and I must compute specific values for the Fourier series of the function $5x+7$ on the interval [-8,8].
The fourier series of a function on an interval [-L, L] is given by: $$ f(x)=\sum_{n=0}^{\infty} A_{n} \cos \left(\frac{n \pi x}{L}\right)+\sum_{n=1}^{\infty} B_{n} \sin \left(\frac{n \pi x}{L}\right) $$
I find first $A_0$: $$ A_{0}=\frac{1}{2 L} \int_{-L}^{L} 5x+7 d x $$ The first term disappears (odd), and integrating 7 on the interval gives $A_0 = 7$
Finding $A_m$ $$ A_{m}=\frac{1}{L} \int_{-L}^{L} (5x+7) \cos \left(\frac{m \pi x}{L}\right) d x \quad m=1,2,3, \ldots \\ = \int_{-L}^{L} 5x \cos \left(\frac{m \pi x}{L}\right) d x + \int_{-L}^{L} 7 \cos \left(\frac{m \pi x}{L}\right) d x $$ The first term is odd (odd * even = odd), the second is orthogonal, so $A_m=0$.
Finding $B_m$ in the same manner:
$$ B_{m}=\frac{1}{L} \int_{-L}^{L} (5x+7) \sin \left(\frac{m \pi x}{L}\right) d x \quad m=1,2,3, \ldots \\ = \int_{-L}^{L} 5x \sin \left(\frac{m \pi x}{L}\right) d x + \int_{-L}^{L} 7 \sin \left(\frac{m \pi x}{L}\right) d x $$ The second term is orthogonal, but the first is odd and can be integrated. By partial integration I find: $$B_{m}=\frac{-1^{n+1}}{n \pi}$$
ie my Fourier series is: $$7 + \sum_{n=1}^{\infty} \frac{-1^{n+1} 80}{n \pi} \sin \left(\frac{n \pi x}{8}\right)$$
EDIT: I asked about $f(0)$ and as @Ninad pointed in the comment, it was easy to calculate. I edited my question for clarity!
EDIT 2: added missing 80 in the fourier series.
My issue is when calculating special values for this series. The site I am following is not covering this part and focusing in computing Fourier series (if I am not blind!: https://tutorial.math.lamar.edu/Classes/DE/FourierSeries.aspx) I cannot find a good example to follow (I don't understand how the person comes to their conclusion here: Computing value of fourier series)
So I would be grateful for an explanation on how one computes positive and negative values in the interval of a Fourier series, or some resources to read with exemplified process!
For example, how do I take f(2), and f(-2) and deal with the infinite sum?