Skip to content

Instantly share code, notes, and snippets.

@sohang3112
Last active January 14, 2026 04:56
Show Gist options
  • Select an option

  • Save sohang3112/9228825c4a688e2edb3592fb92babaae to your computer and use it in GitHub Desktop.

Select an option

Save sohang3112/9228825c4a688e2edb3592fb92babaae to your computer and use it in GitHub Desktop.
Notes on MathJAX (a Latex-like mini language using which pretty math expressions can be embedded in Github Markdown documents)

MathJAX NOTES

Reference: MathJAX Macros table - macros start with \. Github Markdown allows a limited subset of MathJAX and no MathJAX extensions can be used. But in static site generators, extensions can be installed using <script> tag.

Inline expressions are written within $ $, block expressions within $$ $$. Curly Brackets { } are required for grouping multiple symbols where otherwise only a single character/symbol is expected

  • eg. after _ (superscript under) and ^ (power/subscript over).

Notably MathJAX rendered by ChatGPT is a slightly different dialect - eg. it uses ( ) delimiters for inline expressions and [ ] for block expressions.

Some common function usages are:

MathJAX Code Rendered Output Description
$\min\limits_{x,y} f(x,y)$ $\min\limits_{x,y} f(x,y)$ Put limits directly under previous symbol \min
\emptyset $\emptyset$ Empty (Null) set
E \cup F, E \cap F $E \cup F, E \cap F$ Set union, intersection
\mathbf{x} $\mathbf{x}$ Indicate x is a vector
\mathbb{R}, \mathbb{C} $\mathbb{R}, \mathbb{C}$ Number systems / sets (Real numbers set, Complex numbers)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment