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!)
A152661 Number of permutations of [n] for which the first two entries have the same parity (n>=2). 1

%I #15 Nov 28 2017 10:57:12

%S 0,2,8,48,288,2160,17280,161280,1612800,18144000,217728000,2874009600,

%T 40236134400,610248038400,9763968614400,167382319104000,

%U 3012881743872000,57621363351552000,1152427267031040000,24329020081766400000,535238441798860800000

%N Number of permutations of [n] for which the first two entries have the same parity (n>=2).

%C a(n) is also the number of 3-term arithmetic progressions of consecutive entries in all permutations of {1,2,...,n}. Example: a(4)=8 because we have 12'3'4, 412'3, 143'2, 23'41, 32'14, 43'2'1 (the mid-terms of the arithmetic progressions are marked). [_Emeric Deutsch_, Aug 31 2009]

%H S. Tanimoto, <a href="http://arxiv.org/abs/0812.1839">Combinatorial study on the group of parity alternating permutations</a>, arXiv:0812.1839 [math.CO], 2008-2017.

%F a(n) = A152660(n,1).

%F a(2n) = 2*(n!)^2*binomial(2*n-2,n);

%F a(2n+1) = n!*(n+1)!*binomial(2n,n-1).

%F Conjecture: (-n+3)*a(n) +2*(n-2)*a(n-1) +(n-1)*(n-2)*(n-3)*a(n-2)=0. - _R. J. Mathar_, Apr 20 2015

%F Conjecture: a(n) = 2*A077613(n-1). - _R. J. Mathar_, Apr 20 2015

%e a(4)=8 because we have 1324, 1342, 3124, 3142, 2413, 2431, 4213 and 4231.

%p a := proc (n) if `mod`(n, 2) = 0 then 2*factorial((1/2)*n)^2*binomial(n-2, (1/2)*n) else factorial((1/2)*n-1/2)*factorial((1/2)*n+1/2)*binomial(n-1, (1/2)*n-3/2) end if end proc: seq(a(n), n = 2 .. 22);

%t a[n0_?EvenQ] := With[{n = n0/2}, 2 (n!)^2*Binomial[2*n - 2, n]];

%t a[n1_?OddQ] := With[{n = (n1 - 1)/2}, n! (n + 1)! Binomial[2 n, n - 1]];

%t Table[a[n], {n, 2, 22}] (* _Jean-François Alcover_, Nov 28 2017 *)

%Y Cf. A152660.

%K nonn

%O 2,2

%A _Emeric Deutsch_, Dec 12 2008

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 24 22:17 EDT 2024. Contains 371964 sequences. (Running on oeis4.)