OFFSET
1,2
COMMENTS
Partial sums of maximum length of non-crossing path on n X n square lattice. The subsequence of primes in this partial sum begins: 5, 197, 593, 3613, 11113, 17183.
LINKS
Index entries for linear recurrences with constant coefficients, signature (3, -2, -2, 3, -1).
FORMULA
a(n) = SUM[i=1..n] A049486(i).
Conjecture: a(n) = (3*(-9+(-1)^n)+34*n-12*n^2+8*n^3)/12 for n>1. G.f.: x*(x^5-x^4+3*x^3+2*x^2+2*x+1) / ((x-1)^4*(x+1)). - Colin Barker, May 02 2013
EXAMPLE
a(7) = 1 + 4 + 10 + 21 + 34 + 53 + 74 = 197 is prime.
MATHEMATICA
Accumulate[Join[{1, 4}, LinearRecurrence[{2, 0, -2, 1}, {10, 21, 34, 53}, 40]]] (* or *) Join[{1, 5}, LinearRecurrence[{3, -2, -2, 3, -1}, {15, 36, 70, 123, 197}, 40]] (* Harvey P. Dale, Aug 21 2013 *)
CROSSREFS
KEYWORD
nonn
AUTHOR
Jonathan Vos Post, Mar 25 2010
STATUS
approved