[tex4ht] [bug #481] Problem with Braces / Brackets in Maths equations using mk4ht latex->mathml

Michal Hoftich michal.h21 at gmail.com
Fri Aug 21 10:54:54 CEST 2020


Hi Nasser,

>After changing the command and adding "mathml", now some
>of my latex files no longer compile.
>
>Please see this MWE
>
>\documentclass{article}
>\usepackage{amsmath}
>\begin{document}
>$n^\text{th}$
>\end{document}
>
>THe above used to compile OK using
>
>         make4ht filename.tex "mathjax,htm"
>
>But now using
>
>         make4ht filename.tex "mathml,mathjax,htm"
>
>it gives error

I can confirm this issue. BTW, you will get this error even without the 
"mathml" option. It is a know issue, see:

https://tug.org/tex4ht/doc/mml.html

Quoting:

> Missing grouping for subscripts and suprscripts, such as 
> ‘A_\mathit{...}’ instead of ‘A_{\mathit{...}}’. (LaTeX allows indirect 
> access to the content of the operands; TeX4ht requires direct access.) 

So the correct way is "$n^{\text{th}}$". I know that your files are 
automatically generated so it is not something easilly solvable. 

You will not get this error with "mathjax" option, without "mathml", so 
you may want to stick to it.

Best regards,
Michal


More information about the tex4ht mailing list.