cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

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.

Original entry on oeis.org

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

Views

Author

M. F. Hasler, Aug 08 2015

Keywords

Comments

Each second entry is 0 because the terms on the l.h.s. are all odd and the r.h.s. is even.

Examples

			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.
		

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).

Programs

  • 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.

Formula

a(2n-1) = 0 for all n >= 1.

Extensions

a(25)-a(49) from Alois P. Heinz, Aug 08 2015