Let \[ f:S^n\times S^n\longrightarrow S^n\times S^n \] be a homeomorphism. Let \(z\) generate \(H^n(S^n)\) and put \[ \alpha=z\times1,\qquad \beta=1\times z \] in \(H^n(S^n\times S^n)\). Write \[ f^*(\alpha)=k\alpha+l\beta,\qquad f^*(\beta)=p\alpha+q\beta \] for integers \(k,l,p,q\).
Prove that if \(n\) is even, then \[ \begin{pmatrix}k&l\\ p&q\end{pmatrix} \] is one of the eight signed permutation matrices. Also find homeomorphisms \(f\) realizing all eight possibilities.