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!)
A322614 Smallest k such that A305445(k) = n, i.e., smallest k > 1 such that the minimum number of bit inversions required to convert k into a prime equals n. 2
2, 4, 8, 84, 45812984490 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,1
COMMENTS
Does a(n) exist for every n?
LINKS
PROG
(PARI) a305445(n) = my(b, L, N, s, v); if(n < 2, , if(isprime(n), 0, b = binary(n); L = #b; for(j = 1, L, v = vector(j, Y, [1, L]); forvec(X = v, N = n + sum(k = 1, j, if(b[X[k]], s = -1, s = 1); s*2^(L - X[k])); if(isprime(N), return(j)), 2)))) \\ after Rick L. Shepherd in A305445
a(n) = for(k=2, oo, if(a305445(k)==n, return(k)))
CROSSREFS
Cf. A305445.
Sequence in context: A087375 A018580 A267457 * A089337 A088114 A348050
KEYWORD
nonn,base,more
AUTHOR
Felix Fröhlich, Dec 20 2018
EXTENSIONS
a(4) from Giovanni Resta, Jan 03 2019
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 April 24 04:14 EDT 2024. Contains 371918 sequences. (Running on oeis4.)