Not sure if Maxima is the best choice for this



Ardillas del Monte <ardillasdelmonte at gmail.com> writes:
> Hi,
>
> I want to create a simple system for generating print-quality (LaTeX)
> solutions of simple 2D statics problems of forces vectors. The system I've
> on my mind would:
>
> 1- Read an arbitrary array of forces from a file. Each force can be defined
> in different units, so the 'ezunits' package would be used.
> 2- Generate a drawing of the forces vectors, with labels on them
> 3- Perform some computations on the given forces
> 4- Generate a print-quality LaTeX output with all of the above, together
> with more text that I might add for explaining the exercise.
>
> So, in other words, the idea is to have a system for conveniently
> generating the solutions of similar exercises which only differ in the
> input file describing the forces.
>
> By googling, I felt like Maxima could be perfect for doing this, but I'm
> not sure. For example, one first "difficulty" I found is the ezunits
> syntax: I didn't find a way for getting rid of the apostrophe it uses
> (obviously I don't wish to have such apostrophes in the generated LaTeX).

Have you decided what the input syntax should be? I suspect that's going
to be the more difficult problem. I confess that I've never seriously
used ezunits, but looking at ezunits.lisp I see that the tex function
throws away the backtick, so you probably don't need to worry about it.

> Also, since I'm new to Maxima, I don't know how hard will it be for me to
> learn what I need to do this. I've read the programming basics, and I think
> I understand blocks, for loops, and if-then-else test clauses, but I
> believe the key topic for me will be array of data (since the problem
> definition will be given as an array of an arbitrary number of forces).

Quick comment: An array in Maxima is quite a specialised data type,
which you probably don't need to use here. The type you should use is
just called a "list" in the documentation. Literal lists are entered
with the syntax [1,2,3] and so on. This terminology is quite confusing
to people coming to Maxima from a C background.

General advice:

I'd probably approach this by starting with the "computation"
bit. Hand-type example data into a .mac file in whatever syntax is most
convenient for your program and get the calculations working. Then write
a component which is responsible for converting from "easy to type" to
the "easy to use" syntax you were using. Generating the images will be
very specific to the toolset you're using: you might be able to get what
you want outputting tex from a Maxima script and using xypic or tikz,
but I suspect it'll take a long time to get right.

I hope this is some help: it sounds like a nice project.

Rupert
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 315 bytes
Desc: not available
URL: <http://www.math.utexas.edu/pipermail/maxima/attachments/20120907/0865e349/attachment-0001.pgp>;