Re: Outputting S-expressions

[email protected] (Ludovic Courtès)
Newsgroups gmane.comp.mathematics.axiom.user
Organization LAAS-CNRS
Message-ID <[email protected]>
Hi,

root <[email protected]> writes:

> | > One minor thing: in the output file, variable names are enclosed in `|'
> | > (e.g., `(+ 1 |x|)').  Is there a way to turn it off?
> | 
> | Similarly, Axiom sometimes issues additional information that is not
> | relevant to me, for instance:
> | 
> |   (|primeFactor| (|::| |lambda| #0=(|Polynomial| (|Integer|))) 1)
> | 
> |   ...
> | 
> |   (|primeFactor| (|::| (+ |lambda| (* (+ R 1) |beta|)) #0#) 4)
> | 
> | Is there a way one could tweak it into removing those additional
> | annotations?
>
> The output syntax says that these are eq objects (that is, they
> share the same memory locations). The #0= syntax says that this
> is the first instance of the s-expression and the #0# syntax says
> that this is a repeat. You can set *print-circle* to false to 
> skip this syntax but be aware that a circular structure might
> print forever. From the Axiom prompt do:
>
> -> )lisp (setq *print-circle* nil)

Thanks for your quick answer.

I had actually guessed that this had something to do with shared
sublists.

However, what I'm interested in is removing the type and type conversion
information, i.e., the `::' and `primeFactor'.  IOW, I'd like to get
exactly the same information as is available on the console (or other
output styles), no more.  Is this feasible?

Maybe what I'm really looking for is an `sexp' output style?

Thanks,
Ludovic.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.