The question essentially pertains to how Gauss's lemma relates to polynomials with coefficients in a polynomial ring over the integers.
I have a polynomial $f(y) = \sum_{k=0}^D c_k y^k$ where $\forall k, c_k \in \mathbb{Z}[x_0,x_1,\dots, x_d]$ the coefficients are polynomials of other variables $x_i$ with integer coefficients. That is $c_k = \sum_i b_i \left(\prod_j x_j^{p_{i,j}}\right)$ where $b_i, p_{i,j}\in \mathbb{Z}$ where $b_i, p_{i,j}\in \mathbb{Z}$.
In my case I'm actually interested in the case where $D=3$ and $f$ is a cubic. Gauss's lemma states that when the coefficients $c_k$ are 'integers' then the rational root test should give us co-prime $p,q$ where $q|c_3$ and $p|c_0$ such that there is a root $qy-p$.
Additionally I know that $f$ is reducible.
The question is what does it mean in this case for the coefficients $c_k$ to be integers?
Intuitively if the elements $x_k$ are integers in $\mathbb{Z}[x_0,x_1,\dots, x_d]$ then I would expect the set of integers to be closed under addition and multiplication such that each $c_k$ should be an integer in the field
$\mathbb{F} = \mathbb{Z}[x_1,x_2,\dots, x_d]$. Then since $f\in \mathbb{F}[y]$ I would think that there should be a $p,q\in \mathbb{F}$ such that $(qy-p)| f$.
My apologies if the above is ridiculous, I don't have much experience working with these types of structures.
I am trying to find the factor $qy-p$ for a particular polynomial. Sympy is able to find an analytic solution for the roots of $f$ but I am surprised that there are radicals in the expression for the real root. I suppose this could be related to how the roots are found by the sympy algorithm though.