# How can we find a monic polynomial with the smallest degree in left ideal of $\mathrm{Mat}(F[x])$?

Let $F$ be a finite field, $R=F[x]$ be a polynomial ring and $K = \mathrm{Mat}_n(R)$ be a full matrix ring over $R$. We identify the ring $K$ with the ring $\mathrm{Mat}_n(F)[x]$, for example $$\left( \begin{smallmatrix} x&0\\ x^2+1&1 \end{smallmatrix} \right)= \left( \begin{smallmatrix} 0&0\\ 1&0 \end{smallmatrix} \right)x^2+ \left( \begin{smallmatrix} 1&0\\ 0&0 \end{smallmatrix} \right)x+ \left( \begin{smallmatrix} 0&0\\ 1&1 \end{smallmatrix} \right).$$ It is known (see, for example article) that every left ideal $I$ in the ring $K$ is principal left ideal, moreover $I = K\cdot A$ for some triangular matrix $A\in K$.

For given two monic polynomials $A(x), B(x)\in K$ I want to find a monic polynomial $C(x)\in K$ of the smallest degree such that $$C\in K\cdot A+K\cdot B.$$

Using the technique of the mentioned article It is quite easily to find a triangular matrix $D$ such that $$KA+KB = KD.$$ The principal intricacy is to find matrix $C\in KD$ such that the corresponding polynomial from $\mathrm{Mat}_n(F)[x]$ is monic and has the smallest degree.

Maybe it is possible to find the polynomial from $K$ with the smallest degree (not necessarily monic)?