Skip site navigation (1) Skip section navigation (2)

Re: Arbitrary precision modulo operation

From: Alvaro Herrera <alvherre(at)dcc(dot)uchile(dot)cl>
To: Dann Corbit <DCorbit(at)connx(dot)com>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: Arbitrary precision modulo operation
Date: 2004-04-29 02:26:38
Message-ID: 20040429022638.GD8757@dcc.uchile.cl (view raw or flat)
Thread:
Lists: pgsql-general
On Wed, Apr 28, 2004 at 03:06:25PM -0700, Dann Corbit wrote:
> /*
> ** Hopefully, I am not annoying anyone with all of this.
> ** This is a brief demonstration of how Newton's division algorithm
> works:
> */

Well, have you looked at Postgres implementation?  I don't know if it's
Newton or not, but it certainly is not simple (I didn't take the time to
understand it).

Have a look at src/backend/utils/adt/numeric.c function div_var()

 Cc: list trimmed ...

-- 
Alvaro Herrera (<alvherre[a]dcc.uchile.cl>)
"¿Cómo puedes confiar en algo que pagas y que no ves,
y no confiar en algo que te dan y te lo muestran?" (Germán Poo)

In response to

pgsql-general by date

Next:From: RobDate: 2004-04-29 02:43:43
Subject: postgresql web problems?
Previous:From: 帅猛Date: 2004-04-29 01:40:59
Subject: error about tcl/tk

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group