GithubHelp home page GithubHelp logo

Comments (50)

boricj avatar boricj commented on May 27, 2024 14

I got bored and made an RPN app for the NumWorks. It's quite basic and a bit rough around the edges for now, but it's a real native third-party app. I need fans of RPN to check it out to see if it actually works properly in real life.

I also need to gauge interest for this. I've spent my entire Saturday afternoon and evening into this PoC and I want to know if there's a real interest for this before I continue.

https://github.com/boricj/numworks-rpn

from epsilon.

boricj avatar boricj commented on May 27, 2024 12

It doesn't need to be RPN-aware everywhere. I think most people yearning for RPN would be perfectly happy with just a RPN toggle setting that affects only the Calculation app.

from epsilon.

garycmartin avatar garycmartin commented on May 27, 2024 6

Not sure if there's progress on any official support, but here's a python RPN script I've been tinkering with over the last few days.

https://workshop.numworks.com/python/garycmartin/rpn

Not exactly an integrated or robust solution, but nice to use python to experiment with some RPN calculations. There's plenty more that could be added but trying to keep an eye on memory... V0.3 supports pi, e, rnd, !, *, +, -, /, acos, asin, atan, cos, deg, log, log10, pow, rad, recip, sin, sqr, sqrt and tan. Type ? for a list of operators, clr to clear the stack, swap to swap the two most recent stack items, roll to roll the stack, drop to drop the last stack item, and q to quit.

Example:

> 3 sqr 4 sqr + 5 sqr - 2 3 * 4 * / acos deg
[90.0]
> 4 sqr 5 sqr + 3 sqr - 2 4 * 5 * / acos deg
[90.0, 36.86989764584401]
> 5 sqr 3 sqr + 4 sqr - 2 5 * 3 * / acos deg
[90.0, 36.86989764584401, 53.13010235415599]
> +
[90.0, 90.0]
> +
[180.0]

from epsilon.

boricj avatar boricj commented on May 27, 2024 6

I've updated the RPN app. I've modified the stack handling to be closer to old HP calculators (or at least as much as I could recall) and made numerous other improvements. It's still bare-bones, but it's actually usable now.

from epsilon.

ch-nry avatar ch-nry commented on May 27, 2024 5

+1 : RPN is the only way I use calculators!

from epsilon.

boricj avatar boricj commented on May 27, 2024 5

I've cleaned up the app a bit, implemented stack scrolling/picking and bumped the stack size to 16 elements. The RPN app actually feels like a proper NumWorks app and while there's still things left to be implemented it should be good enough for everyday usage.

@Ecco Please consider closing this issue, as unless people want the RPN app built-in this issue has been fixed. Everyone else, I'd suggest you add yourself as a watcher of my repo if you want to keep track of improvements. Until there's a better place to discuss about the app, we should probably keep discussing it here.

from epsilon.

akoun avatar akoun commented on May 27, 2024 4

thanks for this.
RPN really means "parenthesis free notation" and should be a default in any serious calculator...

  • from a usability standpoint the number of keystrokes is greatly diminished
  • errors in complicated expressions are harder to make
  • learning curve about 10 minutes.

Such calculators are usually intended for probably smart people to who the calculator is a tool so I guess that is why after trying RPN for 10 min there is no going back :)

from epsilon.

bwaels avatar bwaels commented on May 27, 2024 2

tribute to HP calculators . The yellow keys ae a reference yet

from epsilon.

boricj avatar boricj commented on May 27, 2024 2

As a heads-up, the RPN app was fixed on master thanks to @qguv. I've left a precompiled ROM on TI-Planet (https://tiplanet.org/forum/viewtopic.php?f=102&t=21808&p=236212#p236212) with the latest epsilon master if you want to try it out.

from epsilon.

mchobby avatar mchobby commented on May 27, 2024 1

I still use my HP48Gx with RPN (in Belgium).
I cannot imagine use something else than RPN... it is so efficient.

