From: | Dean Rasheed <dean(dot)a(dot)rasheed(at)gmail(dot)com> |
---|---|
To: | Vik Fearing <vik(dot)fearing(at)2ndquadrant(dot)com> |
Cc: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Fabien COELHO <coelho(at)cri(dot)ensmp(dot)fr>, Stephen Frost <sfrost(at)snowman(dot)net>, Chapman Flack <chap(at)anastigmatix(dot)net>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org> |
Subject: | Re: Greatest Common Divisor |
Date: | 2020-01-20 10:28:37 |
Message-ID: | CAEZATCW282AQ0QwR-n+FSeyhyifvLZP9+p-iy_+8K-Nm1vCdNA@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Looking at the docs, I think it's worth going a little further than
just saying what the acronyms stand for -- especially since the
behaviour for zero inputs is an implementation choice (albeit the most
common one). I propose the following:
+ <entry>
+ greatest common divisor — the largest positive number that
+ divides both inputs with no remainder; returns <literal>0</literal> if
+ both inputs are zero
+ </entry>
and:
+ <entry>
+ least common multiple — the smallest strictly positive number
+ that is an integer multiple of both inputs; returns
<literal>0</literal>
+ if either input is zero
+ </entry>
(I have tried to be precise in my use of terms like "number" and
"integer", to cover the different cases)
Regards,
Dean
From | Date | Subject | |
---|---|---|---|
Next Message | Daniel Verite | 2020-01-20 10:42:05 | Re: Making psql error out on output failures |
Previous Message | Peter Eisentraut | 2020-01-20 09:17:50 | Re: Unicode normalization SQL functions |