OFFSET
1,2
COMMENTS
LINKS
EXAMPLE
a(2)=3 because 4=1+3 or 4=2+2 or 4=3+1;
a(3)=3 because 6=1+5 or 6=3+3 or 6=5+1;
a(4)=4 because 8=1+7 or 8=3+5 or 8=5+3 or 8=7+1;
a(5)=3 because 10=3+7 or 10=5+5 or 10=7+3.
PROG
(Haskell)
a096139 n = sum (map a010051 gs') + fromEnum (1 `elem` gs')
where gs' = map (2 * n -) $ takeWhile (< 2 * n) a008578_list
-- Reinhard Zumkeller, Aug 28 2013
(PARI) { a(n) = local(s(n) = if(n==1, 1, isprime(n))); sum(i=1, 2*n, s(i)*s(2*n-i)); } \\ Christian Krause, Dec 06 2022
CROSSREFS
KEYWORD
easy,nonn
AUTHOR
David Stroup, Jul 23 2004
EXTENSIONS
Example extended and typo fixed by Reinhard Zumkeller, Aug 28 2013
STATUS
approved