# Ring-theoretic characterization of open affines?

### Background

Recall that, given two commutative rings $A$ and $B$, the set of morphisms of rings $A\to B$ is in bijection with the set of morphisms of schemes $\text{Spec}(B)\to\text{Spec}(A)$. Furthermore, we know that Spec$(A)$ has a base of open affine subsets, the "basic" or "principal" open affines $D(f)$ for all $f\in A$. Furthermore, $D(f)\cong$Spec$(A)$ as schemes, and the inclusion $D(f)\hookrightarrow\text{Spec}(A)$ corresponds to the localization map $A\to A_f$.

But answers to a recent MathOverflow question show that open affine subschemes of affine schemes can arise in other ways.

### Question

In order to try to make sense of the situation above, I'd like to know the following.

Given a commutative ring $A$, is there a "ring-theoretic" characterization of the ring homomorphisms $A\to B$ that realize $\text{Spec}(B)$ as an open affine subscheme of $\text{Spec}(A)$ (more precisely, those morphisms such that the induced map $\text{Spec}(B)\to\text{Spec}(A)$ is an open immersion)?

Of course, "ring-theoretic" is a bit vague. Let's certainly avoid any tautological characterizations. I would prefer if an answer didn't make any reference to the Zariski topology (for instance, the morphisms $A\to A_f$ make perfect sense without the Zariski topology), but I'm not sure whether that's reasonable.

Update: I received two great answers, thank you both! I chose the one that was closer to the kind of condition that I had in mind. But Dan Petersen's answer was also very interesting and unexpected.

-

Theorem 1: Let $R$ be an integral domain with field of fractions $K$, and $R \to A$ a homomorphism. Then $Spec(A) \to Spec(R)$ is an open immersion if and only if $A=0$ or $R \to K$ factors through $R \to A$ (i.e. $A$ is birational over $R$) and $A$ is flat and of finite type over $R$.

Proof: Assume $Spec(A) \to Spec(R)$ is an open immersion and $A \neq 0$. It is known that open immersions are flat and of finite type. Thus the same is true vor $R \to A$. Now $R \to K$ is injective, thus also $A \to A \otimes_R K$. In particular, $A \otimes_R K \neq 0$. Open immersions are stable under base change, so that $Spec(A \otimes_R K) \to Spec(K)$ is an open immersion. But since $Spec(K)$ has only one element and $Spec(A \otimes_R K)$ is non-empty, it has to be an isomorphism, i.e. $K \to A \otimes_R K$ is an isomorphism. Now $R \to A \to A \otimes_R K \cong K$ is the desired factorization.

Of course, the converse is not as trivial. It is proven in the paper

Susumu Oda, On finitely generated birational flat extensions of integral domains Annales mathématiques Blaise Pascal, 11 no. 1 (2004), p. 35-40

It is available online. In the section "Added in Proof." you can find some theorems concerning the general case without integral domains. In particular, it is remarked that in E.G.A. it is shown that

Theorem 2: $Spec(A) \to Spec(R)$ is an open immersion if and only if $R \to A$ is flat, of finite presentation and an epimorphism in the category of rings.

More generally, in EGA IV, 17.9.1 it is proven that a morphism of schemes is an open immersion if and only if it is flat, a (categorical) monomorphism and locally of finite presentation.

There are several descriptions of epimorphisms of rings (they don't have to be surjective), see this MO-question.

-
Thanks for the interesting answer, reference and reminder. –  Georges Elencwajg Apr 8 '10 at 22:47
Very nice information, thank you. Do you know what volume of EGA would have the result you refer to? –  Manny Reyes Apr 13 '10 at 23:09
again only one direction is hard. in EGA IV 2.4.6 it is shown that $Spec(A) \to Spec(R)$ is open (but to be honest, as always, I can track back the 'proof root' forever, without understanding anything ...). the fibre morphisms come from epis on fields, which are isomorphisms, thus the map is injective. I don't know how to prove that the stalk morphisms are bijective. –  Martin Brandenburg Apr 15 '10 at 6:30
A morphism of affines is a Zariski-open immersion if it is an étale monomorphism of affines. Then back in our category of rings, it is an étale epimorphism because the tensor product is right-exact, so epis are stable under base change. You can find this in stacks-GIT. –  Harry Gindi Apr 16 '10 at 23:34
'owk' gave me the EGA reference. now it's in the answer. –  Martin Brandenburg Apr 27 '10 at 13:26
There is the following characterisation. I don't think it's too tautological. Let $T \subseteq A$ be the set of f such that the induced map $A[f^{-1}] \to B[f^{-1}]$ is an isomorphism. Then $\mathrm{Spec}(B) \to \mathrm{Spec}(A)$ is an open immersion if and only if the image of $T$ in $B$ generates the unit ideal.
If $Spec(B) \to Spec(A)$ is an open immersion, the image is a ppen subset of $Spec(A)$, thus a union of some $D(f_i)$. Then $f_i \in T$ and the preimages of the $D(f_i)$ in $Spec(B)$ cover $Spec(B)$, i.e. the images of the $f_i$ in $B$ generate the unit ideal. For the converse, assume that the image of $T$ in $B$ generates the unit ideal. For every $f \in T$, we have an isomorphism $D_B(f) \cong D_A(f)$. Remark that $T$ is closed under multiplication and that these isomorphisms are compatible, thus glue to $Spec(B) \cong \cup_{f \in T} D_A(f)$. –  Martin Brandenburg Apr 14 '10 at 17:55