next up previous

Generating MathML markup
using LATEX2HTML, WebEQ and WebTEX

Ross Moore
Macquarie University, Sydney

This page describes the results of work performed by Ross Moore while visiting the Geometry Center, Univ of Minnesota, during July of 1998.

The ultimate goal is to use LATEX2HTML to generate MathML markup for mathematics, starting from LATEX source documents. This is a very large task, too large to be completed in just a few weeks.

As a significant step towards this goal we have combined the use of existing tools: the Java-based WebEQ, WebTEX and LATEX2HTML. The results can be viewed most effectively using the TechExplorer plug-in to interpret the resulting MathML source.

The strategy adopted is as follows.

LATEX2HTML processes a document written using LATEX markup, in which some of the mathematics uses the simplified WebTEX markup macros, within some inline and displayed math-environments.

With the webtex.sty package loaded, the content of these math-environments are processed by the WebEQ Wizard authoring software to produce either Java applets, or MathML markup or both.

Using Perl subroutines from webtex.perl, LATEX2HTML processes the output from WebEQ, wrapping it inside <EMBED>, <APPLET> or <OBJECT> tags, as appropriate for the level of HTML requested. The <NOEMBED> tag is used in conjunction with <EMBED> to provide a fall-back which is the usual LATEX2HTML translation; i.e. either a single <IMG> or parsed text with images.
(Although <EMBED> and <NOEMBED> are not part of any W3C recommendation for HTML, they are recognised by both Netscape's Navigator and Microsoft's Internet Explorer browsers as a method for including data for plug-in modules, with a fall-back.)

Since different versions of browsers support different levels of HTML and may not be equipped with the plug-in modules required to view the markup, the generated information is presented using a hierarchy of fall-back mechanisms.

Either the WebEQ Java applets, or the MathML plug-in can be the primary source, with the other as an optional fall-back. Normally an <IMG> is included as a last-ditch fall-back, but this can be omitted if desired.

Browse the following pages for examples of some of these combinations:

The following pages use tags recognised by version 3 of the Navigator and Internet Explorer browsers;
that is, they use the <APPLET>, <EMBED> and <NOEMBED> tags.

* MML/webeq/IMG

* webeq/MML/IMG


Mathematics occurring inline is often badly placed by Internet Explorer. It's notion of ALIGN=MIDDLE seems to be to align the middle of an image with the middle of the largest object occurring on the same line. This means that text in bold-face or a larger size will affect the placement of all images.

On the other hand Navigator aligns the middle of the image with the baseline of the text. Images created by LATEX2HTML assume this behaviour from the browser.

The following pages use tags recognised by version 4 of the Navigator and Internet Explorer browsers;
i.e they use the <OBJECT> tag wherever possible.
Earlier versions of these browsers should show a fall-back even if capable of supporting the primary method.

* MML/webeq/IMG
The fall-back mechanism for <OBJECT> tags fails with Internet Explorer 4 -- it shows the <APPLET> as well.

* webeq/MML/IMG


The latest version of the Navigator browser handles these pages best, provided the TechExplorer plug-in is installed. If not, such as on a Macintosh where TechExplorer is not yet available, then a ``missing plug-in'' image is shown instead of using a fall-back. Earlier versions fail to recognise the <OBJECT> tag, so politely choose the provided fall-back.

With Internet Explorer 4, apart from the problem mentioned already, a blank image is shown when applets are the first choice, but Java has been disabled; a fall-back is not used. When TechExplorer is missing as the first choice, it does use a fall-back.

Future Extensions

About this document ...

Generating MathML markup
using LATEX2HTML, WebEQ and WebTEX

This document was generated using the LaTeX2HTML translator Version 98.2 beta4 (July 21st, 1998)

Copyright © 1993, 1994, 1995, 1996, Nikos Drakos, Computer Based Learning Unit, University of Leeds.
Copyright © 1997, 1998, Ross Moore, Mathematics Department, Macquarie University, Sydney.

The command line arguments were:
latex2html -split 3 webtex.doc

The translation was initiated by Ross Moore on 1998-07-22

next up previous
Ross Moore