In this paper we investigate the solutions of the equation in the title, where φ is the Euler function. We first show that it suffices to find the solutions of the above equation when m = 4 and x and y are coprime positive integers. For this last equation, we show that aside from a few small solutions, all the others are in a one-to-one correspondence with the Fermat primes.
We assign to each pair of positive integers $n$ and $k\ge 2$ a digraph $G(n,k)$ whose set of vertices is $H=\{0,1,\dots ,n-1\}$ and for which there is a directed edge from $a\in H$ to $b\in H$ if $a^k\equiv b\pmod n$. We investigate the structure of $G(n,k)$. In particular, upper bounds are given for the longest cycle in $G(n,k)$. We find subdigraphs of $G(n,k)$, called fundamental constituents of $G(n,k)$, for which all trees attached to cycle vertices are isomorphic.