iPhone’s Calculator Pi Button Issues
by Jody Mitoma on August 27, 2008 at 4:03 am

A small warning to those whom are using the iPhone’s (or iPod Touch for that matter) calculator for schooling and such. Do not put full trust on the scientific calculator app, especially when it comes to using the calculator’s pi (3.14159..) button.
A TUAW reader recently tipped about the issue, showing that when you type π × 2 + 5 = into the calculator you get 11.283… (the correct answer). However, when you reverse the pi and 2, entering 2 × π + 5, the answer given is 7.
What’s odd about this is that if you enter in pi manually (which is 3.1415926..), instead of simply hitting the pi button, you will get the correct answer for the two equations above, either way.
Have a read about the bug here.
(via TUAW)








Posted in 

















August 27th, 2008 at 9:02 am
Pi R
SquaredRound!Programmatically, I can’t even imagine how that bug would happen. It isn’t like routines evaluating BEDMAS are new, so how the hell do you screw that up? Based on the above, it’s somehow completely cutting out the middle of the equation when Pi is the right-hand factor, evaluating just 2+5, but not when it’s on the left, which makes it even more confusing because the rules of BEDMAS don’t change based on which factors are on either side of the infix unless one or both are part of separate equations evaluated on a higher priority.
Weird.
August 27th, 2008 at 3:09 pm
it seems that the iPod calc igonres the pi in such a situation, but trying this works 2X(pi)+5=11.283….. by using () it knows that the pi is part of the
August 27th, 2008 at 3:11 pm
… Ecuation.
August 27th, 2008 at 3:14 pm
or I just found out that u do this first!… 2Xpi press = u get the awnser than add up the 5… Could try (2Xpi)+5=11.28
August 27th, 2008 at 4:10 pm
yeah this is weird :-s
how is this possible… I guess pi is not treated as a number like it should. Instead the programmers assigned a pecial value to it or something :-s