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!)
A152878 Triangle read by rows: T(n,k) is the number of permutations of {1,2,...,n} with maximal number of initial entries of the same parity equal to k (1 <= k <= ceiling(n/2)). 0
1, 2, 4, 2, 16, 8, 72, 36, 12, 432, 216, 72, 2880, 1440, 576, 144, 23040, 11520, 4608, 1152, 201600, 100800, 43200, 14400, 2880, 2016000, 1008000, 432000, 144000, 28800, 21772800, 10886400, 4838400, 1814400, 518400, 86400, 261273600 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,2
COMMENTS
Sum of entries in row n is n! = A000142(n).
Row n contains ceiling(n/2) entries.
REFERENCES
E. Deutsch and J. H. Nieto, Mathematics Magazine, Problem 1823, Vol. 83, No. 3, 2010, pp. 230-231. [From Emeric Deutsch, Aug 12 2010]
LINKS
FORMULA
a(2n,k) = 2nk!(2n-k-1)!binomial(n,k);
a(2n+1,k) = n!(n+1)!*binomial(2n-k+1,n).
From Emeric Deutsch, Aug 12 2010: (Start)
T(n,k) = (ceiling(n/2)*binomial(floor(n/2),k) + floor(n/2)*binomial(ceiling(n/2),k))*k!*(n-k-1)! (from J. H. Nieto's solution).
(End)
EXAMPLE
T(4,2)=8 because we have 1324, 1342, 3124, 3142, 2413, 2431, 4213 and 4231.
T(5,3)=12 because the first 3 entries form a permutation of (1,3,5) (6 choices) and the last 2 entries form a permutation of {2,4} (2 choices).
Triangle starts:
1;
2;
4, 2;
16, 8;
72, 36, 12;
432, 216, 72;
MAPLE
ae := proc (n, k) options operator, arrow: 2*n*factorial(k)*factorial(2*n-k-1)*binomial(n, k) end proc: ao := proc (n, k) options operator, arrow: factorial(n)*factorial(n+1)*binomial(2*n-k+1, n) end proc: a := proc (n, k) if `mod`(n, 2) = 0 and k <= (1/2)*n then ae((1/2)*n, k) elif `mod`(n, 2) = 1 and k <= ceil((1/2)*n) then ao((1/2)*n-1/2, k) else 0 end if end proc: for n to 12 do seq(a(n, k), k = 1 .. ceil((1/2)*n)) end do; # yields sequence in triangular form
CROSSREFS
Cf. A000142.
Sequence in context: A134763 A370135 A290645 * A186526 A350816 A326723
KEYWORD
nonn,tabf
AUTHOR
Emeric Deutsch, Dec 26 2008
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 April 25 05:18 EDT 2024. Contains 371964 sequences. (Running on oeis4.)