TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am trying to use Anki to create calculus flash cards. I use the input box on the math.stackexchange.com site since it is the easiest LaTex editor I know of to use for math equations. However, I spend a lot of time trying to fix errors because of differences in the way the code is compiled in Anki, which is probably due to differences in the preamble between Anki and math.stackexchange. Is there a way to find out what they use?

share|improve this question
Math.SE uses MathJax which is not (La)TeX, although it uses mostly LaTeX syntax. There is no preamble nor any TeX processing of the input. – egreg Jun 15 '13 at 23:04
up vote 8 down vote accepted

As it has been already answered, math.SE uses MathJax in order to display math equations specified in a TeX notation.

It is possible to reuse codes from math.SE in your document, by loading the right packages. With a look into the math.SE source code, you can find the following line, which calls MathJaX:

<script type="text/javascript" 

As you can read in the MathJaX Documentation, the TeX-AMS_HTML option "allows math to be specified in TeX or LaTeX notation, with the AMSmath and AMSsymbols packages included".

You should be able to reuse any equation from math.SE by loading amsmath and amssymb packages in your preamble:


It also works with Anki: in Anki2, go into the Option button in the Manage note types dialog, and add those two packages in the preamble. In Anki1, you can change the preamble in Settings > Deck Properties.

share|improve this answer

enter image description here

Installing and Testing MathJax

The easiest way to use MathJax is to link directly to the MathJax distributed network service (see Using the MathJax CDN). In that case, there is no need to install MathJax yourself, and you can begin using MathJax right away; skip this document on installation and go directly to Configuring MathJax.

MathJax can be loaded from a public web server or privately from your hard drive or other local media. To use MathJax in either way, you will need to obtain a copy of MathJax. There are three ways to do this: via git, svn, or via a pre-packaged archive. We recommend git or svn, as it is easier to keep your installation up to date with these tools.


More details, visit MathJax.

share|improve this answer
I got some reputations only by copying and pasting. A nice job for today. Thank you! – kiss my armpit Jun 16 '13 at 11:28
that happens :) I got most votes for this answer of mine before I made the edit when it only contained a quote. – clemens Jun 16 '13 at 13:07

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.