When is the composition of a pushforward pullback of a vector bundle a vector bundle? Let $j:U \subset X$ be a subset of scheme $X$, and let $\mathcal{E}$ denote a vector bundle (locally free sheaf) on $X$.
Doe there exists a set of sufficient conditions on $U,X,j$ such that the natural map $\mathcal{E} \to j_* j^* \mathcal{E}$ an isomorphism?
My guess: $U$ of codimension $\ge 2$, and then apply Hartog's lemma. However, Hartog's lemma (as far as I know) is a statement about complex manifolds; thus we should also assume that $U,X$ are smooth.
 A: Maybe not the type of answer you're looking for, but here is a try.
If $U:=X\setminus D$ for a $\mathcal E$-regular principal subscheme $ D\subset X$, then $j_{*}j^{*}\mathcal E \cong \varinjlim_{m\in \Bbb Z}\mathcal E(mD) $.
We can see that as follows.
Let $\mathcal I_D$ be the ideal sheaf that cuts out $D$ and let $ \mathcal I_D \otimes j_*j^*\mathcal E\xrightarrow{\alpha} j_*j^*\mathcal E$ be the  morphism induced by the multiplication $\mathcal O_X \xrightarrow[]{.u}
 \mathcal O_X$ where $u$ is the global section generating $\mathcal I_D$ (locally).
Then define
$\mathcal E(-D):=\alpha(\mathcal I_D \otimes \mathcal E)$ (the image presheaf, sheafified if necessary)
$\mathcal E(D):=\operatorname{max}\{\mathcal F\subset j_*j^*\mathcal E: \alpha(\mathcal I_D\otimes\mathcal F) \subset j_*j^*\mathcal E)\}$
By definition, there are canonical injections $\mathcal E(-D)\hookrightarrow \mathcal E \hookrightarrow \mathcal E(D)$.
Using the affine local interpretation of $j$ as a localization by $u$, there is an isomorphism $j_*j^*\mathcal E\cong \varinjlim_{m\in \Bbb Z}\mathcal E(mD)$.
P.S. Maybe the $\mathcal E$-regularity of $D$ is superfluous.
