# Basic criterion for affineness of schemes

Given a scheme $X$, we can construct a canonical map $\varphi:X\rightarrow \text{Spec}(\mathcal{O}_X(X))$ by attaching to every point $x\in X$ the prime ideal in $\mathcal{O}_X(X)$ given by taking the inverse image of the maximal ideal of $\mathcal{O}_{X,x}$ under the map $\mathcal{O}_X(X)\rightarrow\mathcal{O}_{X,x}$.

This map $\varphi: X\rightarrow \text{Spec}(\mathcal{O}_X(X))$ can be extended to a morphism of schemes by defining $\varphi^{\sharp}_{X_a}: \mathcal{O}_X(X)_a\rightarrow \mathcal{O}_X(X_a)$ as the extension of the restriction map $\mathcal{O}_X(X)\rightarrow \mathcal{O}_X(X_a)$.

Now my question is the following

Suppouse the map $\varphi:X\rightarrow \text{Spec}(\mathcal{O}_X(X))$ is bijective (as a map between sets). Is it true that it should be an isomorphism?

This is a slightly improved version of this criterion.

• What is the set $X_a$? May 2, 2018 at 8:49
• $a$ belongs to $\mathcal{O}_X(X)$ and $X_a$ is the set of all $x\in X$ such that $a_x$ is invertible in $\mathcal{O}_{X,x}$. If $X$ is affine $X_a$ is just the principal open subset of $a$, so you can think of this as the generalization of this sets to non affine schemes. In other words, $X_a$ is "the set of points where the function $a$ don't vanish". May 2, 2018 at 10:41