Cent. Eur. J. Math. • 12(9) • 2014 • 1390-1402 DOI: 10.2478/s11533-014-0421-2
Central European Journal of Mathematics
Parity-alternating permutations and successions
Research Article
Augustine O. Munagi1∗
1 School of Mathematics, University of the Witwatersrand, Private Bag 3, Wits 2050, Johannesburg, South Africa
Received 24 January 2013; accepted 10 September 2013
Abstract: The study of parity-alternating permutations of {1; 2; : : : ; n} is extended to permutations containing a prescribed number of parity successions – adjacent pairs of elements of the same parity. Several enumeration formulae are computed for permutations containing a given number of parity successions, in conjunction with further parity and length restrictions. The objects are classified using direct construction and elementary combinatorial techniques. Analogous results are derived for circular permutations.
MSC: 05A05, 05A15
Keywords: Parity-alternating permutation • Succession block • Circular permutation © Versita Sp. z o.o.
1. Introduction
p ; p ;::: n { ; ; : : : ; n} We consider the enumeration of linear permutations ( 1 2 ) of elements of the set [ ] = 1 2 with respect p ; p to pairs of entries ( i i+1) satisfying p ≡ p ; i > : i i+1 (mod 2) 0 (1) p ; p parity succession succession An ordered pair ( i i+1) satisfying (1) will also be called a , or simply a . This terminology is adapted from an analogous usage in the study of finite integer sequences (π(1); : : : ; π(N)) in which a succession refers to a pair π(i); π(i + 1) with π(i + 1) = π(i) + 1 (see for example [2, 3, 6, 8]). The concept of parity succession was first introduced in [5] in connection with certain general results in the study of alternating subsets of integers. Our definition immediately generalizes the class of parity-alternating permutations, that is, linear arrangements of distinct positive integers in which the terms assume even and odd values alternately. Since there is no pair of adjacent elements satisfying (1), a parity-alternating permutation always contains 0 successions.
∗ E-mail: [email protected]
1390 A.O. Munagi
Enumeration study of permutations of [n] according to parity of individual elements is still at a budding stage. Tanimoto has applied the properties of parity-alternating permutations to the investigation of signed Eulerian numbers [7]. But we found only one relevant enumeration result, namely (2) below. In [4] the author provides permutation analogues of classical theorems on alternating subsets such as the theorems of Terquem and Skolem, with some generalizations. This paper supplies a budget of enumeration formulae for permutations classified by assorted parity criteria. Permutations are arguably the most popular objects in combinatorics, and it should not come as a surprise to find more interesting results here than those from alternating subsets. f n n The number 0( ) of parity-alternating permutations of [ ] may be stated as follows:
− n n n f n 3 + ( 1) + 1 0( ) = ! ! (2) 2 2 2
We will obtain several generalizations of (2) by imposing restrictions on the number of elements of a fixed parity, the number of parity successions, and so forth (Section 2). We begin by devising a fundamental algorithm for constructing the relevant permutations (proof of Theorem 2.1). By a succession block we understand a maximal (sub-)string of elements of the same parity. A sequence of consecutive succession blocks will also be referred to as alternating. For example, the permutation (10; 1; 3; 9; 5; 12; 4; 11; 6; 2; 7; 8) has seven alternating blocks, (10); (1; 3; 9; 5); (12; 4); (11); (6; 2); (7); (8), consisting of three blocks of odd integers and four blocks of even integers, with a total of five parity successions of which two are contributed by even integers. The final section deals with the enumeration of circular permutations of [n] under similar parity restrictions (Section 3). The section opens with a brief description of these permutations. The following basic facts and notations will be used in the proofs. • The number c(n; m) of compositions (or ordered partitions) of a positive integer n into m parts is given by [1, p. 54]: c n; m n−1 ( ) = m−1 . • A permutation of [n] taken k at a time, will be referred to as a k-permutation of [n]. If a k-permutation contains r parity successions and v alternating succession blocks, then v = k − r: representing the lengths of the blocks by b ; : : : ; b k b ··· b b − ··· b − v r v 1 v , we have = 1 + + v = ( 1 1) + + ( v 1) + = + . • The number of odd and even integers in [n] will be denoted, respectively, by D(n) and E(n), that is, D(n) = b(n+1)/2c, E(n) = bn/2c. • The formula for the number p(N; k) of k-permutations of [N] has three forms, namely, N! N p(N; k) = = k! = Nk ; (N − k)! k
N N N N − ··· N − k N p N; k where k denotes the falling factorial, k = ( 1) ( + 1), 0 = 1. Our choice of expression for ( ), at any time, will depend on brevity, typesetting convenience or aesthetic appeal. n • If n ≥ 0, then the binomial coefficient k will assume the value zero if k is negative or not integral.
2. Enumeration of permutations by parity successions
Let f(n; k; s; r) denote the number of k-permutations of [n] containing s odd integers and r parity successions. Then f(n; 1; s; r) = 0 if r > 0 since a singleton cannot contain a succession, and f(n; 1; 0; 0) = E(n), that is,
n f n; ; ; r δ ; ( 1 0 ) = r;0 2 where δij is the Kronecker delta. We also have
n f n; s; s; r + 1 δ ; ( ) = r;s−1 2 s
1391 Parity-alternating permutations and successions
since an s-permutation consisting of odd integers contains s − 1 successions. In every permutation enumerated by f(n; k; s; r), the number k − r of alternating blocks of even and odd integers cannot exceed 2s or 2s + 1, depending on parity. Hence s ≥ b(k − r)/2c. For an upper bound we consider an object in which the first and last entries are odd integers. If odd integers account for all the successions, then there are k − s even integers separating the blocks of odd integers. Thus in general, k − r = 2(k − s) + 1, or 2s = k + r + 1. Hence k − r k + r + 1 f(n; k; s; r) > 0 =⇒ ≤ s ≤ ; (3) 2 2
where the last quantity is independently bounded above by k and D(n). k n s r We remark that the number of -permutations of [ ] containing 0 even integers and parity successions is given by f n; k; k − s ; r ( 0 ).
Theorem 2.1. Let n; k; s; r be positive integers, 2 ≤ k < n, 1 ≤ s < k, with s satisfying equation (3). Then s − 1 k − s − 1 s − 1 k − s − 1 n + 1 n f(n; k; s; r) = k − r − 1 k − r − 2 + k − r − 2 k − r − 1 : 2 s 2 k−s 2 2 2 2
Proof. We construct an enumerated object B as follows. The symbols o and e will represent an unspecified odd and s n o ; o ; : : : ; o p D n ; s even integer, respectively. Take any -permutation of [ ] consisting of odd integers ( 1 2 s), in ( ( ) ) ways, k − s n b ; b ; : : : ; bv s c s; v and a ( )-permutation of [ ] consisting of even integers. Then obtain a composition ( 1 2 1 ) of , in ( 1) ways, to represent the sequence of sizes of the blocks of odd integers in B. Let the block sizes of even integers be c ; c ; : : : ; cv B ( 1 2 0 ). So the sequence of lengths of the alternating blocks of (assuming an odd first element) has the form b ; c ; b ; c ;::: ( 1 1 2 2 ). B o ; o ; : : : ; o j To specify , we insert separators in the permutation ( 1 2 s) so that a separator immediately follows the -th j b ; b b ; b b b ;::: k − s element, where = 1 1 + 2 1 + 2 + 3 The ( )-permutation of even integers is similarly separated. Now combine the two sequences of succession blocks, alternately, in a unique manner consistent with the prescribed form of B. Let f(n; k; s; r)T denote the number of permutations counted by f(n; k; s; r) in which the first element has parity T . If T is of either parity, it follows that
f n; k; s; r p D n ; s p E n ; k − s c s; v c k − s; v ; ( )T = ( ( ) ) ( ( ) ) ( 1) ( 0)
that is, s − k − s − f n; k; s; r p D n ; s p E n ; k − s 1 1 : ( )T = ( ( ) ) ( ( ) ) v − v − (4) 1 1 0 1 v v B It remains to specify the lengths of the blocks of even and odd integers, 0 and 1, subject to the pattern of and the parity of k − r, the number of alternating succession blocks. Note that
f n; k; s; r f n; k; s; r f n; k; s; r : ( ) = ( )odd + ( )even (5)
B v v q > k − r q First assume that the first element of is odd. Then the blocks satisfy 1 = 0 = 1 0 if = 2 1, and v v q > k − r q o; : : : ; e o; : : : ; o 1 = 0 + 1 = 2 + 1 1 if = 2 2 + 1, which correspond to permutations of the form ( ) and ( ), respectively. Hence we obtain from (4),
f n; k; s; r s − k − s − s − k − s − ( )odd 1 1 1 1 p D n ; s p E n ; k − s = q − q − + q q − ( ( ) ) ( ( ) ) 1 1 1 1 2 2 1 s − 1 k − s − 1 s − 1 k − s − 1 = k − r − 2 k − r − 2 + k − r − 1 k − r − 3 ; 2 2 2 2
1392 A.O. Munagi
which is equivalent to
s − 1 k − s − 1 f n; k; s; r p D n ; s p E n ; k − s k − r − k − r − : ( )odd = ( ( ) ) ( ( ) ) 1 2 (6) 2 2
e; : : : ; o e; : : : ; e v v q v v q > Similarly for permutations of the form ( ) or ( ), we have 1 = 0 = 1, or 1 + 1 = 0 = 2 + 1 1. Hence,
f n; k; s; r s − k − s − s − k − s − ( )even 1 1 1 1 ; p D n ; s p E n ; k − s = q − q − + q − q ( ( ) ) ( ( ) ) 1 1 1 1 2 1 2 which gives s − 1 k − s − 1 f n; k; s; r p D n ; s p E n ; k − s k − r − k − r − : ( )even = ( ( ) ) ( ( ) ) 2 1 (7) 2 2 The asserted result follows from (5), with (6) and (7), and the notations.
Remark 2.2. We emphasize that Theorem 2.1, or any other result throughout the paper, stated in terms of the length k of a permutation and the number r of parity successions, has an equivalent statement in terms of k and the number v of succession blocks, due to the relation v = k − r. Thus the theorem has the following alternative form: The number of k-permutations of [n] containing s odd integers and v parity succession blocks is given by f(n; k; s; k − v):
s − 1 k − s − 1 s − 1 k − s − 1 n + 1 n v − 1 v − 2 + v − 2 v − 1 : 2 s 2 k−s 2 2 2 2
The number of k-permutations of [n] containing r parity successions is obtained from Theorem 2.1 by summation over s, P s f(n; k; s; r). However, there are three range cases to the summation index which correspond to the forms, (o; : : : ; e) (with (e; : : : ; o)), (o; : : : ; o) and (e; : : : ; e). Thus the upper summation indices in the following corollary are, respectively,
n + 1 n + 1 n + 1 min k − 1; ; min k; ; min k − 2; : 2 2 2
Corollary 2.3. The number fr(n; k) of k-permutations of [n] containing r parity successions is given by
s − ! k − s − ! X n + 1 n 1 1 fr(n; k) = 2 k − r − 2 k − r − 2 ; 2 s 2 k−s s≥1 2 2 provided that k − r is even; and by
s − ! k − s − ! s − ! k − s − ! X n + 1 n 1 1 X n + 1 n 1 1 fr(n; k) = k − r − 1 k − r − 3 + k − r − 3 k − r − 1 ; 2 s 2 k−s 2 s 2 k−s s≥2 2 2 s≥0 2 2 provided that k − r is odd.
In particular, taking the last term of each sum in Corollary 2.3, when k = n, we obtain the formula for fr(n; n) = fr(n).
1393 Parity-alternating permutations and successions
Corollary 2.4. The number of permutations of [n] containing r parity successions is given by n − 1 n − 2 n − 1 n − 2 n n + 1 2 2 2 2 fr(n) = ! ! + : 2 2 n − r − 1 n − r − 2 n − r − 2 n − r − 1 2 2 2 2
Remark 2.5. When r = 0 in Corollary 2.4, we recover (2).
Remark 2.6. When r = 0 in Corollary 2.3, we obtain the formula for the number of parity-alternating k-permutations of [n]:
n n n n + 1 + 1 k k f n; k + 1 2 2 2 2 : 0( ) = ! ! + 2 2 k + 1 k k k + 1 2 2 2 2
r r If we are interested in the number 1 of parity successions contributed by odd integers, and not the total number of f n; k; s; r h n; k; s; r successions, in each permutation counted by ( ), the enumerator, say ( 1), can be deduced from the proof v s − r of Theorem 2.1 by first using the relation 1 = 1 in (4), to get
s − k − s − h n; k; s; r p D n ; s p E n ; k − s 1 1 ; ( 1)T = ( ( ) ) ( ( ) ) r v − 1 0 1
v v s − r v where 0 depends on 1 = 1. The following expressions then follow upon eliminating 0 with the usual parity arguments:
s − k − s − k − s − h n; k; s; r p D n ; s p E n ; k − s 1 1 1 ; ( 1)odd = ( ( ) ) ( ( ) ) r s − r − + s − r − 1 1 1 1 2 s − k − s − k − s − h n; k; s; r p D n ; s p E n ; k − s 1 1 1 ; ( 1)even = ( ( ) ) ( ( ) ) r s − r − + s − r 1 1 1 1
which, on addition, simplify to
s − k − s h n; k; s; r p D n ; s p E n ; k − s 1 + 1 : ( 1) = ( ( ) ) ( ( ) ) r1 s − r1
Corollary 2.7. The number h n; k; s; r of k-permutations of n containing s odd integers which contribute r parity successions is ( 1) [ ] 1 given by n n + 1 s − k − s h n; k; s; r s k − s 1 + 1 : ( 1) = !( )! 2 2 r s − r s k − s 1 1
Example 2.8. n k s r h ; ; ; As an illustration of Corollary 2.7, consider = 6, = 5, = 2, 1 = 0. Then (6 5 2 0) = 216 which is made up of three parts, 216 = 36 + 144 + 36 corresponding, respectively, to permutations with 0; 1 or 2, parity successions in total:
(2; 1; 4; 3; 6); (2; 1; 6; 3; 4); (2; 3; 6; 1; 4);:::; (6; 4; 3; 2; 1); (5; 4; 1; 2; 6); (3; 4; 6; 5; 2);:::; (3; 6; 4; 2; 5); (1; 6; 4; 2; 5); (5; 4; 6; 2; 1);:::
1394 A.O. Munagi
r h ; ; ; But when 1 = 1, we have (6 5 2 1) = 144 which is made up of two parts, 144 = 72 + 72 corresponding, respectively, to permutations with 2 or 3, parity successions in total:
(4; 6; 3; 5; 2); (4; 2; 5; 3; 6); (6; 4; 5; 3; 2);:::; (2; 6; 4; 3; 1); (1; 3; 6; 2; 4); (5; 3; 4; 6; 2);:::
Remark 2.9. (i) If the s odd integers form a single succession block in each permutation, the result becomes:
n + 1 n h(n; k; s; s − 1) = s!(k − s)! 2 2 (k − s + 1): s k − s
P r h n; k; s; r h n; k; s k n s (ii) From the sum 1 ( 1) = ( ) one deduces: The number of -permutations of [ ] containing odd integers is given by n n + 1 k h n; k; s s k − s : ( ) = !( )! 2 2 s s k − s
The case k = n implies the easily-verified identity,
n n + 1 n ! ! n + 1 = n! 2 2 2
r On setting 1 = 0 in Corollary 2.7, we deduce
Corollary 2.10. There are n + 2 n n + 1 2 h(n; n; D(n); 0) = ! ! 2 2 n + 1 2 permutations of [n] avoiding adjacent pairs of odd integers.
2.1. A flexible enumerator
For more flexibility we suppress the number s of odd integers in favour of the number of parity successions contributed g n; k; r; r k n r by odd integers. Let ( 1) denote the number of -permutations of [ ] containing parity successions in which r g n; ; r; r n > r r 1 of the successions are contributed by odd integers. We have at once that ( 1 1) = 0 iff = 0 = 1, and if r > 1 0, we have n + 1 g n; r ; r; r δr;r : ( 1 + 1 1) = 1 r 2 1+1 Factorials will be defined only for nonnegative integers, and any product containing an undefined factor is assumed to be equal to zero.
1395 Parity-alternating permutations and successions
Theorem 2.11. Let n; k; r be positive integers, r ≥ r , ≤ k < n. Then the number g n; k; r; r is given by 1 2 ( 1)
g n; k; r; r g n; k; r; r g n; k; r; r ; ( 1) = ( 1)odd + ( 1)even
where n n + 1 ! ! g n; k; r; r 2 2 ( 1)odd = n k − r r n k r − r + 1 + 2 1 + 1 + 2 1 − ! − ! 2 2 2 2 k − r r − k r − r − + 2 1 1 + 2 1 2 × 2 2 ; r1 r − r1 n n + 1 ! ! g n; k; r; r 2 2 ( 1)even = n k − r r n k r − r + 1 + 2 1 + 2 1 + 1 − ! − ! 2 2 2 2 k − r r − k r − r − + 2 1 2 + 2 1 1 × 2 2 : r1 r − r1
Proof. Let B denote an enumerated permutation, and assume that B contains s odd integers. Thus, necessarily s > r B 1, and may be constructed with the algorithm of the proof of Theorem 2.1. Using previous notations, together s v r k − s v r − r B with = 1 + 1 and = 0 + ( 1), we obtain the required number of permutations as
g n; k; r; r p D n ; v r p E n ; v r − r c v r ; v c v r − r ; v ; ( 1)T = ( ( ) 1 + 1) ( ( ) 0 + 1) ( 1 + 1 1) ( 0 + 1 0)
that is, v r − v r − r − g n; k; r; r p D n ; v r p E n ; v r − r 1 + 1 1 0 + 1 1 ; ( 1)T = ( ( ) 1 + 1) ( ( ) 0 + 1) (8) r1 r − r1 where T is either parity. o; : : : ; e o; : : : ; o v v q > k − r q Then for permutations of the form ( ) and ( ), we have 1 = 0 = 1 0, where = 2 1, and v v q > k − r q 1 = 0 + 1 = 2 + 1 1, where = 2 2 + 1. Hence (8) gives
q r − q r − r − g n; k; r; r p D n ; q r p E n ; q r − r 1 + 1 1 1 + 1 1 ( 1)odd = ( ( ) 1 + 1) ( ( ) 1 + 1) r1 r − r1 q r q r − r − p D n ; q r p E n ; q r − r 2 + 1 2 + 1 1 + ( ( ) 2 + 1 + 1) ( ( ) 2 + 1) r1 r − r1 k − r r − k r − r − k − r r k r − r + 2 1 1 + 2 1 2 + 2 1 + 1 + 2 1 = p D(n); p E(n); 2 2 : 2 2 r1 r − r1
e; : : : ; o e; : : : ; e v v q v v q Similarly for permutations of the form ( ) or ( ), we have 1 = 0 = 1, or 1 + 1 = 0 = 2 + 1. Hence,
k − r r − k r − r − k − r r k r − r + 2 1 2 + 2 1 1 g n; k; r; r p D n ; + 2 1 p E n ; + 2 1 + 1 : ( 1)even = ( ) ( ) 2 2 2 2 r1 r − r1
Lastly, the result follows from the relation
g n; k; r; r g n; k; r; r g n; k; r; r : ( 1) = ( 1)odd + ( 1)even
1396 A.O. Munagi
r r g n; k; r; r w n; k; r When = 1 in Theorem 2.11, we obtain the interesting case ( ) = ( ).
Corollary 2.12. The number w(n; k; r) of k-permutations of [n] containing r parity successions which are all contributed by odd integers, is given by w n; k; r w n; k; r w n; k; r ; ( ) = ( )odd + ( )even where
n n + 1 ! ! k + r − 1 w n; k; r 2 2 ; ( )odd = n k r n k − r 2 + 1 + + 1 r − ! − ! 2 2 2 2 n n + 1 ! ! k + r − 2 w n; k; r 2 2 : ( )even = n k r n k − r 2 + 1 + + 1 r − ! − ! 2 2 2 2
r g n; k; r; ` n; k; r On the other hand, if 1 = 0 in Theorem 2.11, we obtain ( 0) = ( ).
Corollary 2.13. The number `(n; k; r) of k-permutations of [n] containing r parity successions all of which are contributed by even integers, is given by
` n; k; r ` n; k; r ` n; k; r ; ( ) = ( )odd + ( )even where
n n + 1 ! ! k + r − 2 ` n; k; r 2 2 ; ( )odd = n k − r n k r 2 + 1 + 1 + r − ! − ! 2 2 2 2 n n + 1 ! ! k + r − 1 ` n; k; r 2 2 : ( )even = n k − r n k r 2 + 1 + + 1 r − ! − ! 2 2 2 2
Remark 2.14. Corollary 2.13 gives a refinement of Corollary 2.10 by asserting that a permutation of [n] avoiding adjacent pairs of odd integers admits at most one parity succession. Specifically,
n n 3 + (−1) n n + 1 1 + (−1) n − 2 n `(n; n; 0) = ! !; `(n; n; 1) = !2: 2 2 2 2 2 2
So we should have `(n; n; 0) + `(n; n; 1) = h(n; n; D(n); 0).
Remark 2.15. By analogous reasoning, permutations of [n] avoiding adjacent pairs of even integers admit at most two successions, and Corollary 2.12 gives the enumerator and its decomposition as follows:
1397 Parity-alternating permutations and successions
n + 3 n n + 1 2 ! ! = w(n; n; 0) + w(n; n; 1) + w(n; n; 2) 2 2 n 2 n n 3 + (−1) n n + 1 3 + (−1) +1 n − 1 n n + 1 = ! ! + ! ! 2 2 2 2 2 2 2 n − n 1 1 + (−1) +1 n − 1 n + 1 + ! ! 2 : 2 2 2 2
3. Circular permutations
A circular permutation is an arrangement of distinct positive integers clockwise around a circle, two arrangements being considered identical if they differ only by a rotation. This definition implies a natural equivalence relation on any set of permutations in which an equivalence class C(p) of a member p consists of permutations obtained from p by a t-fold cyclic shift of the sequence of elements of p, where t = 0; 1; : : : ; k − 1, and k is the length of p. We will count circular k-permutations of [n], or (what is the same thing) the distinct equivalence classes C(p), with q q ; q ; : : : ; q respect to parity successions. Each class will be identified with its unique member = ( 1 2 k ) satisfying q q min( ) = 1. Note that the definition of a parity succession now includes the possibility of the first and last entries having the same parity. For example the class C((1; 2; 3)) = {(1; 2; 3); (2; 3; 1); (3; 1; 2)} is counted as a single circular permutation of [3] which contains one parity succession. Let f(n; k; s; r) be the number of circular k-permutations of [n] containing s odd integers and r parity successions. Then we see at once that f(n; 1; s; r) = 0 whenever r > 0, and
n n f n; ; s; + 1 δ δ : ( 1 0) = 1s + 0s (9) 2 2
Also, f(n; 2; s; r) = 0 if r = 1 or r > 2, and
n n n n + 1 f n; ; s; + 1 δ ; f n; ; s; δ δ : ( 2 0) = 1s ( 2 2) = 2 2s + 2 0s (10) 2 2 2 2
a a ∈ n−k C C a; p ; p ; : : : ; p Generally, if the smallest entry is , then [ +1], since an enumerated object has the form = ( 2 3 k ), p ; p ; : : : ; p k − {a ; a ; : : : ; n} where ( 2 3 k ) is a ( 1)-permutation of the set + 1 + 2 . We first assume that a is odd, say a = 2j − 1. Then C may be found using a modified form of the previous algorithm. Obtain an (s−1)-permutation of D(n)−j odd integers, with a (k −s)-permutation of E(n)−j +1 even integers (excluding 1; 2; 3;:::; 2j − 1), noting that a is already fixed in the first position. Then combine the sequences of s odd integers and k − s even integers in the usual manner, to get
s − k − s − F n; k; s; r def p D n − j; s − p E n − j ; k − s 1 1 : ( )(2j−1;::: ) = ( ( ) 1) ( ( ) + 1 ) v − v − 1 1 0 1
Similarly, by starting with an even integer a = 2j ∈ [n − k + 1], we obtain
s − k − s − F n; k; s; r def p D n − j; s p E n − j; k − s − 1 1 : ( )(2j;::: ) = ( ( ) ) ( ( ) 1) v − v − (11) 1 1 0 1
1398 A.O. Munagi
v ; v Lastly we apply the usual parity arguments to evaluate the quantities 1 0, taking account of possible parity successions introduced on wrapping permutations around. For each j ∈ {1; 2;:::; b(n − k + 2)/2c}, the number of permutations of the forms (2j − 1; : : : ; e) and (2j − 1; : : : ; o) is given by F n; k; s; r F n; k; s; r − : ( )(2j−1;:::;e) + ( 1)(2j−1;:::;o)
Note that r drops by 1 in the second summand since a permutation of the form (o; : : : ; o) introduces an additional succession when wrapped around. Thus the sum becomes
s − 1 k − s − 1 s − 1 k − s − 1 p(D(n) − j; s − 1)p(E(n) − j + 1; k − s) k − r − 2 k − r − 2 + k − r k − r − 2 2 2 2 2 s k − s − 1 = p(D(n) − j; s − 1)p(E(n) − j + 1; k − s) k − r k − r − 2 : 2 2
Hence, writing f(n; k; s; r)T for the number of permutations enumerated by f(n; k; s; r) in which the smallest entry has parity T , we obtain
X s k − s − 1 f n; k; s; r p D n − j; s − p E n − j ; k − s : ( )odd = ( ( ) 1) ( ( ) + 1 ) k − r k − r − 2 j≥ 1 2 2
Similarly, for each j ∈ {1; 2;:::; b(n − k + 1)/2c}, the number of permutations of the forms (2j; : : : ; o) and (2j; : : : ; e) is derived, from (11), to be
X s − 1 k − s f n; k; s; r p D n − j; s p E n − j; k − s − : ( )even = ( ( ) ) ( ( ) 1) k − r − 2 k − r j≥ 1 2 2
The foregoing results are summarized in the following theorem.
Theorem 3.1. The number f(n; k; s; r) of circular k-permutations of [n] containing s odd integers and r parity successions is 0 if k − r is odd. Otherwise, we have
f n; k; s; r f n; k; s; r f n; k; s; r ; ≤ k ≤ n; ( ) = ( )odd + ( )even 2 where
! ! b n−k / c n n s k − s − 1 ( X+2) 2 + 1 − j + 2 − j f n; k; s; r s − k − s k − r k − r − ; ( )odd = ( 1)!( )! 2 2 2 j s − k − s 2 2 =1 1 ! ! b n−k / c n n s − 1 k − s ( X+1) 2 + 1 − j − j f n; k; s; r s k − s − k − r − k − r : ( )even = !( 1)! 2 2 2 j s k − s − 2 2 =1 1
The number fr(n; k) of circular k-permutations of [n] containing r parity successions can be found by summing f(n; k; s; r) over s, a result that is too complicated to state here. However, we can set r = 0 in the latter to obtain a simple expression.
1399 Parity-alternating permutations and successions
Theorem 3.2. For an even positive integer k ≤ n, the number of parity-alternating circular k-permutations of [n] is
n n + 1 n + 1 n + 2 b(n−k+1)/2c − j − j b(n−k+2)/2c − j − j k − k X X f n; k 2 2 2 2 2 : 0( ) = ! ! k − k + k − k 2 2 j 2 j 2 =1 =1 2 2 2 2
Proof. The proof can be deduced straight from the proof of Theorem 3.1. Note that r = 0 implies that k is even, which implies s = k/2 = k − s. Of the four types of permutations, (o; : : : ; e); (o; : : : ; o); (e; : : : ; o); (e; : : : ; e), only the f n; k first and third can contribute to 0( ). Hence
f n; k f n; k f n; k 0( ) = 0( )odd + 0( )even b(n−k+2)/2c b(n−k+1)/2c X k − 2 k X k k − 2 = p D(n) − j; p E(n) − j + 1; + p D(n) − j; p E(n) − j; : j=1 2 2 j=1 2 2
The stated result now follows from the notations.
The formula for fr(n) = fr(n; n) may be found via the relation fr(n) = f(n; n; D(n); r).
Corollary 3.3. The number fr(n) of circular permutations of [n] containing r parity successions is 0 if n − r is odd. Otherwise, we have
n − 2 n + 1 n − n 1 2 2 fr(n) = ! ! : 2 2 n − r − 2 n − r 2 2
In particular, the number f n of parity-alternating circular permutations of n is 0( ) [ ]
− n n − n f n 1 + ( 1) 2 0( ) = ! ! 2 2 2
3.1. Other formulae
We follow through the agenda of Section 2, for circular permutations, by stating the other parallel formulae. The proof details are omitted since the procedures are similar to the linear cases.
Theorem 3.4. The number h n; k; s; r of circular k-permutations of n containing s odd integers which contribute r parity successions ( 1) [ ] 1 is given by h n; k; s; r h n; k; s; r h n; k; s; r ; ( 1) = ( 1)odd + ( 1)even where
b n−k / c n n s k − s − ( X+2) 2 + 1 − j + 2 − j h n; k; s; r s − k − s 1 ; ( 1)odd = ( 1)!( )! r s − r − 2 2 1 1 1 j=1 s − 1 k − s b n−k / c n n s − k − s ( X+1) 2 + 1 − j − j h n; k; s; r s k − s − 1 : ( 1)even = !( 1)! 2 2 r1 s − r1 j=1 s k − s − 1
1400 A.O. Munagi
Hence, in particular,
b n−k / c n n ( X+2) 2 + 1 − j + 2 − j h(n; k; s; s − 1) = s!(k − s)! 2 2 j=1 s − 1 k − s (12) b n−k / c n n ( X+1) 2 + 1 − j − j + 2 2 : j=1 s k − s − 1 Remark 3.5. The number of circular k-permutations of [n] containing s odd integers is given by b n−k / c n n b n−k / c n n ( X+2) 2 + 1 − j + 2 − j ( X+1) 2 + 1 − j − j h(n; k; s) = (k − 1)! 2 2 + 2 2 : j=1 s − 1 k − s j=1 s k − s − 1
Theorem 3.4 also specializes to b(n−k+2)/2c n + 1 n + 2 (k − s − 1)!(k − s)! X − j − j h(n; k; s; 0) = 2 2 (k − 2s)! j=1 s − 1 k − s b n−k / c n n ( X+1) 2 + 1 − j − j + 2 2 : j=1 s k − s − 1 Remark 3.6. In particular, a circular permutation of [n] avoids adjacent pairs of odd integers if and only if it is parity-alternating, f n n that is, counted by 0( ). On the other hand, circular permutations of [ ] avoiding adjacent pairs of even integers may contain at most one parity succession: n − n w n; n; f n ; w n; n; − n+1 1 + 1 ( 0) = 0( ) ( 1) = 1 + ( 1) ! ! 2 2
The total number of such permutations is
n 3 + (−1) +1 n − 1 n + 1 ! ! 2 2 2 3.2. Direct enumeration
f n; k In the spirit of equations (9)–(10), we apply direct combinatorial reasoning to find an alternative formula for 0( ). f n; k > k P Since 0( ) 0 requires to be an even integer, each enumerated object consists of an equal number of even D k E k k/ P k/ D(n) E(n) and odd elements, ( ) = ( ) = 2. Thus to find we select 2 odd integers and even integers, in k/2 k/2 ways. Then arrange these on a circle so that even and odd integers alternate, as follows: pick an integer x at random and place it on the circle, followed with arrangement of the other (D(k) − 1) + E(k) = D(k) + (E(k) − 1) integers, accordingly. Clearly, there are (D(k) − 1)!E(k)! possible arrangements. Hence the total number of permutations P is D(n) E(n) D k − E k k/2 k/2 ( ( ) 1)! ( )!.
Theorem 3.7. The number of parity-alternating circular k-permutations of [n] is n n + 1 k − k f n; k 2 2 2 ; k ≡ : 0( ) = ! ! 0 (mod 2) 2 2 k k 2 2
1401 Parity-alternating permutations and successions
Lastly, we remark that it can be proved directly that h(n; k; s; s − 1) is given by
n n + 1 h(n; k; s; s − 1) = s!(k − s)! 2 2 ; s k − s
which is then equivalent to (12). By comparing the two formulas we obtain the following identity which is valid for all positive integers k ≤ n:
n n b n−k / c n n b n−k / c n n + 1 ( +2) 2 + 1 + 2 ( +1) 2 + 1 − j X − j − j X − j 2 2 = 2 2 + 2 2 ; k j=1 k − k j=1 k − 1 k2 1 1 2 k1 2 1
k k k where 1 and 2 are positive integers summing to . k k k/ The special case of this identity, corresponding to 1 = 2 = 2, may be obtained by equating the results of Theorems 3.7 and 3.2.
References
[1] Andrews G.E., The Theory of Partitions, Encyclopedia of Mathematics and its Applications, 2, Addison-Wesley, Reading, 1976 [2] Knopfmacher A., Munagi A., Wagner S., Successions in words and compositions, Ann. Comb., 2012, 16(2), 277–287 [3] Moser W.O.J., Abramson M., Generalizations of Terquem’s problem, J. Combinatorial Theory, 1969, 7(2), 171–180 [4] Munagi A.O., Alternating subsets and permutations, Rocky Mountain J. Math., 2010, 40(6), 1965–1977 [5] Munagi A.O., Alternating subsets and successions, Ars Combin., 2013, 110, 77–86 [6] Riordan J., Permutations without 3-sequences, Bull. Amer. Math. Soc., 1945, 51, 745–748 [7] Tanimoto S., Parity alternating permutations and signed Eulerian numbers, Ann. Comb., 2010, 14(3), 355–366 [8] Tanny S.M., Permutations and successions, J. Combinatorial Theory Ser. A, 1976, 21(2), 196–202
1402