
> 
> 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)$.



Prime avoidance in adjacent degrees
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. 


