\section{Singular cohomology} Cohomology forms a dual notion to homology. To every topological space we assign a graded group $H^*(X)$ equipped with a ring structure given by a product $\cup: H^i(X)\times H^j(X)\to H^{i+j}(X)$. In this section we give basic definitions and properties of singular cohomology groups which are very similar to those of homology groups. \begin{cislo}\label{COchain}{\bf Cochain complexes.} A \emph{cochain complex}\index{cochain complex} $(C,\delta)$ is a sequence of Abelian groups (or modules over a ring) and their homomorphisms indexed by integers $$\dots\xrightarrow{\ \delta^{n-2}\ } C^{n-1}\xrightarrow{\ \delta^{n-1}\ } C^n\xrightarrow{\ \delta^{n}\ } C^{n+1}\xrightarrow{\ \delta^{n+1}\ }\dots$$ such that $$\delta^{n}\delta^{n-1}=0.$$ $\delta^n$ is called a coboundary operator. A \emph{cochain homomorphism}\index{cochain homomorphism} of cochain complexes $(C,\delta_C)$ and $(D,\delta_D)$ is a sequence of homomorphisms of Abelian groups (or modules over a ring) $f^n:C^n\to D^n$ which commute with the coboundary operators $$\delta_D^nf_{n}=f^{n+1}\delta_C^n.$$ \end{cislo} \begin{cislo}\label{COhomology}{\bf Cohomology of cochain complexes.} The $n$-th \emph{cohomology group}\index{cohomology group of a cochain complex} of a cochain complex $(C,\delta)$ is the group $$H^{n}(C)=\frac{\ker\delta^n}{\im\delta^{n-1}}.$$ The elements of $\ker\delta^n=Z^n$ are called \emph{cocycles}\index{cocycle} of dimension $n$ and the elements of $\im\delta^{n-1}=B^n$ are called \emph{coboundaries}\index{coboundary} (of dimension $n$). If a cochain complex is exact, then its cohomology groups are trivial. The component $f^n$ of the cochain homomorphism $f:(C,\delta_C)\to (D,\delta_D)$ maps cocycles into cocycles and coboundaries into coboundaries. It enables us to define $$H^n(f):H^{n}(C)\to H^n(D)$$ by the prescription $H^n(f)[c]=[f^n(c)]$ where $[c]\in H^n(C)$ and $[f^n(c)]\in H^n(D)$ are classes represented by the elements $c\in Z^n(C)$ and $f^n(c)\in Z^n(D)$, respectively. \end{cislo} \begin{cislo}\label{COlesch}{\bf Long exact sequence in cohomology.} A sequence of cochain homomorphisms $$\dots\to A\xrightarrow{\ f\ }B\xrightarrow{\ g\ }C\to\dots$$ is exact if for every $n\in\mathbb Z$ $$\dots\to A^n\xrightarrow{\ f^n\ }B_n\xrightarrow{\ g^n\ }C^n\to\dots$$ is an exact sequence of Abelian groups. Similarly as for homology groups we can prove \begin{thm*} Let $0\to A\xrightarrow{\ i\ }B\xrightarrow{\ j\ }C\to 0$ be a short exact sequence of cochain complexes. Then there is a so called \emph{connecting homomorphism}\index{connecting homomorphism} $\delta^*:H^n(C)\to H^{n+1}(A)$ such that the sequence $$\dots\xrightarrow{\ \delta^*\ } H^{n}(A)\xrightarrow{H^{n}(i)} H^n(B) \xrightarrow{H^n(j)}H^{n}(C)\xrightarrow{\ \delta^*\ }H^{n+1}(A) \xrightarrow{H^{n+1}(i)} \dots$$ is exact. \end{thm*} \end{cislo} \begin{cislo}\label{COchhmtp}{\bf Cochain homotopy.} Let $f,g:C\to D$ be two cochain homomorphisms. We say that they are \emph{cochain homotopic}\index{cochain homotopic} if there are homomorphisms $s^n:C^n\to D^{n-1}$ such that $$\delta_D^{n-1}s^n+s^{n+1}\delta_C^{n}=f^n-g^n \quad \text{for all }n.$$ The relation to be cochain homotopic is an equivalence. The sequence of maps $s^n$ is called a \emph{cochain homotopy}.\index{cochain homotopy} Similarly as for homology we have \begin{thm*} If two cochain homomorphism $f,g:C\to D$ are cochain homotopic, then $$H^n(f)=H^n(g).$$ \end{thm*} \end{cislo} \begin{cislo}\label{COsing}{\bf Singular cohomology groups of a pair.} Consider a pair of topological spaces $(X,A)$, an inclusion $i:A\hookrightarrow X$ and an Abelian group $G$. Let $$C(X,A)=(C_n(X)/C_n(A),\partial_n)$$ be the singular chain complex of the pair $(X,A)$. The \emph{singular cochain complex}\index{singular cochain complex} $(C(X,A;G),\delta)$ for the pair $(X,A)$ is defined as \begin{align*} C^n(X,A;G)=\hom\left(C_n(X,A),G\right)&\cong\{h\in\hom(C_n(X),G); \ h\vert C_n(A)=0\}\\ &=\ker i^{*}:\hom(C_n(X),G)\longrightarrow \hom(C_n(A),G). \end{align*} and $$\delta^n(h)=h\circ\partial_{n+1}\quad\text{for }h\in\hom(C_n(X,A),G).$$ The $n$-th \emph{cohomology group}\index{cohomology group} of the pair $(X,A)$ with coefficients in the group $G$ is the $n$-th cohomology group of this cochain complex $$H^n(X,A;G)=H^n(C(X,A;G),\delta).$$ We write $H^n(X;G)$ for $H^n(X,\emptyset;G)$. A map $f:(X,A)\to(Y,B)$ induces the cochain homomorphism $C^n(f):C^n(Y;G)\to C^n(X;G)$ by $$C^n(f)(h)=h\circ C_n(f)$$ which restricts to a cochain homomorphism $C^n(Y,B;G)\to C^n(X,A;G)$ since $f(A)\subseteq B$. In cohomology it induces the homomorphism $$f^*=H^n(f):H^n(Y,B)\to H^n(X,A).$$ Moreover, $H^n(\id_{(X,A)})=\id_{H^n(X,A;G)}$ and $H^n(fg)=H^n(g)H^n(f)$. We can conclude that $H^n$ is a contravariant functor (cofunctor) from the category $\top^2$ into the category $\abAG$ of Abelian groups. \end{cislo} \begin{cislo}\label{COles}{\bf Long exact sequence for singular cohomology.} Consider inclusions of spaces $i:A\hookrightarrow X$, $i':B\hookrightarrow Y$ and maps $j:(X,\emptyset)\to (X,A)$, $j':(Y,\emptyset)\to (Y,B)$ induced by $\id_{X}$ and $\id_Y$, respectively. Let $f:(X,A)\to (Y,B)$ be a map. Then there are connecting homomorphisms $\delta_X^*$ and $\delta^*_Y$ such that the following diagram $$ \xymatrix{ \dots \ar[r]^-{\delta_X^*} & H^n(X,A;G) \ar[r]^-{j^*} & H^n(X;G) \ar[r]^-{i^*} &H^n(A;G) \ar[r]^-{\delta_X^*} & H^{n+1}(X,A;G) \ar[r]^-{j^*} & \dots \\ \dots \ar[r]^-{\delta_Y^*} & H^n(X,B;G) \ar[r]^-{j'^*} \ar[u]_{f^*} & H^n(Y;G) \ar[r]^-{i'^*} \ar[u]_{f^*}&H^n(B;G) \ar[r]^-{\delta_Y^*} \ar[u]_{(f/B)^*} &H^{n+1}(Y,B;G) \ar[r]^-{j'^*}\ar[u]_{f^*}& \dots } $$ commutes and its horizontal sequences are exact. The proof follows from Theorem \ref{COlesch} using the fact that $$0\to C^n(X,A;G)\xrightarrow{C^n(j)} C^n(X;G)\xrightarrow{C^n(i)} C^n(A;G)\to 0$$ is a short exact sequence of cochain complexes as it follows directly from the definition of $C^n(X,A;G)$. \begin{remark} Consider the functor $I:\top^2\to\top^2$ which assigns to every pair $(X,A)$ the pair $(A,\emptyset)$. The commutativity of the last square in the diagram above means that $\delta^*$ is a natural transformation of contravariant functors $H^n\circ I$ and $H^{n+1}$ defined on $\top^2$. \end{remark} \begin{remark} It is useful to realize how $\delta^*:H^n(A;G)\to H^{n+1}(X,A;G)$ looks like. Every element of $H^{n}(A;G)$ is represented by a cochain $q\in \hom(C_n(A);G)$ with a zero coboundary $\delta q\in \hom(C_{n+1}(A);G)$. Extend $q$ to $Q\in \hom(C_n(X);G)$ in arbitrary way. Then $\delta Q\in\hom(C_{n+1}(X),G)$ restricted to $C_{n+1}(A)$ is equal to $\delta q=0$. Hence it lies in $\hom(C_{n+1}(X,A);G)$ and from the definition in \ref{COlesch} we have $$\delta^*[q]=[\delta Q].$$ \end{remark} \end{cislo} \begin{cislo}\label{COhmtp}{\bf Homotopy invariance.} If two maps $f,g:(X,A)\to (Y,B)$ are homotopic, then they induce the same homomorphisms $$f^*=g^*:H^n(Y,B;G)\to H_n(X,A;G).$$ \begin{proof} We already know that the homotopy between $f$ and $g$ induces a chain homotopy $s_*$ between $C_*(f)$ and $C_*(g)$. Then we can define a cochain homotopy between $C^*(f)$ and $C^*(g)$ as $$s^n(h)=h\circ s_{n-1}\quad\text{for }h\in \hom(C_n(Y);G)$$ and use Theorem \ref{COchhmtp}. \end{proof} \begin{cor*} If $X$ and $Y$ are homotopy equivalent spaces, then $$H^n(X)\cong H^n(Y).$$ \end{cor*} \end{cislo} \begin{cislo}\label{COet}{\bf Excision Theorem.} Similarly as for singular homology groups there are two equivalent versions of this theorem. \begin{thma}[Excision Theorem, 1st version] Consider spaces $C\subseteq A\subseteq X$ and suppose that $\bar C\subseteq \inte A$. Then the inclusion $$i:(X-C,A-C)\hookrightarrow (X,A)$$ induces the isomorphism $$i^*:H^n(X,A;G)\xrightarrow{\cong} H^n(X-C,A-C;G).$$ \end{thma} \begin{thma}[Excision Theorem, 2nd version] Consider two subspaces $A$ and $B$ of a space $X$. Suppose that $X=\inte A\cup\inte B$. Then the inclusion $$i:(B,A\cap B)\hookrightarrow (X,A)$$ induces the isomorphism $$i^*:H^n(X,A;G)\xrightarrow{\cong} H^n(B,A\cap B;G).$$ \end{thma} The proof of Excision Theorem for singular cohomology follows from the proof of the homology version. \end{cislo} \begin{cislo}\label{COsum}{\bf Cohomology of finite disjoint union.} Let $X=\coprod_{\alpha=1}^k X_{\alpha}$ be a disjoint union. Then $$H^n(X;G)=\bigoplus_{\alpha=1}^kH^n(X_{\alpha}).$$ The statement is not generally true for infinite unions. \end{cislo} \begin{cislo}\label{COred}{\bf Reduced cohomology groups.} For every space $X\ne\emptyset$ we define the \emph{augmented cochain complex} \index{augmented cochain complex} $(\tilde C^*(X;G),\tilde\delta)$ as follows $$ \tilde C^n(X;G)= \hom(\tilde C_n(X);G) $$ with $\tilde\delta^nh=h\circ\tilde\partial_{n+1}$ for $h\in\hom(\tilde C_n(X);G)$. See 3.14. %\ref{HOred}. The \emph{reduced cohomology groups}\index{reduced cohomology groups} $\tilde H_n(X;G)$ with coefficients in $G$ are the cohomology groups of the augmented cochain complex. From the definition it is clear that $$\tilde H^n(X;G)=H^n(X;G)\quad \text{for }n\ne 0$$ and $$\tilde H^n(*;G)=0\quad\text{for all }n.$$ For pairs of spaces we define $\tilde H^n(X,A;G)=H^n(X,A;G)$ for all $n$. Then theorems on long exact sequence, homotopy invariance and excision hold for reduced cohomology groups as well. Considering a space $X$ with base point $*$ and applying the long exact sequence for the pair $(X,*)$, we get that for all $n$ $$\tilde H^n(X;G)=\tilde H^{n}(X,*;G)=H^{n}(X,*;G).$$ Using this equality and the long exact sequence for unreduced cohomology we get that $$H^0(X;G)\cong H^0(X,*;G)\oplus H^0(*;G)\cong \tilde H^0(X)\oplus \mathbb G.$$ Analogously as for homology groups we have \begin{lemma*} Let $(X,A)$ be a pair of CW-complexes. Then $$\tilde H^n(X/A;G)=H^n(X,A;G)$$ and we have the long exact sequence $$\dots\to \tilde H^n(X/A;G)\to \tilde H^n(X;G)\to \tilde H^n(A;G)\to \tilde H^{n+1}(X/A;G)\to\dots$$ \end{lemma*} \end{cislo} \begin{cislo}\label{COtriple}{\bf The long exact sequence of a triple.} Consider a triple $(X,B,A)$, $A\subseteq B\subseteq X$. Denote $i:(B,A)\hookrightarrow (X,A)$ and $j:(X,A)\to (X,B)$ maps induced by the inclusion $B\hookrightarrow X$ and $\id_X$, respectively. Analogously as for homology one can derive the long exact sequence of the triple $(X,B,A)$ $$\dots\xrightarrow{\ \delta^*\ } H^n(X,B;G)\xrightarrow{\ j^*\ } H^n(X,A;G)\xrightarrow{\ i^*\ } H^{n}(B,A;G)\xrightarrow{\ \delta^*\ }H^{n+1}(X,B;G)\xrightarrow{\ j^*\ }\dots$$ \end{cislo} \begin{cislo}\label{COsphere}{\bf Singular cohomology groups of spheres.} Considering the long exact sequence of the triple $(\Delta^n,\delta\Delta^n,V=\delta\Delta^n-\Delta^{n-1})$: we get that $$H^{i}(\Delta^n,\partial\Delta^n;G)= \begin{cases} G\quad& \text{for }i=n,\\ 0\quad& \text{for }i\ne n. \end{cases}$$ The pair $(D^n,S^{n-1})$ is homeomorphic to $(\Delta^n,\partial\Delta^n)$. Hence it has the same cohomology groups. Using the long exact sequence for this pair we obtain $$\tilde H^{i}(S^{n};G)=H^{i+1}(D^{n+1},S^{n})= \begin{cases} 0\quad & \text{for }i\ne n,\\ G\quad& \text{for }i=n. \end{cases}$$ \end{cislo} \begin{cislo}\label{COmves}{\bf Mayer-Vietoris exact sequence.} \index{Mayer-Vietoris exact sequence} Denote inclusions $A\cap B\hookrightarrow A$, $A\cap B\hookrightarrow B$, $A\hookrightarrow X$, $B\hookrightarrow X$ by $i_A$, $i_B$, $j_A$, $j_B$, respectively. Let $C\hookrightarrow A$, $D\hookrightarrow B$ and suppose that $X=\inte A\cup\inte B$, $Y=\inte C\cup\inte D$. Then there is the long exact sequence \begin{multline*} \dots \xrightarrow{\ \delta^*\ } H^n(X,Y;G)\xrightarrow{\ (j_{A}^*,j_{B}^*)\ } H^n(A,C;G)\oplus H^n(B,D;G)\\ \xrightarrow{\ i_{A}^*-i_{B}^*\ } H_{n}(A\cap B,C\cap D;G)\xrightarrow{\ \delta^*\ }H^{n+1}(X,Y;G) \xrightarrow{\ \ \ } \dots \end{multline*} \begin{proof} The coverings $\mathcal{U}=\{A,B\}$ and $\mathcal{V}=\{C,D\}$ satisfy conditions of Lemma 3.12. %\ref{HOet}. The sequence of chain complexes $$0\longrightarrow C_n(A\cap B,C\cap D)\overset{i}\longrightarrow C_n(A,C)\oplus C_n(B;D)\overset{j}\longrightarrow C_n^{\mathcal{U},\mathcal{V}}(X,Y)\longrightarrow 0$$ where $i(x)=(x,x)$ and $j(x,y)=x-y$ is exact. Applying $\hom(-,G)$ we get a new short exact sequence of cochain complexes $$0\longrightarrow C^n_{\mathcal{U},\mathcal{V}}(X,Y;G)\overset{j^*}\longrightarrow C^n(A,C;G)\oplus C^n(B,D;G)\overset{i^*}\longrightarrow C^n(A\cap B,C\cap D;G) \longrightarrow 0$$ and it induces a long exact sequence. Using Lemma 3.12 %\ref{HOet} we get that $H^n(C_{\mathcal{U},\mathcal{V}}(X,Y;G))=H^n(X,Y;G)$, which completes the proof. \end{proof} \end{cislo} \begin{cislo}\label{COcomp}{\bf Computations of cohomology of CW-complexes.} If we know a CW-structure of a space $X$, we can compute its cohomology in the same way as homology. Consider the chain complex from Section 4 \begin{equation*} (H_n(X^n,X^{n-1}),d_n). \end{equation*} \begin{thm*} Let $X$ be a CW-complex. The $n$-th cohomology group of the cochain complex $$(\hom(H_n(X^n,X^{n-1};G),d^n)\quad d^n(h)=h\circ d_n$$ is isomorphic to the $n$-th singular cohomology group $H^n(X;G)$. \end{thm*} \begin{ex} After reading the next section try to prove the theorem above using the results and proofs from Section 4. % \ref{HOCWcomp}. \end{ex} \begin{ex} Compute singular cohomology of real and complex projective spaces with coefficients $\mathbb Z$ and $\mathbb Z_2$. \end{ex} \end{cislo}