The space $\mathcal{L}(D)$ is defined as $$\mathcal{L}(D)=\{f \in k(X) \mid D + \operatorname{div}(f) \geq 0\} \cup \{0\}$$ and its dimension is denoted by $\ell(D).$
Let $X$ be a nonsingular projective curve, $P$ a point in $X$, $B$ a divisor.
A number $n\in \mathbb{Z}^+$ is a B-gap if there is no $f\in k(X)$ such that $((f)+B)_\infty=nP$.
The next lemma is true?
Lemma.
$n\in \mathbb{Z}^+$ is an E-gap if and only if $\mathcal{L}(nP+E)=\mathcal{L}((n-1)P+E)$.
I know that this is true in the case of $E=0$. I try to prove it, so the following proof is correct?
Proof. Suppose there is no $f\in k(X)$ with $\operatorname{div}((f)+E)_\infty=nP$. Since $E+(n-1) P \leq E+nP $ we obtain that $\mathcal{L}(E+(n-1)P) \subseteq \mathcal{L}(E+nP)$.
Now, we need to show that $\mathcal{L}(E+nP)\subseteq \mathcal{L}(E+(n-1)P) $. Suppose there is $f\in \mathcal{L}(E+nP)$ such that $f \notin \mathcal{L}(E+(n-1)P)$, this is $-E-nP \leq \operatorname{div}(f) < -E-(n-1)P$. Therefore, $\operatorname{div}(f)+E=-nP$. That is, \begin{equation*} \begin{split} v_{P}((f)+E)&=-n,\\ v_{Q}((f)+E)&=0, \forall Q \neq P. \end{split} \end{equation*} Then, $((f)+E)_{\infty}=nP$ which is a contradiction.
Reciprocally, if $\mathcal{L}(E+nP)=\mathcal{L}(E+(n-1)P)$, suppose that there is $f\in k(X)$ with $\operatorname{div}((f)+E)_\infty=nP$.
This is, $ v_{P}((f)+E)=-n$, and $v_Q((f)+E) \geq 0, \forall Q \neq P$.Then, $f\in \mathcal{L}(nP+E)$. However, $f \notin \mathcal{L}((n-1)P+E)$ because $$v_P(f+E)=-n<-n+1=-v_P((n-1)P)$$ Consequently, $\mathcal{L}(E+nP) \neq \mathcal{L}(E+(n-1)P)$ which is a contradiction.
I am using that $f \in \mathcal{L}(E+nP)$ means that $\operatorname{div}(f)+E+nP \geq 0$, then $\operatorname{div}(f)+E \geq -nP$. That is, $ v_P((f)+E)=-n$, and $v_Q((f)+E) \geq 0, \forall Q \neq P$.