[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Axiom-mail] Re: Outputting S-expressions
From: |
Ludovic Courtès |
Subject: |
[Axiom-mail] Re: Outputting S-expressions |
Date: |
Tue, 07 Nov 2006 10:38:59 +0100 |
User-agent: |
Gnus/5.110006 (No Gnus v0.6) Emacs/21.4 (gnu/linux) |
Hi,
Themos Tsikas <address@hidden> writes:
> (1) -> p:=(1+x)^5
>
> 5 4 3 2
> (1) x + 5x + 10x + 10x + 5x + 1
> Type: Polynomial Integer
> (2) -> VALUES(p)$Lisp
>
> (2) (1 x (5 0 . 1) (4 0 . 5) (3 0 . 10) (2 0 . 10) (1 0 . 5) (0 0 . 1))
> Type: SExpression
Actually, I want a "parsable" S-exp, like `(** (+ 1 x) 5)' in this case.
In the meantime, I found `convert' and `$Lisp', so what I do is the
following:
-> p := (1+x)^5
-> )fin
BOOT> (defun my-output (sexp)
(with-open-file (out "out.sexp" :direction :output)
(format out "~a~%" sexp)))
BOOT> (|spad|)
-> sexp := convert(p)
-> (my-output sexp)$Lisp
However, I can't get `my-output' to be visible from Spad. Hint?
Thanks,
Ludovic.
- [Axiom-mail] Outputting S-expressions, Ludovic Courtès, 2006/11/07
- Re: [Axiom-mail] Outputting S-expressions, Themos Tsikas, 2006/11/07
- [Axiom-mail] Re: Outputting S-expressions,
Ludovic Courtès <=
- Re: [Axiom-mail] Re: Outputting S-expressions, Martin Rubey, 2006/11/07
- [Axiom-mail] Re: Outputting S-expressions, Ludovic Courtès, 2006/11/07
- Re: [Axiom-mail] Re: Outputting S-expressions, Themos Tsikas, 2006/11/07
- Re: [Axiom-mail] Re: Outputting S-expressions, Gabriel Dos Reis, 2006/11/07
- [Axiom-mail] Re: Outputting S-expressions, Ludovic Courtès, 2006/11/07
- Re: [Axiom-mail] Re: Outputting S-expressions, root, 2006/11/07
- [Axiom-mail] Re: Outputting S-expressions, Ludovic Courtès, 2006/11/08
- Re: [Axiom-mail] Re: Outputting S-expressions, Gabriel Dos Reis, 2006/11/08
- Re: [Axiom-mail] Re: Outputting S-expressions, root, 2006/11/08
- [Axiom-mail] Re: Outputting S-expressions, Ludovic Courtès, 2006/11/08