2009/10/26 Robson eduardo Assis <lotom...@gmail.com>:
> Hi! I am a very new GAP user and i wanna use it as the folowing:
> 1) I write source forges using a text editor whithout any prompt of GAP.
> 2) In the prompt of GAP I excecute the content of this file and take the
> results to
> other file.
> 3) I'll create a program in c plus plus to convert this results in LATEX and
> then to PDF.
>
> the my questions are about using text files ".g" and rediretion of output or
> files. The manual don't answered my question!
> Thank for the patience!
> Robson Eduardo

Hi Robson,

A simple way to achieve this is to use the input and output
redirection features of your shell, and GAP's -q option. You don't
write which OS you use, but on any Unix-alike, something like this
should work:

epos...@ubuntu64ma293:~/tmp % cat a.g
f := (1,2,3);
g := f^2;
epos...@ubuntu64ma293:~/tmp % gap -q < a.g > b.out
epos...@ubuntu64ma293:~/tmp % cat b.out
(1,2,3)
(1,3,2)

Hope this helps,
Erik Postma.

_______________________________________________
Forum mailing list
Forum@mail.gap-system.org
http://mail.gap-system.org/mailman/listinfo/forum

Reply via email to