I'm trying to find the greates common divisor of two polynomials. The polynomials are:
p1=x3+3x+1p2=x4+1
Matlab is telling me that the GCD is 1, and that's also what I was expected.
However when I try to do It by hand it dosn't equal to 1, so what am I doing wrong?(I'm using Long division and writing it as Euclidian algorithm).
x4+1=(x3+3x+1)⋅x−(3x2−x+1)x3+3x+1=(−3x2−x+1)⋅(−x3+19)+(31x9+89)−3x2−x+1=(31x9+89)⋅(−27x31−63961)+101796131x9+89=1017961⋅(29791x9153+76889153)+891017961=89⋅91537688+0
so the GCD should be =89??
No comments:
Post a Comment