TITLE: A non-abelian group such that $G/Z(G)$ is abelian.
QUESTION [12 upvotes]: I'm looking for an example of a non-abelian group $G$ such that $G/Z(G)$ is abelian, where $Z(G)$ is the center of the $G$. In other words, I'm looking for a non-abelian group where $Z(G)$ contains the commutator subgroup $[G,G]$.
Further, what if I request $G/Z(G)$ to be a finitely generated and abelian group?

REPLY [8 votes]: A good example of an infinite group of this kind is the "integer Heisenberg group". It has a matrix representation as the group of $3 \times 3$ matrices with $1$'s on the diagonal, $0$'s below the diagonal, and integers above the diagonal. Its center is the infinite cyclic group generated by matrix with one $1$ in the upper right hand corner and with two $0$'s on the super diagonal (and $1$'s on the diagonal). The quotient group is isomorphic to $\mathbb{Z}^2$, represented by nonzero entries on the superdiagonal.