OFFSET
1,2
LINKS
Harvey P. Dale, Table of n, a(n) for n = 1..1000
Index entries for linear recurrences with constant coefficients, signature (2,-1).
FORMULA
a(n) = floor(4*n-6+9/(n+1)-2/(n+1)^2). For n>=8 a(n)=4*n-6 - Benoit Cloitre, Aug 06 2003
EXAMPLE
a(2)=floor((1+2^1+2*2^2+4*2^3)/(1+2*2^1+2^2))=floor(43/9)=floor(4.77778)=4
MATHEMATICA
LinearRecurrence[{2, -1}, {1, 2, 4, 8, 11, 15, 19, 23, 26, 30}, 60] (* Harvey P. Dale, Jun 20 2020 *)
PROG
(PARI) a(n)=floor(4*n-6+9/(n+1)-2/(n+1)^2) \\ Charles R Greathouse IV, Oct 07 2015
CROSSREFS
KEYWORD
easy,nonn
AUTHOR
Wang Dan (wangdan01(AT)lycos.com), Aug 04 2003
EXTENSIONS
More terms from Benoit Cloitre, Aug 06 2003
STATUS
approved