Skyscrapers sheaf's global sections I'm reading a book written by Serre and, even though he's one of the best math writer ever, there's a step I don't understand. This may imply that I'm one of the worst math reader ever! :-)
So, we are dealing with a sheaf $S$ on a projective curve $X$ and we can prove that, given a nonzero local section $s$ defined in a neighborhood of a point $P$, there always exists a smaller neighborhood $U$ of $P$ such that $s$ is vanishes on the whole $U\setminus P$. Then the claim is that
$$ H^0(X, S) = \bigoplus_{P\in X} \;S_P $$
i.e. the space of global sections coincides with the direct sum of the stalks.
This is intuitively clear for me: from the above we know that the set of points $P$ where a global section $s$ is not trivial is discrete. Moreover, it is closed inside a compact space, thus itself compact. Since a discrete set is compact iff it is finite, we see that $s$ is not trivial only on a finite number of points, and this motivates the presence of $\bigoplus$ in place of $\prod$.
Is my reasoning correct? Is there a better/faster/cleaner way to see it?
Further, is this a general fact, or does it depend on the particular nature (which I didn't describe here) of the sheaf $S$ ? In other words, is it true that if a sheaf $F$ is a skyscrapers sheaf (meaning it's support lies in a finite number of points) on a projective variety, then the above formula for its global sections holds?
 A: I think the étalé space argument from the other answer is nice, that was also the first argument that came to mind while reading the same(?) passage of Serre's book. But when I tried to write it down I found another argument which seemed easier to formalize, so maybe you also find it more convincing.
The claim is in fact that $\mathcal{S}=\bigoplus_{P\in X}\mathcal{S}_{P}$, where the summands on the right are the corresponding skyscraper sheaves.
As you pointed out yourself, there is a dense open subset $U\subseteq X$ over which $\mathcal{S}$ has no sections, so $\mathcal{S}_{P}=0$ for all $P\in U$.
So the direct sum is indeed finite and no sheafification is needed. If $Q\in X$ is a point, then we claim that
$$ \Gamma(V,\mathcal{S})=\bigoplus_{P\in X}\Gamma(V,\mathcal{S}_{P})=\Gamma(V,\mathcal{S}_{Q})=\mathcal{S}_{Q}, $$
where $V$ is an open neighbourhood of $Q$ in $X$ not containing any other point with non-zero stalk.
More precisely, we want to show that the restriction to the stalk $s\mapsto [(V,s)]$ is an isomorphism.
For injectivity, suppose $s\in \Gamma(V,\mathcal{S})$ has $s_{Q}=0$.
Since all the other stalks of $\mathcal{S}$ in $V$ are $0$, we get $s_{P}=0$ for all $P\in V$, hence $s=0$.
For surjectivity, let $t_{Q}=[(W,t)]\in \mathcal{S}_{Q}$ for some $Q\in W\subseteq V$ open and some $t\in \Gamma(W,\mathcal{S})$.
Find a smaller open subset $Q\in W'\subseteq W$ such that $t|_{W'\setminus \{Q\}}=0$ and consider the open cover $V=W'\cup (V\setminus \{Q\})$.
The sections $t|_{W'}\in \Gamma(W',\mathcal{S})$ and $0\in \Gamma(V\setminus\{Q\},\mathcal{S})$ are both $0$ on the intersection, so they glue to a section $\tilde{t}\in \Gamma(V,\mathcal{S})$.
Then $\tilde{t}_{Q}=t_{Q}$, because
$$ [(V,\tilde{t})]=[(W',t|_{W'})]=[(W,t)]. $$
The set of such open sets (as we vary the point $Q$) forms a basis for the topology on $X$.
Since both sheaves have the same sections over a basis of the topology, they have to be equal.
P.S. If this is the part of Serre's Algebraic Groups and Class Fields that I think it is, I believe there is a simpler proof.
With the notation of the book: if $Q\in X$ is a point and $U\subseteq X$ is an open neighbourhood of $Q$ in $X$ such that all points in $U\setminus \{Q\}$ have coefficient $0$ in the divisor $D$, then we can explicitly describe the sections of both $\mathcal{A}$ and of $\bigoplus_{P\in X}\mathcal{A}_{P}$ as equivalence classes of rational functions $f$ on $X$ with $f\sim g$ if and only if $v_{Q}(f-g)+v_{Q}(D)\geqslant 0$.
Hence both sheaves have the same sections over each element of a basis of the topology and thus the two sheaves are the same.
A: One idea would be to understand this via the étalé space associated to the sheaf.
If $\mathcal{F}$ is a sheaf over $X$, the étalé space associated to $\mathcal{F}$ is a topological space which is given as a set by $$\tilde{\mathcal{F}} = \bigsqcup_{p \in X} \mathcal{F}_p$$ with a projection $\pi: \tilde{F} \rightarrow X$ taking each element of $\mathcal{F}_p$ to $p$. This space has the property that for any open set $U \subseteq X$ the sections $\mathcal{F}(U)$ correspond to continuous sections $s: U \rightarrow \tilde{\mathcal F}$ i.e. continuous maps such that $\pi \circ s = id_X$.
In the case of a skyscrapers sheaf with $\mathcal{F}_{p_i} \neq 0$ for $i \in \{ 1, \dotsc, n \}$ then $\tilde{\mathcal F} = \bigsqcup_\limits{i=1}^n \mathcal{F}_{p_i}$ and its global sections
$$
s: X \longrightarrow \bigsqcup_\limits{i=1}^n \mathcal{F}_{p_i},
$$
should correspond bijectively with points in $\bigoplus\limits_{i+1}^n \mathcal{F}_{p_i}$.
