How to compute singular homologies of affine hypersurface in $A^4$ I was trying to compute singular homology in integer coefficient of the hypersurface $t^2-1=z^{n}+x(xy-1)$ contained in $A^4$. Can anyone help me computing that? Can anyone tell me some reference where singular homology of some singular affine variety is computed?
 A: Denote the hypersurface $\{(x,y,z,t)\in\Bbb{C}^4\mid t^2-1=z^n+x(xy-1)\}$ by $X$. The equation $x=0$ defines a closed subset $Z$ of $X$ that can be identified with $C\times\Bbb{C}$ where $C$ is the curve $\{(t,z)\in\Bbb{C}^2\mid t^2-1=z^n\}$. The complement $U:=X-Z$ may be identified with $\Bbb{C}^2\times\Bbb{C}^*$ because when $x\neq 0$, one can solve for $y$ as $\frac{t^2-1-z^n+x}{x^2}$. Now consider the long exact sequence in the compactly supported cohomology:
$$
\dots\rightarrow H^i_c(U)\rightarrow H^i_c(X)\rightarrow H^i_c(Z)\rightarrow H^{i+1}_c(U)\rightarrow\dots
$$
Possible non-zero cohomology groups of $Z=C\times\Bbb{C}$ and $U=\Bbb{C}^2\times\Bbb{C}^*$ are given by
$$
H^2_c(Z)\cong H_2(C\times\Bbb{C})\cong H_2(C),\,
H^3_c(Z)\cong H_1(C\times\Bbb{C})\cong H_1(C),\,  
H^4_c(Z)\cong H_0(C\times\Bbb{C})\cong H_0(C);\\
H^5_c(U)\cong H_1(\Bbb{C}^2\times\Bbb{C}^*)\cong \Bbb{Z},\,
H^6_c(U)\cong H_0(\Bbb{C}^2\times\Bbb{C}^*)\cong \Bbb{Z}.
$$
We deduce that for $i\notin\{2,3,4,5,6\}$ $H^i_c(X)$  is trivial; and
$$
H^2_c(X)\cong H^2_c(Z)\cong H_2(C),\\
H^3_c(X)\cong H^3_c(Z)\cong H_1(C),\\
H^6_c(X)\cong H^6_c(U)\cong\Bbb{Z};
$$
and finally, there is a long exact sequence
$$
0\rightarrow H^4_c(X)\rightarrow H_0(C)\rightarrow\Bbb{Z}\rightarrow H^5_c(X)\rightarrow 0.
$$
The curve $C:t^2-1=z^n$ in $\Bbb{C}^2$ is connected because the polynomial $t^2-1-z^n=0$ is irreducible (I am assuming $n\geq 1$). So we see that $C$ is a non-compact Riemann surface of finite type. To compute $H_1(C)$ (and hence $H^3_c(X)$), one should find the genus of its compactification and the number of punctures (points added at infinity); see the note below. Moreover, $H_2(C)$ is trivial (which gives us $H^2_c(X)=0$), and $H_0(C)$ is of rank $1$. Thus the last exact sequence may be written as
$$
0\rightarrow H^4_c(X)\rightarrow \Bbb{Z}\rightarrow\Bbb{Z}\rightarrow H^5_c(X)\rightarrow 0.
$$
So to compute the remaining two cohomology groups, one should analyze the middle morphism $H^4_c(Z)\cong\Bbb{Z}\rightarrow H^5_c(U)\cong\Bbb{Z}$. If it is injective, then $H^4_c(X)$ is trivial and $H^5_c(X)$ is a finite cyclic group. Otherwise, both groups are isomorphic to $\Bbb{Z}$.
Note: It is easy to check that $X$ is non-singular. So the compactly supported cohomology groups above result in homology groups by applying the Poincaré Duality: $H^i_c(X)\cong H_{6-i}(X)$.
Note. The curve $C:t^2=z^n+1$ is hyperelliptic. The compactification $\bar{C}$ is of genus $\frac{n-2}{2}$ if $n$ is even, and $\frac{n-1}{2}$ if $n$ is odd. In the former case, $\bar{C}\rightarrow\Bbb{CP}^1: (t,z)\mapsto t$ has two points above $\infty$ while in the latter case it has only one. Consequently, $H_1(C)$ is a free abelian group of rank $2(\frac{n-2}{2})+2-1=n-1$ if $2\mid n$, and of rank $2(\frac{n-1}{2})+1-1=n-1$ if $2\nmid n$. We conclude that $H^3_c(X)\cong H_1(C)\cong\Bbb{Z}^{n-1}$.
