[SciPy-user] python+maxima+latex for symolic stuff

Ryan Krauss ryanlists at gmail.com
Tue Oct 18 10:10:46 CDT 2005


Sorry, I sort of left out that the main point of this is that when I
do symbolic derivations I really like to look at "pretty" LaTeX output
and I like to add explanations to the derivation as I go along.  So,
mixing LaTeX and symbolic capabilities is very important to me.

On 10/18/05, Ryan Krauss <ryanlists at gmail.com> wrote:
> A while ago I posted a question to this list about how to do symbolic
> stuff in open source software.  I have mixed a few tools together and
> come up with something I am pretty happy with.  It is still in early
> development, but I find it useful and was wondering if it would help
> anyone else or if anyone wanted to help me develop it.
>
> Basically, I write a LaTeX input document and when I want to do
> algebra I use a new environment:
> \begin{maxima}
>     \parseopts{lhs='\theta_a-\theta_b=\theta_{RA}'}
>     thr:Gp*v+M/(k+c*s)
>     \label{thr1}
> \end{maxima}
>
> LaTeX never actually sees this environment.   I use python as a
> pre-processor for LaTeX.  Python takes out all of the maxima
> environments and builds an input script for maxima.  Python calls
> Maxima and tells it to run the script python created, saving each
> equation to a seperate output file (all very small).  Python then
> reads these output files and replaces the maxima environments with
> normal LaTeX equation environments with the output from maxima (it may
> have been possible to do this in a slightly cleaner way with pipes but
> I was originally developing it under windows and I am a hack).
>
> I could package it a little cleaner and include some simple examples
> if anyone is interested.
>
> Ryan
>



More information about the SciPy-user mailing list