login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A056120 a(n) = (3^3)*4^(n-3) with a(0)=1, a(1)=1 and a(2)=7. 2
1, 1, 7, 27, 108, 432, 1728, 6912, 27648, 110592, 442368, 1769472, 7077888, 28311552, 113246208, 452984832, 1811939328, 7247757312, 28991029248, 115964116992, 463856467968, 1855425871872 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,3
COMMENTS
For n>=3, a(n) is equal to the number of functions f:{1,2,...,n}->{1,2,3,4} such that for fixed, different x_1, x_2, x_3 in {1,2,...,n} and fixed y_1, y_2, y_3 in {1,2,3,4} we have f(x_i)<>y_i, (i=1,2,...,n). - Milan Janjic, May 13 2007
LINKS
FORMULA
a(n) = 4*a(n-1) + (-1)^n*binomial(3, 3-n).
G.f.: (1-x)^3/(1-4*x).
E.g.f.: (37 - 44*x + 8*x^2 + 27*exp(4*x))/64. - G. C. Greubel, Jan 18 2020
MAPLE
1, 1, 7, seq( 27*4^(n-3), n=3..25); # G. C. Greubel, Jan 18 2020
MATHEMATICA
Table[If[n<2, 1, If[n==2, 7, 27*4^(n-3)]], {n, 0, 25}] (* G. C. Greubel, Jan 18 2020 *)
PROG
(PARI) vector(26, n, if(n<2, 1, if(n==2, 7, 27*4^(n-3))) ) \\ G. C. Greubel, Jan 18 2020
(Magma) [1, 1, 7] cat [27*4^(n-3): n in [3..25]]; // G. C. Greubel, Jan 18 2020
(Sage) [1, 1, 7]+[27*4^(n-3) for n in (3..25)] # G. C. Greubel, Jan 18 2020
(GAP) Concatenation([1, 1, 7], List([3..25], n-> 27*4^(n-3) )); # G. C. Greubel, Jan 18 2020
CROSSREFS
Cf. A055841.
First differences of A002063.
Sequence in context: A054485 A090856 A055917 * A255278 A294262 A048711
KEYWORD
easy,nonn
AUTHOR
Barry E. Williams, Jul 05 2000
EXTENSIONS
a(21) corrected by R. J. Mathar, Dec 03 2014
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified May 1 19:14 EDT 2024. Contains 372176 sequences. (Running on oeis4.)