Post Reply 
FORTH for the SHARP PC-E500 (S)
11-22-2021, 05:42 PM
Post: #57
RE: FORTH for the SHARP PC-E500 (S)
Happy to announce an update Smile

Forth500 with complex arithmetic

Forth500 GitHub repo

This addition is based on the excellent Forth complex math library complex.fs which is "a revision of Julian V. Noble's complex arithmetic lexicon, with OpenMath principal expressions for inverse functions." The COMPLEX.FTH addition is located in the "additions" folder of the project.

Complex arithmetic is supported in single and 20 digit double precision. The COMPLEX.FTH source code file is 25K with all comments included, but compiles down to 3.2K.

The original complex.fs file loaded in Forth500 after making some minor adjustments in COMPLEX.FTH:
- removed the ENVIRONMENT? query "FLOATING-EXT" which is obsolescent. Forth500 supports FLOATING and FLOATING-EXT with FLOATEXT.FTH loaded. So I included FLOATEXT.FTH in COMPLEX.FTH.
- removed the 2*pi and pi/2 constants and changed the code slightly to support both DEG and RAD modes for polar coordinates.
- simplified fsignbit, because the E500(S) does not use the IEEE 754 floating point standard.

- Rob

"I count on old friends" -- HP 71B,Prime|Ti VOY200,Nspire CXII CAS|Casio fx-CG50...|Sharp PC-G850,E500,2500,1500,14xx,13xx,12xx...
Visit this user's website Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
FORTH for the SHARP PC-E500 (S) - Helix - 09-06-2021, 11:41 PM
RE: FORTH for the SHARP PC-E500 (S) - robve - 11-22-2021 05:42 PM



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