Post Reply 
HP Prime CAS & Large numbers
09-28-2023, 01:25 PM
Post: #13
RE: HP Prime CAS & Large numbers
(09-27-2023 06:37 PM)parisse Wrote:  There is indeed a max for integers, in global.cc
Code:

  double powlog2float=1e4;
  int MPZ_MAXLOG2=8600; // max 2^8600 about 1K
As far as I remember, the long integer library is not optimal for integer operations (it uses Karatsuba multiplication, not FFT), if you multiply/divide really large integers it will be slow. There is always a trade-off between speed and size limits, and I tend to be conservative. I don't remember when the limits were set, if it's an heritage of the hp39gii, then they should probably be raised, perhaps multiplied by 10.

It seems that you confirm that long integers are stored with a limit of 8600 bits (one of which dedicated to sign): ranging from -2^8598 to +2^8599 (0 to 2^8599 plus 1 bit for sign; the single value -2^8599 excluded). (==> MPZ_MAXLOG2=8600)
Anyway it's not evident what the cited piece of code means and what global.cc is, including the comment "// max 2^8600 about 1K" (?).

Now let me start a completely new subject.
I find very useful that the names of user defined functions appear in the ToolBox Catlg list (in italic).
I would appreciate the possibility to add some (used written) help text for them to recall inside the Catlg with the Help key (as for built-in functions). These would provide a mean to remind yourself the scope and syntax of your user defined functions.
Is there any way to get this? For example creating a "Note" to associate with the user defined programs/functions...
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
HP Prime CAS & Large numbers - Bipman - 08-10-2017, 08:27 AM
RE: HP Prime CAS & Large numbers - Arno K - 08-10-2017, 11:35 AM
RE: HP Prime CAS & Large numbers - Bipman - 08-10-2017, 11:39 AM
RE: HP Prime CAS & Large numbers - Bipman - 08-10-2017, 02:03 PM
RE: HP Prime CAS & Large numbers - Bipman - 08-13-2017, 09:11 AM
RE: HP Prime CAS & Large numbers - parisse - 09-27-2023, 06:37 PM
RE: HP Prime CAS & Large numbers - Mario Blasone - 09-28-2023 01:25 PM
RE: HP Prime CAS & Large numbers - parisse - 09-29-2023, 10:46 AM



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