# $a$ is a primitive root modulo a prime $p$; $ab\equiv1\bmod p$; prove $b$ is a primitive root modulo $p$

Let $p$ be prime. Prove that if $a$ is a primitive root modulo $p$ and $ab\equiv1\bmod p$, then $b$ is a primitive root modulo $p$.

I understand the definition of primitive roots. I am having trouble starting the proof and where to go afterwards.

Since $p$ is a prime, the powers of the primitive root $a$ modulo $p$ generate all the positive integers less than $p$ in some sequence, including 1. Since $b\equiv a^{-1}\bmod p$, the powers of $b$ modulo $p$ must generate the same sequence of positive integers less than $p$, but in reverse. Therefore the order of $b$ modulo $p$ is $p-1$ and $b$ is a primitive root modulo $p$.

In general, in any group you have that the order of $a$ is equal to the order of its inverse. This is just the special case in which $a$ is a generator of the multiplicative group of $\mathbb Z_p$.