On 2012-06-20, Phuc Luoi phucluoi@gmail.com wrote:
I 'm working on the E-Learning system mathcoach: http://mathcoach.htw-saarland.de/project/ We plan to use maxima for the back-end our system. We used python to connect to maxima over Pipe (in Linux) and redirect the output of maxima to a http-server written in Python. The Java front-end can then connect to the http server.
Hmm, you might be able to simplify this architecture somewhat. There is a share package, maxima-server.lisp, which implements an ordinary Unix-ish server via listen, accept, and fork function calls (in SBCL). Each client gets a separate session (due to fork). Maxima has command line options to turn off the input and output labels and banner message, so only results are output.
What is the output of the Python HTTP server? You could probably write that same functionality in Lisp, or maybe in Maxima itself.
I think it is more robust if we can integrate maxima directly in Java, something like a jar file or so.
That makes sense to me. The main problem I see, which affects socket-based architectures as well, is that Maxima sometimes wants to ask questions (e.g. "Is x positive, negative, or zero?"). I don't know what to do about that. There is an experimental share package named noninteractive which attempts to intercept such questions and turn them into if-then expressions. I can say more about that if you are interested.
best
Robert Dodier