OFFSET
1,1
COMMENTS
Motivation was the form of differences between consecutive primes that generate this sequence. It seems that 12*k appears in all differences except 4.
Differences between corresponding consecutive primes are 36, 12, 4, 24, 24, 24, 24, 36, 24, 12, 36, 12, 36, 36, 60, 24, 36, 36, 60, 36, 24, 24, 24, 36, 12, 24 ...
LINKS
Amiram Eldar, Table of n, a(n) for n = 1..10000
G. Tarry, I. Franel, A. Korselt, and G. Vacca, Problème chinois, L'intermédiaire des mathématiciens 6 (1899), pp. 142-144.
Eric Weisstein's World of Mathematics, Carmichael Number
EXAMPLE
15841 is a term because it is a Carmichael number and average of 15823 and 15859 that are consecutive primes is equal to 15841.
126217 is a term because it is a Carmichael number and average of 126211 and 126223 that are consecutive primes is equal to 126217.
PROG
(PARI) is(n)={my(f); bittest(n, 0) && !for(i=1, #f=factor(n)~, (f[2, i]==1 && n%(f[1, i]-1)==1)||return) && #f>1}
forcomposite(n=1, 1e9, if(is(n) && (nextprime(n)-n)==(n-precprime(n)), print1(n, ", ")))
CROSSREFS
KEYWORD
nonn
AUTHOR
Altug Alkan, Dec 12 2015
STATUS
approved