Miscellaneous symbols

In 1655 the Oxford mathematician John Wallis, writing about conic sections, put down a sideways figure eight that nobody had used before — the birth of ∞. The miscellaneous symbols on this page — the LaTeX marks \infty, \partial, \nabla, \ell, \hbar, \dagger and their neighbours, which belong to none of the Greek-letter, operator, relation or arrow families — all arrived the same way: somebody invented one, once, and it stayed. What follows traces the ones you actually type, grouped by where they came from and what they are for: which are standard LaTeX and which need amssymb, and how to avoid the classic mix-ups such as \ell against a plain l, or \prime against an apostrophe.

Why \infty in text gives ! Missing $ inserted

Because almost every symbol here is a math-mode-only command. Type \infty straight into running text and LaTeX answers ! Missing $ inserted, then tries to supply the $ for you. To TeX, ∞ is not a picture but an atom classed as ordinary, and the spacing that follows from that class is simply undefined outside math mode. So you wrap it: $\infty$. The exceptions are the marks designed for running text — the section sign \S (§), the paragraph sign \P (¶), \copyright (©), and the daggers \dag and \ddag — which work in text mode as they stand.

document.tex
\usepackage{amssymb}   % needed for \varnothing, \square, \measuredangle, \circledR
% ...
The volume $V$ diverges to $\infty$, and the gradient is $\nabla f$.
\[
  \frac{\partial f}{\partial x}, \qquad \angle ABC = 90^\circ, \qquad \hbar\omega
\]

The other dividing line is the package rule. \infty, \partial, \nabla, \angle, \ell, \hbar, \Re, \Im, \wp, \aleph, \surd, \prime, \dagger, \ddagger, \forall, \exists, \neg, \top, \bot, \emptyset, \flat, \sharp and \natural are all standard LaTeX and need no package at all. By contrast \varnothing (the rounded variant of ∅), \square (□), \measuredangle (∡), \circledR (®) and the Hebrew \beth (ℶ) are AMS additions: forget \usepackage{amssymb} in the preamble and the run stops with ! Undefined control sequence. When that error appears, suspect the package before you suspect your spelling.

Where ∞, ∂, ∇ and ∠ came from

Each was brought in by one writer and adopted by the next generation. \infty (∞) first appears in Wallis's De sectionibus conicis of 1655, and he never explained why he chose that shape. \partial (∂) — the rounded d — was used for partial derivatives by Legendre in 1786, who then abandoned it; Jacobi revived it in 1841 and it stuck. The best story belongs to \nabla (∇). The name "nabla" was suggested by the encyclopedist William Robertson Smith in an 1870 letter to Peter Guthrie Tait: the inverted delta looked to him like a Phoenician harp, Greek νάβλα. Tait and Maxwell went on using the nickname half-jokingly in their private correspondence, and it ended up in textbooks worldwide.

In practice, all four invite mix-ups with look-alikes, and the typesetter will not warn you. \nabla (∇) and capital delta \Delta (Δ) differ only by being upside down, so typing Δ where you meant a gradient compiles perfectly happily. Always write \partial as a command rather than substituting an italic d, or readers lose the distinction between a total and a partial derivative. \infty is used inside subscripts far more often than on its own — \lim_{n \to \infty}, \int_0^{\infty} — and in those positions it is set smaller automatically. \surd (√) is only the tick of the radical sign; its bar does not stretch, so to set an actual square root use the argument-taking \sqrt{x}. \angle (∠) is standard, but the measured angle \measuredangle (∡) and the spherical angle \sphericalangle (∢) need amssymb.

CommandGlyphMeaning / use
\inftyinfinity; standard; common in \lim_{n \to \infty}
\partialthe round d of partial derivatives; standard; never substitute d
\nablanabla / del (grad, div, curl); standard; do not confuse with \Delta
\angleangle; standard; \measuredangle ∡ needs amssymb
\surdthe radical tick only; standard; for square roots use \sqrt{x}
\primeprime; standard; normally written f'

