moved mathjax magic to Rmd