From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 17492 invoked by alias); 6 Dec 2013 14:17:44 -0000 Mailing-List: contact glibc-bugs-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Post: List-Help: , Sender: glibc-bugs-owner@sourceware.org Received: (qmail 17037 invoked by uid 48); 6 Dec 2013 14:17:39 -0000 From: "mwelinder at gmail dot com" To: glibc-bugs@sourceware.org Subject: [Bug math/14473] Inaccurate CPOW* function on all machines. Date: Fri, 06 Dec 2013 14:17:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: glibc X-Bugzilla-Component: math X-Bugzilla-Version: 2.17 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: mwelinder at gmail dot com X-Bugzilla-Status: NEW X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: unassigned at sourceware dot org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Bugzilla-URL: http://sourceware.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-SW-Source: 2013-12/txt/msg00082.txt.bz2 https://sourceware.org/bugzilla/show_bug.cgi?id=14473 --- Comment #6 from M Welinder --- Ok, make that three classes of inaccuracy: (3) Bad handling of real arguments. I see different values in this case: z1 = dont_optimize + 607/128; z2 = 1234567 / 8192; z = cpow (z1, z2); printf ("%.20g + %g i\n", creal (z), cimag (z)); printf ("%.20g\n", pow (creal (z1), creal (z2))); I get: 2.0370359763344673153e+90 + 0 i 2.0370359763344860863e+90 For real arguments cpow should defer to pow. (Or at least use a method that is no less accurate than pow; I think the current evidence is that pow is better.) -- You are receiving this mail because: You are on the CC list for the bug.