When a letter becomes a symbol: ℓ, ℏ, ℜ, ℘, ℵ

These began life as letters and, by a change of typeface or the addition of a stroke, took on meanings of their own. \ell (ℓ) is a script lowercase l, used for lengths, lines and sequence indices. \hbar (ℏ) is an h with a bar through it, standing for the reduced Planck constant h/2π — a perfect example of physics naming, where one extra stroke makes a different constant. \wp (℘) is a calligraphic p for the Weierstrass elliptic function, and \aleph (ℵ) is the Hebrew letter aleph for infinite cardinals. \Re and \Im give the real and imaginary parts of a complex number, and what they output is not a roman R and I but Fraktur ℜ and ℑ. All are standard LaTeX; amssymb is not required.

Two practical judgements follow. First, Fraktur ℜ and ℑ look somewhat old-fashioned on a modern page, and readers do misread them as R and I. If you want an upright "Re" or "Im" set as an operator, the current convention is \operatorname{Re} and \operatorname{Im} from amsmath, which also gets the surrounding spacing right for an operator. Second, \aleph is standard, but the Hebrew letters that follow aleph — beth ℶ, gimel ℷ, daleth ℸ (\beth, \gimel, \daleth) — require amssymb. That is almost always the reason a set-theory paper stops at ! Undefined control sequence on a ℶ.

CommandGlyphMeaning / use
\ellscript lowercase l (lengths, lines); standard
\hbarreduced Planck constant h/2π; standard
\Rereal part; Fraktur; upright form is \operatorname{Re}
\Imimaginary part; Fraktur; upright form is \operatorname{Im}
\wpWeierstrass p (elliptic function); standard
\alephaleph (infinite cardinals); standard
\bethbeth (cardinals); needs amssymb

Quantifiers, negation, ⊤/⊥ and the empty set

The logic marks \forall (∀), \exists (∃), \neg (¬, also \lnot), \top (⊤) and \bot (⊥) are all standard LaTeX. ∀ is an upside-down A for "all" and ∃ a reversed E for "exists" — the shapes carry their own etymology. One distinction repays knowing: \bot versus \perp. The glyph is ⊥ in both cases, but \bot is registered as an ordinary symbol and \perp as a relation, so the space set around them differs. Write \bot for falsity or a least element, and \perp for the relation of perpendicularity, as in AB \perp CD. By the same logic \top serves for truth or a greatest element. Only the negated quantifier \nexists (∄) needs amssymb.

The empty set comes in two spellings. Standard \emptyset is a slashed ellipse, and in Computer Modern it can read as a squashed zero. The \varnothing of amssymb is a slashed circle, and many authors prefer it precisely because it reads at a glance as "not a zero". Either is acceptable — but do not mix them within one document; a reviewer will notice every time. If you go with \varnothing, remember \usepackage{amssymb}, or you get ! Undefined control sequence. The full picture of quantifiers and set operations is on the set and logic symbols page.

CommandGlyphMeaning / use
\foralluniversal quantifier, "for all"; standard
\existsexistential quantifier, "there exists"; standard
\neg¬negation; same as \lnot; standard
\toptruth / greatest element; ordinary symbol; standard
\botfalsity / least element; ordinary symbol; for perpendicular use \perp
\emptysetempty set (slashed ellipse); standard
\varnothingempty set (rounded variant); needs amssymb

Daggers † ‡, and the ∎ that closes a proof

The dagger \dagger (†) and double dagger \ddagger (‡) are both standard LaTeX math-mode symbols. For footnote marks in running text there are the text-mode \dag and \ddag. Inside a formula, though, † means not a footnote but the adjoint, or Hermitian conjugate: A^{\dagger} is read "A dagger", and the creation operator a^{\dagger} of quantum mechanics is the same thing. Because it almost always sits in a superscript, you rarely type \dagger on its own.

