php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #14756 pow(0,[broken power]) gives wrong result
Submitted: 2001-12-29 14:49 UTC Modified: 2002-01-10 17:20 UTC
From: php at mouken dot com Assigned:
Status: Closed Package: Math related
PHP Version: 4.1.1 OS: Linux (Debian 2.2)
Private report: No CVE-ID: None
View Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
If you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: php at mouken dot com
New email:
PHP Version: OS:

 

 [2001-12-29 14:49 UTC] php at mouken dot com
The pow() function returns incorrect results when raising zero to a "broken power".

pow(0,0.5) ("the square root of zero"), for example, returns NAN. It should return zero.

This, is new since 4.0.6. Perhaps it is related to the fix for bug #14544.

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2002-01-10 13:31 UTC] php at mouken dot com
pow() returns incorrect results when raising zero to a "broken power".

Example:
pow(0,0.5) ("the square root of zero") returns NAN. It should return zero.

This was introduced sometime after 4.0.6. Perhaps it is related to the fix for bug #14544.
 [2002-01-10 17:20 UTC] derick@php.net
This is fixed in CVS already

Derick
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sat Dec 21 13:01:31 2024 UTC