# Constants sheaves on an open subset

Let $X$ be a topological space and $U\subset X$ an open subset. Let's work in the category of sheaves of abelian groups on $X$. Consider the constant sheaf on $U$, $\mathbb{Z}_U$, given by $\mathbb{Z}_U(V)=\{\text{continuous maps }U\cap V\rightarrow \mathbb Z\}$, where $\mathbb Z$ is given the discrete topology. I've been struggling to derive from Yoneda's lemma the formula $\hom(\mathbb{Z}_U,F)=F(U)$. Is this a consequence of Yoneda? If so, how? If it doesn't follow from Yoneda, is it true at all? If not, how can one compute $\hom(\mathbb{Z}_U,\mathbb{Z}_V)?$

-
Yes, it is a formal consequence of Yoneda and the fact that sheafification and the free abelian group functor are left adjoints. – Zhen Lin Mar 8 '13 at 13:00
Actually, the formulation of the question is incorrect, which led to the two different answers. You write that $\mathbb Z_U$ is a sheaf on $U$, while $F$ is a sheaf on $X$; so $\mathop{\rm hom}(\mathbb Z_U,F)$ does not make sense. You must either restrict $F$ to $U$ or extend $\mathbb Z_U$ to $X$. In the first case, the answer is yes (Zhen Lin's comment), and in the second it depends on the choice of an extension (direct image or extension by zero). – ACL Apr 24 '15 at 8:08

This is not true; for example, take $X = \mathbb R^2$, $U = \mathbb R^2 \smallsetminus \{(0,0)\}$. Then your $\mathbb Z_U$ coincides with $\mathbb Z_X$, and $Hom(\mathbb Z_U, F)$ is $F(X)$, not $F(U)$.

For the formula to hold you have to take as $\mathbb Z_U$ the extension of the constant sheaf by $0$, which is a very different animal.

-
@Angelo, thanks! Indeed you're right, I must have confused both things, what would then be a direct description of $\mathbb{Z}_U(V)$ for the right $\mathbb{Z}_U$ you suggests? (The extension of the constant sheaf $\mathbb{Z}$ on $U$ to $0$ in the rest). – Fernando Muro Mar 8 '13 at 15:25
Locally constant function $V \to \mathbb Z$ that are zero on $V\smallsetminus U$. – Angelo Mar 8 '13 at 15:39
@Angelo, thanks again! – Fernando Muro Mar 8 '13 at 17:18
You are very welcome. – Angelo Mar 8 '13 at 17:47

See [Tamme, Introduction to étale cohomology], p. 31, Remark (2.1.3).

-
And the sheafification of Tamme's $Z_U$ is my $\mathbb{Z}_U$ above, isn't it? – Fernando Muro Mar 8 '13 at 12:55
You have to distinguish $j_!\mathbf{Z}$ from your $\mathbf{Z}_U$ above. – Timo Keller Mar 8 '13 at 13:33
@Timo, thanks! Is there any easy direct description of the values $(j_!\mathbb{Z})(V)$? – Fernando Muro Mar 8 '13 at 15:30
@Fernando: See [Hartshorne, Algebraic Geometry] Exercise II.1.19 ("Extending a sheaf by zero"). – Timo Keller Mar 8 '13 at 15:35

Pierre Schapira has some very nice, and more elementary notes that could help you.

-