This site is a showcase for using LatexRender for mathematics in WordPress

Using LaTeX in WordPress


Saturday 5th March 2005

Filed under: — Steve @ 11:56 pm

Chemists do make use of \LaTeX but they have different typesetting conventions from mathematicians. For example the chemical \cf{H2O} is quite different from the mathematical H_2O . Martin Hensel’s mhchem package allows the easy typing of chemical symbols. Here are some examples taken from mhchem’s documentation. Needless to say, not being a chemist, they don’t mean much to me 🙂

Hover over, or click on a formula, to see the underlying latex code.






\ce{SO4^2- + Ba^2+ -> BaSO4 v}

<=>[\ce{+ 2OH-}][\ce{+ 2H+}]
{\underset{\text{amphoteres Hydroxid}}{\ce{Zn(OH)2 v}}} %group!
<=>[\ce{+ 2OH-}][\ce{+ 2H+}]
{\underset{\text{Hydroxozikat}}{\cf{[Zn(OH)4]^2-}}}% group!

\ce{{{x\,}} Na(NH4)HPO4 ->[\Delta]
(NaPO3)_{{x}} + {{x\,}} NH3 ^ + {{x\,}} H2O}


RSS feed for comments on this post. TrackBack URI

  1. Nice and useful plugin, thanks for doing this 🙂

    Comment by Wirjo — Monday 14th March 2005 1:41 am #

  2. […] February 3, 2009 Productivity Tags: chemistry, LaTeX There is a LaTeX package called mhchem available that makes typesetting chemical equations a lot easier. Sure, you could be lazy and type […]

    Pingback by Chemistry with LaTeX — mhchem « revision — Monday 2nd February 2009 5:26 pm #

  3. But, how do I install the mhchem on my wordpress blog? Are there some instructions for newbies somwhere?

    Comment by Endeeder — Friday 22nd May 2009 5:50 pm #

  4. mhchem is included with most TeX distributions so all you need to do is add the package to the compilation. In class.latexrender.php after the line
    $string .= "\usepackage{amssymb}\n";
    add the line
    $string .= "\usepackage{mhchem}\n";

    Comment by Steve — Friday 22nd May 2009 6:08 pm #

Leave a comment

XHTML: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>


This site is a showcase for using LatexRender for mathematics in WordPress