[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Axiom-developer] empty line in an axiom pipe.
From: |
Francois Maltey |
Subject: |
[Axiom-developer] empty line in an axiom pipe. |
Date: |
Tue, 24 May 2005 21:47:59 +0200 |
User-agent: |
Gnus/5.1006 (Gnus v5.10.6) XEmacs/21.5 (chestnut, linux) |
Hello,
I try to write a emacs-mode for running axiom.
I can start axiom, read the output and send ONE commandline.
This is the minimal 3 lines to put in a new buffer as *Axiom* buffer :
(setenv "TERM" "xterm")
(setq axiomRun-process
(start-process "axiom" (current-buffer) "axiom" "-noht"))
Then eval this command in emacs, with ^X^E
(process-send-string axiomRun-process "123+456\n")
it's right.
You can send a lot of computation of one line,
but wait the end of the axiom-computation !
If you add a "-noclef" after "-noht", the display is cleaner,
but it isnot the problem.
I get a problem when I send 2 or more \n.
When I send one empty-line with this command,
axiom doesn't seem to understand.
(process-send-string axiomRun-process "123+456\n\n")
(process-send-string axiomRun-process "123*456\n")
After this error, I must send two commands if I want to get one reponse.
And the reponse is the reponse of the previous command, not the reponse
of this command.
The error is the same with the underscore _ end-line.
What is the normal use of axiom command-line ?
Thanks a lot for your help !
François
My log-file is this one, I replace ^H and ^M to ascii 2 chars.
----------------------------------------------------------------
(setenv "TERM" "xterm")
(setq axiomRun-process
(start-process "axiom" (current-buffer) "axiom" "-noht"))
; I evaluate this two lines buffer with M-x eval-buffer
;
;
GCL (GNU Common Lisp) 2.6.6 CLtL1 Jan 18 2005 00:13:38
Source License: LGPL(gcl,gmp), GPL(unexec,bfd)
Binary License: GPL due to GPL'ed components: (READLINE BFD UNEXEC)
Modifications of this banner must retain notice of a compatible license
Dedicated to the memory of W. Schelter
Use (help) to get some basic information on how to use GCL.
AXIOM Computer Algebra System
Version: Axiom 3.0 Beta (February 2005)
Timestamp: Monday February 21, 2005 at 20:01:15
-----------------------------------------------------------------------------
Issue )copyright to view copyright notices.
Issue )summary for a summary of useful system commands.
Issue )quit to leave AXIOM and return to shell.
-----------------------------------------------------------------------------
Re-reading compress.daase Re-reading interp.daase
Re-reading operation.daase
Re-reading category.daase
Re-reading browse.daase
(1) ->
;
;
; then run this with C-x C-e at the end of the next line
;
(process-send-string axiomRun-process "123+456\n")
;
; the result appears before this lisp-line, I move it after.
(1) -> 123+456^H^H^H^H^H^H^H^M(1) -> ^M
(1) 579
Type: PositiveInteger
;
; I can do a lot of calculs so.
; But when I send a 2 lines command axiom become silly :
;
(process-send-string axiomRun-process "123+456\n\n")
;
(2) -> 123+456^H^H^H^H^H^H^H^M(2) -> ^M
(2) 579
Type: PositiveInteger
(process-send-string axiomRun-process "12+56\n")
(process-send-string axiomRun-process "12+56\n")
(process-send-string axiomRun-process "12+56\n")
(process-send-string axiomRun-process "12+5\n")
;
; The command line redisplayed isn't the result : so 12+5=68.
;
(3) -> 12+56^H^H^H^H^H^M(3) -> ^M(3) -> 12+56^H^H^H^H^H^M(3) -> ^M
(3) 68
Type: PositiveInteger
(4) -> 12+56^H^H^H^H^H^M(4) -> ^M
(4) 68
Type: PositiveInteger
(5) -> 12+5^H^H^H^H^M(5) -> ^M
(5) 68
Type: PositiveInte
- [Axiom-developer] empty line in an axiom pipe.,
Francois Maltey <=