# Which packages do I need to include to simulate MathJax?

I've been using Math.SE for a while, and I am comfortable with formatting math in MathJax. Now I am trying to write my first real LaTeX document on "ShareLaTeX". However, I am having trouble, because some things which format on Math.SE (such as \tag {1}) are not compiling with my current packages. I've looked through sample math documents, and what I have so far is:

\usepackage[utf8]{inputenc}
\usepackage[margin=1in]{geometry}
\usepackage{amsmath,amssymb}
\usepackage{multicol}
\usepackage{graphicx}


What are the packages I need to be able to fully emulate what I can do on Math.SE? Alternatively, is there a way for me to format math on Math.SE and download it into a nice PDF?

• It is the other way around, mathjax emulates TeX syntax. \tag works pretty OK but we need to see your code. Mathjax is a limited TeX environment if it has something TeX surely has it way more comprehensively. – percusse Sep 8 '16 at 23:07
• @percusse Sorry if I wasn't clear, I understand that MathJax is the one which emulates LaTex. But without any packages I can't format almost any math, so I would like to know the minimum packages that I need in order to be able to transfer all the stuff I wrote on MathJax to LaTex. – Ovi Sep 8 '16 at 23:16
• @percusse I am using all the packages listed in the question and \tag {1} is not compiling – Ovi Sep 8 '16 at 23:18
• \tag is for forced reference for equations. You just use $$...$$ and it will give you the tag automatically. If you also use \label{myeq} then you can refer to it via \eqref{myeq} in the text if you load amsmath – percusse Sep 8 '16 at 23:37
• \tag is defined in amsmath so if you are getting an error you have used it incorrectly, but as you have not shown how you used it and not shown the error that you got, it's not possible to help! In general the mathjax documentation for its latex support lists in each case which latex package is being emulated. see the right hand column of docs.mathjax.org/en/latest/tex.html#supported-latex-commands – David Carlisle Sep 9 '16 at 8:13

\tag is defined in amsmath so is defined if you have
\usepackage{amsmath}