OFFSET
1,3
COMMENTS
This sequence is the number of digits of each term of A061583. - Dmitry Kamenetsky, Jan 17 2009
LINKS
Michael De Vlieger, Table of n, a(n) for n = 1..6023
Dominika Závacká, Cristina Dalfó, and Miquel Angel Fiol, Integer sequences from k-iterated line digraphs, CEUR: Proc. 24th Conf. Info. Tech. - Appl. and Theory (ITAT 2024) Vol 3792, 156-161. See p. 161, Table 2.
Index entries for linear recurrences with constant coefficients, signature (2,-1,1,-1).
FORMULA
From Joseph Myers, Feb 03 2004: (Start)
G.f.: (1 -x +x^2)/(1-2*x+x^2-x^3+x^4).
a(n) = a(n-1) + a(n-3) + 1. (End)
MATHEMATICA
LinearRecurrence[{2, -1, 1, -1}, {1, 1, 2, 4}, 50] (* or *) CoefficientList[ Series[(x^2-x+1)/(x^4-x^3+x^2-2x+1), {x, 0, 50}], x] (* Harvey P. Dale, Apr 24 2011 *)
PROG
(PARI) a(n)=([0, 1, 0, 0; 0, 0, 1, 0; 0, 0, 0, 1; -1, 1, -1, 2]^(n-1)*[1; 1; 2; 4])[1, 1] \\ Charles R Greathouse IV, Apr 07 2016
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
John W. Layman, May 02 2000
EXTENSIONS
More terms from Joseph Myers, Feb 03 2004
STATUS
approved