MathJax Cheat Sheet: Unterschied zwischen den Versionen
Aus Matts Wiki
Matt (Diskussion | Beiträge) |
Matt (Diskussion | Beiträge) |
||
| (8 dazwischenliegende Versionen desselben Benutzers werden nicht angezeigt) | |||
| Zeile 11: | Zeile 11: | ||
== Cheatsheet == | == Cheatsheet == | ||
=== Formatting === | |||
{| class="wikitable" style="background-color:#ffffff;" | {| class="wikitable" style="background-color:#ffffff;" | ||
!Description | !Description | ||
| Zeile 35: | Zeile 37: | ||
|<math>r_{0_1} + r_{0_2} + ... + r_{0_n}</math> | |<math>r_{0_1} + r_{0_2} + ... + r_{0_n}</math> | ||
|<code>{r_{0_1} + r_{0_2} + ... + r_{0_n}</code> | |<code>{r_{0_1} + r_{0_2} + ... + r_{0_n}</code> | ||
|} | |||
=== Arithmetic === | |||
{| class="wikitable" style="background-color:#ffffff;" | |||
!Description | |||
!Example | |||
!LaTeX Code / Markdown | |||
|- | |||
|times | |||
|<math>a \cdot b</math> | |||
|<code>a \cdot b</code> | |||
|- | |||
|times | |||
|<math>a \times b</math> | |||
|<code>a \times b</code> | |||
|- | |||
|divided by | |||
|<math>a \div b</math> | |||
|<code>a \div b</code> | |||
|- | |||
|plus minus | |||
|<math>\pm x</math> | |||
|<code>\pm x</code> | |||
|- | |||
|minus plus | |||
|<math>\mp x</math> | |||
|<code>\mp x</code> | |||
|- | |||
|equal | |||
|<math>=</math> | |||
|<code>\=</code> | |||
|- | |||
|not equal | |||
|<math>\neq</math> | |||
|<code>\neq</code> | |||
|- | |||
|around | |||
|<math>\approx</math> | |||
|<code>\approx</code> | |||
|- | |||
|less than or equal | |||
|<math>a \le b</math> | |||
|<code>a \le b</code> or <code>a \leq b</code> | |||
|- | |||
|less than or equal | |||
|<math>a \leqq b</math> | |||
|<code>a \leqq b</code> | |||
|- | |||
|greater than or equal | |||
|<math>a \ge b</math> | |||
|<code>a \ge b</code> or <code>a \geq b</code> | |||
|- | |||
|greater than or equal | |||
|<math>a \geqq b</math> | |||
|<code>a \geqq b</code> | |||
|} | |||
=== Symbols === | |||
{| class="wikitable" style="background-color:#ffffff;" | |||
!Description | |||
!Example | |||
!LaTeX Code / Markdown | |||
|- | |||
|Infinity | |||
|<math>\infty</math> | |||
|<code>\infty</code> | |||
|- | |||
|Absolute | |||
|<math>\vert x \vert</math> | |||
|<code>\vert x \vert</code> | |||
|- | |- | ||
|Overline one character | |Overline one character | ||
| Zeile 51: | Zeile 123: | ||
|<math>\widehat {ab}</math> | |<math>\widehat {ab}</math> | ||
|<code>\widehat {ab}</code> | |<code>\widehat {ab}</code> | ||
|- | |||
|Sum of a set | |||
|<math>\sum_{i=1}^n a_i</math> | |||
|<code>\sum_{i=1}^n a_i</code> | |||
|- | |||
|Sum of a set (larger) | |||
|<math>\displaystyle \sum_{i=1}^n a_i</math> | |||
|<code>\displaystyle \sum_{i=1}^n a_i</code> | |||
|} | |||
=== Greek Letters === | |||
{| class="wikitable" style="background-color:#ffffff;" | |||
!Description | |||
!Example | |||
!LaTeX Code / Markdown | |||
|- | |||
|phi | |||
|<math>\phi</math> | |||
|<code>\phi</code> | |||
|- | |||
|epsilon | |||
|<math>\epsilon</math> | |||
|<code>\epsilon</code> | |||
|- | |||
|sigma | |||
|<math>\sigma</math> | |||
|<code>\sigma</code> | |||
|} | |||
=== Constants === | |||
{| class="wikitable" style="background-color:#ffffff;" | |||
!Description | |||
!Example | |||
!LaTeX Code / Markdown | |||
|- | |||
|Pi | |||
|<math>\pi</math> | |||
|<code>\pi</code> | |||
|- | |||
|Euler's Number | |||
|<math>\mathrm{e}</math> | |||
|<code>\mathrm{e}</code> | |||
|} | |||
=== Matrices === | |||
{| class="wikitable" style="background-color:#ffffff;" | |||
!Description | |||
!Example | |||
!LaTeX Code / Markdown | |||
|- | |- | ||
|Matrix with Parentheses | |Matrix with Parentheses | ||
| Zeile 57: | Zeile 178: | ||
1 & 0 | 1 & 0 | ||
\end{pmatrix}</math> | \end{pmatrix}</math> | ||
| | | | ||
\begin{pmatrix} | \begin{pmatrix} | ||
0 & 1 \\ | 0 & 1 \\ | ||
1 & 0 | 1 & 0 | ||
\end{pmatrix} | \end{pmatrix} | ||
|- | |||
|Matrix with Brackets | |||
|<math>\begin{bmatrix} | |||
0 & 1 \\ | |||
1 & 0 | |||
\end{bmatrix}</math> | |||
| | |||
\begin{bmatrix} | |||
0 & 1 \\ | |||
1 & 0 | |||
\end{bmatrix} | |||
|- | |- | ||
|Complex Matrix with Parentheses | |Complex Matrix with Parentheses | ||
Aktuelle Version vom 20. September 2025, 20:47 Uhr
This is a cheat sheet on which code / markdown notation leads to which MathJax output.
MathJax is an open-source JavaScript display engine for LaTeX, MathML, and AsciiMath notation that works in all modern browsers.
MathJax in Obsidian.md
When using MathJax inside Obsidian.md the markdown code representing the MathJax formula needs start and end with the dollar sign, i.e.: $a_1..a_n$
In order to show fractions a little bit bigger and centered use two dollar signs, i.e.: $$a = \frac{\sqrt{b^2 + c^2}}{2}$$
Printing little bigger works too with $\displaystyle$ ahead of the fraction
Cheatsheet
Formatting
| Description | Example | LaTeX Code / Markdown |
|---|---|---|
| Fractions | \frac{km}{h}
| |
| Text with spaces | \text{kilometers or miles}
| |
| Superscript / Exponent | a^2 + b^2 = c^2
| |
| Subscript | a_1..a_n
| |
| Double Subscript | {r_{0_1} + r_{0_2} + ... + r_{0_n}
|
Arithmetic
| Description | Example | LaTeX Code / Markdown |
|---|---|---|
| times | a \cdot b
| |
| times | a \times b
| |
| divided by | a \div b
| |
| plus minus | \pm x
| |
| minus plus | \mp x
| |
| equal | \=
| |
| not equal | \neq
| |
| around | \approx
| |
| less than or equal | a \le b or a \leq b
| |
| less than or equal | a \leqq b
| |
| greater than or equal | a \ge b or a \geq b
| |
| greater than or equal | a \geqq b
|
Symbols
| Description | Example | LaTeX Code / Markdown |
|---|---|---|
| Infinity | \infty
| |
| Absolute | \vert x \vert
| |
| Overline one character | \overline a
| |
| Overline multiple characters | \overline {AB}
| |
| Hat over one character | \hat a
| |
| Hat over two characters | \widehat {ab}
| |
| Sum of a set | \sum_{i=1}^n a_i
| |
| Sum of a set (larger) | \displaystyle \sum_{i=1}^n a_i
|
Greek Letters
| Description | Example | LaTeX Code / Markdown |
|---|---|---|
| phi | \phi
| |
| epsilon | \epsilon
| |
| sigma | \sigma
|
Constants
| Description | Example | LaTeX Code / Markdown |
|---|---|---|
| Pi | \pi
| |
| Euler's Number | \mathrm{e}
|
Matrices
| Description | Example | LaTeX Code / Markdown |
|---|---|---|
| Matrix with Parentheses |
\begin{pmatrix}
0 & 1 \\
1 & 0
\end{pmatrix}
| |
| Matrix with Brackets |
\begin{bmatrix}
0 & 1 \\
1 & 0
\end{bmatrix}
| |
| Complex Matrix with Parentheses |
\begin{pmatrix}
& Bob & Alice \\
Bob & 0 & 1 \\
Alice & 1 & 0
\end{pmatrix}
|
Sources
I found the following sources which helped me out:
- https://de.wikipedia.org/wiki/Liste_mathematischer_Symbole (German)
- https://en.wikipedia.org/wiki/Glossary_of_mathematical_symbols
- https://math.meta.stackexchange.com/questions/5020/mathjax-basic-tutorial-and-quick-reference
- https://easy-copy-mathjax.nakaken88.com/en/matrix/
- https://jojozhuang.github.io/tutorial/mathjax-cheat-sheet-for-mathematical-notation/
- https://bearnok.com/grva/en/knowledge/software/mathjax
