Canonical: https://knowlpedia.com/algebraic-geometry-foundations/affine-scheme/

# Affine scheme

A locally ringed space obtained as the prime spectrum of a commutative ring.

An **affine scheme** is a [locally ringed space](https://knowlpedia.com/algebraic-geometry-foundations/locally-ringed-space/) isomorphic to
\[
(\operatorname{Spec}A,\mathcal O_{\operatorname{Spec}A})
\]
for some [commutative ring](https://knowlpedia.com/algebra-rings/commutative-ring/) \(A\). Here \(\operatorname{Spec}A\) is the [prime spectrum](https://knowlpedia.com/algebra-commutative/prime-spectrum/) with its [Zariski topology](https://knowlpedia.com/algebra-commutative/zariski-topology/), and \(\mathcal O_{\operatorname{Spec}A}\) is its [structure sheaf](https://knowlpedia.com/algebraic-geometry-foundations/structure-sheaf/). The ring is recovered from global sections:
\[
\Gamma(\operatorname{Spec}A,\mathcal O_{\operatorname{Spec}A})\cong A.
\]

## Examples

For example, if \(k\) is a field, \(\operatorname{Spec}k\) is a one-point affine scheme whose local ring is \(k\). The [affine line](https://knowlpedia.com/algebraic-geometry-foundations/affine-line/) \(\operatorname{Spec}k[x]\) is another affine scheme, but it contains more than the familiar \(k\)-valued points: it also has points corresponding to other prime ideals, including a [generic point](https://knowlpedia.com/algebraic-geometry-foundations/generic-point/). General [schemes](https://knowlpedia.com/algebraic-geometry-foundations/scheme/) are assembled by gluing affine schemes along open subsets.
