1
$\begingroup$

So according to WolframAlpha the answer should be $1$ (And by inspection it certainly looks like it should be $1$.

My current working using Euclidean algorithm and polynomial long division

$x^3-x^2+2) = (x) \times (x^2-x+1) + (2-x)$
$x^2-x+1 = (-1-x) \times (2-x) + 3$
$(2-x) = \frac{2}{3} \times 3 - x$

Ok not sure what's going on now - I could keep going but I don't see it ever reaching $1$

What have I done wrong here?

2 Answers 2

3

In your last line, you have \[ (2-x) = \left(\frac 23 - \frac 13x\right) \cdot 3 + 0\] and you are done. Note that $1$ and $3$ are associated in $\mathbb R[X]$ as they are both units and so represent the same gcd.

  • 0
    Oops, nevermind, it's something $f$rom a di$f$ferent part of the question that I didn't include in this question. Forget that last comment2012-11-07
2

Hint $ $ It's much more insightful (and just as simple) to compute the gcd of an arbitrary cubic and quadratic. Let $\rm\:f_3,\, f_2\:$ be polynomials of degree $\:3,\,2\:$ over a field. By the Division algorithm

$\rm f_3 = g\, f_2 + a\, x - b\ \Rightarrow\ gcd(f_2,f_3) = gcd(f_2,\:g\,f_2\!+a\,x-b) = gcd(f_2,a\,x-\!b)$

$\begin{eqnarray} \rm a\ne0 \ &\Rightarrow&\ \rm gcd(f_2,a\,x-\!b)\ =\ a\,x\!-\!b\ \ iff\ \ f_2(b/a)\, =\, 0,\,\ \ else\ \ the\ \ gcd = 1 \\ \\ \rm a=0 \ &\Rightarrow&\ \rm gcd(f_2,a\,x-\!b) = gcd(f_2,b)\ =\ f_2\ \ iff\ \ b= 0,\ \ else\ the\ gcd = 1 \end{eqnarray} $

In your case $\rm\:a\,x-\!b\, =\, -x + 2,\: $ and $\rm\:f_2(2) = 2^2\!-2+1 = 3\ne 0,\:$ so the gcd $=1$ (except in a field of characteristic $3,\:$ such as $\,\Bbb Z/3 = $ integers mod $3$, where the gcd $\rm = x-2 = x+1).\:$