[HOME] jsMath (Authors) [Up][Skip][Next]

Overview of jsMath

JsMath is a collection of JavaScript programs that make it possible to display mathematics within web pages. It works across multiple browsers and hardware platforms, without the need for additional downloads or plugins on the part of the user. (It helps, however, if the user installs a set of math fonts, but that is not required.) Unlike methods that represent mathematics using images, the equations generated by jsMath will be correctly sized in relation to the surrounding text, regardless of the font size set by the user, and can even resize properly if the user changes the font size on the fly. If the math fonts are installed, the equations will print at the full resolution of the printer, and if not, the user can request a hi-resolution version of the page for printing purposes.

The page author enters mathematics into the HTML page using the standard TEX notation. The mathematics are marked within the document by surrounding them with either a SPAN or DIV tag with CLASS="math", depending on whether you want in-line (SPAN) or displayed math (DIV) equations. JsMath looks for these tags and typesets the TEX code they contain.

It is not very convenient, however, to have to type these surrounding tags whenever you want some mathematics. For this reason, jsMath provides a tex2math plugin that scans the document for the TEX and LATEX math delimiters of $...$, $$...$$, \(...\) and \[...\] and inserts appropriate SPAN and DIV tags automatically. You can, in fact, define your own custom delimiters so that you can mark the mathematics in any way you want. This makes it easy to add jsMath support to a blog or other on-line content-management system: you can enter your mathematics in normal TEX-like form, and jsMath will do the rest. It is even possible to have jsMath loaded only when it is needed on the page by taking advantage of jsMath's autoload plugin.

JsMath is highly customizable, and it has a variety of extensions and plugins to control it. These have built up over time, and can make jsMath a bit daunting to a beginner. Fortunately, jsMath has an "easy load" feature that lets you control the main details of jsMath all in one place, and should be sufficient for most page authors. You simply load one JavaScript file and the rest of the setup is done automatically by jsMath.


Get jsMath at SourceForge.net. Fast, secure and Free Open Source software downloads [HOME] jsMath web pages
Created: 21 Mar 2007
Last modified: Mar 28, 2010 3:10:00 PM
Comments to: dpvc@union.edu
[Next] Installation and Testing
[Skip] Browser Support for jsMath
[Up] Information for jsMath Authors