Post Reply 
newRPL: Alpha demo 0.9 released [UPDATED 2017-10-25]
08-22-2017, 04:37 PM (This post was last modified: 08-23-2017 02:49 PM by The Shadow.)
Post: #48
RE: newRPL: Alpha demo 0.9 released [UPDATED 2017-08-11]
(08-20-2017 03:22 AM)Claudio L. Wrote:  I see. ->Q uses a simple algorithm of invert and take the fractional part.

That's the traditional way to do it, but you can get a significant speed-up with no loss of accuracy by rounding instead. Instead of FP, you do:

<< DUP 0 RND - >>

Basically, this groups together strings of 1's, saving many iterations. (The continued fraction of the golden ratio becomes { 2 -3 3 -3 3 -3...} )

There are some rare cases where this will be a bit slower - sqrt(2) is an example - because they don't have any 1's. But I find that a more than acceptable trade-off.

Do be aware that you can end up with both numerator and denominator negative with this method, but that's easy to fix at the end.

-----------

After doing a LOT of programming, I have found some oddities about typing:

Alpha mode seems to disable custom keys. I can't think of any good reason why this should be true.

Entering quotes automatically switches to alpha mode. This is no doubt intended to help, but it catches me off-guard every single time.

When you hold down alpha to enter some letters, the calc will not recognize left or right shift. So for example, you can't type a -> without releasing alpha, which is quite annoying, especially since I frequently name programs with an arrow in the middle.

-----------

Thank you from the bottom of my heart for SDARCHIVE and SDRESTORE. They've already saved me a good deal of grief.

Can I throw in a request for VISIT? I love it to pieces.
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
RE: newRPL: Alpha demo 0.9 released [UPDATED 2017-08-11] - The Shadow - 08-22-2017 04:37 PM



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