%I #11 Jan 20 2019 07:45:55
%S 4,8,10,12,14,15,16,18,20,21,22,24,26,27,28,30,32,33,34,35,36,39,40,
%T 42,44,45,46,48,49,51,52,54,55,57,58,60,62,63,64,65,66,69,70,72,74,75,
%U 76,77,78,80,82,84,86,87,88,90,91,93,94,95,96,98,99,102,104,105,106,108
%N a(0)=4; for n > 0, a(n) is the smallest composite number c > a(n-1) such that c + n is also composite.
%e a(0)=4. Adding a(0) to n=0 gives 4+0=4, which is a composite number; adding a(1) to n=1 gives 8+1=9 which is composite; adding a(2) to n=2 gives 10+2=12 which is composite; adding a(3) to n=3 gives 12+3=15 which is composite; etc.
%p isA002808 := proc(n) option remember; RETURN(n>= 4 and not isprime(n)) ; end: A155878:= proc(n) option remember; local a; if n = 0 then 4; else for a from procname(n-1)+1 do if isA002808(a) and isA002808(a+n) then RETURN(a) ; fi; od: fi; end: seq(A155878(n),n=0..100) ; # _R. J. Mathar_, Jan 31 2009
%Y Cf. A155874.
%K base,easy,nonn
%O 0,1
%A _Eric Angelini_, Jan 29 2009
%E Extended by _R. J. Mathar_, Jan 31 2009
%E Name edited by _Jon E. Schoenfield_, Jan 20 2019