OFFSET

1,8

COMMENTS

Primes p such that a(p) = 0: 2, 3, 7, 19, 31.

EXAMPLE

a(8) = 2 because 2*8 - 4*1 - 1 = 11 is prime where 4*1 + 1 = 5 is prime of the form 4k+1 and 2*8 - 4*3 - 1 = 3 is prime where 4*3 + 1 = 13 is prime of the form 4k+1.

PROG

(Magma) A280667 := func<n|#[4*k+1: k in [1..(2*n-4) div 4]| IsPrime(4*k+1) and IsPrime(2*n-4*k-1)]>; [A280667(n):n in[1..100]];

(PARI) a(n) = sum(k=1, 2*n, isprime(k) && isprime(2*n-k) && ((2*n-k) % 4 == 1)); \\ Michel Marcus, Jan 07 2017

CROSSREFS

KEYWORD

nonn

AUTHOR

Juri-Stepan Gerasimov, Jan 07 2017

STATUS

approved