CORDIC in Degrees vs. Radians



#3

On a Voyager (15C) in degrees mode, cos 60 = 0.5. The same is true for a Pioneer (20S).

If, instead, this is performed in radians mode, first converting 60 degrees to radians using ->RAD, this results in

15C: 0.5000000002
20S: 0.499999999997

My question: How do these machines produce exactly the right answer when in degrees mode?

Is CORDIC internally performed always either degrees or radians (with the necessary conversions of input being done first)? Or is it internally performed using the mode that the calculator is set to?


#4

HP calculators round the answer to the number of digits of the display. Thus, on the 32SII 60 -> RAD returns 1.04719755120, a worst approximation to pi/3 than 1.04719755119660 which would be used internally when in DEG mode. In RAD mode the internal results are

   cos(1.04719755120 rad) = 0.499999999997054
cos(1.04719755119660 rad) = 0.499999999999998
or
0.499999999997
0.500000000000
respectively, when rounded to 12 digits.

Gerson.


#5

Is the following accurate?

When in degrees mode, the 15C internally converts the input to a radians representation that employs guard digits (in other words, a representation with more than 10 digits), which is then passed to the CORDIC routine. The (greater than 10-digit) output of CORDIC is then rounded to the 10 digits of the display.


#6

Yes, I think things occur like that. These past threads might be of interest to you:

http://www.hpmuseum.org/cgi-sys/cgiwrap/hpmuseum/archv016.cgi?read=103151

http://www.hpmuseum.org/cgi-sys/cgiwrap/hpmuseum/archv016.cgi?read=103356

http://www.hpmuseum.org/cgi-sys/cgiwrap/hpmuseum/archv014.cgi?read=62301

Edited: 23 July 2011, 2:37 p.m.


#7

Yep, post #16 in the first thread you referenced indicated the following with respect to trig in degree mode on the 15C:

Quote:
For example, the HP41, HP15, etc., are known to do internal arithmetic with 13 digits although final results are only 10 digits. That is, a 13 digit approximation to PI/180 is used to convert the argument from degrees to radians.

Thanks :)

#8

It is possible to do CORDIC operations in degrees, grads, or other angular units, but generally HP calculators don't do that. They internally convert to radians. As Gerson has noted, they use extra digits in internal calculations to get a more accurate result than if you did the conversion from the keyboard.

I say "generally" because I have no idea how models like the 6s, 8s, 9s, 9g, and 30s work internally.


Possibly Related Threads…
Thread Author Replies Views Last Post
  CORDIC Sok-khieng Chum Hun 3 1,375 04-28-2012, 08:33 PM
Last Post: Eric Smith
  HP-35A/21 D.MS<-->Decimal degrees routines Matt Agajanian 9 2,998 03-29-2012, 11:03 AM
Last Post: Matt Agajanian
  Degrees conversion for trigonometric function Beth Snipes 2 1,131 08-30-2011, 03:32 PM
Last Post: Beth Snipes
  CORDIC Trigonometric Algorithm on an HP17BII Charles 4 1,559 03-14-2008, 12:14 AM
Last Post: Eric Smith
  HP-35 and CORDIC-articles at Dr. Dobb's Karl-Ludwig Butte 2 1,169 11-25-2007, 04:11 AM
Last Post: Karl Schneider
  Radians Question Vincze 55 10,571 08-20-2007, 08:56 AM
Last Post: Vincze
  Angles in radians using expressions with PI?? Alex 3 1,372 03-18-2007, 02:09 AM
Last Post: Alex
  HP33S bug subtracting degrees from minutes? John P 2 1,014 03-18-2005, 12:35 PM
Last Post: Norris
  Sin(Pi) in Radians Mike 33 6,975 08-29-2004, 02:58 PM
Last Post: Eddie Shore
  HP 41C - Converting From Radians to Degrees Mark McLean 14 3,161 04-28-2004, 10:45 PM
Last Post: David Smith

Forum Jump: