(**Edit** : see at the bottom of the question for an additional surprising possible hint.)


Using a computational software program, I found that the kernel of the following matrix is of dimension 2 when $n\geqslant 2$ but I haven't managed to prove it:
\begin{equation}
\text{for almost all } t\_1>0,\quad \text{dim}\,\text{ker}\left(\mathbf{Q}\_2\mathbf{Q}\_1(t\_1)-\mathbf{Q}\_1(t\_2)^{-1}\mathbf{Q}\_2\right)\overbrace{=}^?\;2 
\end{equation} where $t\_2$ is chosen (assuming it exists) such that $$\text{det}\left(\mathbf{Q}\_2\mathbf{Q}\_1(t\_1)-\mathbf{Q}\_1(t\_2)^{-1}\mathbf{Q}\_2\right)=0$$
where


* $n\geqslant 2$
* $\mathbf{Q}\_2$ is the following matrix:
\begin{equation}
\mathbf{Q}\_2=\begin{bmatrix} \mathbf{I}\_n & \mathbf{0}\_n \\ \mathbf{0}\_n & \mathbf{P}^{-1}\begin{bmatrix}1 & && \\ & \ddots && \\ & & 1& \\ &&& -1 \end{bmatrix}\mathbf{P} \end{bmatrix}\in\mathbb{R}^{2n\times2n}
\end{equation}
where $\mathbf{P}\in\mathbb{R}^{n\times n}$ is any invertible matrix.
* $\mathbf{Q}\_1(t)$ is defined by:


\begin{equation}
\forall t>0,\quad\mathbf{Q}\_1(t)=\begin{bmatrix}\textbf{cos}(\boldsymbol \Omega t) & \boldsymbol \Omega^{-1}\,\textbf{sin}(\boldsymbol \Omega t) \\ -\boldsymbol \Omega\,\textbf{sin}(\boldsymbol \Omega t) & \textbf{cos}(\boldsymbol \Omega t)\end{bmatrix}\in\mathbb{R}^{2n\times2n}
\end{equation}
and:
\begin{equation}
\boldsymbol\Omega=\begin{bmatrix} \omega\_1 & & 0\\ & \ddots & \\ 0 & & \omega\_n \end{bmatrix}\in\mathbb{R}^{n\times n},\quad \forall i\in\lbrace 1,\dots, n\rbrace, \omega\_i>0
\end{equation}


and the four blocks are diagonal, for example:
\begin{equation}
\mathbf{cos}(\boldsymbol\Omega t)=\begin{bmatrix} \cos(\omega\_1t) & &0 \\ & \ddots & \\ 0 & & \cos(\omega\_n t) \end{bmatrix}\in\mathbb{R}^{n\times n}
\end{equation}




---


*Few properties of $\mathbf{Q}\_1$ and $\mathbf{Q}\_2$*:


Obviously, $\mathbf{Q}\_2$ is invertible and $\mathbf{Q}\_2=\mathbf{Q}\_2^{-1}$.


Also, $\det(\mathbf{Q}\_1)=1$ ($\omega\_i>0$ and for proper $t>0$) and:
\begin{equation}
\mathbf{Q}\_1(t)^{-1}=\begin{bmatrix}\textbf{cos}(\boldsymbol \Omega t) & -\boldsymbol \Omega^{-1}\,\textbf{sin}(\boldsymbol \Omega t) \\ \boldsymbol \Omega\,\textbf{sin}(\boldsymbol \Omega t) & \textbf{cos}(\boldsymbol \Omega t)\end{bmatrix}
\end{equation}


Also, $\forall s,t,\ \mathbf{Q}\_1(s+t)=\mathbf{Q}\_1(s)\mathbf{Q}\_1(t)=\mathbf{Q}\_1(t)\mathbf{Q\_1}(s)$.


(Note: I've already asked this question [here](https://math.stackexchange.com/questions/976987/proof-of-the-conjecture-that-the-kernel-is-of-dimension-2-extended) but did not get any answer despite a bounty.)




---


**Edit** Additional possible hint:
I've found that for $n=2$ (maybe it's more general), the follow results stands, if $A=\mathbf{Q}\_2\mathbf{Q}\_1(t\_1)-\mathbf{Q}\_1(t\_2)^{-1}\mathbf{Q}\_2$ and $\phi(x)=\det(A-xI)$:
$$\phi'(0)^2=-\phi(0)\det(B)$$
where $B$ is the $A$ matrix if $\mathbf{P}=\mathbf{I}$... ! I have no clue where this comes from, maybe it's obvious for someone (maybe related to Lie algebras?).


This would conclude the proof as $\phi(0)=\det(A(t\_1,t\_2))=0$ for the appropriate $t\_1,t\_2$, so that $0$ would be a double eigenvalue of $A$.



Proving that the kernel of this matrix is of dimension 2
Thanks to [@Terry Tao's answer](https://mathoverflow.net/a/198863/54797), I can now give a solution to the question. I am open to comments or precisions.


$Q\_1(t)$ can be conjugated with by $\text{diag}(\omega\_1,\dots,\omega\_n,1,\dots, 1)$ which transforms it into a rotation matrix without affecting $Q\_2$. 


It is bit more tricky, but $Q\_2$ can be conjugated with a diagonal matrix $\text{diag}(d\_1,\dots,d\_n,d\_1,\dots,d\_n)$ which transforms it into an orientation-reversing orthogonal matrix without affecting $Q\_1(t)$. More precisely, this seems to be true for an open set of $P$ dense in the matrix vector space.


The conjugations do not depend on $t$, so at the end of the day, $Q\_2Q\_1(t\_1)Q\_2Q\_1(t\_1)$ is similar to an orientation-preserving orthogonal matrix, whose eigenvalues lie on the unit circle and can be $1$, $-1$ or appear by pair of complex conjugates. The product of the eigenvalues is $1$, so $-1$ has to appear an even number of times. The matrix $Q\_2Q\_1(t\_1)Q\_2Q\_1(t\_1)$ is a $2n\times 2n$ matrix, so $1$ also has to appear with an even multiplicity.


So if 1 is eigenvalue of $Q\_2Q\_1(t\_1)Q\_2Q\_1(t\_1)$, the corresponding eigenspace is of dimension greater than 2. I do not have the mathematical background to prove it (help is welcome), but I guess one concludes by proving that the set of eigenvalues with exactly two eigenvalues equal to 1 is dense in the set of eigenvalues with at least two eigenvalues equal to 1. But it is still possible to find some values of $P$ and $\omega\_i$ such that 1 has a multiplicity of 4, or even 6, etc.


The last step is to remark that the eigenspace for the eigenvalue 1 of $Q\_2Q\_1(t\_1)Q\_2Q\_1(t\_1)$ is the eigenspace for the eigenvalue 0 of $Q\_2Q\_1(t\_1)-(Q\_2Q\_1(t\_2))^{-1}$ or of $Q\_2Q\_1(t\_1)-Q\_1(-t\_2)Q\_2$.


