What's the best way to write Mathematical Equations on the Web?
Solution 1:
The jsMath package is an option that uses LaTeX markup and native fonts. Quoting from their webpage http://www.math.union.edu/~dpvc/jsMath/:
The jsMath package provides a method of including mathematics in HTML pages that works across multiple browsers under Windows, Macintosh OS X, Linux and other flavors of unix. It overcomes a number of the shortcomings of the traditional method of using images to represent mathematics: jsMath uses native fonts, so they resize when you change the size of the text in your browser, they print at the full resolution of your printer, and you don't have to wait for dozens of images to be downloaded in order to see the mathematics in a web page. There are also advantages for web-page authors, as there is no need to preprocess your web pages to generate any images, and the mathematics is entered in TeX form, so it is easy to create and maintain your web pages.
See for example this page or that one.
Solution 2:
I've just written a javascript module to do this, named jqmath. See http://mathscribe.com/author/jqmath.html
It's sort of similar to MathJax, but simpler, smaller, and faster.
Solution 3:
I have been using borderless tables with merged cells in my website to display math equations. It works excellent for most equations. However, since the markup is usually a bit complex, it would be time consuming in case of hard core mathematics websites.
Here is the code:
<style type="text/css">
table.math{font:17px georgia, times, serif;border-collapse:collapse;border:none;}
td.a{text-align:center;}
td.b{padding:0 2px;}
td.c{border-top:1px solid #505050;border-left:1px solid #505050;border-bottom:1px solid #505050;}
td.d{border-top:1px solid #505050;border-right:1px solid #505050;border-bottom:1px solid #505050;}
td.e{text-align:center;border-top:1px solid #505050;}
</style>
<table class="math">
<tr>
<td class="a">1</td>
<td class="b" rowspan="2">×</td>
<td class="c" rowspan="2"> </td>
<td class="a">8</td>
<td class="b" rowspan="2">+</td>
<td class="a">1</td>
<td class="d" rowspan="2"> </td>
</tr>
<tr>
<td class="e">x + 2</td>
<td class="e">x + 2</td>
<td class="e">x − 1</td>
</tr>
</table>
Here is the output of the above code:
Solution 4:
LaTeX is use extensively already on the net and in academia to render equations.
A great example of this is wikipedia have a look at this page for 1 example.
http://en.wikipedia.org/wiki/Latitude
I know this is a generlisation but: Using images is a viable way to achieve many things on the web in a browser compatible way - provided you provision for some of the shortcomings. ( eg. Google Maps, Rounded Corners, graphs, advanced typography )
Also 'dated' could be interpreted as 'tried, tested and feature complete'
and thanks for point out sIFR - something i'm going to look at later, i already have a list of things to explore with it, such as printing? ( html + images can do this pretty well, can sIFR?....)
Solution 5:
I've been using the LaTeX plugin for the Confluence wiki to write equations on the web (well, on the intranet). It displays an image in the web browser, but you can still see the LaTeX source if you edit the page.
I don't know what you're using to host the web site, but you could maybe use a similar approach: embed the LaTeX source in the page, and render it as an image for the web browser.