maple2html
maple2html - Maple to Html translator
USAGE:
maple2html maplefile "The Title"
maple2html translator.
The file containing the emacs maple output is given
as an argument. It creates the file maplefile.html
with the html-ized translation of maplefile.
It also creates the file maplefile.mpl with all the
maple commands in maplefile.
Here is what the program does:
1) Each line that starts with a ">" is assumed to be a
Maple command. It is written out according to $FONT
to the .html file and saved into the .mpl file.
2) Everything that follows a line with a
maple command until the next line starting with either
">" or "#" is written as it is (preformatted) to
the .html file.
3) A line that starts with a "#" is assumed to be
the first line of a text block which ends at the
next line starting with either ">" or "#". This block
of text is formatted in a table with a right margin.
4) A line that starts with "!" is assumed to contain the
the filename of an image to be included at that point
5) A line that starts with "> gif" is assumed to be a "gif"
maple command.
A gif command has the following syntax:
> gif( AnyMaplePlotCommand, `foo.gif` );
The first argument to gif could be ANY maple command
that generates a plot or plot3d structure. Here is
an example:
> gif(plot3d(x^2+y,x=-1..1,y=-1..1,axes=frame), `apic.gif`);
The gif command (see code below) saves the image generated
by the maple plot command in 'gif' format into the file
given as second argument to the gif command (apic.gif in
the example). The translator isolates the maple plot command
saves it into the .html and .mpl files and transforms the
gif file given as second argument into maplefilen.gif
(where n is 1,2,...) with white background and links this
image in the .html file.
You need to add the following
to your ~/.mapleinit:
x11 := proc()
plotsetup(x11);
plots[display](args[1]);
end:
gif := proc()
plotsetup(gif,plotoutput = args[2]);
plots[display](args[1]);
end:
6) The last character of the maplefile must be ">".
If the progam does not return chances are
you forgot the last maple prompt in the file.
This program works best with the companion Maple2Html emacs mode.
A copy of this mode can be found at:
https://omega0.xyz/omega8008/Maple2html.el
Many examples of maplefiles, and stuff generated by
this program can be found at:
https://omega0.xyz/omega8008/mat214
Look under Lectures with URLs with filenames of the form
filename-m2h.
If you have an account in the math.albany.edu cluster
with access to the /math directories you only need to
modify your shell,man, and emacs paths to use these
programs. Send me email if you need help.
Carlos Rodriguez <carlos@math.albany.edu>
Last update:
Wed Oct 16 15:53:21 EDT 1996