DB48X: HP48-like RPL implementation for DM42
|
Yesterday, 05:07 PM
(This post was last modified: Yesterday 05:08 PM by n1msr.)
Post: #496
|
|||
|
|||
RE: DB48X: HP48-like RPL implementation for DM42
This post is only by way of discussion. Not complaining, but just interested :-)
In experimenting with RPL programs written for the HP-50g, I came across what looks like a difference between the DB48X and HP-50g. I have looked through some of the documentation for both calculators but haven't found an explicit description to explain the difference. This has come about partly because not all HP-50g functions have been implemented on the DB48X yet - in this case the Real to Integer (R->I), which was used by several entries in the 2011 HHC programming contest. It becomes important when the Comb[inations] function is used, because: On the DB48X, it seems that the two parameters, n & r (for nCr) have to be Real Integers (type 28 objects). The result is a Real Integer. The HP-50g doesn't seem to care. You can use Real Integers (Type 28), Real Numbers (Type 0) or mix them. If either input is a Real Number, the result will be a Real Number. If both inputs are Real Integers, the result is a Real Integer. Until R->I is implemented on the DB48X, I was going to resort to using only Real Numbers is these programs, except that Comb[inations] won't use Real Numbers. I could of course do the nCr calculation using factorial (x!), where nCr = n! / (r! * (n-r)!). The DB48X factorial function will take both Real Integers and Real Numbers :-) I did wonder if there is a setting I could make in the DB48X calculator to change the way the functions behave, i.e. accept Real Numbers as well as, or instead of Real Integers? |
|||
« Next Oldest | Next Newest »
|
User(s) browsing this thread: 4 Guest(s)