login
Numbers k such that the k-th non-single or nonisolated number is prime.
0

%I #8 Feb 18 2019 02:29:20

%S 1,6,8,10,11,13,15,16,17,18,21,22,23,26,27,28,29,33,34,36,38,39,40,42,

%T 44,45,47,48,49,51,52,53,54,55,56,57,58,59,60,63,64,65,66,68,69,70,71,

%U 72,73,74,76,77,78,79,81,82,83,85,86,88,90,91,93,94,95,96,97,98,99,100

%N Numbers k such that the k-th non-single or nonisolated number is prime.

%p A167706 := proc(n) if n = 1 then 2; else for a from procname(n-1)+1 do if isA007510(a) or isA014574(a) then return a; end if; end do; end if; end proc:

%p for n from 1 to 110 do p := A167706(n) ; if isprime(p) then printf("%d,",n) : end if; end do: # _R. J. Mathar_, May 23 2010

%Y Cf. A000040 (the prime numbers), A167706 (the single or isolated numbers).

%K nonn

%O 1,2

%A _Juri-Stepan Gerasimov_, Dec 11 2009

%E Corrected (20 replaced with 18, 25 replaced with 23, 32 replaced with 29, etc.) by _R. J. Mathar_, May 23 2010