This post showcases KaTeX math rendering. Make sure katex: true is set in _config.yml.

Inline Math

Einstein’s famous equation \(E = mc^2\) changed physics forever. The quadratic formula \(x = \frac{-b \pm \sqrt{b^2 - 4ac}}{2a}\) solves any quadratic equation. Euler’s identity \(e^{i\pi} + 1 = 0\) is often called the most beautiful equation in mathematics.

Display Math

Fractions and Roots

\[f(x) = \frac{x^2 + 2x + 1}{x - 1}\] \[\sqrt[n]{x} = x^{\frac{1}{n}}, \quad \sqrt{\frac{a}{b}} = \frac{\sqrt{a}}{\sqrt{b}}\]

Greek Letters

\[\alpha + \beta = \gamma, \quad \Delta = \Sigma \cdot \Pi\] \[\phi = \frac{1 + \sqrt{5}}{2} \approx 1.618, \quad \lambda \in \mathbb{R}\] \[\theta, \vartheta, \Theta, \quad \epsilon, \varepsilon, \quad \rho, \varrho\]

Integrals

\[\int_0^\infty e^{-x^2}\, dx = \frac{\sqrt{\pi}}{2}\] \[\int_a^b f(x)\, dx = F(b) - F(a)\] \[\oint_C \mathbf{F} \cdot d\mathbf{r} = \iint_S (\nabla \times \mathbf{F}) \cdot d\mathbf{S}\]

Summations and Products

\[\sum_{n=0}^{\infty} \frac{x^n}{n!} = e^x\] \[\sum_{k=1}^{n} k = \frac{n(n+1)}{2}\] \[\prod_{k=1}^{n} k = n!\]

Limits and Derivatives

\[\lim_{x \to 0} \frac{\sin x}{x} = 1\] \[\lim_{n \to \infty} \left(1 + \frac{1}{n}\right)^n = e\] \[\frac{d}{dx}\left[\int_a^x f(t)\, dt\right] = f(x)\]

Vectors and Operators

\[\nabla f = \left(\frac{\partial f}{\partial x}, \frac{\partial f}{\partial y}, \frac{\partial f}{\partial z}\right)\] \[\mathbf{F} = m\mathbf{a} = m\frac{d^2\mathbf{r}}{dt^2}\] \[\hat{H}\psi = E\psi\]

Matrices

\[\begin{pmatrix} a & b \\ c & d \end{pmatrix} \begin{pmatrix} x \\ y \end{pmatrix} = \begin{pmatrix} ax + by \\ cx + dy \end{pmatrix}\] \[A = \begin{bmatrix} 1 & 2 & 3 \\ 4 & 5 & 6 \\ 7 & 8 & 9 \end{bmatrix}, \quad \det(A) = \begin{vmatrix} a & b \\ c & d \end{vmatrix} = ad - bc\]

Cases

\[f(x) = \begin{cases} x^2 & \text{if } x \geq 0 \\ -x & \text{if } x < 0 \end{cases}\] \[|x| = \begin{cases} x & \text{if } x \geq 0 \\ -x & \text{if } x < 0 \end{cases}\]

Aligned Equations

\[\begin{aligned} (a + b)^2 &= a^2 + 2ab + b^2 \\ (a - b)^2 &= a^2 - 2ab + b^2 \\ (a + b)(a - b) &= a^2 - b^2 \end{aligned}\]

Maxwell’s Equations

\[\begin{aligned} \nabla \cdot \mathbf{E} &= \frac{\rho}{\varepsilon_0} \\ \nabla \cdot \mathbf{B} &= 0 \\ \nabla \times \mathbf{E} &= -\frac{\partial \mathbf{B}}{\partial t} \\ \nabla \times \mathbf{B} &= \mu_0 \mathbf{J} + \mu_0 \varepsilon_0 \frac{\partial \mathbf{E}}{\partial t} \end{aligned}\]

Binomial and Combinatorics

\[\binom{n}{k} = \frac{n!}{k!(n-k)!}\] \[(x + y)^n = \sum_{k=0}^{n} \binom{n}{k} x^{n-k} y^k\]

Number Sets

\[\mathbb{N} \subset \mathbb{Z} \subset \mathbb{Q} \subset \mathbb{R} \subset \mathbb{C}\] \[\forall x \in \mathbb{R},\; \exists y \in \mathbb{R} : y > x\]

Logic and Sets

\[A \cup B = \{x \mid x \in A \lor x \in B\}\] \[A \cap B \subseteq A \subseteq A \cup B\] \[P \Rightarrow Q \iff \neg P \lor Q\]