Bill Allombert on Wed, 22 Sep 2004 11:05:57 +0200


[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]

Re: extended GCD


On Wed, Sep 22, 2004 at 08:38:39AM +0000, Chris Card wrote:
> I was looking for an extended GCD function in PARI/GP and I couldn't find 
> one, which surprised me.
> Is it correct that PARI/GP doesn't have an extended GCD function?

There is one, it is called bezout:

? ?bezout
bezout(x,y): gives a 3-dimensional row vector [u,v,d] such that d=gcd(x,y) and
u*x+v*y=d.

Cheers,
Bill.