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!)
A266393 Number of permutations of n letters that contain exactly 3 distinguishable A's, 2 distinguishable B's and n-5 distinguishable other letters, where no A's are adjacent and no B's are adjacent. 1

%I #23 Sep 08 2022 08:46:15

%S 12,120,1152,11520,122400,1391040,16934400,220631040,3069964800,

%T 45505152000,716586393600,11955879936000,210797108121600,

%U 3917792406528000,76577410990080000,1570715682471936000,33740509429186560000

%N Number of permutations of n letters that contain exactly 3 distinguishable A's, 2 distinguishable B's and n-5 distinguishable other letters, where no A's are adjacent and no B's are adjacent.

%F a(n) = (n-3)! * (n^3 - 11*n^2 + 44*n - 64).

%e For n=5, our base letter sequence is "AAABB". In its 120 permutations (5! = 120), there are 12 instances of "ABABA", the only letter sequence where neither A's nor B's are adjacent to themselves. This can be represented visually by using upper and lower case, and a diacritic in the case of the third "A": ABabá, AbaBá, aBAbá, abABá, áBAba, ábABa, ABába, AbáBa, aBábA, abáBA, áBabA, and ábaBA.

%e For n=6, the base sequence is "AAABBC", which has 720 (6!) permutations. There are similarly 12 instances of each of the 10 letter sequences that don't duplicate A's or B's, namely ABABAC, ABABCA, ABACAB, ABACBA, ABCABA, ACABAB, ACBABA, BABACA, BACABA, and CABABA, making 120 distinguishable permutations that fit this rule.

%p A266393:=n->(n-3)!*(n^3 - 11*n^2 + 44*n - 64): seq(A266393(n), n=5..25); # _Wesley Ivan Hurt_, Jan 01 2016

%t Table[(n - 3)!*(n^3 - 11*n^2 + 44*n - 64), {n, 5, 30}] (* _Wesley Ivan Hurt_, Jan 01 2016 *)

%o (Magma) [Factorial(n-3)*(n^3 - 11*n^2 + 44*n - 64) : n in [5..30]]; // _Wesley Ivan Hurt_, Jan 01 2016

%K nonn,easy

%O 5,1

%A _Curtis Autery_, Dec 28 2015

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 March 28 07:33 EDT 2024. Contains 371235 sequences. (Running on oeis4.)