This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.
%I A131188 #15 Nov 03 2016 15:26:00 %S A131188 6,13,48,103,270,508,1001,1413,2724,3052,4859,5668,8029,9062,9608, %T A131188 12558,13828,17319,18823,22781,28077,40162,42359,48113,60703,71793, %U A131188 79161,83792,90129,94954,140436,144445,146452,156704,165199,218110,223095 %N A131188 Indices of products of twin primes in the semiprimes. %H A131188 Zak Seidov, <a href="/A131188/b131188.txt">Table of n, a(n) for n = 1..300</a> %F A131188 {i: A001358(i) = A001359(k) * A006512(k), for some k > 0}. - _R. J. Mathar_, Oct 26 2007 %e A131188 Ignoring (2, 3), the first twin prime pair is (3, 5). We have 3 * 5 = 15, which is the sixth semiprime (the previous five semiprimes being 4, 6, 9, 10, 14). Hence 6 is the first term of this sequence. %e A131188 The second twin prime pair is (5, 7). Then 5 * 7 = 35, which is the thirteenth semiprime (following 21, 22, 25, 26, 33, 34). Hence 13 is the second term of this sequence. %p A131188 N:= 10^7: # to use semiprimes <= N %p A131188 P:= select(isprime, [2,seq(i,i=3..N/2,2)]): %p A131188 count:= 0: %p A131188 for i from 1 to numtheory:-pi(floor(sqrt(N))) do %p A131188 for j from i to nops(P) while P[i]*P[j] <= N do %p A131188 count:= count+1; %p A131188 S[count]:= [P[i]*P[j],evalb(P[j]-P[i]=2)] %p A131188 od od: %p A131188 S:= sort(convert(S,list),(a,b) -> a[1]<b[1]): %p A131188 select(t -> S[t][2],[$1..nops(S)]); # _Robert Israel_, Dec 30 2015 %t A131188 s = Select[Range[10^6], PrimeOmega@ # == 2 &]; Map[Position[s, #] &, # (# + 2) &@ Select[Prime@ Range@ 160, NextPrime@ # - # == 2 &]] // Flatten (* _Michael De Vlieger_, Dec 31 2015 *) %t A131188 Module[{upto=2*10^6,sp,tp},sp=Select[Range[upto],PrimeOmega[#]==2&]; tp= Times@@@Select[Partition[Prime[Range[upto/2]],2,1],#[[2]]-#[[1]] == 2&]; Table[Position[sp,n],{n,tp}]]//Flatten (* _Harvey P. Dale_, Nov 03 2016 *) %Y A131188 Cf. A128301. %K A131188 nonn %O A131188 1,1 %A A131188 _Zak Seidov_, Sep 25 2007 %E A131188 More terms from _R. J. Mathar_, Oct 26 2007