The cohomology ring of an oriented closed $3$-manifold with $\pi_1=\mathbb Z$

Let $$M$$ be a closed, orientable, connected manifold of dimension $$3$$, such that $$\pi_1(M)=\mathbb Z$$. Find its cohomology ring $$H^*(M;\mathbb Z)$$.

Clearly $$H^0=H^3=\mathbb Z$$. Now since connected implies path connected on a manifold and we know $$H_1=\pi_1/[\pi_1,\pi_1]=\mathbb Z$$, and by Poincaré duality we have $$H^2=\mathbb Z$$. Since there is no torsion in $$H_0$$, then $$H^1(M)=\hom(H_1,\mathbb Z)=\mathbb Z$$. So the cohomology ring has one generator in each positive degree, let's call them $$\alpha\in H^1,\beta\in H^2,\gamma\in H^3$$. The only nontrivial relations to find are $$\alpha\cup\beta$$ and $$\alpha\cup\alpha$$.

By singularity of the cup product pairing $$H^1\times H^2\to \mathbb Z$$ with $$(\phi,\psi)\mapsto(\phi\cup\psi)[M]$$, and $$[M]$$ the fundamental class, we have that $$\alpha$$ is a generator if and only if $$\alpha\cup n\beta=\gamma$$ for some integer $$n$$. If it were true that $$\alpha\cup \alpha=\beta$$, then we could conclude that $$n=\pm1$$, but I don't know how to show (or not show) the latter.

First, the cup product is bilinear, so $$\alpha\cup n\beta=n(\alpha\cup \beta)$$ and so if $$n$$ were not $$\pm1$$ then there would be no possible value of $$\alpha\cup\beta$$. Thus $$n=\pm1$$, and without loss of generality $$n=1$$ by changing your generators if necessary.
As for $$\alpha\cup\alpha$$, since $$\alpha$$ has degree $$1$$ and the cup product is graded-commutative, $$\alpha\cup\alpha=-\alpha\cup\alpha$$ which immediately implies $$\alpha\cup\alpha=0$$ since $$H^2$$ is torsion-free.
• Would you say then that the ring is $\mathbb Z[\alpha,\beta,\gamma] / (\alpha^2,\beta^2,\gamma^2,\alpha\beta-\gamma)$ – George May 6 '19 at 23:29
If you believe that there's a single answer (i.e., given only the information that's it's closed, orientable, connected, and $$\pi_1 = \Bbb Z$$, you can determine the cohomology ring structure uniquely), then you can use the old trick, and compute the answer using an assumption that can be valid. In particular, you can assume that $$M = S^1 \times S^2$$.