Prove, that group of order $p^2$ is abelian. I know there is a proof using these theorems:


*

*The center of a finite p−group is non-trivial

*For any group G ,
$G/Z(G)$ is cyclic iff $G$ is abelian, or in otherwords: the quotient
$G/Z(G)$ can never be non-trivial cyclic.
But is there a proof not using these theorems?
 A: If there is an element of order $p^2$, it's cyclic and thus abelian. Suppose there is no element element of order $p^2$. Then, the order of of the elements of $G$ are either $1$ or $p$. Let $h_1,h_2\in G$ two elements of order $p$ s.t. $h_2\notin\left<h_1\right>$. Then, $\left<h_1,h_2\right>$ is of order $p^2$ and is s.t. $|\left<h_1,h_2\right>|\geq p+1$. Therefore, $|\left<h_1,h_2\right>|=p^2$, and thus $G=\left<h_1,h_2\right>$. Therefore, $G$ is abelian.
We can show that $\left<h_i\right>$ are normal in $G$. Then, $[G:H_i]=p$ and thus $G/H_i$ are cyclic, and thus abelian. Let consider $$\pi: G\longrightarrow G/H_i,$$
defined by $\pi(g)=gH_i$. Take an element of $[G,G]=\left<ghg^{-1}h^{-1}\mid g,h\in G\right>$. You have that
$$\pi(ghg^{-1}h^{-1})=\pi(g)\pi(h)\pi(g^{-1})\pi(h^{-1})\underset{G/H_i\ cyclic}{=}H_i$$
and thus and thus $[G,G]\leq H_i$, and since $H_1\cap H_2=\{1\}$, we get $[G,G]=\{1\}$. Therefore $G=G/[G:G]$ is abelian. 
A: Let $G$ be a non-cyclic group of order $p^2$ with identity element $e$, and let $g,h\in G$ of order $p$ such that $\langle g\rangle\cap \langle h \rangle = \{e\}$. Assume by way of contradiction that $g$ and $h$ do not commute. I claim that $ghg^{-1}$ cannot be a power of $h^k$ of $h$, for if it were, then one calculates that $g^rhg^{-r} = h^{k^r}$ for all $r$, and then $g^{p-1}hg^{1-p} = h^{k^{p-1}}$, which is equal to $h$ by Fermat. This would imply $g^{-1}h=hg^{-1}$ and now $gh=hg$, contradiction.
So $\langle h\rangle$ and $\langle ghg^{-1}\rangle$ are distinct subgroups of order $p$, and the distinct cosets of $\langle ghg^{-1}\rangle$ in $G$ are $\langle ghg^{-1}\rangle, h\langle ghg^{-1}\rangle, h^2\langle ghg^{-1}\rangle, \dots, h^{p-1}\langle ghg^{-1}\rangle$. Therefore $g^{-1}$ lies in some $h^k\langle ghg^{-1}\rangle$, so $g^{-1}=h^kgh^{\ell}g^{-1}$ for some $\ell$. Then $e=h^kgh^{\ell}$ and $g=h^{-k-\ell}$, contradicting that $\langle g \rangle$ and $\langle h \rangle$ intersect trivially.
Well, now we are done: $g$ and $h$ commute, so the mapping from $\mathbb Z_p\times \mathbb Z_p$ to $G$ taking $(a,b)$ to $g^ah^b$ is an isomorphism.
A: Now for something completely different (using representation theory over $\mathbb{C}$)...Let $G$ be a group of order $p^2$. Let $Irr(G)$ be its set of complex irreducible characters. Note that the principal character $1_G \in Irr(G)$. Since $|G|=p^2=\sum_{\chi \in Irr(G)}\chi(1)^2=1 + \sum_{\chi \in Irr(G)-\{1_G\}}\chi(1)^2$, and for all $\chi \in Irr(G)$: $\chi(1) \mid p^2$, it follows that all $\chi$ must be linear, which is equivalent to $G$ being abelian.
A: Here I am referencing a solution given on Aryaman Maithani's github page. These steps can lead the proof straight forwardly and they are:
Firstly, use the first lemma you mentioned to conclude that $Z(G)$ is of order $p$ or $p^2$. The latter case is trivial by the definition of the center. In the former case, take an element $x$ from $G\setminus Z(G)$ and consider all the elements of $G$ that commute to $x$, name that set $H$. Prove that this set $H$ is a subgroup of $G$. Because $x\in H$ we have that $Z(G)$ is a proper subset of $H$. Then, $H$ is a proper subset of $G$ because $x$ isn't in $Z(G)$. Now the order of $H$ must be strictly between $p$ and $p^2$ and must divide $p^2$. This is obviously impossible and that is the contradiction for the former case.
A: We use the fact that the center of any $p-$group is non-trivial (this uses the class equation). Since the order of $G$ is $p^2$, by LaGrange's theorem as $Z(G) \leq G$, we have that either (as $Z(G) \neq \{e\}$) $\vert Z(G) \vert=p$ or $p^2$. If $\vert Z(G) \vert = p^2$, then $Z(G)=G$ and $G$ is abelian. Suppose then that $\vert Z(G) \vert = p$. Then $Z(G) \varsubsetneq G$ and $G$ is non-abelian. Then $\vert G/ Z(G) \vert = \frac{p^2}{p}=p$, then
$$G/Z(G) \cong \Bbb{Z} / p \Bbb{Z}.$$
And we know $\Bbb{Z} / p \Bbb{Z}$ is cyclic hence $G/Z(G)$ is cyclic thus $G$ is abelian (fact that $G$ is abelian iff $G/Z(G)$ is cyclic), contradiction as $G \neq Z(G)$, thus $Z(G)$ has order $p^2$ hence $Z(G)=G$ forcing $G$ to be abelian.
