Thursday, October 17, 2013

The arXiv, Aaronson adopt Mathjax

ArXiv authors expected to use dollar signs in abstracts

This blog, the world's most important personal physics blog, celebrated its 9th birthday last week. Because it has always been focusing on mathematically heavy topics, there has always been the question whether the dominant expert method to type mathematical formalism – \(\rm \TeX\) and/or \(\rm\LaTeX\) – should be implemented.

For long years, there would be many solutions but all of them had some serious bugs that made me sure rather quickly that I wouldn't get used to them. Or you, the readers, wouldn't get used to them.

Techexplorer required the readers to install a plugin, something that a sensible blogger simply shouldn't expect from most readers. LaTeXMathML.js produced a rather ugly outcome; it wasn't using fonts that look fine at any resolution; and there were probably problems with background colors. CodeCogs had also trouble with the background color and high-resolution outcomes. And I wasn't satisfied with Mimetex and its variations, either. There were probably a few other attempts I forgot.

Things changed in Summer 2011, more than two years ago.

Mathjax headquartered at is a Javascript that every modern Internet browser may understand. It looks for \(\rm\TeX/ \LaTeX\)-like sequences on the page and replaces them with the nice \(\rm\TeX/ \LaTeX\) outcome using a few new fonts that may be automatically transmitted to the reader. They look great at any resolution. They may be printed. They don't require the viewer to install any plugins. It just works.

It seemed clear to me from Day 1 that I would keep it, despite the few seconds that your browser needs to reprocess the \(\rm \TeX/\LaTeX\) formulae. If you've never noticed Mathjax, look at this equation:\[

J_\alpha(x) = \sum\limits_{m=0}^\infty \frac{(-1)^m}{m! \, \Gamma(m + \alpha + 1)}{\left({\frac{x}{2}}\right)}^{2 m + \alpha}

\] This formula for Bessel's function is written in the "displayed math" mode. The HTML source looks like this:
...your browser needs to reprocess the \(\rm \TeX/\LaTeX\) formulae. If you've never noticed Mathjax, look at this equation:\[

J_\alpha(x) = \sum\limits_{m=0}^\infty \frac{(-1)^m}{m! \, \Gamma(m + \alpha + 1)}{\left({\frac{x}{2}}\right)}^{2 m + \alpha}

\] This formula formula...
Once the javascript does its job, the esoteric expressions (featuring many commands that start with a backslash) written in between the backslash-parentheses are converted to nicely looking mathematical symbols. Search for "\(\rm\LaTeX\) help" and "Mathjax doc" in the right sidebar of this blog to learn more about \(\rm\LaTeX\) and Mathjax. Once you feel confident that you have learned some \(\rm\TeX/\rm\LaTeX\), you may test your skills here.

Sorry, the DISQUS comments don't allow Mathjax – or any website-injected script, for that matter.

You might say that your humble correspondent was an early adopter, probably the first personal blog with more than "hundreds" of visitors per day (4,000 in average for TRF) that installed this feature. It's easy and it just works. It was bound to spread. But it is amazing to see how slow the rest of the Internet is.

Now, more than 2 years later, the most important server for high-energy physics (and some other) preprints,, finally installed Mathjax as well. Look e.g. at the following abstract of a (very interesting) paper that was released today:
A realistic renormalizable supersymmetric \(E_6\) model
Among other things, the abstract contains this piece of mathematics:\[


\] You may see that it is being typeset using slightly different fonts. I got the \(\rm\TeX\) source simply by right-clicking the mathematical expression and choosing "show math source as \(\rm\TeX\) commands"; you are invited to go through the right-click menus. You may "disable Mathjax" by clicking at this phrase at the bottom of the arXiv page (this button may then re-enable Mathjax, and so on). The mathematical expression changes to
Well, the representations should have been written in boldface, the pluses should have been circled, and the bar's should have been overline's, i.e. the right form should have been \[

2\times({\bf 27}\oplus\overline{\bf 27})\oplus{\bf 351'} \oplus \overline{\bf 351'},

\] but let me not be too picky because the paper is nice. ;-)

Note that $...$ is the standard format to identify "inline mathematics" (in between the dollar signs) and allows that. I don't allow that because single dollar signs are reserved for financial applications. Instead, you need to type \(...\) for inline mathematics. Similarly, $$...$$ is reserved for displayed maths. This double-dollar terminology is allowed on this blog, too, but I mostly use an equivalent notation with \[...\] that you have already encountered.

Congratulations to It's not really at the forefront of the IT technologies ;-) but at least it reduced its lag to several years or decades. Authors of preprints are invited to try $...$ maths in their abstracts.

Scott Aaronson has installed Mathjax on his blog, too. You may check this comment of mine (and upvote it, to partially compensate the vandalism by a dozen of pro-global-warming imbeciles who downvoted it – and who apparently hope that quantum computing will "solve" global warming, a non-existent problem). ;-)

