$x^2=5$

In the PaperMod theme, math is rendered using $\KaTeX$. Follow instructions here to modify Hugo site pages, then use math: true in front matter to enable math rendering. Rendering also works with the front matter title!

Block elements

Code:

1
$$\displaystyle\sum\limits_{i=0}^n i^3$$

Result: ๐Ÿ’ฏ $$\displaystyle\sum\limits_{i=0}^n i^3$$

Code:

1
$$\frac{n!}{k!(n-k)!} = \binom{n}{k}$$

Result: ๐Ÿ’ฏ $$\frac{n!}{k!(n-k)!} = \binom{n}{k}$$

Code:

1
2
3
4
5
$$f(n) =
  \begin{cases}
    n/2       & \quad \text{if } n \ge 0\\
    -(n+1)/2  & \quad \text{if } n \lt 0
  \end{cases}$$

Result: ๐Ÿ˜ญ $$f(n) = \begin{cases} n/2 & \quad \text{if } n \ge 0\ -(n+1)/2 & \quad \text{if } n \lt 0 \end{cases}$$

It should look like this: