TITLE: Prime avoidance in adjacent degrees
QUESTION [8 upvotes]: Let $\mathfrak{p}_1, \dotsc, \mathfrak{p}_k$ be relevant homogeneous primes ideals in the graded ring $R := \Bbbk[x_0, \dotsc, x_n]$, where $\Bbbk$ is a field.  Prime avoidance (in Eisenbud's terminology) tells us that there exists a nonconstant homogenous polynomial $f \not\in \cup_i \mathfrak{p}_i$.  Is there an easy way to see that for some $d \geq 1$, there exist homogeneous $f \in R_d$, $g \in R_{d+1}$, neither of which is contained in $\cup_i \mathfrak{p}_i$?

Note: If $\Bbbk$ is infinite, this is easy: we can use the fact that no vector space is a finite union of proper subspaces to find $\alpha \in R_1 \smallsetminus \cup_i \mathfrak{p}_i$, and then take $f=\alpha$, $g = \alpha^2$.
Motivation: If the $\mathfrak{p}_i$ are the associated primes of a closed subscheme $X$ of $\mathbb{P}^n_{\Bbbk}$ then we can pull back $g/f$ to a nice rational section of $\mathcal{O}_X(1)$.  Consequently, we know that $\mathcal{O}_X(1)$ comes from a Cartier divisor.  Using the fact that any line bundle can be twisted to a very ample line bundle, this shows that the Cartier divisor group surjects onto $Pic(X)$.

REPLY [6 votes]: The answer is yes. The following is extracted from a preprint of Gabber-Liu-Lorenzini. 

Let $B=\oplus_{n\ge 0}B(n)$ be a graded ring. Let $I=\oplus_{n\ge 0}I(n)$ be a homogeneous ideal of $B$. Let $\mathfrak p_1,\dots,\mathfrak p_r$ be homogeneous prime ideals of $B$ not containing $B(1)$ and not containing $I$. Then there exists an integer $n_0 \geq 1$ such
  that for all $n\ge n_0$, $I(n)\not\subseteq \cup_{1\le i\le r} \mathfrak p_i$.    

Proof. We proceed by induction on $r$. If $r=1$, choose $t\in B(1)\setminus \mathfrak p_1$ and a homogeneous element $\alpha\in I\setminus \mathfrak p_1$, say of degree $n_0$. Then 
$t^{n-n_0}\alpha\in I(n) \setminus \mathfrak p_1$ for all $n\ge n_0$, as desired.
Let $r\ge 2$ and suppose that the lemma is true for $r-1$. We can suppose
that $\mathfrak p_i$ is not contained in $\mathfrak p_r$ for all $i\ne r$, so that 
$I\mathfrak p_1\cdots\mathfrak p_{r-1} \not\subseteq \mathfrak p_r$. Similarly, 
we can suppose that $\mathfrak p_r$ is not contained in $\mathfrak p_i$ for all 
$i\ne r$, so that 
$I\mathfrak p_r\not\subseteq (\mathfrak p_1\cup \ldots\cup\mathfrak p_{r-1})$. 
Hence, we can apply the case $r=1$ and the induction hypothesis 
to obtain that there exists $n_0$ such that for all $n\ge n_0$, 
there are homogeneous elements 
$f_n\in I\mathfrak p_1\cdots\mathfrak p_{r-1} \setminus \mathfrak p_r$ and 
$g_n\in I\mathfrak p_r\setminus (\mathfrak p_1\cup \ldots\cup\mathfrak p_{r-1})$
of degree $n$. It is easy to check that 
$f_n+g_n\in I(n)\setminus \cup_{1\le i\le r}\mathfrak p_i$, as desired.