I’ve edited your post. When you post syntax, put it between ``` backticks. Otherwise it won’t format properly.
More forum formatting info here: Forum use and formatting tips - #3 by ariehen
I don’t have an answer to your problem. I don’t think Mathjax inside html is supported: Text in subscript in mathjax not rendered correctly when surrounded by html character code inside html list in a markdown table