Post Reply 
Plus42 algebraic expressions update
02-26-2021, 09:10 AM
Post: #21
RE: Plus42 algebraic expressions update
Thanks Thomas, progressing well, and general comparisons are a nice addition too !
Maybe something should be done to access the parenthesis. On the 27S/17BII you have dedicated keys, but not on the 42S, so you have to dig several layers of alpha menu to find them - not so practical when you just want to close SIN(X !
I'm sure you'll also find a way to put INTEG in equations Wink

Cheers
Find all posts by this user
Quote this message in a reply
02-26-2021, 11:29 AM (This post was last modified: 02-26-2021 11:35 AM by Thomas Okken.)
Post: #22
RE: Plus42 algebraic expressions update
(02-26-2021 08:21 AM)SammysHP Wrote:  I would expect that the same resolution applies as for multiple identical labels. Still unclear whether equations or programs should get a higher priority...

I'd say programs. Optimize the most common use case.

(02-26-2021 09:01 AM)Werner Wrote:  
(02-26-2021 06:37 AM)Thomas Okken Wrote:  it includes the generalized comparison functions: X=? param, 0=? param, etc.
And the Y^X fix, and a new error code for RTNERR: 8 => Too Few Arguments... forgot to add that one when I added the big stack.
What is the Y^X fix? (EDIT ah of course the sign of complex zero, silly me)
and I hope the other functions make it into Free42 as well?

Yes.

(02-26-2021 09:10 AM)Vincent Weber Wrote:  Maybe something should be done to access the parenthesis. On the 27S/17BII you have dedicated keys, but not on the 42S, so you have to dig several layers of alpha menu to find them - not so practical when you just want to close SIN(X !
I'm sure you'll also find a way to put INTEG in equations Wink

Yes, the parentheses should be easier to reach. I could put them on [X⇄Y] and [+/-], or [Shift] [▲] and [Shift] [▼]... (Not [STO] and [RCL], I think those should insert L( and G(.)

And sure, I could make SOLVE and INTEG callable from equations... But I can already see the emails from users who are going to discover that SOLVE and INTEG don't nest!
Visit this user's website Find all posts by this user
Quote this message in a reply
02-26-2021, 11:31 AM
Post: #23
RE: Plus42 algebraic expressions update
Since we're on a new page, here's the download link again:

https://thomasokken.com/free42/download/test/
Visit this user's website Find all posts by this user
Quote this message in a reply
02-26-2021, 11:43 AM
Post: #24
RE: Plus42 algebraic expressions update
Thanks Thomas.
I thought INTEG and SOLVE did nest since the HP-34C ?

Cheers
Find all posts by this user
Quote this message in a reply
02-26-2021, 12:07 PM
Post: #25
RE: Plus42 algebraic expressions update
The 34C allows solve to call integrate (and the reverse) but not solve to call solve or integrate call integrate.

Pauli
Find all posts by this user
Quote this message in a reply
02-26-2021, 12:13 PM
Post: #26
RE: Plus42 algebraic expressions update
The HP-42S and Free42 do allow SOLVE and INTEG to call each other, but not themselves.
Visit this user's website Find all posts by this user
Quote this message in a reply
02-26-2021, 12:15 PM
Post: #27
RE: Plus42 algebraic expressions update
You can SOLVE an integral or INTEG a solved function; you can't nest INTEGs to calculate a double integral.
eg.
find a zero of the Bessel function

J0(x) = 1/PI * INT(0,PI,COS(x*SIN(t),t)

1.define the integrand
Code:
 LBL "J0i"
 RCL "T"
 SIN
 RCL* "X"
 COS
 END

2.define the function
Code:
 LBL "J0"
 MVAR "X"
 FC? 45
 STO "X"
 PGMINT "J0i"
 CLX
 STO "LLIM"
 PI
 STO "ULIM"
 5e-5
 STO "ACC"
 INTEG "T"
 PI
 /
 END

3.Invoke the interactive SOLVER, choose J0 etc.

Cheers, Werner

41CV†,42S,48GX,49G,DM42,DM41X,17BII,15CE,DM15L,12C,16CE
Find all posts by this user
Quote this message in a reply
02-26-2021, 12:30 PM
Post: #28
RE: Plus42 algebraic expressions update
Thanks, yes, that's what I had in mind. I thought by "nested" you also meant calling each other Smile

Cheers
Find all posts by this user
Quote this message in a reply
02-26-2021, 01:56 PM
Post: #29
RE: Plus42 algebraic expressions update
Question for people more familiar with the 17B/27S expressions:

Do the square brackets have any special meaning?

I would like to use [ and ] for list and array indexing, but also remain compatible with the original calculators as much as is reasonably possible.
Visit this user's website Find all posts by this user
Quote this message in a reply
02-26-2021, 02:24 PM (This post was last modified: 02-26-2021 03:31 PM by Vincent Weber.)
Post: #30
RE: Plus42 algebraic expressions update
AFAIK the square brackets are unused in the 27S/17BII solver. Everything follows the FUNCTION(param1:param2:...paramn) logic.

Cheers
Find all posts by this user
Quote this message in a reply
02-26-2021, 02:50 PM
Post: #31
RE: Plus42 algebraic expressions update
Great, thanks!
Visit this user's website Find all posts by this user
Quote this message in a reply
02-26-2021, 03:53 PM (This post was last modified: 02-26-2021 04:19 PM by Thomas Okken.)
Post: #32
RE: Plus42 algebraic expressions update
10:46 AM EST / 15:46 UTC -- Uploaded new builds
  • STO → L(
  • RCL → G(
  • X⇄Y → (
  • +/- → )
  • Shift X⇄Y → [
  • Shift +/- → ]
  • Support for direct command mapping (skins with function names mapped directly to keys)
  • Fixed a bug where the Windows version would create files with .f42 extension instead of .p42 when creating a new, empty state

I still have to add support for CATALOG, but apart from that, I think the equation editor is pretty much done.

Things I noticed and fixed after creating these builds:
  • Direct command mapping: for 1/X, Y^X, and X^2, insert INV(, ^, and SQ(, not the RPN function names
  • The : is pretty important so you shouldn't have to go into the ALPHA menu to type it; I put it on Shift ÷
Visit this user's website Find all posts by this user
Quote this message in a reply
02-26-2021, 05:43 PM
Post: #33
RE: Plus42 algebraic expressions update
One thing that may help: on this page you have all the solver functions from the 19B (the most complete set, with the highest number of financial functions):

http://www.finseth.com/hpdata/hp19b.php

Cheers
Find all posts by this user
Quote this message in a reply
02-26-2021, 09:28 PM
Post: #34
RE: Plus42 algebraic expressions update
4:25 PM EST / 21:25 UTC -- New builds, fixing incorrect encoding of the new comparison operators in raw files and in the state file, causing them to get mangled.
Also fixed handling of direct-mapped 1/X, Y^X, and X^2 in the equation editor (affects the DM42 skin, for example), and added mapping of : to Shift ÷.
Visit this user's website Find all posts by this user
Quote this message in a reply
02-26-2021, 09:34 PM
Post: #35
RE: Plus42 algebraic expressions update
Talking about top row functions, maybe it would be nice that the sigma sign translates not only into sigma sign, but add an opening parenthesis, as the sigma (sum) function always requires one to enter its parameters...
Find all posts by this user
Quote this message in a reply
02-26-2021, 11:31 PM
Post: #36
RE: Plus42 algebraic expressions update
(02-26-2021 05:43 PM)Vincent Weber Wrote:  One thing that may help: on this page you have all the solver functions from the 19B (the most complete set, with the highest number of financial functions):

http://www.finseth.com/hpdata/hp19b.php

Noted. Thanks!

(02-26-2021 09:34 PM)Vincent Weber Wrote:  Talking about top row functions, maybe it would be nice that the sigma sign translates not only into sigma sign, but add an opening parenthesis, as the sigma (sum) function always requires one to enter its parameters...

Indeed. Done!

I'm also adding a mapping from R/S to the equals sign.
Visit this user's website Find all posts by this user
Quote this message in a reply
02-27-2021, 12:11 PM
Post: #37
RE: Plus42 algebraic expressions update
Great !
Last thing may be a shortcut to IF(, as conditionals are important Smile

Cheers
Find all posts by this user
Quote this message in a reply
02-28-2021, 12:00 AM
Post: #38
RE: Plus42 algebraic expressions update
6:59 PM EST / 23:59 UTC -- New build, lots of small fixes having to do with menu behavior, and with skins with Direct Command Mapping.
Visit this user's website Find all posts by this user
Quote this message in a reply
02-28-2021, 03:52 AM
Post: #39
RE: Plus42 algebraic expressions update
(02-27-2021 12:11 PM)Vincent Weber Wrote:  Last thing may be a shortcut to IF(, as conditionals are important Smile

Noted! I'll put it on my list.

I think the equation editor is OK now, it's complete in terms of functionality and seems robust, apart from Copy & Paste and some error handling for low-memory situations. I'm starting on the equation parser tomorrow, that's when it starts to get interesting.

UPDATE 10:49 PM EST / 3:49 UTC -- Copy & Paste implemented in the equation editor.
Also, eliminated the 256-character string length limit in Paste.
Visit this user's website Find all posts by this user
Quote this message in a reply
02-28-2021, 08:49 AM
Post: #40
RE: Plus42 algebraic expressions update
Thanks Thomas ! This is going to be terrific, the best of 42S/41CX/27S features, without altering the 42S look and feel...

Just one funny thing, it is great to be able to access the catalog from the equation editor, but this is the old catalog, not the new one with extended functions organized in groups ? Why ?

Cheers
Find all posts by this user
Quote this message in a reply
Post Reply 




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