In cellular homology, how should we define the degree of a map between $0$-spheres? Cellular homology is one of many homology theories available for 'nice' spaces. There are doubtless many equivalent definitions for it, in increasing levels of abstraction, but I want to ask about the concrete description exhibited on Wikipedia.
To explain my question, I need to explain what I think the definition of cellular homology is and explain my notation. This section is skippable if you wish! (though I'd really appreciate it if someone experience could confirm or deny the correctness of my definitions)

To standardise my notation, let me define a cell complex as follows:

Let $X_{-1}:=\emptyset$. For every $n\in\Bbb N_0$ there suppose there is a space $X_{n-1}$ and a set $I_n$ with given continuous functions: $$(\Phi^\alpha_n:S^{n-1}\to X_{n-1})_{\alpha\in I_n}$$Then define:

*

*$X_n$ is the colimit of the diagram of spaces: $$(D^n\hookleftarrow S^{n-1}\overset{\Phi^\alpha_n}{\longrightarrow}X_{n-1})_{\alpha\in I_n}$$Where the copies of $D^n,S^{n-1}$ vary but the target $X_{n-1}$ is fixed (a new 'cell' $D^n$ for every $\alpha\in I_n$).

Then define the associated cell complex $X$ to be the colimit of the inclusion diagram: $$X_{-1}\hookrightarrow X_0\hookrightarrow X_1\hookrightarrow\cdots$$
Where the inclusions $X_{n-1}\hookrightarrow X_n$ are the legs of the colimit. Let, for every $n$ and $\alpha$, $e^\alpha_n$ denote the image of $D^n$ in $X_n$ under the leg of the associated colimit, and $(e^{\alpha}_n)^\circ$ denote the image of the interior of $D^n$ under this leg.

I may have slipped up a formal phrasing here and there, if so I apologise. Now, the cellular homology for the cell complex $X$ is defined as the homology of the chain complex: $$\cdots\to C_{n+1}\overset{\partial_n}{\longrightarrow}C_n\overset{\partial_{n-1}}{\longrightarrow}C_{n-1}\to\cdots\to C_0\to0$$In the category of abelian groups, where $C_k$ is the free abelian group on $I_k$ - let's denote the basis by $c^\alpha_k$ for every $\alpha\in I_k$. The differentials $\partial_k$ are more difficult to describe, and my question is about the definition of $\partial_0$. In general, according to Wikipedia and a private conversation, the boundary maps are the homomorphisms defined by: $$c^\alpha_n\mapsto\sum_{\beta\in I_{n-1}}\deg(\chi^{\alpha,\beta}_n)c^\beta_{n-1}$$Where $\chi^{\alpha,\beta}_n:S^{n-1}\to S^{n-1}$ is the continuous composite: $$S^{n-1}\overset{\Phi^{\alpha}_n}{\longrightarrow}X_{n-1}\twoheadrightarrow X_{n-1}/(X_{n-1}\setminus(e^\beta_{n-1})^\circ)\cong S^{n-1}$$Where the final homeomorphism is given by fixing, for every $k$, a chosen 'canonical' quotient map $D^k\to S^k$ for killing the boundary $S^{k-1}\subset D^k$ - then the composite: $$D^{n-1}\to X_{n-1}\twoheadrightarrow X_{n-1}/(X_{n-1}\setminus(e^\beta_{n-1})^\circ)$$Must factor through $S^{n-1}\to X_{n-1}/(X_{n-1}\setminus(e^\beta_{n-1})^\circ)$ via the universal property of the chosen quotient $D^{n-1}\to S^{n-1}$. This factored arrow is the desired homeomorphism.

That's all very well, but this definition seems to break down in the case that $n=0$. For simplicity, consider the cellulation of $S^1$ via one zero-cell, call it $v$, and one one-cell,  call it $e$, where the attaching map $\Phi:I\to \{v\}$ is just the quotient mapping for identifying the two endpoints of $e$. The zeroth cellular homology of the circle is supposed to be $\Bbb Z$ - I want to test that out. The composite $\chi$ in this case is that map that assigns the two points of $S^0$ to the one point $v$ of $X_0$, and then we send this through the quotient machinery. There is a problem - $X_0\setminus\{v\}$ is empty, and $X_0/\emptyset$ is either $X_0$ or $X_0\sqcup\{\text{pt}\}$, depending on who you ask and how you define things. $X_0$ is certainly not homeomorphic to $S^0$, so I suppose we must choose the convention $X_0/\emptyset=X_0\sqcup\{\text{pt}\}$. Next, we need to compute the degree of this map, which is essentially the constant map $\{-1,1\}\to\{v,\text{pt}\},\,\pm1\mapsto v$. My question:

*

*How is the degree of a map $S^0\to S^0$ defined? The usual definition via homotopy classes fails, as there are only four homotopy classes of $[S^0,S^0]$ if I'm not mistaken. There is no obvious ordering to these.

*If the degree (of the composites $\chi$, which are always constant!) is set to be always zero, as I suspect, then that forces the homology $\mathrm{H}_0$ to be $\Bbb Z^{|I_0|}/0=\Bbb Z^{|I_0|}$. However, if we instead cellulated (?) the circle with two or more zero-cells, we'd get a contradictory answer of $\mathrm{H}_0(S^1)\cong\Bbb Z^2$, etc., which is - or should be - false. What's going on?

 A: Yeah, the $n=0$ case is annoyingly exceptional in this explicit description and oftentimes swept under the rug. As pointed out in the comments, relative homology provides a more streamlined framework for formulating cellular homology. Nonetheless, with the right conventions, this can be made to work just fine.
First of all, indeed, $X/\emptyset=X\sqcup\{\ast\}$ for any topological space. This is arguably the right convention. Next, there are precisely $4$ maps $f\colon S^0\rightarrow S^0$. If $f$ is constant, let $\deg(f)=0$, if $f=\mathrm{id}$, let $\deg(f)=1$ and if $f$ is the "flip" map switching the two points of $S^0$, let $\deg(f)=-1$. Here are some remarks that might convince you this is the "right" definition:

*

*It matches the pattern. Constant maps always have degree $0$, the identity always degree $1$ and the antipodal map on $S^n$ (which, for $n=0$, is the "flip" map) degree $(-1)^{n+1}$.


*If $S$ denotes suspension, then $\deg(f)=\deg(Sf)$, which is a property we expect.


*If $f,f^{\prime}\colon S^0\rightarrow S^0$ are given, then $\deg(f^{\prime}\circ f)=\deg(f^{\prime})\deg(f)$.


*For $S^n$, $n\ge0$, the reduced homology $\tilde{H}_n(S^n)$ is free abelian of rank $1$ (for $n>0$, this agrees with the homology $H_n(S^n)$, but for $n=0$, we need to look at the reduced homology to get a unified statement). A continuous map $g\colon S^n\rightarrow S^n$ induces a map $\tilde{H}_n(g)\colon\tilde{H}_n(S^n)\rightarrow\tilde{H}_n(S^n)$, which only depends on its homotopy class. Since the group is free abelian of rank $1$, this map is given by multiplication with an integer, which is defined to be $\deg(g)$. For $n>0$, this is the usual definition of degree; for $n=0$, it agrees with what I've given above.
The one thing that is genuinely different is that not all integers appears as possible degrees anymore. This can be traced back to the absence of a canonical group structure on $[S^0,S^0]$, which, on a conceptual level, is because the $S^n$ for $n>1$ are cogroup objects in the homotopy category of topological spaces, whereas $S^0$ is not. This is a genuine difference, but not one that impacts what we are doing.
Now, let's briefly consider what this means for the cellular complex. The group $C_0$ is the free abelian group on the $0$-cells of $X$, which are precisely the points of the discrete space $X_0$. Every element of $C_0$ is a cycle by definition, so we only need to understand the boundaries. If $\varphi_0^{\alpha}\colon S^0\rightarrow X_0$ is the attaching map of a $1$-cell and $e_0^{\beta}$ is a $0$-cell, we are looking at the composite $\chi_0^{\alpha,\beta}\colon S^0\rightarrow X_0\rightarrow X_0/(X_0-(e_0^{\beta})^{\circ})\cong S^0$.
Since the $0$-cell $e_0^{\beta}=(e_0^{\beta})^{\circ}$ is just a single point in the discrete space $X_0$, collapsing its complement yields a copy of $S^0$, where one point corresponds to the point $e_0^{\beta}$ in $X_0$ and the other point of $S^0$ corresponds to all the other points of $X_0$. Thus, we see that $\chi_0^{\alpha,\beta}$ is constant (i.e. has degree $0$) if and only if $S^0$ maps constantly to the point $e_0^{\beta}$ or into the complement $X_0-(e_0^{\beta})^{\circ}$.
So, if $\varphi_0^{\alpha}$ is constant, the boundary of the corresponding $1$-cell is $0$. If it is not constant, let $e_0^{\beta_1}$ and $e_0^{\beta_1}$ be the two points in its image. Then, the previous considerations show that $\partial(e_1^{\alpha})=\pm(e_0^{\beta_1}-e_0^{\beta_2})$ (this actually requires an additional argument, using that the flip map has degree $-1$, which I'll leave for you to ponder). Note that I'm writing $\pm$, because I have not chosen a fixed identification with $S^0$, but this is inessential for the image of $\partial\colon C_1\rightarrow C_0$ (of course, the choice has to be fixed in any case).
In intuitive terms, $C_0$ is the free abelian group on the points of $X_0$, the $0$-cells of $X$, and two $0$-cells of $X$ get identified precisely whenever there is a $1$-cell attached to both of these points. Try some examples (including the different possible cellular decompositions of $S^1$) to get a feeling for why this should model $H_0(X)$ as we know it.
A: Thorgott has given a perfect answer, but I have some remarks too long for a comment.
The cellular chain complex of a CW-complex $X$ with $n$-skeleta $X^n$ is usually defined by $C^{CW}_n(X) = H_n(X^n,X^{n-1})$ and $\partial^{CW}_n : C_n(X) = H_n(X^n,X^{n-1}) \stackrel{\partial_n}{\to} H_{n-1}(X^{n-1}) \stackrel{j_*}{\to} H_{n-1}(X^{n-1},X^{n-2}) = C_{n-1}^{CW}(X)$.
It is easy to see that we can naturally identify $C_n(X)$ with the free abelian group whose generators are the $n$-cells of $X$. This leaves the question how to describe $\partial^{CW}_n$ in terms of these "cellular generators".
Hatcher (in his book "Algebraic Topology") writes

Next we describe how the cellular boundary maps $\partial^{CW}_n$ can be computed. When $n = 1$ this is easy since the boundary map $\partial^{CW}_1 : H_1(X^1,X^0) \to H_0(X^0)$ is the same as the simplicial boundary map $Δ_1(X) \to Δ_0(X)$. In case $X$ is connected and has only one $0$ cell, then $\partial^{CW}_1$ must be $0$, otherwise $H_0(X)$ would not be $\mathbb Z$. When $n > 1$ we will show that $\partial^{CW}_n$ can be computed in terms of degrees:
Cellular Boundary Formula. [ ... ]

Note that Hatcher introduces the simplicial chain complex for so-called $\Delta$-complexes. These are less general than CW-complexes, but the $1$-skeleton $X^1$ of a CW-complex $X$ is always a $\Delta$-complex.
I shall not go into details, but let me emphasize that the Cellular Boundary Formula is valid only for $n > 1$. As you say, the problem for $n =1$ is that initially we do not have a concept of the degree of a map $S^0 \to S^0$. However, we can find a fitting concept for this case as shown in Thorgott's answer.
