OFFSET
0,2
COMMENTS
From Erich Friedman's math magic page 2nd paragraph under "Answers" section.
Let A be the Hessenberg matrix of order n, defined by: A[1,j] = 1, A[i,i] = 2,(i>1), A[i,i-1] = -1, and A[i,j] = 0 otherwise. Then, for n >= 1, a(n) = (-1)^n*charpoly(A,-1). - Milan Janjic, Jan 26 2010
If n > 0 and H = hex number (A003215), then 9*H(a(n)) - 2 = H(a(n+1)), for example 9*H(2) - 2 = 9*19 - 2 = 169 = H(7). For n > 2, this is a subsequence of A017209, see formula. - Klaus Purath, Mar 31 2021
LINKS
Harry J. Smith, Table of n, a(n) for n = 0..200
Erich Friedman, Math. Magic
Index entries for linear recurrences with constant coefficients, signature (4,-3).
FORMULA
The following is a summary of formulas added over the past 18 years.
a(n) = 3*a(n-1) + 1; with a(0)=1, a(1)=2. - Jason Earls, Apr 29 2001
For n>0, a(n) = a(n-1)+5*3^(n-2) = (5*A003462(n)+1)/3 = a(n-1)+A005030(n-2). - Henry Bottomley, May 01 2001
From Colin Barker, Apr 24 2012: (Start)
a(n) = 4*a(n-1) - 3*a(n-2) for n > 2.
G.f.: (1-2*x+2*x^2)/((1-x)*(1-3*x)). (End)
a(n+1) = A134931(n) + 1. - Philippe Deléham, Apr 14 2013
For n > 0, A008343(a(n)) = 0. - Dmitry Kamenetsky, Feb 14 2017
For n > 0, a(n) = floor(3^n*5/6). - M. F. Hasler, Apr 06 2019
From Klaus Purath, Mar 31 2021: (Start)
a(n) = A017209(a(n-2)), n > 2.
a(n) = 2 + Sum_{i = 0..n-2} A005030(i).
a(n+1)*a(n+2) = a(n)*a(n+3) + 20*3^n, n > 1.
a(n) = 3^n - A007051(n-1). (End)
E.g.f.: (5*exp(3*x) - 3*exp(x) + 4)/6. - Stefano Spezia, Aug 28 2023
MATHEMATICA
LinearRecurrence[{4, -3}, {1, 2, 7}, 30] (* Harvey P. Dale, Nov 15 2022 *)
PROG
(PARI) { for (n=0, 200, if (n>1, a1=a=3*a1 + 1, if (n==0, a=1, a1=a=2)); write("b060816.txt", n, " ", a); ) } \\ Harry J. Smith, Jul 13 2009
(PARI) A060816(n)=if(n, 3^n*5\6, 1) \\ M. F. Hasler, Apr 06 2019
CROSSREFS
KEYWORD
easy,nonn
AUTHOR
Jason Earls, Apr 29 2001
EXTENSIONS
Edited by M. F. Hasler, Apr 06 2019 and by N. J. A. Sloane, Apr 09 2019
STATUS
approved