Bill Allombert on Thu, 11 Dec 2025 18:21:33 +0100


[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]

Re: Large data (multivariate polynomials) successfully written but unreadable by PARI-GP


On Thu, Dec 11, 2025 at 05:57:37PM +0100, Ewan Delanoy wrote:
> In my current project, I'm dealing with polynomials in six variables and
> integer coefficients, max degree 20 for each variable (although the degrees
> are often smaller). 
> 
> A certain program I made successfully computes about 300.000 of those polynomials, and also successfully writes

Instead of storing them as a vector, store them line by line (you can even use
filewrite which is faster than write) and read it using readvec.

If you are in a hurry, you can use writebin() to write your data in binary
format, which requires much less memory.

If you really have a multivariate polynomial so large you cannot read it with read,
then you can apply Vecrev recursively.

Cheers,
Bill