Following on from this post (apologies for bad etiquette, seemed cleaner to repost with new information), I want to prove the assertion that for a UFD $D$, $F$ the field of fractions of $D$ and $p(x) \in D[x]$,
$p(x)$ irreducible in $F[x]$ $\Leftrightarrow$ $p(x)$ irreducible in $D[x]$
I had struggled to understand the relevance of the primitive property of $p(x)$, but found from other questions that e.g. $2x+4$ is reducible over $\mathbb{Z}[x]$, but not over $\mathbb{Q}[z]$, which was something that escaped me, since I thought irreducibility for polynomials was slightly different to elements of a UFD.
So does the following proof seem correct (this is not a hw Q, just something I'm playing with):
First, this lemma without proof:
Let $D$ be a UFD and $F$ its field of fractions. Suppose that $p(x)\in D[x]$ and $p(x)=f(x)g(x)$, where $f(x)$ and $g(x)$ are in $F[x]$. Then $p(x)=f_1(x)g_1(x)$, where $f_1(x)$ and $g_1(x)$ are in $D[x]$. Furthermore, $deg~f(x)=deg~f_1(x)$ and $deg~g(x)=deg~g_1(x)$.
Then to the main result:
$\Rightarrow$:
Let $p(x)$ be irreducible over $F[x]$. Then $p(x)=a g(x)$, where $a\in F$, $g(x) \in F[x]$, and $deg~g(x) = deg~p(x)$.
Suppose $p(x)=f_1(x)g_1(x)$ with $f_1(x)$,$g_1(x)$ $\in D[x]$, and let the content of $f_1(x)$, $g_1(x)$ be $a_1, b_1$ respectively. Since $p(x)$ is primitive, we have $1=a_1b_1$ so $a_1$, $b_1$ are units in $D$.
Since $D[x]\subset F[x]$, we must then have either $f_1(x)$ a constant and $deg~g_1(x) = deg~p(x)$ , or vice versa. If $f_1(x)$ is a constant, it is $a_1$ and thus a unit in $D$, so $p(x) = a_1 g_1(x)$ is irreducible in $D[x]$.
$\Leftarrow$:
Let $p(x)$ be irreducible in $D[x]$. Suppose $p(x)=f(x)g(x)$, with $f(x),g(x)\in F[x]$. The lemma tells us that we must have $p(x)=f_1(x)g_1(x)$ with $f_1(x),g_1(x)\in D[x]$ with the appropriate degrees.
Since $p(x)$ is irreducible, then either $f_1(x) =a_1 \in D$ and $deg~g_1(x) = deg~p(x)$, or vice versa. Again, using the fact that $p(x)$ is primitive tells us that $a_1$ must be a unit in $D$.
Since the degrees of the factors are the same in $F[x]$ and $D[x]$, we must have that $f(x)$ is a constant (and since $F$ is a field, a unit) and $deg~g(x) = deg~p(x)$. Hence $p(x)$ is irreducible in $F[x]$.
I realize it may be simpler to directly prove the contrapositive statement but this is how the logic flows in my head.