1

Find $n$ such that $2^n = 1 \pmod m$ for a given odd number $m$. I have checked the first $400$ odd numbers and the $n$ values look pretty erratic so wondering there is a general solution in terms of $m$.

DeepSea
  • 77,651
  • 2
    The units group of the integers mod $m$ has order $\varphi(m)$ (number of integers less than $m$ that are coprime to $m$), so $n = \varphi(m)$ will always work. Are you looking for the smallest such $n$? – Francis Begbie Jan 10 '16 at 00:01
  • 1
    $2^n\equiv 1\pmod{m}\iff n=\text{ord}m(2)k$ for some $k\in\mathbb Z{\ge 0}$, so essentially you're asking about the behaviour of $\text{ord}_m(2)$ (i.e. the multiplicative order of $2$ mod $m$) for various odd positive integers $m$. – user236182 Jan 10 '16 at 00:22
  • See OEIS A002326. An easy lower bound on $\operatorname{ord}_m(2)$ is $\lceil \log_2 m \rceil$. So one way to articulate how "erratic" the sequence is would be by considering the ratio of $\operatorname{ord}_m(2)$ to said lower bound. – hardmath Jan 10 '16 at 00:36
  • To @FrancisBegbie, yes I was looking for an expression in terms of m for the "smallest" n, but in view of OEIS A002326 indicated by hardmath, it seems like there isn't any such expression, it is given as a sequence in open form a[m]= n. – Bahadir Canpolat Jan 10 '16 at 09:44
  • Oh, I don't think you will find a solution to that problem, but you may be able to develop some bounds or asymptotics. Check out Artin's Conjecture, which concerns how often a number is a primitive root modulo a prime (i.e. the last '$n$' is $\varphi(p)=p-1$) . – Francis Begbie Jan 10 '16 at 13:26

0 Answers0