from epsilon.

Ecco avatar Ecco commented on May 27, 2024 1

We're all in favor of adding RPN (even though, let's be honest, it quite doesn't appeal to newcomers). That being said, the problem is that RPN is stack-based, and we couldn't figure out how to get it to play well with the rest of the user interface.

Question to the RPN gurus out there: how would you fit an RPN entry mode in, say, the "Functions" app?

from epsilon.

ch-nry avatar ch-nry commented on May 27, 2024 1

Having a RPN_calculation app is fine for me.

To control the stack, you need ENTER, SWAP, DUP, DROP, and PICK.
PASTE and CLEAR can be used for DUP and DROP.
EXE for ENTER, arrow (to go on the stack) and ENTER for PICK, and a parenthesis for SWAP. You can even use the other parenthesis for OVER. (i.e: dup argument 2)

from epsilon.

Ecco avatar Ecco commented on May 27, 2024 1

Well an RPN app could definitely leverage the clipboard (copy and paste) to interact with other apps. That being said, I'm still not very happy with the idea of having a separate app just for entering expressions.

from epsilon.

adriweb avatar adriweb commented on May 27, 2024 1

Wouldn't it be possible for the NumWorks team to merge your app but not build it by default?

from epsilon.

fabuffet avatar fabuffet commented on May 27, 2024

Rpn seams so natural and logical once you have understood how it works. I find it hard to use something else now.

from epsilon.

fabuffet avatar fabuffet commented on May 27, 2024

I'm still using it too. The numworks with rpn would be a real treat.

from epsilon.

AshleyF avatar AshleyF commented on May 27, 2024

+1 RPN is a must

from epsilon.

AshleyF avatar AshleyF commented on May 27, 2024

Agree. I'd be thrilled to see it in the Calculation app alone.

For the Functions app, technically, a "function" would be a "truncated" stack expression with missing parameters or perhaps with an initial x in place.

Example f(x) = x * x would be f(x) = dup * or maybe f(x) = x dup *
Example g(x) = 1 / x would be g(x) = 1 swap / or maybe g(x) = x 1 swap /

Note that x is always to the far left (or truncated). Swaps rots and dups are required to reorder or reference multiple times.

Not sure which keys would become dup, swap, etc. Parenthesis are not needed, so maybe overloaded? HP-35 got by with just x↔y (swap), R↓ (rot) and ENTER to dup.

from epsilon.

Ecco avatar Ecco commented on May 27, 2024

Having a RPN_calculation app is fine for me.

I'd be thrilled to see it in the Calculation app alone.

I guess an easy solution would indeed be to add a new, RPN-only calculation app. It wouldn't feel very well integrated though.

from epsilon.

UDXS avatar UDXS commented on May 27, 2024

Could it be possible to have an RPN app that is able to convert the expressions back to normal for use in functions and others automatically. Like an "Export Expression" button so that there is some level of integration.

from epsilon.

UDXS avatar UDXS commented on May 27, 2024

Clipboard would be a good idea. It wouldn't be just for entering expressions. It would be like the Calculation app. Otherwise, I think it's a good compromise for something that won't be used very much.

from epsilon.

boricj avatar boricj commented on May 27, 2024

I think the kind of people that truly want a real graphical RPN calculator would rather use a HP 48/49/50 oldie than a NumWorks calculator. My father used a HP 15C until recently when he switched to the HP 35S and I swear he'd still use his HP 35 if it still worked. He just loves RPN and HP calculator keyboards that much.

@Ecco The NumWorks hardware and software is just not targeted at people demanding HP-grade calculators, so I would not worry too much about deeply integrating RPN into the calculator for the time being. Let's do a RPN calculation app first (even if just a third-party one) and see if people asking for RPN are happy with it. We can always figure out something better later on if enough people want more.

from epsilon.

UDXS avatar UDXS commented on May 27, 2024

You could try making an emulator for the older calculators. It'd be interesting.

