# “Display math should end with $$” when using MathML with amsmath and \fbox with tex4ht I just like to get an understanding on why I get this error, only when I use MathML and not in other configurations. pdflatex work fine with this MWE. Only when there is an \fox{}, will tex4ht gives an error. The MWE is below, showing 3 cases. The case with the \fbox fails only with tex4ht, and only when using mathml. Here is the MWE \documentclass{article} \usepackage{amsmath} \begin{document} $\fbox{\sin(x)=0} % OK$ $$\sin(x)=0 \tag{1} % OK$$ $$\fbox{\sin(x)=0} \tag{1} %fails only with mathml$$ \end{document}  now, pdflatex compiles the above with no problem, here is the pdf now, tex4ht compiles it ok, with default html setting:  htlatex foo.tex "htm"  no error. HTML is generated ok. Now with I use mathml (which I wanted to do for mathjax use), I get an error >htlatex foo.tex "htm,mathml" This is pdfTeX, Version 3.1415926-2.5-1.40.14 (TeX Live 2013) restricted \write18 enabled. entering extended mode ......... (/usr/local/texlive/2013/texmf-dist/tex/generic/tex4ht/html-mml.4ht) (/usr/local/texlive/2013/texmf-dist/tex/generic/tex4ht/html4-uni.4ht)) (./foo.aux) ! Display math should end with$$.
\bgroup
l.16

?


The error is due to using \fbox{}

Any idea what is going on? Is this an tex4ht issue, or mathml or something else? The above is small example from autogenerated code by Scientific word. It is generated when I put a box around an equation in display mode.

texlive 2013, linux mint

• I get no error if I use the correct command, that is, \boxed{\sin(x)=0}. If SWP doesn't know about \boxed, which has been around for more than 20 years, I don't know what to do. – egreg Jan 6 '14 at 0:00
• I've added this to tex4ht issue tracker puszcza.gnu.org.ua/bugs/?244 – michal.h21 Feb 8 '15 at 15:05