HP49-50G : Matrix & Strings
|
09-28-2022, 04:58 AM
Post: #2
|
|||
|
|||
RE: HP49-50G : Matrix & Strings
(09-27-2022 11:18 PM)Gil Wrote: ...Because when executing now This is an unintended consequence of how different parts of the calculator's firmware construct symbolic objects containing negative integers. Consider that there are multiple ways for the simple rational -1/7 to be represented internally on the 50g. Here are two of them: SYMBOL ZINT -1 ZINT 7 x/ ; and SYMBOL Z1_ xNEG Z7_ x/ ; These look the same on the stack, but the bit patterns are different between them, so SAME being executed on those two would result in 0. In your specific example, converting the symbolic rational to a string, then performing OBJ-> to compile the string back into a symbolic, you start out with something like the former and end up with something like the latter. This problem is not limited to SAME. Even replacing SAME with == won't get around this. Note that I'm not trying to justify this, just to show what's happening. |
|||
« Next Oldest | Next Newest »
|
Messages In This Thread |
HP49-50G : Matrix & Strings - Gil - 09-27-2022, 11:18 PM
RE: HP49-50G : Matrix & Strings - DavidM - 09-28-2022 04:58 AM
RE: HP49-50G : Matrix & Strings - Gil - 09-28-2022, 07:27 AM
RE: HP49-50G : Matrix & Strings - DavidM - 09-28-2022, 03:28 PM
RE: HP49-50G : Matrix & Strings - Gil - 09-28-2022, 09:56 PM
RE: HP49-50G : Matrix & Strings - DavidM - 09-28-2022, 10:35 PM
|
User(s) browsing this thread: 1 Guest(s)