from epsilon.

boricj avatar boricj commented on May 27, 2024

@UDXS Those already exist (Free42, newRPL) and they have ports to either original or look-alike HP calculators. One certainly could port them to the NumWorks calculator (beware though, Free42 is licensed under the GPL so we can't mix in epsilon's code for porting).

from epsilon.

0b101 avatar 0b101 commented on May 27, 2024

What about an option in settings that changes the way the Calculation app behaves (Algebraic vs RPN)? It would decrease the amount of storage needed to implement RPN.

from epsilon.

wawachief avatar wawachief commented on May 27, 2024

@boricj, you are a genius. Please, get bored more often :)
I tried your proof of concept and it looks very promising. I installed the rpn app among the other apps so I can still use my numworks as usal while testing your rpn app. To do that, I edited the file build/config.mak and added rpn to the EPSILON_APPS definition. Maybe this could be added to the readme ?

img_0265
img_0266

I found a problem using the rpn app : when the stack is full (more than 5 elements), I can't input more numbers, the EXE key is no longer working. Bay the way, is it RPN or RPL ? hp42 or HP48 like ?

Thank you for this initiative !

from epsilon.

boricj avatar boricj commented on May 27, 2024

@wawachief You don't need to modify config.mk to add apps, just redefine EPSILON_APPS on the command line as shown on the README. Do a make info to see a list of useful variables you can override. For the stack, it's limited to 5 elements because more would not fit on the screen and I haven't implemented scrolling yet. The limit can be increased once this is fixed, but gracefully handling a full stack has a couple of nasty issues.

The app is just an immediate RPN frontend for poincare and it is not programmable (nor can poincare express programs in its current form). But there's a lot of room for improvement nevertheless since most poincare features aren't accessible yet within this app.

from epsilon.

wawachief avatar wawachief commented on May 27, 2024

Thank you @boricj for your answer. I've seen the EPSILON_APPS= option in your README file, but as it is, you only have RPN and settings on the calculator, which is quite disturbing when you first look at your calculator after flashing the firmware. Maybe, adding to the readme a complete set of apps into the EPSILON_APPS option would be easier for those who would like to test the rpn app among the other apps.

5 elements in the stack is more than enough. 4 (XYZT) would be fine, and would not require any scrolling. For the stack display, I am used to see the X register on the bottom of the screen.

I've noticed that The e^x key returns e and does not compute the exponential of the X register.
I've noticed too that the log key computes the Y base logarithm of X and not the decimal logarithm. Now that I know it, it is not a problem.
I searched for the +/- key but didn't find it. Is it implemented yet ?

from epsilon.

boricj avatar boricj commented on May 27, 2024

I'll amend the README next time I'll work on this. The whole third-party app mechanism needs to be properly documented, but sadly NumWorks's technical documentation does not explain this and https://en.wikibooks.org/wiki/Unofficial_Guide_To_Expanding_Your_Numworks is thoroughly obsolete...

The handled keys are currently raw mappings to single poincare primitives, which explain most idiosyncrasies you've encountered (and the fact that there's no toolbox for now). The +/- key is not implemented yet, I guess I should map it to ,. As you've noticed, there's a lot of room for improvements.

from epsilon.

wawachief avatar wawachief commented on May 27, 2024

Thank you ! This update makes the rpn app totally usable. I will use it as my default calc app on the numworks :)

from epsilon.

JensGrabner avatar JensGrabner commented on May 27, 2024

From this one givs a emulator writen in the Programming Language Paskal.
The calculator here: http://mk.semico.ru/vid161.htm
The Emulator here: https://sourceforge.net/projects/emkatic/
Is this possible for this Hardware ?

from epsilon.

boricj avatar boricj commented on May 27, 2024

