Re: Problem with storage of large data

"Ruud H.G. van Tol" <[email protected]> Mon, 25 Aug 2025 11:27:14 +0200
Newsgroups gmane.comp.mathematics.pari.user
Message-ID <[email protected]>
On 2025-08-25 11:12, Ewan Delanoy wrote:
> I've got a large (1.2 GB, around 100000 lines) gp file that the GP 
> interpreter cannot read - when I call `read` on that file the 
> interpreter, after a few minutes, prints "Killed" and exits suddenly.
> The issue is only one of file size, because the operations in the file 
> are very elementary - it only uses addition, multiplication and 
> accessing/setting elements of an array.
> My intent was to store the results of somewhat long computations. The 
> values involved are all univariate polynomials, and the heavy core of 
> the data is a set of about 700 polynomials of degree 71, whose 
> coefficients are rationals whose numerators and denominators have up 
> to 10000 digits.
> When I simply and naively use the `write` function to put all this 
> data into a file, I get this
> large GP-unreadable file.
> Any ideas on how to make this storage work ?

Use a separate file per polynomial?
(or some other similar mapping)

See "writebin".

-- Ruud