Let $$ f(x)=3x^4 -2x^3-6x^2+7x-2 $$ and $$ g(x)=3x^4 -8x^3+13x^2-12x+4 $$ I want to find two polynomials $a$ and $b$ so that $$ m=af+bg $$ whereas $m$ is the greatest common divisor.
With some basic algebra, I got $$f(x)=(x-1)(3x-2)(x^2-x+2)$$ $$g(x)=(x-1)(3x-2)(x^2+x-1).$$
So $m=(x-1)(3x-2).$
Now I have $$(x-1)(3x-2)=a(x-1)(3x-2)(x^2-x+2)+b(x-1)(3x-2)(x^2+x-1),$$ which is equivalent to
$$m=m(a(x^2-x+2)+b(x^2+x-1)),$$ and furthermore, $$1=a(x^2-x+2)+b(x^2+x-1)=(a+b)x^2+(b-a)x+2a-b.$$
I read something about Bézout's Identity and with the euclidean algorithm I'll try to reach my goal. Thanks for the help in the comments.