Given 3 matrices $A, B, C \in \mathbb{F} ^ {n x n}$, let $T = \left( \begin{array}{rrr} A & C \\ 0 & B \\ \end{array}\right)$$\in\mathbb{F}^{2nx2n}$. Let $m_A, m_B, m_T$ be the minimal polynomials of these matrices and $g:=gcd(m_A,m_B)$.
I am searching for an example, such that $(m_A.m_B)\over g$ $\neq m_T \neq m_A.m_B$.
I tried out various forms of $C=0$ and $A, B$ being diagonal matrices. However, $g$ cancels the terms always in such a way that $(m_A.m_B)\over g$$= m_T$. Could you give me a hint as to how i could efficiently approach finding a counter example?
It turns out that there are no counterexamples with $C = 0$. In all such cases, it holds that $m_T = (m_A \cdot m_B)/g$, as you observed.
I'm not sure how one would systematically go about finding counterexamples. However, I found this example by following a hunch that we could do something using nilpotent matrices as the diagonal entries: $$ T = \left[ \begin{array}{cc|cc} 0&1&1&0\\0&0&0&1\\ \hline 0&0&0&1\\0&0&0&0 \end{array} \right]. $$ We find that $m_A(x) = m_B(x) = x^2$, but $m_T(x) = x^3$ and $m_A\cdot m_B = x^4$.