The OEIS mourns the passing of Jim Simons and is grateful to the Simons Foundation for its support of research in many branches of science, including the OEIS.
login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A216185 a(n) is the smallest odd number k with GCD(k,n)=1 such that all the powers of 2 mod k are distinct from n mod k, or 0 if n is a power of 2. 1
0, 7, 0, 7, 7, 15, 0, 31, 7, 15, 7, 7, 15, 23, 0, 7, 31, 7, 7, 23, 15, 17, 7, 31, 7, 7, 15, 15, 23, 7, 0, 7, 7, 39, 31, 15, 7, 17, 7, 7, 23, 15, 15, 7, 17, 7, 7, 31, 31, 23, 7, 23, 7, 7, 15, 17, 15, 7, 23, 7, 7, 17, 0, 17, 7, 15, 7, 7, 39, 15, 31, 7, 15, 7, 7 (list; graph; refs; listen; history; text; internal format)
OFFSET
2,2
COMMENTS
All nonzero values are >= 7.
LINKS
EXAMPLE
a(3) = 7 because the powers of 2 mod 7 are 2,4,1,2,4,1,2,4,1,2,4,... (and 3 never appears).
PROG
(PARI) a216185(n) = {local(k, m); if((omega(n) == 1) && (Mod(n, 2) == Mod(0, 2)), return(0), k=3; while(gcd(k, n) != 1 || (sum(m=0, eulerphi(k) - 1, (Mod(2, k)^m == Mod(n, k))) >= 1), k = k+2)); k} \\ Michael B. Porter, Mar 16 2013
CROSSREFS
Sequence in context: A341273 A011438 A321022 * A202996 A019597 A096444
KEYWORD
nonn
AUTHOR
J. Lowell, Mar 11 2013
EXTENSIONS
a(34)-a(76) from Michael B. Porter, Mar 16 2013
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified June 4 22:04 EDT 2024. Contains 373102 sequences. (Running on oeis4.)