Using hevea2mml

Bernard.Parisse@ujf-grenoble.fr

2017

Contents

1  Introduction

hevea2mml is a HTML+Latex to HTML+MathML translator, forked from the itex2MML project
https://golem.ph.utexas.edu/~distler/blog/itex2MML.html
The fork was made to process LaTeX file converted to HTML+Latex by hevea, in order to make the HTML output nicer and fast with mathml-enabled browsers like Firefox.

2  Installation

Install hevea with mathjax support from hevea.inria.fr (get the latest version) or with
git clone https://github.com/YannickChevalier/hevea-mathjax
Copy hevea2mml from bin/Linux or bin/MacOS to /usr/local/bin
(Linux) sudo cp bin/Linux/hevea2mml /usr/local/bin
(Mac) sudo cp bin/MacOS/hevea2mml /usr/local/bin
On other platforms cd bin; make should work, perhaps you will have to adjust the Makefile.

3  Writing the LaTeX file

Add in the preamble

\usepackage{hevea} 
\giacmathjax

References to numbered equations should be inside additional backslashed parenthesis. (see example below). \mathbb{} should be explicit (newcommand will not work).

4  Compiling the LaTeX file

Without keeping an intermediate HTML file
(hevea) hevea example
(hevea-mathjax fork) hevea -mathjax example
hevea2mml example

Keeping an intermediate HTML file:
(hevea) hevea example.tex -o tmp.html
(hevea-mathjax fork) hevea -mathjax example.tex -o tmp.html
hevea2mml tmp.html example.html

In one step:
hevea2mml example.tex

5  Example

Inline math xx \in \mathbb{R}, numbered equation 1x 41(1) \frac{1}{x^4-1} \qquad (1)

From equation (1), we deduce...

6  Other files

The giac* files may be used to produce interactive HTML5 output with CAS capabilities. Replace \usepackage{hevea} with \input{giacfr.tex} or giac.tex and look at test.tex or testfr.tex (French) for more information.


This document was translated from LATEX by HEVEA.