A081352 Main diagonal of square maze arrangement of natural numbers A081349.
1, 7, 11, 21, 29, 43, 55, 73, 89, 111, 131, 157, 181, 211, 239, 273, 305, 343, 379, 421, 461, 507, 551, 601, 649, 703, 755, 813, 869, 931, 991, 1057, 1121, 1191, 1259, 1333, 1405, 1483, 1559, 1641, 1721, 1807, 1891, 1981, 2069, 2163, 2255, 2353, 2449, 2551
Offset: 0
Links
- B. Berselli, Table of n, a(n) for n = 0..10000
- Index entries for linear recurrences with constant coefficients, signature (2,0,-2,1).
Programs
-
Magma
I:=[1,7,11,21]; [n le 4 select I[n] else 2*Self(n-1)-2*Self(n-3)+Self(n-4): n in [1..50]]; // Vincenzo Librandi, Aug 08 2013
-
Maple
A081352:=n->(n + 1)*(n + 2) - (-1)^n; seq(A081352(n), n=0..50); # Wesley Ivan Hurt, Feb 26 2014
-
Mathematica
CoefficientList[Series[(1 + 5 x - 3 x^2 + x^3) / ((1 + x) (1 - x)^3), {x, 0, 60}], x] (* Vincenzo Librandi, Aug 08 2013 *)
-
PARI
x='x+O('x^99); Vec((1+5*x-3*x^2+x^3)/((1+x)*(1-x)^3)) \\ Altug Alkan, Mar 26 2016
Formula
a(n) = (n + 1)*(n + 2) - (-1)^n = 2*C(n+2, 2) - (-1)^n.
G.f.: (1 +5*x -3*x^2 +x^3) / ((1+x)*(1-x)^3). [Bruno Berselli, Aug 01 2010]
a(n) -2*a(n-1) +2*a(n-3) -a(n-4) = 0 with n>3. [Bruno Berselli, Aug 01 2010]
a(n) = (2*n^2 + 6*n - 2*(-1)^n + (-1)^(2*n) + 3)/2. - Kritsada Moomuang, Oct 24 2019
Comments