Commuting polynomials in twisted polynomial ring with constant terms satisfying a polynomial relation Suppose $q$ is a prime power, and let $A=\mathbb{F}_q[x,y]/f(x,y)$ where $f(x,y)$ is an irreducible polynomial. Let $K$ be any field such that $A$ injectively maps into $K$. (For ease of notation, assume $A$ is contained in $K$.)
Let $K\{\tau\}$ be the twisted polynomial ring over $K$, where polynomials do not necessarily commute but instead satisfy the relation $\tau\cdot c = c^q\tau$ for any $c\in K$.
Suppose we have two polynomials $\phi_x,\phi_y\in K\{\tau\}$ such that the constant term of $\phi_x$ is $x$ and the constant term of $\phi_y$ is $y$, and such that $\phi_x\phi_y=\phi_y\phi_x$. Then is it necessarily true that $f(\phi_x,\phi_y)=0$ in $K\{\tau\}$? I was surprised to see that the result holds for every example I have tried, which are typically with $q=2$ or $3$ and $f(x,y)=g(x)+h(y)$ for small degree polynomials $g,h$. Here is one such example.
Suppose $q=2$ and $f(x,y)=y^2+y+x^3+x+1$. Suppose we want $\phi_x = x+g_1\tau +\tau^2$ and $\phi_y=y+c_1\tau+c_2\tau^2+c_3\tau^3$ such that $\phi_x\phi_y=\phi_y\phi_x$. Finding such an example requires finding $g_1,c_1,c_2,c_3$ such that each coefficient in the polynomial $\phi_x\phi_y-\phi_y\phi_x$ is zero. If we assume $c_3=0$, there are no solutions according to my computations in Sage. If we assume $c_3=1$, then there is one solution,
\begin{align*}
g_1 &= x^2 +x\\
c_1 &= x^3+x+1\\
c_2 &= x^4 +x^2 +x
\end{align*}
The surprising part to me is that these coefficients also form a solution to the equation
\begin{align*}
\phi_y^2+\phi_y +\phi_x^3+\phi_x+1 =0,
\end{align*}
and that I keep getting the same result for other choices of $f(x,y)$ (within the bounds of what I can ask Sage to compute quickly.)
Is there a way to prove directly that $\phi_x\phi_y=\phi_y\phi_x$ implies $f(\phi_x,\phi_y)=0$?
 A: As you may know, what you are observing comes up in the theory of Drinfeld modules. Briefly this entails considering elements of $K\{\tau\}$ as $\mathbb{F}_q$-linear endomorphisms of the additive group of $K$. The fact that $f(\phi_x,\phi_y)=0$ implies that one can extend $\phi$ to an $\mathbb{F}_q$-algebra homomorphism, $\phi : A \to K\{\tau\}$. This then allows us to define a new $A$-module structure on $K$. Namely,
$$a * z := \phi_a(z), \quad \forall\,a \in A,\ z \in K.$$
One then calls $\phi$ a Drinfeld module, but really it's $K$ together with the $A$-module structure induced by $\phi$.
However, your question was about why your three conditions, that (i) the constant term of $\phi_x$ is $x$, (ii) the constant term of $\phi_y$ is $y$, and (iii) $\phi_x\phi_y=\phi_y\phi_x$, together imply that $f(\phi_x,\phi_y)=0$ in $K\{\tau\}$. This was first observed by D. Hayes in the paper "On the reduction of rank-one Drinfeld modules," Mathematics of Computation 57 (1991), 339-349. Later in a joint paper with D. Dummit, "Rank-one Drinfeld modules on elliptic curves," Math. Comp. 62 (1994), 875-883, Dummit and Hayes provide a nice proof (see the bottom of p. 877), which they credit to M. Rosen.
Rosen's argument goes like this. Conditions (i) and (ii) imply that the constant term, with respect to $\tau$, in $f(\phi_x,\phi_y)$ is $f(x,y)$, and by construction $f(x,y)=0$ in $K$. Therefore, as a polynomial in $\tau$, $f(\phi_x,\phi_y)$ has no constant term.
It is implicit in your set-up, but we should assume that $x$ does not reduce to an element of $\mathbb{F}_q$ in $A = \mathbb{F}_q[x,y]/(f(x,y))$. (E.g., we don't want $f=x-1$.) Though this degenerate case can be handled separately if desired.
Now supposing that $f(\phi_x,\phi_y) \neq 0$, the term of lowest degree in $f(\phi_x,\phi_y)$ is of the form $d_m\tau^m$ for some $m \geq 1$ and $d_m\neq 0$. The commutativity property (iii) and the initial choice that $f$ has coefficients in $\mathbb{F}_q$ imply that
$$\phi_x f(\phi_x,\phi_y)=f(\phi_x,\phi_y)\phi_x.$$
By comparing the coefficients of the $\tau^m$ terms on both sides we obtain the identity in $K$,
$$xd_m = d_mx^{q^m}.$$
The assumption that $x \notin \mathbb{F}_q$ then implies that $d_m=0$ after all.
