HP Forums

Full Version: newRPL - build 1255 released! [updated to 1282]
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30
I did some more thinking on list variants, I thought I'd share. Think of this as a speculative dream, not a list of demands. Smile

First, any list can be converted into "multiset" format. I'm not sure how this should be displayed, but mechanically it's basically two lists: One of elements, one of their multiplicities. ADDing two multiset lists would just add the multiplicities for elements they have in common. A new UNION command would instead take the MAX of the two multiplicities. INTERSECT (or some shorter name) would take their MIN instead. SSUB (set subtraction) would subtract the multiplicities, treating negative numbers as zero. (Naturally, a multiplicity of zero means being removed from the list.)

(I've actually coded a version of set subtraction for regular lists in oldRPL. It has all sorts of unexpected uses!)

There would be a command to split a multiset into two regular lists, one of elements and one of multiplicities. Also one to retrieve the multiplicity of a given element.

(Incidentally, if multisets exist, they would be the natural way for FACTORS to output.)

Sets would then just be multiset lists in which the multiplicities would be constrained to be at most one.

I think multisets are actually more useful than sets, though harder to get working. You can immediately convert a multiset into a set by setting all multiplicities to 1.

The question remains how multisets should respond to operations like '+' and '*'. I'm honestly not sure yet.
Aha, thoughts converging into something.
The dictionary-lists or lua tables would allow you to assign a multiplicity to a numeric key, so it's a good container for what you want to achieve with multi sets. From there it's just a matter of defining sets commands to do the operations. Not sure about using overloadable operators (to keep the tables generic), but specific commands would work (much like it works now for binary integers, BADD, BSUB, etc operating over an existing generic type).
Is there any easy way to retrieve a list of the numeric keys? I'm not familiar with Lua.
(02-19-2019 02:04 AM)The Shadow Wrote: [ -> ]Is there any easy way to retrieve a list of the numeric keys? I'm not familiar with Lua.

A bit off topic but yes, there's a function pairs() that iterates over all key/value pairs, and there's ipairs() that iterates over numeric keys only.
But I was talking about the object itself, not necessarily how Lua interacts with it. It's a generic container with key/value pairs, much like directories are in RPL, except the key can be any object, not just idents.
All ROMs were updated to 1177.

All crashes from 1171 should (hopefully) be fixed. Other glitches are still there, like the rule for sqrt(-3) wasn't fixed.
At least shouldn't crash, allowing people to test and experiment.

BTW, the ROM size is pushing 1002 kbytes, very close to the 1024 kbyte limit of the 39gs and 40g. After we reach the limit, some things will need to be trimmed down on those platforms unfortunately.
All ROMs updated to build 1180 (well, not all of them, just the ROMs but not the android version, for now).

* I fixed an infinite loop when using more than one expansive variables '.XX' in rules (I had the code in place to break the infinite loop, but the decision had the logic inverted... oh well, it's fixed now).
* Improved the rule set of AUTOSIMPLIFY to keep polynomials better.
* Changed the base assumption of variables to be "Finite real" or "Finite complex", depending on complex mode flag, when no attributes are explicitly given.

Should make a little more sense now (writing rules is hard).
Sounds great! Unfortunately I probably won't have time to test today, but I look forward to it!

By the way, what's the status of the rule conditions?
(03-03-2019 06:33 PM)The Shadow Wrote: [ -> ]Sounds great! Unfortunately I probably won't have time to test today, but I look forward to it!

By the way, what's the status of the rule conditions?

The status is "not yet implemented". I took a short break from this symbolic engine, it's getting boring after a while. So I'm developing my very own compression algorithm for no reason at all, and it won't be better than all the available algorithms, in fact it will compress less and be very slow, but fun to code and test. Like when food critics need to cleanse their palates before they keep working, I need a mind cleansing, then I'll be back at newRPL and its complexity.
(03-03-2019 07:00 PM)Claudio L. Wrote: [ -> ]
(03-03-2019 06:33 PM)The Shadow Wrote: [ -> ]Sounds great! Unfortunately I probably won't have time to test today, but I look forward to it!

By the way, what's the status of the rule conditions?

The status is "not yet implemented". I took a short break from this symbolic engine, it's getting boring after a while. So I'm developing my very own compression algorithm for no reason at all, and it won't be better than all the available algorithms, in fact it will compress less and be very slow, but fun to code and test. Like when food critics need to cleanse their palates before they keep working, I need a mind cleansing, then I'll be back at newRPL and its complexity.

Understood, have a good time! Do you want me to refrain from bringing up any issues I may find for the next few weeks?

I really appreciate all the work you've done on newRPL.
(03-03-2019 09:34 PM)The Shadow Wrote: [ -> ]Understood, have a good time! Do you want me to refrain from bringing up any issues I may find for the next few weeks?

Feel free to bring in new ideas, issues and discussions. It's the only part that makes it "not so boring", and seeing people interested pushes me to keep coming back to it. I wasn't going to have a CAS, for example, but once I got into how to implement the basic algebraic manipulation commands in the 50g, I had to implement a proper rules engine. It's all a "why not?", but when the code gets too complex it can drain your energy very quickly (and your spare time).
(03-05-2019 01:58 PM)Claudio L. Wrote: [ -> ]but when the code gets too complex it can drain your energy very quickly (and your spare time).

This should be one of the maxim that everyone doing a non trivial project (not paid) should know.
Just upgraded my 50g to the latest build. I had the most awful trouble with paperclips and fingers trying to get it to the initial boot menu. I did manage it eventually; I don't recall having this trouble before, perhaps I was lucky.

Is there a knack to it, or a timing window I'm not finding it easy to hit? Most of the time it just remained off, no matter how fast or slow I performed the sequence.
(03-23-2019 07:53 PM)cdmackay Wrote: [ -> ]Just upgraded my 50g to the latest build. I had the most awful trouble with paperclips and fingers trying to get it to the initial boot menu. I did manage it eventually; I don't recall having this trouble before, perhaps I was lucky.

Is there a knack to it, or a timing window I'm not finding it easy to hit? Most of the time it just remained off, no matter how fast or slow I performed the sequence.

The timing needs to be right. You can press and hold + and - with 2 fingers as you turn it over and use the paper clip. The screen will blank and wait for all keys to be released, giving you time to turn it over again, then do a quick release-and-press-again motion on those 2 fingers as quick as you can. I find this to be quite reliable.
Thanks Claudio; looks like my problem was simply that I wasn't pressing anywhere near hard enough with the paper-clip. Once I started pressing much harder, it now works every time.
(03-24-2019 03:57 PM)cdmackay Wrote: [ -> ]Thanks Claudio; looks like my problem was simply that I wasn't pressing anywhere near hard enough with the paper-clip. Once I started pressing much harder, it now works every time.

Also, paperclip isn't really necessary if all you want is to flash a ROM:
From the stock calculator, use On-D, then On-C to do a full reset and immediately press + and -.
From newRPL press On-A-F, then any Shift+F, immediately followed by + and -.
(03-25-2019 03:27 PM)Claudio L. Wrote: [ -> ]
(03-24-2019 03:57 PM)cdmackay Wrote: [ -> ]Thanks Claudio; looks like my problem was simply that I wasn't pressing anywhere near hard enough with the paper-clip. Once I started pressing much harder, it now works every time.

Also, paperclip isn't really necessary if all you want is to flash a ROM:
From the stock calculator, use On-D, then On-C to do a full reset and immediately press + and -.
From newRPL press On-A-F, then any Shift+F, immediately followed by + and -.

oh! yes of course, I'd forgotten about that; please considering adding that to the install section.

thanks again!
(03-25-2019 03:27 PM)Claudio L. Wrote: [ -> ]
(03-24-2019 03:57 PM)cdmackay Wrote: [ -> ]Thanks Claudio; looks like my problem was simply that I wasn't pressing anywhere near hard enough with the paper-clip. Once I started pressing much harder, it now works every time.

Also, paperclip isn't really necessary if all you want is to flash a ROM:
From the stock calculator, use On-D, then On-C to do a full reset and immediately press + and -.
From newRPL press On-A-F, then any Shift+F, immediately followed by + and -.

Huh, didn't know that one, thanks.
Claudio did you recover your 50g?
(03-28-2019 06:08 PM)pier4r Wrote: [ -> ]Claudio did you recover your 50g?

Not yet. I connected the JTAG interface, but it seems this FlashCatUSB doesn't have support for older ARM9 cores, it connects to the CPU but can't detect the flash ROM. I'm not ready to give up yet, especially seeing the prices of 50g's.
If I may suggest if you are patient and search on classifieds/ebay (also "search" announcements), you get the attention of people that do not know how valuable those things are (for us) and keep them in drawers.

The prices for my 4 50gs were:
the first in 2010: 100 euro (refurbished from the US)
2017: 47 Euro , classified from Germany.
2018: 43 Euro, classified from Germany
2018: 40 Euro, classified from Germany

One has to be patient and make his wish visible (again, "search" announcements).
Pages: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30
Reference URL's