[GAP Forum] How to write a compressed file

Raphael C drraph at gmail.com
Tue Apr 14 20:23:51 BST 2020


I am making a large DFA and would like to compress it before writing
it to a file. I tried the following:

    dfa := RemovedSinkStates(NFAtoDFA(nfa));
    output := OutputTextFile("test.gz", false);
    AppendTo(output, dfa);
    CloseStream(output);

But the file test.gz is not compressed.

I was attempting to follow the instructions from
https://www.gap-system.org/Manuals/doc/ref/chap10.html .

How should this be done?

Raphael



More information about the Forum mailing list