# Math Works Now

Docutils has supported math rendering for a while now. That means Nikola should have supported it for a while too, but never did correctly because ... well, because noone ever tried, maybe?

Well, it does now, because Damian Avila has fixed it!

For example, I can now casually mention Euler's formula, which is \(e^{ix} = \cos x + i\sin x\) and it just works. How did I do that? Like this:

I can now casually mention Euler's formula, which is :math:`e^{ix} = \cos x + i\sin x`

And I can show whole equations!

\begin{equation*}
\int \frac{dx}{1+ax}=\frac{1}{a}\ln(1+ax)+C
\end{equation*}

That was done like this:

.. math:: \int \frac{dx}{1+ax}=\frac{1}{a}\ln(1+ax)+C

And all you need to do to make this work is tag your posts as "mathjax" so the right javascript is loaded. If you don't do that, then your page has no mathematical javascript at all :-)

I am glad to have contributed a little bit, I hope to do it again soon... ;-)

I just ran into this problem today but my solution wasn't as classy. I just added the mathjax script loader to my template head

Doing it in that way, you will probably have some problems with the rendering... we can discuss it if you want but I encourage to use this solution...

Cheers.

Well done, Damian and Roberto! This is the feature I've been waiting for! My rst2html static site is showing its age and the latex math rendering broke long ago.

cool :-)