# Canonical class

The class $K_X$ of divisors, with respect to linear equivalence on an algebraic variety $X$, which are divisors of differential forms $\omega$ of maximal degree. If $X$ is a non-singular algebraic variety of dimension $n$, then in local coordinates $x_1,\ldots,x_n$ a form $\omega$ can be written as $$\omega = f(x_1,\ldots,x_n) \, dx_1 \wedge \cdots \wedge dx_n \ .$$
The divisor $(\omega)$ of $\omega$ is locally equal to the divisor $(f)$ of this rational function $f$. This construction does not depend on the choice of local coordinates and gives the divisor $(\omega)$ of $\omega$ on all of $X$. Since for any other form $\omega'$ of the same degree as $\omega$, $\omega' = g\omega$, it follows that $(\omega') = (g) + (\omega)$, and corresponding divisors are equivalent. The canonical class $K_X$ thus constructed is the first Chern class of the sheaf $\Omega_X^n$ of regular differential forms of degree $n$. Its numerical characteristics (degree, index, self-intersections, etc.) are effectively calculable invariants of the algebraic variety.
If $X$ is a non-singular projective curve of genus $g$, then $\deg K_X = 2g-2$. For elliptic curves and, more generally, for Abelian varieties, $K_X = 0$. If $X$ is a non-singular hypersurface of degree $d$ in projective space $\mathbf{P}^n$, then $K_X = (d-n-1)H$, where $H$ is a hyperplane section of it.