Notation in Hartshorne Exercise 1.2.6 I am now doing Hartshorne Problem 1.2.6. 

Hartshorne 1.2.6: Let $Y$ be a projective variety with homogeneous coordinate ring $S(Y)$, show that $\dim S(Y) = \dim Y + 1$. [Hint: Let $\varphi_i : U_i \to \Bbb{A}^n$ be the homeomorphism of (2.2), let $Y_i$ be the affine variety $\varphi(Y \cap U_i)$ be its affine coordinate ring. Show that $A(Y_i)$ can be identified with the subring of elements of degree $0$ of the localized ring $S(Y)_{x_i}$. Then show that $S(Y)_{x_i} \cong A(Y_i)[x_i,x_i^{-1}]$.

Now I have done most of the exercise but have several questions related to it:


*

*The notation $S(Y)_{x_i}$ means localization at the multiplicative set $\{1,x_i,x_i^2,\ldots\}$ yes? It does not mean localization at the prime ideal $ (x_i)$ right? I don't think the two coincide.

*Assuming I understand the notation right, I am confused how we can just do $S(Y)_{x_i}$ without some extra assumptions. In particular it could be that $x_i$ is zero in $S(Y)$, i.e. $x_i \in I(Y)$ then we are in trouble because the localization is the zero ring. Should there be an extra assumption here?

*Also how can I say that $S(Y)_{x_i} \cong A(Y_i)[x_i,x_i^{-1}]$? I know how to prove this if $S(Y)$ is a $\Bbb{Z}$ - graded ring but now it is just a $\Bbb{N}$ - graded ring.
 A: *

*Yes, $S(Y)_{x_i}$  means localization at the multiplicative set $\{1,x_i,x_i^2,\ldots\}$ .
Not only does it not coincide with $S(Y)_{(x_i) }$ but in a sense it is complementary, as seen in the following affine example:
Let $\mathbb A^1_k=\text{Spec}(k[T])$. Then  $k[T]_T$ is the ring of regular functions on $\mathbb A^1_k\setminus \{0\}$,i.e. defined outside $0\in \mathbb A^1_k$, whereas $k[T]_{(T)}$ is the ring of germs of functions defined only near $0\in \mathbb A^1_k$ .  

*You are very attentive: congratulations!
But Hartshorne's isomorphism is correct: if $x_i\in I(Y)$, then $Y$ is contained in the hyperplane $H_i\subset \mathbb P^n_k$ given by  $x_i=0$.
Since $Y\subset H_i=\mathbb P^n_k\setminus U_i$  ,  its   intersection with $U_i$ is empty:  $Y_i=Y\cap U_i=\emptyset$.
The ring of functions of $Y_i$ is thus zero: $A(Y_i)=0$, and since $S(Y)_{x_i}=0$  too because you are inverting $x_i=0\in S(Y)$ Hartshorne's isomorphisms reduces to $0\cong 0 :$  not exciting but true!

*As you correctly write in your comment below, you may use that for a $\mathbb Z$-graded ring $R$ and a homogeneous element $f\in R_1$ of degree $1$ you have  the isomorphism of $\mathbb Z$-graded rings $$(R[f^{-1}]_0)[x,x^{-1}]\stackrel {\cong}{\to}  R[f^{-1}]:\sum_{j\in \mathbb Z} q_jx^j\mapsto \sum_{j\in \mathbb Z} q_j f^j   \quad (q_j\in R[f^{-1}]_0)   $$
You would like to apply this to $R=S(Y)$ and $f=x_i$, but there is the apparent difficulty that $S(Y)$ is $\mathbb N$-graded instead of being $\mathbb Z$-graded.
The solution is purely formal: just decree that $S(Y)_n=0$ for $n\lt 0$ and $S(Y)$ becomes a $\mathbb Z$- graded ring.
This is a general formal procedure allowing to consider any $\mathbb N$- graded ring as a $\mathbb Z$- graded ring.
