Post Reply 
@Thomas Klemm -> CORDIC Article
06-04-2014, 06:21 PM
Post: #25
RE: @Thomas Klemm -> CORDIC Article
(06-04-2014 06:06 PM)pito Wrote:  
Quote:I recently implemented from scratch all the transcendental functions using CORDIC
On which hw platform your implementation runs (cpu)?

Right now it's running on x86 (actually amd64).
(06-04-2014 06:06 PM)pito Wrote:  
Quote:But how do we know right from wrong?
The 9 degree test:
The windows calculator (most probably decNumber lib 34+) gives you 9.0
Wolfram's alfa online gives you 9.0

That's my point, it's hard to find the right result. Obviously the 9.0 is incorrect if we accept that rounding is a fact.
What I did to check:
I got all my partial results at 34 digits precision on the stack, for each operation.
Then I set the precision to 9 digits more.
Then I picked each partial result and applied the operation (sin, cos, etc), and compared the result with higher precision to the rounded one to verify correct rounding (so I took a previous result, rounded to 34 digits, and used it as argument to a function with 43 digits). newRPL did the correct rounding every time. I found also that doing * PI / 180 is not the same as / 180 * PI (difference of 1 in the last digit).
So I guess the "correct" answer will also depend on the order of the operations.
I also tried preccalc (from sourceforge), which uses adaptive precision and also gives the useless 9.0.

Claudio
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
@Thomas Klemm -> CORDIC Article - Tugdual - 05-31-2014, 08:00 PM
RE: @Thomas Klemm -> CORDIC Article - pito - 06-01-2014, 08:28 PM
RE: @Thomas Klemm -> CORDIC Article - pito - 06-02-2014, 10:13 PM
RE: @Thomas Klemm -> CORDIC Article - pito - 06-02-2014, 10:58 PM
RE: @Thomas Klemm -> CORDIC Article - pito - 06-02-2014, 11:05 PM
RE: @Thomas Klemm -> CORDIC Article - pito - 06-02-2014, 11:20 PM
RE: @Thomas Klemm -> CORDIC Article - pito - 06-03-2014, 02:02 PM
RE: @Thomas Klemm -> CORDIC Article - pito - 06-04-2014, 02:52 PM
RE: @Thomas Klemm -> CORDIC Article - pito - 06-04-2014, 06:06 PM
RE: @Thomas Klemm -> CORDIC Article - Claudio L. - 06-04-2014 06:21 PM
RE: @Thomas Klemm -> CORDIC Article - pito - 06-04-2014, 06:30 PM
RE: @Thomas Klemm -> CORDIC Article - pito - 06-04-2014, 06:45 PM
RE: @Thomas Klemm -> CORDIC Article - pito - 06-04-2014, 07:16 PM
RE: @Thomas Klemm -> CORDIC Article - pito - 06-04-2014, 07:30 PM
RE: @Thomas Klemm -> CORDIC Article - pito - 06-04-2014, 07:51 PM
RE: @Thomas Klemm -> CORDIC Article - pito - 06-04-2014, 08:12 PM
RE: @Thomas Klemm -> CORDIC Article - pito - 06-04-2014, 08:34 PM
RE: @Thomas Klemm -> CORDIC Article - pito - 06-04-2014, 09:21 PM
RE: @Thomas Klemm -> CORDIC Article - pito - 06-04-2014, 09:33 PM
RE: @Thomas Klemm -> CORDIC Article - pito - 06-04-2014, 09:41 PM
RE: @Thomas Klemm -> CORDIC Article - pito - 06-04-2014, 09:50 PM
RE: @Thomas Klemm -> CORDIC Article - pito - 06-04-2014, 10:46 PM



User(s) browsing this thread: 5 Guest(s)