Re: [colorforth] very long numbers / response
- Subject: Re: [colorforth] very long numbers / response
- From: Tim Neitz <tim@xxxxxxxxxxxxxx>
- Date: Mon, 1 Sep 2003 09:41:20 +0200 (CEST)
On Mon, 1 Sep 2003, Albert Loggy wrote:
> Hi Group,
>
> My application seems to need some numbers that don't fit in a word. Chuck
> refers to large numbers requiring 2 32 bit words which is just what I want.
> Could someone indicate how to make this business work?
>
> Albert
Albert, Tim here.
As far as I know colorforth only supports 32 bit numbers for the most part.
I think what you have read about 2 32 bit numbers is referencing the pre
parsed source code. Numbers larger than 27 bit's take 2 32 bit numbers to
store in source form because of the 4 bit (pre parsed) header.
What might help in some cases is that there is a a word */ I believe. this
word can multiply two 32 bit numbers and return a 32 bit quotient. the
intermeddiate result is 64 bit. This can sometimes avoid the need for a full
64 bit arithmetic set of words. I think some call this a scaling factor.
Should that not be enough, one would define words for the needed 64 bit
operators. Maybe others have already done this or some of it?
With kind regards,
Tim Neitz
rj_cf on #c4th IRCnet
tim@xxxxxxxxxxxxxx
---------------------------------------------------------------------
To unsubscribe, e-mail: colorforth-unsubscribe@xxxxxxxxxxxxxxxxxx
For additional commands, e-mail: colorforth-help@xxxxxxxxxxxxxxxxxx
Main web page - http://www.colorforth.com