|
| |
| |
|
|
|
0, 2, 8, 36, 192, 1200, 8640, 70560, 645120, 6531840, 72576000, 878169600, 11496038400, 161902540800, 2440992153600, 39230231040000, 669529276416000, 12093372555264000, 230485453406208000
(list; graph; refs; listen; history; internal format)
|
|
|
|
OFFSET
| 0,2
|
|
|
COMMENTS
| Total number of pairs (a_i,a_(i+1)) in all permutations on [n] such that a_i,a_(i+1) are consecutive integers. - David Callan (callan(AT)stat.wisc.edu), Nov 04 2003
Number of permutations of {1,2,...,n+2} such that there is exactly one entry between the entries 1 and 2. Example: a(2)=8 because we have 1324, 1423, 2314, 2413, 3142, 4132, 3241 and 4231. - Emeric Deutsch (deutsch(AT)duke.poly.edu), Apr 06 2008
a(n)=A138770(n+2,1). - Emeric Deutsch (deutsch(AT)duke.poly.edu), Apr 06 2008
Number of permutations of 0 to n distinct letters (ABC...) 1 times ("-" (0), A (1), AB (1-1), ABC (1-1-1), ABCD (1-1-1-1 )etc...) and one after the other to resemble motif:( "-",... BB (0-2), ABB (1-2-0), AABB (2-2-0-0), AAABB (3-2-0-0-0) AAAABB (4-2-0-0-0-0), AAAAABB (5-2-0-0-0-0-0), AAAAAABB (6-2-0-0-0-0-0-0), etc... 0 fixed point (or free fixed point). Example: if ABC (1-1-1) and motif ABB (1-2-0) then 2 * 0 (free) fixed point, if ABCD (1-1-1-1), and motif AABB (2-2-0-0) then 8 * 0 (free) fixed point, if ABCDE (1-1-1-1-1), and motif AAABB (3-2-0-0-0), then 36 * 0 (free) fixed point, if ABCDEF (1-1-1-1-1-1), and motif AAAABB (4-2-0-0-0-0), then 192 * 0 (free) fixed point, if ABCDEFG (1-1-1-1-1-1-1), and motif AAAAABB (5-2-0-0-0-0-0), then 1200 * 0 (free) fixed point, etc... [From Zerinvary Lajos (zerinvarylajos(AT)yahoo.com), Dec 07 2009]
|
|
|
LINKS
| Reinhard Zumkeller, Table of n, a(n) for n = 0..250
INRIA Algorithms Project, Encyclopedia of Combinatorial Structures 526
|
|
|
FORMULA
| E.g.f.: 2*x / (1 - x)^2.
Recurrence: {a(0)=0, a(1)=2, (-n^2-2*n-1)*a(n)+a(n+1)*n=0.}.
a(n) = A001339(n) - A007808(n). - Michael Somos, Oct 20 2011
a(n) = (a(n-1)^2 - 2 * a(n-2)^2 + a(n-2) * a(n-3) - 4 * a(n-1) * a(n-3)) / (a(n-2) - a(n-3)) if n>2. - Michael Somos, Oct 20 2011
a(n)=2*n*n! [From Gary Detlefs (gdetlefs(AT)aol.com), Sep 16 2010]
a(n+1) = a(n) * (n+1)^2 / n. [Reinhard Zumkeller, Nov 12 2011]
|
|
|
MAPLE
| spec := [S, {S=Prod(Sequence(Z), Sequence(Z), Union(Z, Z))}, labeled]: seq(combstruct[count](spec, size=n), n=0..20);
|
|
|
MATHEMATICA
| a[ n_] := If[ n<0, 0, n! SeriesCoefficient[ 2 x / (1 - x)^2, {x, 0, n}]] (* Michael Somos, Oct 20 2011 *)
a[ n_] := If[ n<0, 0, 2 n n!] (* Michael Somos, Oct 20 2011 *)
|
|
|
PROG
| {a(n) = if( n<0, 0, 2 * n * n!)} /* Michael Somos, Oct 20 2011 */
(Haskell)
a052582 n = a052582_list !! n
a052582_list = 0 : 2 : zipWith
div (zipWith (*) (tail a052582_list) (drop 2 a000290_list)) [1..]
-- Reinhard Zumkeller, Nov 12 2011
|
|
|
CROSSREFS
| Cf. A001339, A007808, A138770.
Cf. A000142, A000290.
Sequence in context: A081958 A001540 A129044 * A020021 A052618 A055142
Adjacent sequences: A052579 A052580 A052581 * A052583 A052584 A052585
|
|
|
KEYWORD
| easy,nonn
|
|
|
AUTHOR
| encyclopedia(AT)pommard.inria.fr, Jan 25 2000
|
| |
|
|