OFFSET
1,3
COMMENTS
a(n) is not 0 for n = 1, 3, 4, 5, 8, 9, 11, 15, 20, 21, 24, 25, 27, 28, 29, ... - Michel Marcus, Apr 16 2014
EXAMPLE
a(9) = 3 because
1) 9 + 1 + 1 = 11 and 9 + 9/1 + 1 = 19 are both prime for value of k = 1,
2) 9 + 3 + 1 = 13 and 9 + 9/3 + 1 = 13 are both prime for value of k = 3,
3) 9 + 9 + 1 = 19 and 9 + 9/9 + 1 = 11 are both prime for value of k = 9.
MAPLE
with(numtheory): A240753 := proc (n) local ct, k: ct := 0: for k in divisors(n) do if isprime(n+k+1) and isprime(n+n/k+1) then ct := ct+1: end if end do: return ct: end proc: seq(A240753(n), n = 1 .. 100); # Nathaniel Johnston, Apr 15 2014
PROG
(PARI) for(n=1, 100, m=0; fordiv(n, k, if(isprime(n+k+1) && isprime(n+n/k+1), m++)); print1(m, ", ")) \\ Colin Barker, Apr 12 2014
CROSSREFS
KEYWORD
nonn
AUTHOR
Ilya Lopatin and Juri-Stepan Gerasimov, Apr 12 2014
EXTENSIONS
Several terms and the example corrected by Colin Barker, Apr 13 2014
STATUS
approved