I have a hunch that this problem is solved using using the theorem (a +cb, b) = (a, b) where a, b, and c are all integers (a and b are not both zero).

Show that ifnis a positive integer, then $\displaystyle (n^2 + 2, n^3 +1) = $ 1, 3, or 9.

I just can't get this to work out.