tanh function returns incorrect results

Bug #871988 reported by Steve Atwell
14
This bug affects 1 person
Affects Status Importance Assigned to Milestone
gcalctool (Debian)
Fix Released
Unknown
gcalctool (Ubuntu)
Fix Released
High
Unassigned
Lucid
Fix Released
High
Unassigned

Bug Description

gcalctool evaluates the tanh function incorrectly.

Steps to reproduce:

Run "gcalctool --solve 'tanh 0.1'". It will print 0.549833997, although the actual answer is 0.099667995. This is also repeatable using the graphical calculator interface.

Installed: 5.30.0.is.5.28.2-0ubuntu2
Distributor ID: Ubuntu
Description: Ubuntu 10.04.2 LTS

This has been fixed in Debian (see http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=604032) and Natty, but it's still a problem in Lucid. Can you please add the patch to Lucid and SRU this? It's a very simple patch, and it's pretty bad to have the default calculator in gnome give incorrect answers.

Revision history for this message
Steve Atwell (satwell) wrote :

Oops, the repro instructions should say:

gcalctool --solve 'tanh 0.1'

Not gconftool.

Changed in gcalctool (Debian):
status: Unknown → Fix Released
Revision history for this message
Robert Roth (evfool) wrote :

Thank you for taking the time to report this bug. As this bug has been fixed, and the Oneiric version of gcalctool does return the correct result, I am marking this as Fix Released.

Changed in gcalctool (Ubuntu):
status: New → Fix Released
Revision history for this message
Steve Atwell (satwell) wrote :

The fix isn't in Lucid. Can you please SRU this for Lucid?

Revision history for this message
Sebastien Bacher (seb128) wrote :

We will SRU this as time permit which might be after UDS

Changed in gcalctool (Ubuntu Lucid):
importance: Undecided → High
status: New → Triaged
Changed in gcalctool (Ubuntu):
importance: Undecided → High
Revision history for this message
Sebastien Bacher (seb128) wrote :
Changed in gcalctool (Ubuntu Lucid):
status: Triaged → Fix Committed
description: updated
description: updated
Revision history for this message
Martin Pitt (pitti) wrote : Please test proposed package

Hello Steve, or anyone else affected,

Accepted gcalctool into lucid-proposed, the package will build now and be available in a few hours. Please test and give feedback here. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation how to enable and use -proposed. Thank you in advance!

tags: added: verification-needed
Revision history for this message
Steve Atwell (satwell) wrote :

5.30.0.is.5.28.2-0ubuntu3 fixes the tanh calculation for me. Thanks!

tags: added: verification-done
removed: verification-needed
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package gcalctool - 5.30.0.is.5.28.2-0ubuntu3

---------------
gcalctool (5.30.0.is.5.28.2-0ubuntu3) lucid-proposed; urgency=low

  * 03_correct_tanh.patch: git patch to fix tanh calculation (lp: #871988)
 -- Sebastien Bacher <email address hidden> Tue, 15 Nov 2011 18:36:47 +0100

Changed in gcalctool (Ubuntu Lucid):
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.