<s>[INST] extracting the middle term of $ (z \cos \theta + w\sin \theta )^m(- z\sin \theta + w\cos \theta )^m $ Is there a systematic way to extract the middle term of the following expression?
$$ (z \cos \theta  + w\sin \theta )^m(- z\sin \theta  + w\cos \theta )^m $$
This is homogeneous polynomial of degree $2m$, so I am looking for the $(zw)^m$ term.

Example $m = 2$:
$$ (z \cos \theta  + w\sin \theta )^2(- z\sin \theta  + w\sin \theta )^2
= \dots + (zw)^2(\cos^4 \theta - 4 \cos^2 \theta \sin^2 \theta + \sin^4 \theta) + \dots $$
The middle terms can be simplified using the cosine double angle formulas.
\begin{eqnarray}\cos^4 \theta - 4 \cos^2 \theta \sin^2 \theta + \sin^4 \theta
&=& (\cos^2 \theta - \sin^2 \theta)^2 - 2 \cos^2 \theta \sin^2 \theta \\
&=& \cos^2 2\theta - \tfrac{1}{2}\sin^2 2\theta \\
&=& \boxed{\tfrac{3}{2}\cos^2 2\theta - \tfrac{1}{2}}
\end{eqnarray}
Is it true this middle term can always be expanded as a polynomial in $x=\cos 2\theta$?  

I learned of this trick while studying the Wigner D-matrices.  It says the Legendre polynomials are certain matrix elements in the representation theory of $SU(2)$.  Checking this fact was surprisingly hard.
 [/INST] Continuing mickep's answer, these are, indeed, the Legendre Polynomials
$$
\sum_{k=0}^m (-1)^k{m\choose k}^2 \bigl[\tfrac{1}{2}(1+\cos2\theta)\bigr]^{m-k}\bigl[\tfrac{1}{2}(1-\cos2\theta)\bigr]^k
= P_m(\cos(2\theta))
$$
</s>