timmerk / hpcalc-iphone

Automatically exported from code.google.com/p/hpcalc-iphone
GNU General Public License v2.0
0 stars 0 forks source link

Functions sine and cosine produce wrong values with argument "pi" #81

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. "g" "EEX" (should return the number "pi")
2. "SIN" or "COS"
3.

What is the expected output? What do you see instead?

   Expected output is "0.00" for "SIN" and "1.00" for "COS"

   Returned instead:  "0.0548" for "SIN" and "0.9985" for "COS"

What version of the product are you using? On what operating system?

  Vicinno Soft LLC version 1.5 running on IPad model MC497LL with latest Apple software (5.0.1)

Please provide any additional information below.

Original issue reported on code.google.com by goetzk...@gmail.com on 26 Dec 2011 at 3:54

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
All this is normal!

First, expected output are 0.00 (or something very small such as 10^-9) for SIN 
and -1.00 for COS.
Second, these outputs should be obtained when the angles are fed-in in 
'radians' (this can be specified by pressing [g] and then [8]). By default 
angles are in degrees, therefore [g][EEX][COS] should give Cos(Pi * (Pi/180)) 
which value is about... 0.9985 and  [g][EEX][SIN] should give Sin(Pi * 
(Pi/180)) ~ 0.0548...

Original comment by gaetan.m...@gmail.com on 19 Feb 2012 at 3:19