[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Octave-bug-tracker] [bug #39768] Improve tcdf() accuracy around x = 0
From: |
Julien Bect |
Subject: |
[Octave-bug-tracker] [bug #39768] Improve tcdf() accuracy around x = 0 |
Date: |
Mon, 12 Aug 2013 13:29:35 +0000 |
User-agent: |
Mozilla/5.0 (X11; Ubuntu; Linux i686; rv:23.0) Gecko/20100101 Firefox/23.0 |
URL:
<http://savannah.gnu.org/bugs/?39768>
Summary: Improve tcdf() accuracy around x = 0
Project: GNU Octave
Submitted by: jbect
Submitted on: lun. 12 août 2013 13:29:34 GMT
Category: Octave Function
Severity: 3 - Normal
Priority: 5 - Normal
Item Group: Inaccurate Result
Status: None
Assigned to: None
Originator Name: Julien Bect
Originator Email:
Open/Closed: Open
Discussion Lock: Any
Release: 3.6.4
Operating System: GNU/Linux
_______________________________________________________
Details:
The attached bugfix improves the accuracy of tcdf(x, nu) around x = 0.
As an example, for x=1e-5 and nu=2.5, the reference value obtained using
mpmath is 0.50000361808724021 (computations with 100 significant digits, only
17 significant digits shown).
With Octave 3.6.4 I get:
octave:1> format long
octave:2> y = tcdf(1e-5, 2.5)
y = 0.500003618087390
octave:3> yref = 0.50000361808724021
yref = 0.500003618087240
octave:4> err = (y - yref)/yref
err = 2.99313961550892e-13
With the patch applied:
octave:1> format long
octave:2> y = tcdf(1e-5, 2.5)
y = 0.500003618087240
octave:3> yref = 0.50000361808724021
yref = 0.500003618087240
octave:4> err = (y - yref)/yref
err = 0
_______________________________________________________
File Attachments:
-------------------------------------------------------
Date: lun. 12 août 2013 13:29:34 GMT Name: jbPatch_tcdf_accuracy.patch
Size: 3 ko By: jbect
<http://savannah.gnu.org/bugs/download.php?file_id=28817>
_______________________________________________________
Reply to this item at:
<http://savannah.gnu.org/bugs/?39768>
_______________________________________________
Message posté via/par Savannah
http://savannah.gnu.org/
- [Octave-bug-tracker] [bug #39768] Improve tcdf() accuracy around x = 0,
Julien Bect <=