[PATCH] random_normal function

From: Paul Ramsey <pramsey(at)cleverelephant(dot)ca>
To: Pgsql Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: [PATCH] random_normal function
Date: 2022-12-08 21:53:23
Message-ID: CACowWR0DqHAvOKUCNxTrASFkWsDLqKMd6WiXvVvaWg4pV1BMnQ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Just a utility function to generate random numbers from a normal
distribution. I find myself doing this several times a year, and I am
sure I must not be the only one.

random_normal(stddev float8 DEFAULT 1.0, mean float8 DEFAULT 0.0)

Attachment Content-Type Size
random_normal_01.patch application/octet-stream 6.0 KB

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Andres Freund 2022-12-08 21:58:36 Re: Error-safe user functions
Previous Message Andres Freund 2022-12-08 21:53:18 Re: sendFileWithContent() does not advance the source pointer