Proving $\frac{\sin x}{x} =\left(1-\frac{x^2}{\pi^2}\right)\left(1-\frac{x^2}{2^2\pi^2}\right) \left(1-\frac{x^2}{3^2\pi^2}\right)\cdots$
Solution 1:
Real analysis approach.
Let $\alpha\in(0,1)$, then define on the interval $[-\pi,\pi]$ the function $f(x)=\cos(\alpha x)$ and $2\pi$-periodically extended it the real line. It is straightforward to compute its Fourier series. Since $f$ is $2\pi$-periodic and continuous on $[-\pi,\pi]$, then its Fourier series converges pointwise to $f$ on $[-\pi,\pi]$: $$ f(x)=\frac{2\alpha\sin\pi\alpha}{\pi}\left(\frac{1}{2\alpha^2}+\sum\limits_{n=1}^\infty\frac{(-1)^n}{\alpha^2-n^2}\cos nx\right), \quad x\in[-\pi,\pi]\tag{1} $$ Now take $x=\pi$, then we get $$ \cot\pi\alpha-\frac{1}{\pi\alpha}=\frac{2\alpha}{\pi}\sum\limits_{n=1}^\infty\frac{1}{\alpha^2-n^2}, \quad\alpha\in(-1,1)\tag{2} $$ Fix $t\in(0,1)$. Note that for each $\alpha\in(0,t)$ we have $|(\alpha^2-n^2)^{-1}|\leq(n^2-t^2)^{-1}$ and the series $\sum_{n=1}^\infty(n^2-t^2)^{-1}$ is convergent. By Weierstrass $M$-test the series in the right hand side of $(2)$ is uniformly convergent for $\alpha\in(0,t)$. Hence we can integrate $(2)$ over the interval $[0,t]$. And we get $$ \ln\frac{\sin \pi t}{\pi t}=\sum\limits_{n=1}^\infty\ln\left(1-\frac{t^2}{n^2}\right), \quad t\in(0,1) $$ Finally, substitute $x=\pi t$, to obtain $$ \frac{\sin x}{x}=\prod\limits_{n=1}^\infty\left(1-\frac{x^2}{\pi^2 n^2}\right), \quad x\in(0,\pi) $$
Complex analysis approach
We will need the following theorem (due to Weierstrass).
Let $f$ be an entire function with infinite number of zeros $\{a_n:n\in\mathbb{N}\}$. Assume that $a_0=0$ is zero of order $r$ and $\lim\limits_{n\to\infty}a_n=\infty$, then $$ f(z)= z^r\exp(h(z))\prod\limits_{n=1}^\infty\left(1-\frac{z}{a_n}\right) \exp\left(\sum\limits_{k=1}^{p_n}\frac{1}{k}\left(\frac{z}{a_n}\right)^{k}\right) $$ for some entire function $h$ and sequence of positive integers $\{p_n:n\in\mathbb{N}\}$. The sequence $\{p_n:n\in\mathbb{N}\}$ can be chosen arbitrary with only one requirement $-$ the series $$ \sum\limits_{n=1}^\infty\left(\frac{z}{a_n}\right)^{p_n+1} $$ is uniformly convergent on each compact $K\subset\mathbb{C}$.
Now we apply this theorem to the entire function $\sin z$. In this case we have $a_n=\pi n$ and $r=1$. Since the series $$ \sum\limits_{n=1}^\infty\left(\frac{z}{\pi n}\right)^2 $$ is uniformly convergent on each compact $K\subset \mathbb{C}$, then we may choose $p_n=1$. In this case we have $$ \sin z=z\exp(h(z))\prod\limits_{n\in\mathbb{Z}\setminus\{0\}}\left(1-\frac{z}{\pi n}\right)\exp\left(\frac{z}{\pi n}\right) $$ Let $K\subset\mathbb{C}$ be a compact which doesn't contain zeros of $\sin z$. For all $z\in K$ we have $$ \ln\sin z=h(z)+\ln(z)+\sum\limits_{n\in\mathbb{Z}\setminus\{0\}}\left(\ln\left(1-\frac{z}{\pi n}\right)+\frac{z}{\pi n}\right) $$ $$ \cot z=\frac{d}{dz}\ln\sin z=h'(z)+\frac{1}{z}+\sum\limits_{n\in\mathbb{Z}\setminus\{0\}}\left(\frac{1}{z-\pi n}+\frac{1}{\pi n}\right) $$ It is known that (here you can find the proof) $$ \cot z=\frac{1}{z}+\sum\limits_{n\in\mathbb{Z}\setminus\{0\}}\left(\frac{1}{z-\pi n}+\frac{1}{\pi n}\right). $$ hence $h'(z)=0$ for all $z\in K$. Since $K$ is arbitrary then $h(z)=\mathrm{const}$. This means that $$ \sin z=Cz\prod\limits_{n\in\mathbb{Z}\setminus\{0\}}\left(1-\frac{z}{\pi n}\right)\exp\left(\frac{z}{\pi n}\right) $$ Since $\lim\limits_{z\to 0}z^{-1}\sin z=1$, then $C=1$. Finally, $$ \frac{\sin z}{z}=\prod\limits_{n\in\mathbb{Z}\setminus\{0\}}\left(1-\frac{z}{\pi n}\right)\exp\left(\frac{z}{\pi n}\right)= \lim\limits_{N\to\infty}\prod\limits_{n=-N,n\neq 0}^N\left(1-\frac{z}{\pi n}\right)\exp\left(\frac{z}{\pi n}\right)= $$ $$ \lim\limits_{N\to\infty}\prod\limits_{n=1}^N\left(1-\frac{z^2}{\pi^2 n^2}\right)= \prod\limits_{n=1}^\infty\left(1-\frac{z^2}{\pi^2 n^2}\right) $$ This result is much more stronger because it holds for all complex numbers. But in this proof I cheated because series representation for $\cot z$ given above require additional efforts and use of Mittag-Leffler's theorem.
Solution 2:
It is easy to prove , using complex , worth equality below: \begin{equation} \sin((2n+1)z)=\sum_{k=0}^{n}{2n+1 \choose 2k+1}(-1)^k(\cos z)^{2n-2k} \tag{1}(\sin z)^{2k+1} \end{equation}
Dividing above equality by $\displaystyle \sin(z)\cos^{2n}z$, we get: \begin{equation} \frac{\sin((2n+1)z)}{\sin(z)\cos^{2n}z}=\sum_{k=0}^{n}{2n+1 \choose 2k+1}(-1)^k\tan^{2k}(z) \tag{2} \end{equation}
Dividing (1) by $\displaystyle sin^{2n+1}z$ , we get: \begin{equation} \frac{\sin((2n+1)z)}{\sin^{2n+1}z}=\sum_{k=0}^{n}{2n+1 \choose 2k+1}(-1)^k\cot^{2(n-k)}(z) \tag{3} \end{equation}
Making $\displaystyle \cot^2z=\zeta$, we obtain a polynomial in the variable $\displaystyle \zeta$:
\begin{equation} \frac{\sin((2n+1)z)}{\sin^{2n+1}z}=\sum_{k=0}^{n}{2n+1 \choose 2k+1}(-1)^k\zeta^{n-k} \tag{4} \end{equation}
Which is a polynomial of degree n in $\displaystyle \zeta$.As $\displaystyle \zeta$ It is a function of z, we can find the roots of this polynomial by sine the left side, see that: $\\ \displaystyle \sin((2n+1)z)=0\Rightarrow (2n+1)z=k\pi \Rightarrow z=\frac{k\pi}{2n+1}, k \in \mathbb{N}^{*}|k\leq n \\ \\$
The roots of polynomial is:
\begin{equation} \zeta_k=\cot^2\left(\frac{k\pi}{2n+1}\right), k \in \mathbb{N}^{*}|k\leq n \end{equation}
The fundamental theorem of algebra can factor a polynomial by its roots , then we can rewrite ( 4 ) as:
\begin{equation} \frac{\sin((2n+1)z)}{\sin^{2n+1}z}={2n+1 \choose 1}\prod_{k=1}^{n}(\zeta-\zeta_k) \end{equation} ut we have $\displaystyle \cot^2z=\zeta$ and $\displaystyle \zeta_k=\cot^2\left(\frac{k\pi}{2n+1}\right)$, and we get:
\begin{equation} \frac{\sin((2n+1)z)}{\sin^{2n+1}z}=(2n+1)\prod_{k=1}^{n}\left(\cot^2(z)-\cot^2\left(\frac{k\pi}{2n+1}\right)\right) \end{equation}
Multiplying both sides of the above equality by $\displaystyle \tan^{2n}z$, we get:
\begin{equation} \frac{\sin((2n+1)z)}{\sin z\cos^{2n}z}=(2n+1)\prod_{k=1}^{n}\left(1-\tan^2(z) \cot^2\left(\frac{k\pi}{2n+1}\right)\right) \tag{5} \end{equation}
Comparing ( 2 ) and ( 5) , we have:
\begin{equation} \sum_{k=0}^{n}{2n+1 \choose 2k+1}(-1)^k\tan^{2k}(z)=(2n+1)\prod_{k=1}^{n}\left(1-\tan^2(z) \cot^2\left(\frac{k\pi}{2n+1}\right)\right) \end{equation}
Replacing z by $\displaystyle \arctan \frac{z}{2n+1}$, we get:
\begin{equation} \sum_{k=0}^{n}{2n+1 \choose 2k+1}(-1)^k\left( \frac{z}{2n+1}\right)^{2k}=(2n+1)\prod_{k=1}^{n}\left(1-\left( \frac{z}{2n+1}\right)^2 \cot^2\left(\frac{k\pi}{2n+1}\right)\right) \end{equation} Multiplying both sides of the above equality by $\displaystyle \frac{z}{2n+1}$, we have:
\begin{equation} \sum_{k=0}^{n}{2n+1 \choose 2k+1}(-1)^k\left( \frac{z}{2n+1}\right)^{2k+1}=z\prod_{k=1}^{n}\left(1-\left( \frac{z}{2n+1}\right)^2 \cot^2\left(\frac{k\pi}{2n+1}\right)\right) \tag{6} \end{equation}
Notice that: \begin{equation} \sum_{k=0}^{n}{2n+1 \choose 2k+1}(-1)^k\left( \frac{z}{2n+1}\right)^{2k+1}=\frac{1}{2i}\left[\left(1+\frac{zi}{2n+1}\right)^{2n+1}-\left(1-\frac{zi}{2n+1}\right)^{2n+1}\right] \tag{7} \end{equation}
Substituting ( 7) into ( 6) and taking the limit to infinity , it follows that : \begin{equation} \lim_{n \rightarrow \infty} \frac{1}{2i}\left(\left(1+\frac{zi}{2n+1}\right)^{2n+1}-\left(1-\frac{zi}{2n+1}\right)^{2n+1}\right)=\lim_{n \rightarrow \infty} z\prod_{k=1}^{n}\left(1-\left( \frac{z}{2n+1}\right)^2 \cot^2\left(\frac{k\pi}{2n+1}\right)\right) \end{equation}
And this implies:
\begin{equation} \sin z=\lim_{n \rightarrow \infty} z\prod_{k=1}^{n}\left(1-\left( \frac{z}{2n+1}\right)^2 \cot^2\left(\frac{k\pi}{2n+1}\right)\right) \end{equation} Applying "Tannery's Theorem" we get:
\begin{equation*} \sin z=z\prod_{k=1}^{ \infty}\left(1- \frac{z^2}{k^2\pi^2}\right) \end{equation*}