View Full Version : floating point on MPE Forth
Running MPE Forth on the TinyArm
All floating point words and entry of floating
point numbers return the error message
is undefined
Anyone know what's happening here.
Thanks
Bill
RMDumse
03-24-05, 06:52 PM
Hi Bill, Long time! Good to hear from you.
Yes, that seems strange. We see we can use predefined floats, for instance PI F. We see we can use most all the Float functions. But it looks like we can't enter a Float directly.
So we've emailed for support from MPE.
In the mean time, you can try this if you care to. 1234 S>F 100 S>F F/ FCONSTANT <name>
So you can put numbers in as singles. To get decimal points, enter the exponenet separately and divide. Then use assembled Float for your operations.
Hi Randy
How have you been? Good to hear from you too.
Just figured it out this morning. The word
reals
enables floating point routines. I remember FPC
had a similar enabler word.
alpierce
03-25-05, 04:57 PM
Even after using "reals" I can't enter a float unless I use exponent notation.
1.25 yields undefined message
but 1.25e0 is accepted
Also 1.25e0 1.34e0 f+ f. yields 2.59, no exponent notation!
curiouser.
vBulletin v3.0.7, Copyright ©2000-2012, Jelsoft Enterprises Ltd.