@JensGrabner I'm having a hard time finding information about the MK-161 in a language I can understand, but from what I gathered a custom firmware could reimplement it on the NumWorks calculator with room to spare. The emulator is extremely Windows-specific and can't be ported though. Please note that I only intend to create an immediate RPN frontend for poincare with my app, so extending the feature set or emulating other calculators is out of the scope of this particular issue.

from epsilon.

JensGrabner avatar JensGrabner commented on May 27, 2024

Thanks -- i think, it is the same with this project - https://commerce.hpcalc.org/34s.php

from epsilon.

boricj avatar boricj commented on May 27, 2024

@adriweb It's possible, but that would hinder development since the NumWorks team would need to review and merge all future commits instead of me directly pushing on my own repo. Unless they want to integrate and maintain it in the official firmware, it probably won't happen.

from epsilon.

adriweb avatar adriweb commented on May 27, 2024

Well yes, I was thinking that it would/could eventually be mainlined.
Another "solution" would be a submodule - and the NW team would update it from time to time when they are happy with the state at a certain time.

from epsilon.

boricj avatar boricj commented on May 27, 2024

Submodules would make sense only if NumWorks add custom firmware creation to the workshop, with submodules acting as a curated set of apps to pick from. Submodules are notoriously difficult for Git newbies to grok, let's not complicate things unless we need to.

from epsilon.

ch-nry avatar ch-nry commented on May 27, 2024

thanks boricj for this work,
I'm overbuzzy for the moment, but 'ill buy a numworks calculator as soon as possible to test this app.
I'll report on your github if I have problem.

from epsilon.

augustz avatar augustz commented on May 27, 2024

I’ll also be buying a calculator to give this a shot

from epsilon.

ch-nry avatar ch-nry commented on May 27, 2024

