Re: Add error functions: erf() and erfc()

Nathan Bossart <nathandbossart@gmail.com>

From: Nathan Bossart <nathandbossart@gmail.com>
To: Dean Rasheed <dean.a.rasheed@gmail.com>
Cc: PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>
Date: 2023-03-09T00:30:02Z
Lists: pgsql-hackers
On Thu, Mar 09, 2023 at 12:27:47AM +0000, Dean Rasheed wrote:
> On Thu, 9 Mar 2023 at 00:13, Nathan Bossart <nathandbossart@gmail.com> wrote:
>> I'm also wondering about whether we need the isinf() checks.  IIUC that
>> should never happen, but maybe you added that "just in case."
> 
> I copied those from dtanh(), otherwise I probably wouldn't have
> bothered. erf() is always in the range [-1, 1], just like tanh(), so
> it should never overflow, but maybe it can happen in a broken
> implementation.

Okay.  This looks good to me, then.

-- 
Nathan Bossart
Amazon Web Services: https://aws.amazon.com



Commits

  1. Add support for the error functions erf() and erfc().