A380651 a(n) = 4^n - n*3^(n-1).
1, 3, 10, 37, 148, 619, 2638, 11281, 48040, 203095, 851746, 3544765, 14651452, 60200131, 246114934, 1001997289, 4065384784, 16448074927, 66394953802, 267516917653, 1076266398436, 4324824038683, 17362058273950, 69646979806657, 279215540418808
Offset: 0
Examples
For n=2, the 10 words on {0, 1, 2, 3} that do not use 0 exactly once are 12, 21, 13, 31, 23, 32, 11, 22, 33, 00.
Links
- Paolo Xausa, Table of n, a(n) for n = 0..1000
- Index entries for linear recurrences with constant coefficients, signature (10,-33,36).
Programs
-
Mathematica
Table[4^n - n*3^(n - 1), {n, 0, 25}] (* Paolo Xausa, Feb 06 2025 *)
Formula
E.g.f.: exp(3*x)*(exp(x)-x).
From Alois P. Heinz, Jan 29 2025: (Start)
G.f.: -(13*x^2-7*x+1)/((4*x-1)*(3*x-1)^2).
Comments