OFFSET
1,3
LINKS
Eric Weisstein's World of Mathematics, Independence Number.
Eric Weisstein's World of Mathematics, Mycielski Graph.
Eric Weisstein's World of Mathematics, Upper Domination Number.
Eric Weisstein's World of Mathematics, Upper Irredundance Number.
Index entries for linear recurrences with constant coefficients, signature (3,-2).
FORMULA
G.f.: x + x^2*(1 - x + x^2)/((1 - x)*(1 - 2*x)).
a(n) = 3*a(n-1)-2*a(n-2) for n>2. - Vincenzo Librandi, Jan 01 2016
a(n) = A052940(n-3) for n > 3. - Georg Fischer, Oct 23 2018
E.g.f.: (3*exp(2*x) - 8*exp(x) + 5 + 10*x+ 2*x^2)/8. - Stefano Spezia, Sep 14 2024
MATHEMATICA
Table[Piecewise[{{-1 + 3 2^(n - 3), n > 2}}, 1], {n, 35}]
CoefficientList[Series[1 + x*(1 - x + x^2)/((1 - x)*(1 - 2*x)), {x, 0, 35}], x] (* Vincenzo Librandi, Jan 01 2016 *)
PROG
(Magma) [1, 1] cat [-1+3*2^(n-3): n in [3..40]]; // Vincenzo Librandi, Jan 01 2016
(Magma) I:=[1, 1, 2, 5]; [n le 4 select I[n] else 3*Self(n-1)-2*Self(n-2): n in [1..40]]; // Vincenzo Librandi, Jan 01 2016
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Eric W. Weisstein, Dec 31 2015
EXTENSIONS
Definition broadened by Eric W. Weisstein, Feb 23 2026
STATUS
approved
