User:IanDavidWild/Mathematical Content in Electronic Media

Encoding Mathematical Content
At present there are three main methods for encoding mathematical content, namely
 * TeX/LaTeX, primarily used for print and PDF publishing
 * MathML (presentation and content), for web pages and accessibility
 * OpenMath, an extensible standard for the semantics of mathematical objects

Each of these encodings has its own range of applicability. For each, there are problems with authoring and conversion. A single system, for example for e-Assessment, may require LaTeX for authoring, MathML for accessibility and OpenMath for back-end marking of student input.

The main electronic media used for mathematical content are PDF, HTML and graphics (including handwriting and scan).

Mathematical Content From Commercial Publishers
Commercial publishers, such as Pearson with http://www.mathxl.com, are linking course books to proprietary e-Learning systems for mathematics.

Conversion Tools
There are many standards and conversion tools in use, most developed for a particular purpose. Conversion tools include GELLMU, LaTeX, LaTeX2HTML, LaTeXML, latex2wp, MathTran, mimeTeX, mathTeX (the successor to mimeTeX), PlasTeX, SnuggleTeX, LatexRender.

Each conversion tool has an implied standard for mathematical content.

Rendering Mathematics As Images
Programs such as mathTeX, LatexRender and CodeCogs Equation Editor render mathematical expressions as images with PNG or GIF format. LatexRender-ng can also generate SVG images in some browsers. Although using images suffers from disadvantages such as non-scaleable graphics and possibly slower loading web pages, it does allow access to the full LaTeX capability via the use of packages such as PSTricks, mhchem (for chemical expressions) and Asymptote (for geometrical diagrams).

This method was originally written by Benjamin Zeiss in 2003 and has become popular with online programs such as phpBB forums, Moodle and Wordpress.com blogs because it works in every browser and doesn't require the reader to install any special plugins or fonts. It puts the mathematical expression in the alt/title tags of the image satisfying accessibility requirements; this expression is retained to enable re-editing the content and, optionally, can appear in a popup window for readers to copy.

The process takes the required expression and puts it in small but complete LaTeX document, using any packages that the server owner wishes to add. This is then compiled to DVI and the image abstracted from the output using programs such as ImageMagick and dvipng, and is then displayed. To avoid re-rendering the image every time the expression appears, the images are cached. This is achieved by calculating the MD5 hash of the expression and using that hash for the filename.

For users unfamiliar with LaTeX, it is possible to add editors such as CodeCogs Equation Editor to the Javascript editor used to create content in forums and blogs.

Problems Encoding Mathematical Content
Authoring of mathematical content by students, and in web pages, are long-standing problems that inhibit eLearning of mathematics and dissemination of mathematics, which frustrates even great mathematicians. For example, text can be copied from one computer application to another, even if in a non-Latin script. However, often this cannot be done with mathematical content. For this reason, formulas are often reduced to images, which cannot be edited or made accessible.

One common solution is a "drag and drop" equation editor. An expression is built up on-screen in a traditional form before being exported in the desired format. For example [Dragmath] is one such editor. Unusually, a user can define an "output format file" to describe the desired target output format without having to re-compile the software itself.