Re: GCD in Z[x]_5

From: LD (spam_at_go.home)
Date: 12/15/04


Date: Wed, 15 Dec 2004 20:34:10 +0100

Mkajuma wrote:

> Hi,
> I need to find the gcd of f(x) = x^5 +3x^3 +x^2 +2x+ 2 and g(x) = x^4+
> 3x^3 +3x^2 +x +2 in Z[x]_5 and express it in the form a(x)f(x) + b(x)g(x)
> for some a(x), b(x) in Z[x]_5.

One way to do this is to first determine the gcd via Euclid's algorithm:

f=g*q_1+r_1
g=r_1*q_2+r_2
r_1=r_2*q_3+r_3
...

Stop when you get r_k=0; then gcd(f,g)=r_(k-1) (can you see why?).

Now rewrite the bottom line as r_(k-1)=r_(k-3)-r_(k-2)*q_(k-1), and
substitute r_(k-2) with its value given by the previous line, then r_(k-3)
from the line before, etc., working all the way up to the top line. If you
look at it right, you should see your answer!

Computationally speaking, it looks cumbersome, but I don't think solving for
the coefficients of a and b would be any less so.

LD



Relevant Pages

  • Re: I was right, surrogate factoring proof
    ... >> factor 9 via gcd. ... > There's a proof that the method does not work for primes squared. ... To prove that, mess with the algorithm. ... No, I'm not estimating anything. ...
    (sci.crypt)
  • Re: Analysis ToolPak Function in VBA is sloooow
    ... the algorithm you offered is the best performer of all the solutions offered in this thread so far. ... Thus each scenario calls Totient(and therefore GCD) 1,000,000 times. ... Even after uncommenting the debug.print statements in ATP's native GCD function, timings were in the 80's. ... Dim Remainder As Long ...
    (microsoft.public.excel.programming)
  • Re: how to rotate an array
    ... You can easily find the explanation of Euclidean algorithm on the Internet. ... gcd of original a,b values. ... > loops through the number of elements in the series, ...
    (comp.lang.cpp)
  • Re: euclidean algorithm over Q[i]
    ... Z, the Gaussian integers, may be what you remember seeing. ... written a pretty simplistic algorithm in java that carries out polynomial ... GCD, just using polynomial long division and the euclidean algorithm. ... GCD's of univariate polynomials over Q? ...
    (sci.math.symbolic)
  • Simple factoring algorithm?
    ... Now I'm going to step it out into an algorithm. ... It will come out rational and a fraction, and you make sure that the ... To finish you just substitute in the value of x, ... But hey, it's also an engaging process for me, which I enjoy, ...
    (sci.crypt)