Canonical: https://knowlpedia.com/convex-analysis/codimension/

# Codimension

The dimension of the quotient space X/L for a subspace L⊂X.

Let \(X\) be a [vector space](https://knowlpedia.com/linear-algebra/vector-space/) and let \(L\subset X\) be a [linear subspace](https://knowlpedia.com/convex-analysis/linear-subspace/). The **codimension** of \(L\) in \(X\) is
\[
\operatorname{codim}(L):=\dim(X/L),
\]

where \(X/L\) is the [quotient space](https://knowlpedia.com/convex-analysis/quotient-vector-space-codimension/) of \(X\) by \(L\).

Codimension measures "how many independent linear constraints" define \(L\). Codimension one subspaces play a special role in the geometry of [hyperplanes](https://knowlpedia.com/convex-analysis/hyperplane/).

## Examples

- In \(\mathbb{R}^n\), a hyperplane through the origin has codimension \(1\).
- If \(L=\{0\}\) and \(\dim X=n<\infty\), then \(\operatorname{codim}(L)=n\).
