The OEIS is supported by the many generous donors to the OEIS Foundation.

 Hints (Greetings from The On-Line Encyclopedia of Integer Sequences!)
 A184908 Let S_n be the set of the integers having alternating bit sum equal to -n. There are a(n) primes among the smallest 3n+5 odd numbers of S_n. 1
 1, 7, 5, 0, 7, 5, 0, 7, 10, 0, 6, 3, 0, 5, 9, 0, 7, 7, 0, 7, 9, 0, 5, 6, 0, 6, 7, 0, 10, 7, 0, 4, 5, 0, 11, 7, 0, 10, 9, 0, 9, 4, 0, 4, 8, 0, 2, 6, 0, 9, 5, 0, 10, 9, 0, 8, 6, 0, 4, 3, 0, 4, 11, 0, 9, 3, 0, 5, 8, 0, 6, 3, 0, 11, 7, 0, 6, 8, 0, 5, 6 (list; graph; refs; listen; history; text; internal format)
 OFFSET 0,2 LINKS EXAMPLE The smallest 3n+5 = 8 odd numbers of the set S_1 of the integers having alternating bit sum -1 are 11, 35, 41, 47, 59, 107, 131, and 137, so a(1)=7. MAPLE A065359 := proc(n) local dgs ; dgs := convert(n, base, 2) ; add( -op(i, dgs)*(-1)^i, i=1..nops(dgs)) ; end proc: S := proc(n) local ads, k; ads := {} ; for k from 1 by 2 do if A065359(k) = -n then ads := ads union {k} ; end if; if nops(ads) = 3*n+5 then return ads; end if; end do: end proc: A184908 := proc(n) local ads, a, p; a := 0 ; for p in S(n) do if isprime(p) then a := a+1 ; end if; end do: a ; end proc: for n from 0 do print(A184908(n)); end do: # slow! R. J. Mathar, Feb 11 2011 PROG (PARI)II()={i = (2/3)*(4^n-1) + 1 + 2^(2*n+1); if(isprime(i), an++)}; III()={w = 2^(2*n+3); for(j=1, n+1, i += w; w /= 4; i -= w; if(isprime(i), an++ ))}; IV()={i+=6; if(isprime(i), an++ ); w=4; for(j=1, n, i -= w; w *= 4; i += w; if(isprime(i), an++))}; V()={i += 2^(2*n+4) - 2^(2*n+2); if(isprime(i), an++ ); w = i + 2^(2*n+5) - 2^(2*n+4); i = w - 2^(2*n+3) - 2^(2*n+1); if(isprime(i), an++ ); w = 2^(2*n+1); for(j=1, n, i += w; w /= 4; i -= w; if(isprime(i), an++ ))}; print1("1, 7, "); for(n=2, 80, an=0; II(); III(); IV(); V(); print1(an, ", ")) \\ Washington Bomfim, Feb 06 2011 CROSSREFS Cf. A065359, A065085, A184907, A020988. Sequence in context: A113223 A096414 A144923 * A197519 A290374 A202350 Adjacent sequences:  A184905 A184906 A184907 * A184909 A184910 A184911 KEYWORD nonn,base AUTHOR Washington Bomfim, Jan 27 2011 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.

Last modified May 27 16:48 EDT 2022. Contains 354110 sequences. (Running on oeis4.)