// latex cheat sheet
Quick reference for writing math in Blogger posts. Wrap display math in $$...$$ and inline math in \(...\)
Display math (centered, own line):
Inline math (inside a sentence):
$$your equation here$$Inline math (inside a sentence):
\(your equation here\)
Set Theory
\in | ∈ — element of | x \in A |
\notin | ∉ — not element of | x \notin A |
\subset | ⊂ — proper subset | A \subset B |
\subseteq | ⊆ — subset or equal | A \subseteq B |
\supset | ⊃ — proper superset | A \supset B |
\cup | ∪ — union | A \cup B |
\cap | ∩ — intersection | A \cap B |
\setminus | ∖ — set difference | A \setminus B |
\emptyset | ∅ — empty set | \emptyset |
\mathcal{P}(A) | 𝒫(A) — power set | \mathcal{P}(A) |
|A| | cardinality | |A| = 5 |
\times | × — Cartesian product | A \times B |
Set Builder Notation
$$A = \{x \in \mathbb{Z} : 0 \leq x^3 < 100\}$$
Number Sets
\mathbb{N} | ℕ — natural numbers | |
\mathbb{Z} | ℤ — integers | |
\mathbb{Q} | ℚ — rationals | |
\mathbb{R} | ℝ — reals | |
\mathbb{C} | ℂ — complex numbers | |
\mathbb{Z}^+ | ℤ⁺ — positive integers |
Logic & Propositional Calculus
\land | ∧ — and (conjunction) | p \land q |
\lor | ∨ — or (disjunction) | p \lor q |
\lnot | ¬ — not (negation) | \lnot p |
\implies | ⟹ — implies | p \implies q |
\iff | ⟺ — if and only if | p \iff q |
\oplus | ⊕ — exclusive or (XOR) | p \oplus q |
\forall | ∀ — for all | \forall x \in A |
\exists | ∃ — there exists | \exists x \in A |
\nexists | ∄ — there does not exist | \nexists x |
\top | ⊤ — tautology / true | |
\bot | ⊥ — contradiction / false |
Relations & Ordering
\leq | ≤ — less than or equal | x \leq y |
\geq | ≥ — greater than or equal | x \geq y |
\neq | ≠ — not equal | x \neq y |
\equiv | ≡ — equivalent / congruent | a \equiv b \pmod{n} |
\approx | ≈ — approximately equal | |
\sim | ∼ — similar / related | a \sim b |
\mid | ∣ — divides | a \mid b |
\nmid | ∤ — does not divide | a \nmid b |
Proof & Reasoning
\therefore | ∴ — therefore | |
\because | ∵ — because | |
\square | □ — QED / end of proof | |
\blacksquare | ■ — QED (filled) | |
\contradiction | ↯ — contradiction |
Functions & Algebra
\frac{a}{b} | fraction | \frac{x+1}{x-1} |
\sqrt{x} | square root | \sqrt{x^2+y^2} |
\sqrt[n]{x} | nth root | \sqrt[3]{8} |
x^{n} | superscript / exponent | x^{n+1} |
x_{n} | subscript | a_{n} |
\lfloor x \rfloor | ⌊x⌋ — floor | |
\lceil x \rceil | ⌈x⌉ — ceiling | |
\bmod | mod operator | a \bmod n |
\pmod{n} | modulo (in parens) | a \equiv b \pmod{n} |
Summation & Products
\sum_{i=0}^{n} | summation | \sum_{i=1}^{n} i = \frac{n(n+1)}{2} |
\prod_{i=0}^{n} | product | \prod_{i=1}^{n} i = n! |
n! | factorial | |
\binom{n}{k} | binomial coefficient C(n,k) | \binom{n}{k} = \frac{n!}{k!(n-k)!} |
Matrices & Vectors
2×2 matrix:
System of equations:
$$\begin{pmatrix} a & b \\ c & d \end{pmatrix}$$System of equations:
$$\begin{cases} 2x + y = 5 \\ x - y = 1 \end{cases}$$
Spacing (inside equations)
\; | thick space | |
\, | thin space | |
\quad | large space | |
\qquad | extra large space | |
\text{and} | regular text inside math | x \in A \text{ and } x > 0 |
Ready-to-Use Examples
Divisibility definition:
Modular arithmetic:
Set intersection:
Summation formula:
Binomial coefficient:
Proof by contradiction opener (inline):
$$a \mid b \iff \exists k \in \mathbb{Z} : b = ka$$Modular arithmetic:
$$a \equiv b \pmod{n} \iff n \mid (a - b)$$Set intersection:
$$A \cap B = \{x : x \in A \land x \in B\}$$Summation formula:
$$\sum_{i=1}^{n} i = \frac{n(n+1)}{2}$$Binomial coefficient:
$$\binom{n}{k} = \frac{n!}{k!(n-k)!}$$Proof by contradiction opener (inline):
Assume \(p\) is prime and \(p \mid ab\) but \(p \nmid a\) and \(p \nmid b\).
0 comments