Fourier Series doubt

I have a doubt regarding the Fourier series usage in terms of the Fourier series formula, which has multiple variants and is quite complicated.

EDIT: I would like to mention that this question (of mine) is a repeat of the one I had asked earlier, but I could not bump it however, to show the new comment I had added. So I am askign again - sorry for the double question.

$A$ $summary$ $of$ $my$ $question$ $before$ $I$ $ask$ $it$: I need the exact Fourier series formula to compute the values of $a_0$, $a_n$ and $b_n$, for a function $f(x)$ where: $$f(x) = a_0 + \sum_{n=1}^\infty(a_n\cos nx) + \sum_{n=1}^\infty(b_n \sin nx)$$

$Question:$

In one of my notes, it is given that, for a function $f(x)$ defined on an interval $-\pi$ to $\pi$, the function can be written as follows:$f(x) = a_0 + \sum_{n=1}^\infty(a_n\cos nx) + \sum_{n=1}^\infty(b_n \sin nx)$. I need the formula as follows:

$$f(x) = a_0 + \sum_{n=1}^\infty(a_n\cos nx) + \sum_{n=1}^\infty(b_n \sin nx)$$

And that:

\begin{align}a_0 &= \dfrac 1{2\pi}\int_{-T_0}^{T_0}f(x)dx \\ a_n &= \dfrac 1\pi\int_{-T_0}^{T_0}f(x)\cos(nx)dx \\ b_n &= \dfrac 1\pi\int_{-T_0}^{T_0}f(x)\sin(nx)dx \end{align}

However, when I searched online, I found different formulae. In some of them, the integral limits went from $0$ to $\pi$, in others from $-T_0$ to $T_O$. Also, the fraction before the integral differed - in some cases, the integral was multiplied not with $\dfrac 1{2\pi}$, but $\dfrac 1T$, etc.

I need the formula to solve the fourier series for basic functions such as $\sin^2(x)$, etc.

My biggest confusion lies with regard to the 'n' term used in the formulae. In some formula, I have seen it written as, for example, where the $nx$ has been replaced with $nw_0x$, such as follows:

$$f(x) = a_0 + \sum_{n=1}^\infty(a_n\cos(nw_0x)) + \sum_{n=1}^\infty(b_n\sin(nw_0x))$$

$My$ $Confusion:$

What is the difference between $nx$ and $nw_0x$, and which one do I use to solve for the fourier series? I need an explanation of the connection between the two. Could you please list the three formula exactly as I need? I wish to use only the trigonometric Fourier series, please, and in terms of $nx$, not $nw_0x$.

What's important? First, the period of your series must match the period of your original function. For instance, if my period of $f(x)$ is $2 \pi$, then if I write
$$f(x) = a_0 + \sum_{n=1}^\infty a_n \cos(2xn) + \sum_{n=1}^\infty b_n \sin(2xn)$$
it's no good, since the periods of $\sin(2x)$ and $\cos(2x)$, which we get for the smallest $n$, are both $\pi$. Instead, we should use $\cos(nx)$ and $\sin(nx)$. In general, if our function has period $L$, we use $\sin(2\pi n x/L)$ and $\cos(2 \pi n x/L)$. So for your problem, use $L=2 \pi$ since you go from $-\pi$ to $\pi$.
Second, once you have the form of your series down, you choose the appropriate formula. In general for $f$ defined on $[-L/2, -L/2]$ with period $L$, it is $$a_n = \frac{2}{L} \int_{-L/2}^{L/2} f(x) \cos(2\pi nx/L) dx$$ $$b_n = \frac{2}{L} \int_{-L/2}^{L/2} f(x) \sin(2\pi nx/L) dx$$ Again, in your case, $L=2 \pi$, so substitute that in and simplify.