What about others? Mr Adam Jester Falkowski and Mr Tommaso Dorigo, open this gate! Prof Matt Strassler, tear down this wall! ;-)

Let me mention one more thing related to \(\rm\LaTeX\), more precisely ShareLaTeX previously discussed on TRF. You may now become a \(\rm\LaTeX\) adviser etc. The full (unedited) e-mail below that I received from the ShareLaTeX folks also contains links to some video lectures about \(\rm\LaTeX\) and other things.

Hi Lubos, we've been working on some more cool stuff at ShareLaTeX recently! Here are some of the highlights that we're pleased to announce:

Advisor program

You can now join the ShareLaTeX team as an official advisor. Selected advisors will
  • Teach introductory LaTeX sessions in your Institution,
  • Help us refine our LaTeX learning resources for use in your teaching sessions,
  • Give us feedback and new ideas,
  • Let us know the needs of your Institution, and
  • Get to know other advisors and the ShareLaTeX team.
There's also some other cool stuff in the works (including some freebies). If you would like to become a ShareLaTeX advisor then please apply now!

LaTeX Tutorial Videos

A lot of people find the best way to learn is via video. So we now have four different free video series on youtube (all with a corresponding blog write up and example document) for your viewing pleasure:
Group plans

We have had a lot of requests from people who want to use ShareLaTeX with their entire lab or team so we've added official group plans. With group plans you can manage your team members easily.


Finally, we have a new survey which we would really appreciate you filling in. It should only take 60 seconds and the results help us build a better product for you. Click here to help us out by filling it in.

Best Regards
Henry & James
ShareLaTeX co-founders


  1. I use it too. It produces very nice looking math stuff. Highly recommended!

  2. Sorry if you were an early adopter and I forgot about you!

  3. Yay! Great!

    I noticed the Loading [MathJaX]/... thing in LaTeX abstracts.

    Do you know why Math JaX LaTeX takes so much time to work on ArXiV, though? It is fine every where else.

    I wonder if this will make Physics.SE adopt a new policy of linking to the text-only version of the abstract page (Currently, we just have to link to the abstract and not the PDF) : )

  4. LOL, I don't know but this Mathjax in titles and abstracts is arguably the first visible improvement that Paul Ginsparg and his many employees have done since 1991, isn't it? So given their complete avoidance of all new trends in the information technologies, I am surprised that this Mathjax switch occurred at all.

  5. No need to upvote your comment on Scott's blog---he removed the upvote/downvote feature after a quick poll of readers wanted it removed.

  6. Nice that they now have LaTex on the Arxiv :-)

    LaTex, together with loading the TP data dump is the most important thing that we want to work on the new physics site too ...
    Does there exist som FM how to install the Java script on my Wordpress blog for exmple?

    Matt Strassler should not only enable LaTex, but he should make the comments up/down votable too, such that heavily downvoted comments get hidden automatically. This would largely improve his comment sections, in particular below articles where keywords such as "supersymmetry" or "string theory" are featured too prominently ...

  7. Why did Aron Scott do such a poll?

    Making comments up/down votable largely improves the comment sections.

    It is clear that uninformed trolls do not like this feature, because their comments then have a high probability to get downvoted by the more numerous reasonable but often less vocal readers ...

  8. I kind of (but not strongly) disagree with you, Dilaton.
    The upvote/downvote feature allows sock puppets of the blog dictator ( :) ) to gang up on anyone posting a different viewpoint. Also, more reticent lurkers may be put off commenting because they haven't put their toes in the water enough to tolerate some flaming (what a mangled metaphor!) It does, however, allow identification of out-and-out crackpots.

  9. I agree Dilaton (Bizarrely I can't upvote or downvote on this site - but can on other disqus sites?) I wasn't sure it was suitable for Sean Carroll's preposterousuniverse blog at first but I think it has been pretty successful there.

  10. It is not possible to install MathJaX CDN onto a WordPress.Com blog.

    It is only possible with a WordPress.Org or BloggerSpot blog.

    In fact, no java script can be added to a WordPress.Com blog. They said, when I asked them, that only giyants like Google can take such risks : )

    HOWEVER, WordPress.Com has its own option for latex. Format it like this:


    That's how I added the GS Formalism thing in the example questions.

  11. Hm sure, it can have disadvantages and bad things can happen with votable comments as you say too ;-)

    But my hope or expectation is that on physics blogs there is certain amount of reasonable people just silently lurking and reading who does not comment, but who would downvote low-level uninformed trolling comments if they have the possibility to do it.

    That is what I have seen happen below this nice guest post of Lance Dixon

    The reasonable comments got upvoted and (the astonishingly few) trolls buried in downvotes as it should be ... :-)

  12. Thanks for mentioning the Dixon guest blog on Preposterous Universe----what a masterful and interesting guest blog!

  13. Yep I liked it a lot too :-)