MathJax Cheatsheet

Aus MattWiki

This is a cheat sheet on which code / markdown notation leads to which MathJax output. As MathJax seems to be somewhat compatible to LaTeX, some LaTeX Keywords seem to work too.

When using inside Obsidian.md the code representing the MathJax formular needs start and end with the dollar sign, i.e.: $a_1..a_n$

Sources

I found the following sources which helped me out:

Subscript and Superscript

Description Example Code / Markdown
Subscript a1..an
a_1..a_n
Double Subscript r01+r02+...+r0n

{r_{0_1}​​ + r_{0_2} ​+ ... + r_{0_n}

Superscript / Exponent a2+b2=c2 a^2 + b^2 = c^2
Matrix
Complex Matrix (BobAliceBob01Alice10) \begin{pmatrix} & ​Bob & Alice \\\ Bob & 0 & 1 \\\​Alice & 1 & 0  \end{pmatrix}

Subscript

a_1..a_n

a1..an

Double Subscript

{r_{0_1}​​ + r_{0_2} ​+ ... + r_{0_n}

r01+r02+...+r0n​​​

Superscript / Exponents

a^2 + b^2 = c^2

a2+b2=c2

Matrix / Matrices

\begin{pmatrix}
 & ​Bob & Alice \\\ 
Bob & 0 & 1 \\\ 
​Alice & 1 & 0  
\end{pmatrix}

(BobAliceBob01Alice10)