Mutual indivisibility and ideals 
Show that two polynomials in $\mathbb{Z}[x]$ are mutually indivisible in $\mathbb{Q}[x]$ if and only if the ideal that is generated by them in $\mathbb{Z}[x]$ contains a non-zero integer.

Suppose that $z\ne 0 \in (f,g)$, then $z=f\cdot f_0 + g\cdot g_0$, for $f,f_0,g,g_0\in\mathbb{Z}[x]$. $z$ is an integer, and therefore would not 'disappear' when considering this equation modulo $f$ or modulo $g$. I believe that this will somehow lead to them being mutually indivisible in $\mathbb{Z}[x]$, but what about $\mathbb{Q}[x]$?
Conversely: $f\not\mid g$ and $g\not\mid f$, then $f$ and $g$ are not associates and therefore $(f)\ne (g)$. Now, $(f,g)=(f)+(g)$. I don't see how to introduce non-zero integers here.
Any ideas? Thanks!
 A: The Euclidean algorithm tells us that for all $f(X)$ and $g(X)$ in $\mathbb{Q}[X]$ there exists $a(X)$ and $b(X)$ such that
$$
  f(X) a(X) + g(X) b(X) = h(X)
$$ 
with $h(X)$ the greatest common divisor of $f(X)$ and $g(X)$. 
Suppose $f(X),g(X)$ are mutually indivisible, with other words, they are relatively prime, this means the greatest common divisor equals $h(X) \in \mathbb{Q}[X]^\times$, this is a non-zero number in $\mathbb{Q}$, name $h(X) = z$.
We see 
$$
  f(X) a(X) + g(X) b(X) = z
$$
this equation is in $\mathbb{Q}[X]$, to bring it in $\mathbb{Z}[X]$ we multiply both sides by all the divisors of the coefficients of $a(X)$ and $b(X)$ and by the divisor of $z$.
This gives $a'(X),b'(X)\in\mathbb{Z}[X]$ and $z'\in\mathbb{Z}$ ($z'\neq0$) such that 
$$ 
  f(X) a'(X) + g(X) b'(X) = z'.
$$
Now the ideal equals
$$(f(X),g(X)) = \{h(X) | h(X) = f(X)a(X)+g(X)b(X) \}.$$ 
And clearly $z'\in(f(X),g(X))$.
On the other hand, suppose $z\neq0\in(f(X),g(X))$, than there are $a(X),b(X)\in\mathbb{Z}[X]$ such that $z = f(X)a(X) + g(X) h(X)$, by definition $f$ and $g$ are relative prime in $\mathbb{Q}[X]$, because $z\in\mathbb{Q}[X]^\times$.
