Re: RFC: New math functions: log2, etc

From: Date: Fri, 03 Aug 2001 23:46:57 +0000
Subject: Re: RFC: New math functions: log2, etc
References: 1  Groups: php.dev 
Request: Send a blank email to php-dev+get-62021@lists.php.net to get a copy of this message
At 01:41 AM 8/4/2001 +0200, jeroen@php.net wrote:
Hi, I've got the following suggestion, about some of the new math-functions recently added: log2 and log10: remove from PHP exp2 and exp10: remove from PHP (the pow-way is also simply better, in the case of exp2/10, that is) Add second parameter to log, to specify base. (better than writing log(a)/log(b)) Optional: add second parameter to exp, to specify base. I am not in favor of the latter one, since exp(exp,base) === pow(base,exp). But for consistency with log, you could argue to do so. Remove cbrt?, isn't used much, and the name isn't as familiar as sqrt. expm1, log1p: Could be useful for some people, so leave them there.
log(a) / log(n) is not that much harder, and its the right way, imho. Why not move the more complex functions into a separate "math" extension or statistics extension? -Sterling

« previous php.dev (#62021) next »