login
A261044
Number of solutions to c(1)*prime(4)+...+c(n)*prime(n+3) = -2, where c(i) = +-1 for i > 1, c(1) = 1.
17
0, 0, 0, 0, 0, 0, 0, 2, 0, 5, 0, 18, 0, 48, 0, 170, 0, 540, 0, 1868, 0, 6385, 0, 22247, 0, 79355, 0, 282754, 0, 1008714, 0, 3627599, 0, 13156851, 0, 47949883, 0, 175599692, 0, 646384942, 0, 2392644640, 0, 8890619925, 0, 32943781423, 0, 122928406923, 0
OFFSET
1,8
COMMENTS
Each second entry is 0 because the terms on the l.h.s. are all odd and the r.h.s. is even.
FORMULA
a(2n-1) = 0 for all n >= 1.
EXAMPLE
a(8) = 2 counts the two solutions prime(4) - prime(5) + prime(6) - prime(7) - prime(8) + prime(9) - prime(10) + prime(11) = -2 and prime(4) - prime(5) - prime(6) + prime(7) + prime(8) - prime(9) - prime(10) + prime(11) = -2.
PROG
(PARI) A261044(n, rhs=-2, firstprime=4)={rhs-=prime(firstprime); my(p=vector(n-1, i, prime(i+firstprime))); sum(i=1, 2^#p-1, sum(j=1, #p, (-1)^bittest(i, j-1)*p[j])==rhs)} \\ For illustrative purpose; too slow for n >> 10.
CROSSREFS
Cf. A261061 - A261063 (starting with prime(1), prime(2) and prime(3)), A022894 - A022904, A083309, A022920 (r.h.s. = 0, 1 or 2), A261057, A261059, A261060, A261045 (r.h.s. = -2).
Sequence in context: A126120 A260330 A094032 * A117780 A155759 A202209
KEYWORD
nonn
AUTHOR
M. F. Hasler, Aug 08 2015
EXTENSIONS
a(25)-a(49) from Alois P. Heinz, Aug 08 2015
STATUS
approved