Theorem
- If f,dβF[x]
- if dξ =0
- Then, there exists a unique q,rβF[x] s.t:
- f=qd+r
- either r=0 or deg(r)<deg(f)
- If the remainder r=0, then we say:
- d divides f
- f is a multiple of d
- q is the quotient of f and d
You can use the Division Algorithm for Polynomials
Process
Given f1β,f2β. WLOG, let deg(f1β)β₯deg(f2β)
- Set f=f1β,d=f2β, then solve for q,r s.t f=qd+r
- While rξ =0, set f=d,d=r, and solve for q,r s.t f=qd+r
- When r=0,gcd(a,b)=dxakβ1β from your last iteration where akβ is the leading coefficient of a
Example
Find the gcd(x3+2x2βxβ2,x2+2x+1)
- x2+2x+1x3+2x2βxβ2β=(x)(x2+2x+1)+β2xβ2
- β2xβ2x2+2x+1β=(β21βxβ21β)(β2xβ2)+0
- Thus, β21β(β2xβ2) is the GCD
- Thus (x+1) is the GCD