The hollow square ∎ that ends a proof is called the tombstone, or the Halmos symbol. The arrows page mentions in passing that Paul Halmos brought it into mathematics; there is a little more to the story. In his memoir I Want to Be a Mathematician, Halmos writes that the symbol was not his invention at all — he had seen it in popular magazines, nothing to do with mathematics, where it marked the end of an article, and borrowed it. He first used it in a mathematical context in 1950. In LaTeX you can set it as \square (□) or \blacksquare (■) from amssymb, but in practice the proof environment of amsthm appends it for you. Use \qedhere when you need to control where it lands, and \renewcommand{\qedsymbol}{...} to change the mark itself.

CommandGlyphMeaning / use
\daggermath mode; adjoint A^{\dagger}; standard
\ddaggerdouble dagger, math mode; standard
\dagtext mode; for footnote marks; standard
\squarewhite square / QED mark; needs amssymb
\blacksquareblack square; needs amssymb

Setting ♭, ♯ and ♮ — and why \sharp is not #

The three accidentals — flat \flat (♭), sharp \sharp (♯) and natural \natural (♮) — are standard LaTeX math symbols. Even in running text you enter math mode for them: B$\flat$ or $B\flat$. The trap here is #. To TeX, # is the special character that marks a macro argument, so writing it in text is an error; to print it you must escape it as \#. And what \# prints is the number sign, not the musical sharp ♯ — two different characters with different shapes and different slants. Write $C\sharp$ for the note and C\# for the programming language. Setting actual sheet music is another matter, handled by dedicated systems.

CommandGlyphMeaning / use
\flatflat; math mode; standard
\sharpsharp; not the same as \#; standard
\naturalnatural; math mode; standard

Three look-alikes: \ell vs l, \prime vs ', \Re vs R

First, \ell (ℓ) against a math-italic l. In many math fonts the italic lowercase l is nearly indistinguishable from the digit 1 and from a vertical bar |, and the script ℓ exists precisely to avoid that. For quantities you want read as "l" — lengths, lines, indices — \ell is the safe choice. What you must not do is use \ell and l for two different quantities in the same document: readers will confuse them, every time. Pick one. For the same reason, accents over i and j sit on the dotless \imath (ı) and \jmath (ȷ): \hat{i} collides the dot with the hat, so write \hat{\imath}.

Next, \prime (′) against the apostrophe. In math mode ' is shorthand for ^{\prime}, so f' and f^{\prime} produce exactly the same thing. Writing a bare \prime puts a superscript-sized glyph down on the baseline and looks wrong, so it is almost never used on its own. TeX handles a run of primes together with a ^ that immediately follows, which is why x'^2 sets without complaint. What breaks is the reverse order: x^2' is read as x^2^{\prime} and stops with ! Double superscript. There, spell out the intent as {x^2}' or x^{2\prime}. And note that a ' in running text is a right single quote, not a prime.

Third, \Re against R. What \Re sets is the Fraktur ℜ, an entirely different symbol from , the set of real numbers (\mathbb{R} from amssymb or amsfonts). "The real part of z" is \Re z or \operatorname{Re} z; "z is real" is z \in \mathbb{R}. Mix the two and your reader will misread several lines before noticing. The same caution applies to \Im and \mathbb{I}.

latex
% x'^2 is fine; x^2' raises ! Double superscript.
\[ f'(x), \quad f''(x), \quad x'^2, \quad {x^2}' \]
% real part vs the set of real numbers
\[ \Re z, \qquad \operatorname{Re} z, \qquad z \in \mathbb{R} \]
% dotless bases keep the accent clear
\[ \hat{\imath}, \quad \hat{\jmath}, \quad \ell = 2\pi r \]

For any symbol not covered here, the final answer is Scott Pakin's Comprehensive LaTeX Symbol List (ctan.org/pkg/comprehensive), which catalogues more than twenty thousand symbols — 20,323 in the edition shipped with TeX Live 2024 — together with the commands and packages that produce them. Almost any "how do I type this glyph" question ends there.