Thanks for this binary.
I just received my calculator and I made the automatic update (I had to install chromium on my computer, I'm not glad about that). Anyway, the update did not ask for a specific file. So I don't know how to use this ROM. I tried to install the SDK, but it is only available for windows or osX (I'm on linux). What should I do now?
Please forgive me and point me to the right place if this is not the best place to ask for help.

from epsilon.

boricj avatar boricj commented on May 27, 2024

The automatic update from NumWorks will only install the latest official stable version. To flash a specific ROM file, the easiest way is to use https://devanlai.github.io/webdfu/dfu-util/. Plug in the calculator to the computer with a USB cable and push the reset button through the pinhole on the back to enter recovery, which is effectively unbrickable by design.

The SDK can easily be installed on Linux and I actually use Linux when developing for the NumWorks calculator. The SDK manual installation instructions is tailored for Debian (https://www.numworks.com/resources/engineering/software/sdk/other/), but other distributions should work as long as they are recent and can provide the dependencies.

On the matter of places to ask for help, while I don't have an account on Reddit the main NumWorks forum is at https://www.reddit.com/r/numworks/. There's also TI-Planet, where I left the ROM, which does accept English posts alongside the French language and is where most major community projects are announced or covered, like zardam's NES emulator port, my HP Prime port of epsilon or my turtle module implementation for Python.

from epsilon.

ch-nry avatar ch-nry commented on May 27, 2024

Thanks for all this informations,
Installing the ROM when without any problem.

I read the SDK installing page to fast and did not spot the linux instruction (I read "virtual OS" instead of "virtually any operating system"), thanks for pointing it. I can now compile the ROM.

So, I tested the RPN app. It is very nice. I will use it as my default calculator. However I have few comment and propositions.

  • duplicating a "undef" crash the app and reboot the calculator.
  • the ! is not an operator : it is possible to type 3!, but not 3 EXE and then ! EXE
  • there is no "nth root" function
  • there is no UNDO function
  • the x10^x key should be use as an operator when the prompt is empty (as 10^X)
  • I would prefer having the -X function on shift -, better than alpha -
  • I miss the 1/X function, can it be add to the shift / (or alpha /)
  • Rot N can be usefull (N being the last value in the stack)

So a key mapping proposition :
EXE : dup
shift EXE : over
Ans : undo
) : swap
( : rot
shift ( : rot N
shift - : -X
shift % : 1/x
shift . : nth root

When editing the stack (using the UP/Down arrow), EXE is used as PICK : it's a great feature. can the DROP be also implemented? (to remove any element in the stack)

When switching the calculator off and on again in the RPN app, the display is a bit corrupted (on the top if the stack is empty, and near the cursor)

Anyway, thanks a lot for this app, I'll use it a lot.

from epsilon.

boricj avatar boricj commented on May 27, 2024

The current architecture of the RPN app has a couple of issues I need to sort out before making improvements to it (the latest fixes to get it running on master are especially nasty workarounds). Most notably, I must write a RPN parser (while reusing the existing poincare lexer) and a RPN serializer to really take this to the next level.

from epsilon.

ch-nry avatar ch-nry commented on May 27, 2024

This look like a huge work. I hope it is still on your todo list.
thanks

from epsilon.

boricj avatar boricj commented on May 27, 2024

After thinking about it, I'm postponing writing a RPN parse/serializer for now since I managed to get away with a code cleanup that leaves things in a not too shabby state.

I've pushed an update that takes advantage of exact computations, but I'm worried that performance is going to take a hit with heavy-duty expressions (especially those involving inverse trigonometrics). Switching between exact and approximate modes is done with '=' (shift+pi). Similarly, I've reduced the stack size to 8 elements, just in case the added memory consumption in a worst-case scenario pushes the calculator over the edge.

from epsilon.

ch-nry avatar ch-nry commented on May 27, 2024

This look great on the simulator. (the app did not crash anymore)
but I don't find the rom file when i make with : make EPSILON_APPS='rpn graph code statistics probability solver calculation sequence regression settings'
where should it be?

from epsilon.

boricj avatar boricj commented on May 27, 2024

The default make target will build epsilon.elf or (epsilon.exe if you're under Windows). You need to explicitly ask for epsilon.bin while invoking make if you want the firmware binary, but you might as well call make epsilon_flash to upload it to your calculator.

from epsilon.

ch-nry avatar ch-nry commented on May 27, 2024

thanks, it's working.
(this info is missing in the readme file.)

from epsilon.

shaunsingh avatar shaunsingh commented on May 27, 2024

I would definitely love an RPN app built into epsilon itself, but saying that it should be default is a stretch. This is a calculator made for high school and college education, the target demographic is likely working with algebra, basic calculus, geometry, etc. In those cases, "textbook" (algebraic) notation is far easier (and in some cases quicker) to use and follow

Disclaimer: I have both a DM42 and a numworks n0110, both of which I use. On the numworks for simple calculations I prefer the RPN app, for others I prefer the KhiCas app.

https://www.youtube.com/watch?v=VyQpylN0FiE&lc=UgzfS07r5hBubkK1dFR4AaABAg.9U61hK3A4Ws9U7w2We3gtd

Many of the examples in the video I can solve much faster on my Numworks using KhiCas.

There are instances where RPN is much faster. However, most of the time what are students doing? Writing down equations, plotting them, solving for x, etc. The numworks handles this well, you can input and graph functions in one app, solve them in another, and calculate in another app.

errors in complicated expressions are harder to make

This was the case when calculators couldn't process PEMDAS ootb. Nowadays, its as simple as copying what's on the paper into your calculator, not having to insert parenthesis may be faster, but I'm not sure how it's harder to make errors.

I do like using RPN when it makes sense, but by no means should it be default nor is it a tool for only "smart people" (in my opinion).

from epsilon.

nozense avatar nozense commented on May 27, 2024

Is this anywhere in the pipeline for the official os/firmware?
Not having rpn is the only reason I'm considering an alternative firmware.

from epsilon.

raparici avatar raparici commented on May 27, 2024

A 5 stack official app would be amazing for those who are used with RPN (or are willing to try). The former rpn app is not compiling anymore along the current firmware.

from epsilon.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.