login
Semiprimes p*q for which p and q are successive primes and their binary representations differ from each other in one bit position only.
2

%I #11 Jan 29 2016 16:27:11

%S 6,35,323,437,899,1763,2021,4757,9797,10403,19043,22499,27221,38021,

%T 39203,72899,79523,95477,99221,131753,145157,154433,164009,205193,

%U 210677,213443,250997,272483,324899,381923,412163,416021,455621,549077,557993,594437,656099,675683,736163,741317,777923,783221,826277,870473,881717,974153,1022117,1102499,1127843,1238753

%N Semiprimes p*q for which p and q are successive primes and their binary representations differ from each other in one bit position only.

%C Numbers n for which A260737(n) = A261079(n) = 1.

%H Harvey P. Dale, <a href="/A261080/b261080.txt">Table of n, a(n) for n = 1..1000</a>

%F a(n) = A205511(n) * A205302(n).

%e 6 is included as 6 = 2*3, 2 and 3 are successive primes, and 2 (in binary "10") and 3 (in binary "11") differ by only one bit from each other.

%t brdQ[{a_,b_}]:=Module[{c=IntegerDigits[a,2],d=IntegerDigits[b,2]}, Length[ c] == Length[d]&&Count[Total/@Transpose[{c,d}],1]==1]; Times@@@ Select[ Partition[Prime[Range[200]],2,1],brdQ] (* _Harvey P. Dale_, Jan 29 2016 *)

%o (Scheme, two variants, the other one requiring _Antti Karttunen_'s IntSeq-library)

%o (define (A261080 n) (* (A205302 n) (A205511 n)))

%o (define A261080 (MATCHING-POS 1 1 (lambda (n) (and (= 1 (A260737 n)) (= 1 (A261079 n))))))

%Y Cf. A205302, A205511, A260737, A261079.

%Y Intersection of A006094 and A261077.

%K nonn

%O 1,1

%A _Antti Karttunen_, Sep 23 2015