In arithmetic topology, every prime number \(p\) in \(\mathbb{Z}\) is depicted as a knot in a fixed 3-fold. Since all primes sit in the same 3-fold, one might hope to obtain invariants of a set \(T\) of primes in terms of these knots - and indeed one does: One such example is the linking number of two knots, counting how many times a knot \(L\) "wraps around" a knot \(K\). In the number-theoretical context – modulo 2 – this is roughly the Legendre symbol. The symmetry of the linking number implies Gauss' quadratic reciprocity law.
One depicts primes as knots via a gadget that associates to every ring \(R\) (commutative, with unit) a "homotopy type": to an algebraically-closed field \(k\) we associate a point; if \(k\) is any field, then the homotopy type associated to \(k\) is \(K(G,1)\), where \(G\) is the absolute Galois group of \(k\); the homotopy type associated to \(\mathbb Z\) has cohomological dimension 3.
The analogies between knot theory and number theory are rich: many topological notions such as tubular neighborhoods - punctured or not, knot groups etc. admit an algebraic counterpart. Some notions are subtler than one would initially imagine. Such is the punctured neighborhood of a knot, which is a strangely twisted torus. Orientability in the number theoretical setting is a more delicate matter.