How many permutations are there of M, M, A, A, A, T, T, E, I, K, so that no two consecutive letters are the same?How many strings are there (inclusion exclusion principle)How many permutations of the letters in HURRAH have the first R preceding the first H?How many words can be written with $aabbbccdd$ such that no two equal letters are adjacent?How many words can be formed, given $4$ letters, and in each word there must be at least two letters are the same?Arrangements of a,a,a,b,b,b,c,c,c in which no three consecutive letters are the sameNumber of arrangements with no consecutive letter the sameHow many 4-letter “words” have no two consecutive letters identical - clarification needed on answerHow many arrangements of these letters are there with no pair of consecutive letters the same?Number of ways to arrange $A,A,A,B,C,C$ such that no $2$ consecutive letters are the sameIn how many ways can letters in a word CALCULUS be rearranged

What has been your most complicated TikZ drawing?

Good allowance savings plan?

Is it normal that my co-workers at a fitness company criticize my food choices?

Why do Australian milk farmers need to protest supermarkets' milk price?

Why did it take so long to abandon sail after steamships were demonstrated?

Welcoming 2019 Pi day: How to draw the letter π?

How to make healing in an exploration game interesting

An Accountant Seeks the Help of a Mathematician

The use of "touch" and "touch on" in context

Meaning of "SEVERA INDEOVI VAS" from 3rd Century slab

Ban on all campaign finance?

Make a transparent 448*448 image

Happy pi day, everyone!

How to write cleanly even if my character uses expletive language?

Will a pinhole camera work with instant film?

RegionDifference for Cylinder and Cuboid

Rejected in 4th interview round citing insufficient years of experience

Rules about breaking the rules. How do I do it well?

Sword in the Stone story where the sword was held in place by electromagnets

Provisioning profile doesn't include the application-identifier and keychain-access-groups entitlements

Possible Leak In Concrete

PTIJ: Who should pay for Uber rides: the child or the parent?

How to simplify this time periods definition interface?

Does the statement `int val = (++i > ++j) ? ++i : ++j;` invoke undefined behavior?



How many permutations are there of M, M, A, A, A, T, T, E, I, K, so that no two consecutive letters are the same?


How many strings are there (inclusion exclusion principle)How many permutations of the letters in HURRAH have the first R preceding the first H?How many words can be written with $aabbbccdd$ such that no two equal letters are adjacent?How many words can be formed, given $4$ letters, and in each word there must be at least two letters are the same?Arrangements of a,a,a,b,b,b,c,c,c in which no three consecutive letters are the sameNumber of arrangements with no consecutive letter the sameHow many 4-letter “words” have no two consecutive letters identical - clarification needed on answerHow many arrangements of these letters are there with no pair of consecutive letters the same?Number of ways to arrange $A,A,A,B,C,C$ such that no $2$ consecutive letters are the sameIn how many ways can letters in a word CALCULUS be rearranged













3












$begingroup$


How many permutations are there of
$$ M, M, A, A, A, T, T, E, I, K $$
so that there are no two consecutive letters are the same?
I would use the Inclusion-exclusion principle where
$$ A_i = texton i-textth text and (i+1)-textth text position, there are two same consecutive letters . $$
So my answer would be
$$ frac10!2!3!2! - 9 cdot left(frac9!3!2! + frac9!3!2! +frac9!2!2!right)+ 8 cdot left(frac8!2!2!right) +8 cdot 7 cdot left(frac8!3! + frac8!2! +frac8!2!right) - 7 cdot 6 cdot 5 cdot 7!$$










share|cite|improve this question











$endgroup$
















    3












    $begingroup$


    How many permutations are there of
    $$ M, M, A, A, A, T, T, E, I, K $$
    so that there are no two consecutive letters are the same?
    I would use the Inclusion-exclusion principle where
    $$ A_i = texton i-textth text and (i+1)-textth text position, there are two same consecutive letters . $$
    So my answer would be
    $$ frac10!2!3!2! - 9 cdot left(frac9!3!2! + frac9!3!2! +frac9!2!2!right)+ 8 cdot left(frac8!2!2!right) +8 cdot 7 cdot left(frac8!3! + frac8!2! +frac8!2!right) - 7 cdot 6 cdot 5 cdot 7!$$










    share|cite|improve this question











    $endgroup$














      3












      3








      3


      0



      $begingroup$


      How many permutations are there of
      $$ M, M, A, A, A, T, T, E, I, K $$
      so that there are no two consecutive letters are the same?
      I would use the Inclusion-exclusion principle where
      $$ A_i = texton i-textth text and (i+1)-textth text position, there are two same consecutive letters . $$
      So my answer would be
      $$ frac10!2!3!2! - 9 cdot left(frac9!3!2! + frac9!3!2! +frac9!2!2!right)+ 8 cdot left(frac8!2!2!right) +8 cdot 7 cdot left(frac8!3! + frac8!2! +frac8!2!right) - 7 cdot 6 cdot 5 cdot 7!$$










      share|cite|improve this question











      $endgroup$




      How many permutations are there of
      $$ M, M, A, A, A, T, T, E, I, K $$
      so that there are no two consecutive letters are the same?
      I would use the Inclusion-exclusion principle where
      $$ A_i = texton i-textth text and (i+1)-textth text position, there are two same consecutive letters . $$
      So my answer would be
      $$ frac10!2!3!2! - 9 cdot left(frac9!3!2! + frac9!3!2! +frac9!2!2!right)+ 8 cdot left(frac8!2!2!right) +8 cdot 7 cdot left(frac8!3! + frac8!2! +frac8!2!right) - 7 cdot 6 cdot 5 cdot 7!$$







      combinatorics inclusion-exclusion






      share|cite|improve this question















      share|cite|improve this question













      share|cite|improve this question




      share|cite|improve this question








      edited Mar 11 at 16:37









      N. F. Taussig

      44.7k103358




      44.7k103358










      asked Mar 11 at 9:24









      user15269user15269

      388110




      388110




















          2 Answers
          2






          active

          oldest

          votes


















          2












          $begingroup$

          As you observed, there are $10$ letters, of which $3$ are $A$s, $2$ are $M$s, $2$ are $T$s, $1$ is an $E$, $1$ is an $I$, and $1$ is a $K$.



          If there were no restrictions, we would choose three of the ten positions for the $A$s, two of the remaining seven positions for the $M$s, two of the remaining five positions for the $T$s, and arrange the $E$, $I$, $K$ in the remaining three positions in
          $$binom103binom72binom523! = frac10!3!7! cdot frac7!2!5! cdot frac5!2!3! cdot 3! = frac10!3!2!2!$$
          in agreement with your answer.



          From these, we must subtract those arrangements in which or more pairs of identical letters are adjacent.



          Arrangements with a pair of adjacent identical letters: We have to consider cases, depending on whether the identical letters are $A$s, $M$s, or $T$s.



          A pair of $A$s are adjacent: We have nine objects to arrange: $AA, A, M, M, T, T, E, I, K$. Choose two of the nine positions for the $M$s, two of the remaining seven positions for the $T$s, and then arrange the five distinct objects $AA$, $A$, $E$, $I$, $K$ in the remaining five positions, which can be done in
          $$binom92binom725!$$
          ways.



          A pair of $M$s are adjacent: We have nine objects to arrange: $A, A, A, MM, T, T, E, I, K$. Choose three of the nine positions for the $A$s, two of the remaining six positions for the $T$s, and arrange the four distinct objects $MM, E, I, K$ in the remaining four positions, which can be done in
          $$binom93binom624!$$
          ways.



          A pair of $T$s are adjacent: By symmetry, there are
          $$binom93binom624!$$
          such arrangements.



          Arrangements with two pairs of adjacent identical letters: This can occur in two ways. Either the pairs are disjoint or they overlap.



          Two pairs of $A$s are adjacent: This can only occur if the three $A$s are consecutive. Thus, we have eight objects to arrange: $AAA, M, M, T, T, E, I, K$. Choose two of the eight positions for the $M$s, two of the remaining six positions for the $T$s, and arrange the four distinct objects $AAA, E, I, K$ in the remaining four positions, which can be done in
          $$binom82binom624!$$
          ways.



          A pair of $A$s are adjacent and a pair of $M$s are adjacent: We have eight objects to arrange: $AA, A, MM, T, T, E, I, K$. Choose two of the eight positions for the $T$s and arrange the six distinct objects $AA, A, MM, E, I, K$ in the remaining six positions in
          $$binom826!$$
          ways.



          A pair of $A$s are adjacent and a pair of $T$s are adjacent: By symmetry, there are
          $$binom826!$$
          such arrangements.



          A pair of $M$s are adjacent and a pair of $T$s are adjacent: We have eight objects to arrange: $A, A, A, MM, TT, E, I, K$. Choose three of the eight positions for the $A$s and then arrange the remaining five distinct objects $MM, TT, E, I, K$ in the remaining five positions in
          $$binom835!$$
          ways.



          Arrangements with three pairs of adjacent identical letters: We again consider cases.



          Two pairs of $A$s are adjacent and a pair of $M$s are adjacent: We have seven objects to arrange, $AAA, MM, T, T, E, I, K$. Choose two of the seven positions for the $T$s and arrange the five distinct objects $AAA, MM, E, I, K$ in the remaining five positions in
          $$binom725!$$
          ways.



          Two pairs of $A$s are adjacent and a pair of $T$s are adjacent: By symmetry, there are
          $$binom725!$$
          such arrangements.



          A pair of $A$s are adjacent, a pair of $M$s are adjacent, and a pair of $T$s are adjacent: We have seven objects to arrange: $AA, A, MM, TT, E, I, K$. Since all the objects are distinct, there are
          $$7!$$
          such arrangements.



          Arrangements containing four pairs of adjacent identical letters: We have six objects to arrange: $AAA, MM, TT, E, I, K$. Since all the objects are distinct, there are
          $$6!$$
          such arrangements.



          By the Inclusion-Exclusion Principle, there are
          $$binom103binom72binom523! - binom92binom725! - binom93binom624! - binom93binom624! + binom82binom624! + binom826! + binom826! + binom835! - binom725! - binom725! - 7! + 6!=47760$$
          arrangements in which no two adjacent letters are identical.






          share|cite|improve this answer











          $endgroup$








          • 1




            $begingroup$
            I have added the final result, it matches perfectly with my computations. So +1
            $endgroup$
            – Oldboy
            2 days ago


















          0












          $begingroup$

          If I calculated everything correctly, your answer is 446880.



          I used the following program to check it:



          public class PermutationCounter 
          public static int[] duplicate(int[] source)
          int[] dest = new int[source.length];
          System.arraycopy(source, 0, dest, 0, source.length);
          return dest;


          public static boolean allLettersExhausted(int[] source)
          for(int i = 0; i < source.length; i++)
          if(source[i] != 0)
          return false;


          return true;


          private char[] letters;
          private int[] count;

          public PermutationCounter(char[] letters, int[] count)
          this.letters = letters;
          this.count = count;


          public int countPermutations()
          return countPermutations(-1, count, "");


          private int countPermutations(int last, int[] alphabet, String permutation)
          if(allLettersExhausted(alphabet))
          System.out.println(permutation);
          return 1;

          int sum = 0;
          for(int i = 0; i < alphabet.length; i++)
          if(i != last && alphabet[i] > 0)
          int[] alphabetCopy = duplicate(alphabet);
          alphabetCopy[i]--;
          sum += countPermutations(i, alphabetCopy, permutation + letters[i]);


          return sum;


          public static void main(String[] args)
          char[] letters = new char[] 'M', 'A', 'T', 'E', 'I', 'K';
          int[] count = new int[] 2, 3, 2, 1, 1, 1;
          PermutationCounter counter = new PermutationCounter(letters, count);
          System.out.println("TOTAL PERMUTATIONS: " + counter.countPermutations());




          My answer is 47760 (much lower number) and the full list of all permutations can be found here (yes, the word "MATEMATIKA" is also there).



          The code starts with two lists. The first contains the list of letters, the second list contains the number of appearances of each letter in the final word. The code is recursive: it tracks the last letter and counts all shorter words starting with a different letter.



          I know this is not the answer you were hoping for but it might help you to conclude if your answer is right or wrong.






          share|cite|improve this answer









          $endgroup$












            Your Answer





            StackExchange.ifUsing("editor", function ()
            return StackExchange.using("mathjaxEditing", function ()
            StackExchange.MarkdownEditor.creationCallbacks.add(function (editor, postfix)
            StackExchange.mathjaxEditing.prepareWmdForMathJax(editor, postfix, [["$", "$"], ["\\(","\\)"]]);
            );
            );
            , "mathjax-editing");

            StackExchange.ready(function()
            var channelOptions =
            tags: "".split(" "),
            id: "69"
            ;
            initTagRenderer("".split(" "), "".split(" "), channelOptions);

            StackExchange.using("externalEditor", function()
            // Have to fire editor after snippets, if snippets enabled
            if (StackExchange.settings.snippets.snippetsEnabled)
            StackExchange.using("snippets", function()
            createEditor();
            );

            else
            createEditor();

            );

            function createEditor()
            StackExchange.prepareEditor(
            heartbeatType: 'answer',
            autoActivateHeartbeat: false,
            convertImagesToLinks: true,
            noModals: true,
            showLowRepImageUploadWarning: true,
            reputationToPostImages: 10,
            bindNavPrevention: true,
            postfix: "",
            imageUploader:
            brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
            contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
            allowUrls: true
            ,
            noCode: true, onDemand: true,
            discardSelector: ".discard-answer"
            ,immediatelyShowMarkdownHelp:true
            );



            );













            draft saved

            draft discarded


















            StackExchange.ready(
            function ()
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f3143471%2fhow-many-permutations-are-there-of-m-m-a-a-a-t-t-e-i-k-so-that-no-two%23new-answer', 'question_page');

            );

            Post as a guest















            Required, but never shown

























            2 Answers
            2






            active

            oldest

            votes








            2 Answers
            2






            active

            oldest

            votes









            active

            oldest

            votes






            active

            oldest

            votes









            2












            $begingroup$

            As you observed, there are $10$ letters, of which $3$ are $A$s, $2$ are $M$s, $2$ are $T$s, $1$ is an $E$, $1$ is an $I$, and $1$ is a $K$.



            If there were no restrictions, we would choose three of the ten positions for the $A$s, two of the remaining seven positions for the $M$s, two of the remaining five positions for the $T$s, and arrange the $E$, $I$, $K$ in the remaining three positions in
            $$binom103binom72binom523! = frac10!3!7! cdot frac7!2!5! cdot frac5!2!3! cdot 3! = frac10!3!2!2!$$
            in agreement with your answer.



            From these, we must subtract those arrangements in which or more pairs of identical letters are adjacent.



            Arrangements with a pair of adjacent identical letters: We have to consider cases, depending on whether the identical letters are $A$s, $M$s, or $T$s.



            A pair of $A$s are adjacent: We have nine objects to arrange: $AA, A, M, M, T, T, E, I, K$. Choose two of the nine positions for the $M$s, two of the remaining seven positions for the $T$s, and then arrange the five distinct objects $AA$, $A$, $E$, $I$, $K$ in the remaining five positions, which can be done in
            $$binom92binom725!$$
            ways.



            A pair of $M$s are adjacent: We have nine objects to arrange: $A, A, A, MM, T, T, E, I, K$. Choose three of the nine positions for the $A$s, two of the remaining six positions for the $T$s, and arrange the four distinct objects $MM, E, I, K$ in the remaining four positions, which can be done in
            $$binom93binom624!$$
            ways.



            A pair of $T$s are adjacent: By symmetry, there are
            $$binom93binom624!$$
            such arrangements.



            Arrangements with two pairs of adjacent identical letters: This can occur in two ways. Either the pairs are disjoint or they overlap.



            Two pairs of $A$s are adjacent: This can only occur if the three $A$s are consecutive. Thus, we have eight objects to arrange: $AAA, M, M, T, T, E, I, K$. Choose two of the eight positions for the $M$s, two of the remaining six positions for the $T$s, and arrange the four distinct objects $AAA, E, I, K$ in the remaining four positions, which can be done in
            $$binom82binom624!$$
            ways.



            A pair of $A$s are adjacent and a pair of $M$s are adjacent: We have eight objects to arrange: $AA, A, MM, T, T, E, I, K$. Choose two of the eight positions for the $T$s and arrange the six distinct objects $AA, A, MM, E, I, K$ in the remaining six positions in
            $$binom826!$$
            ways.



            A pair of $A$s are adjacent and a pair of $T$s are adjacent: By symmetry, there are
            $$binom826!$$
            such arrangements.



            A pair of $M$s are adjacent and a pair of $T$s are adjacent: We have eight objects to arrange: $A, A, A, MM, TT, E, I, K$. Choose three of the eight positions for the $A$s and then arrange the remaining five distinct objects $MM, TT, E, I, K$ in the remaining five positions in
            $$binom835!$$
            ways.



            Arrangements with three pairs of adjacent identical letters: We again consider cases.



            Two pairs of $A$s are adjacent and a pair of $M$s are adjacent: We have seven objects to arrange, $AAA, MM, T, T, E, I, K$. Choose two of the seven positions for the $T$s and arrange the five distinct objects $AAA, MM, E, I, K$ in the remaining five positions in
            $$binom725!$$
            ways.



            Two pairs of $A$s are adjacent and a pair of $T$s are adjacent: By symmetry, there are
            $$binom725!$$
            such arrangements.



            A pair of $A$s are adjacent, a pair of $M$s are adjacent, and a pair of $T$s are adjacent: We have seven objects to arrange: $AA, A, MM, TT, E, I, K$. Since all the objects are distinct, there are
            $$7!$$
            such arrangements.



            Arrangements containing four pairs of adjacent identical letters: We have six objects to arrange: $AAA, MM, TT, E, I, K$. Since all the objects are distinct, there are
            $$6!$$
            such arrangements.



            By the Inclusion-Exclusion Principle, there are
            $$binom103binom72binom523! - binom92binom725! - binom93binom624! - binom93binom624! + binom82binom624! + binom826! + binom826! + binom835! - binom725! - binom725! - 7! + 6!=47760$$
            arrangements in which no two adjacent letters are identical.






            share|cite|improve this answer











            $endgroup$








            • 1




              $begingroup$
              I have added the final result, it matches perfectly with my computations. So +1
              $endgroup$
              – Oldboy
              2 days ago















            2












            $begingroup$

            As you observed, there are $10$ letters, of which $3$ are $A$s, $2$ are $M$s, $2$ are $T$s, $1$ is an $E$, $1$ is an $I$, and $1$ is a $K$.



            If there were no restrictions, we would choose three of the ten positions for the $A$s, two of the remaining seven positions for the $M$s, two of the remaining five positions for the $T$s, and arrange the $E$, $I$, $K$ in the remaining three positions in
            $$binom103binom72binom523! = frac10!3!7! cdot frac7!2!5! cdot frac5!2!3! cdot 3! = frac10!3!2!2!$$
            in agreement with your answer.



            From these, we must subtract those arrangements in which or more pairs of identical letters are adjacent.



            Arrangements with a pair of adjacent identical letters: We have to consider cases, depending on whether the identical letters are $A$s, $M$s, or $T$s.



            A pair of $A$s are adjacent: We have nine objects to arrange: $AA, A, M, M, T, T, E, I, K$. Choose two of the nine positions for the $M$s, two of the remaining seven positions for the $T$s, and then arrange the five distinct objects $AA$, $A$, $E$, $I$, $K$ in the remaining five positions, which can be done in
            $$binom92binom725!$$
            ways.



            A pair of $M$s are adjacent: We have nine objects to arrange: $A, A, A, MM, T, T, E, I, K$. Choose three of the nine positions for the $A$s, two of the remaining six positions for the $T$s, and arrange the four distinct objects $MM, E, I, K$ in the remaining four positions, which can be done in
            $$binom93binom624!$$
            ways.



            A pair of $T$s are adjacent: By symmetry, there are
            $$binom93binom624!$$
            such arrangements.



            Arrangements with two pairs of adjacent identical letters: This can occur in two ways. Either the pairs are disjoint or they overlap.



            Two pairs of $A$s are adjacent: This can only occur if the three $A$s are consecutive. Thus, we have eight objects to arrange: $AAA, M, M, T, T, E, I, K$. Choose two of the eight positions for the $M$s, two of the remaining six positions for the $T$s, and arrange the four distinct objects $AAA, E, I, K$ in the remaining four positions, which can be done in
            $$binom82binom624!$$
            ways.



            A pair of $A$s are adjacent and a pair of $M$s are adjacent: We have eight objects to arrange: $AA, A, MM, T, T, E, I, K$. Choose two of the eight positions for the $T$s and arrange the six distinct objects $AA, A, MM, E, I, K$ in the remaining six positions in
            $$binom826!$$
            ways.



            A pair of $A$s are adjacent and a pair of $T$s are adjacent: By symmetry, there are
            $$binom826!$$
            such arrangements.



            A pair of $M$s are adjacent and a pair of $T$s are adjacent: We have eight objects to arrange: $A, A, A, MM, TT, E, I, K$. Choose three of the eight positions for the $A$s and then arrange the remaining five distinct objects $MM, TT, E, I, K$ in the remaining five positions in
            $$binom835!$$
            ways.



            Arrangements with three pairs of adjacent identical letters: We again consider cases.



            Two pairs of $A$s are adjacent and a pair of $M$s are adjacent: We have seven objects to arrange, $AAA, MM, T, T, E, I, K$. Choose two of the seven positions for the $T$s and arrange the five distinct objects $AAA, MM, E, I, K$ in the remaining five positions in
            $$binom725!$$
            ways.



            Two pairs of $A$s are adjacent and a pair of $T$s are adjacent: By symmetry, there are
            $$binom725!$$
            such arrangements.



            A pair of $A$s are adjacent, a pair of $M$s are adjacent, and a pair of $T$s are adjacent: We have seven objects to arrange: $AA, A, MM, TT, E, I, K$. Since all the objects are distinct, there are
            $$7!$$
            such arrangements.



            Arrangements containing four pairs of adjacent identical letters: We have six objects to arrange: $AAA, MM, TT, E, I, K$. Since all the objects are distinct, there are
            $$6!$$
            such arrangements.



            By the Inclusion-Exclusion Principle, there are
            $$binom103binom72binom523! - binom92binom725! - binom93binom624! - binom93binom624! + binom82binom624! + binom826! + binom826! + binom835! - binom725! - binom725! - 7! + 6!=47760$$
            arrangements in which no two adjacent letters are identical.






            share|cite|improve this answer











            $endgroup$








            • 1




              $begingroup$
              I have added the final result, it matches perfectly with my computations. So +1
              $endgroup$
              – Oldboy
              2 days ago













            2












            2








            2





            $begingroup$

            As you observed, there are $10$ letters, of which $3$ are $A$s, $2$ are $M$s, $2$ are $T$s, $1$ is an $E$, $1$ is an $I$, and $1$ is a $K$.



            If there were no restrictions, we would choose three of the ten positions for the $A$s, two of the remaining seven positions for the $M$s, two of the remaining five positions for the $T$s, and arrange the $E$, $I$, $K$ in the remaining three positions in
            $$binom103binom72binom523! = frac10!3!7! cdot frac7!2!5! cdot frac5!2!3! cdot 3! = frac10!3!2!2!$$
            in agreement with your answer.



            From these, we must subtract those arrangements in which or more pairs of identical letters are adjacent.



            Arrangements with a pair of adjacent identical letters: We have to consider cases, depending on whether the identical letters are $A$s, $M$s, or $T$s.



            A pair of $A$s are adjacent: We have nine objects to arrange: $AA, A, M, M, T, T, E, I, K$. Choose two of the nine positions for the $M$s, two of the remaining seven positions for the $T$s, and then arrange the five distinct objects $AA$, $A$, $E$, $I$, $K$ in the remaining five positions, which can be done in
            $$binom92binom725!$$
            ways.



            A pair of $M$s are adjacent: We have nine objects to arrange: $A, A, A, MM, T, T, E, I, K$. Choose three of the nine positions for the $A$s, two of the remaining six positions for the $T$s, and arrange the four distinct objects $MM, E, I, K$ in the remaining four positions, which can be done in
            $$binom93binom624!$$
            ways.



            A pair of $T$s are adjacent: By symmetry, there are
            $$binom93binom624!$$
            such arrangements.



            Arrangements with two pairs of adjacent identical letters: This can occur in two ways. Either the pairs are disjoint or they overlap.



            Two pairs of $A$s are adjacent: This can only occur if the three $A$s are consecutive. Thus, we have eight objects to arrange: $AAA, M, M, T, T, E, I, K$. Choose two of the eight positions for the $M$s, two of the remaining six positions for the $T$s, and arrange the four distinct objects $AAA, E, I, K$ in the remaining four positions, which can be done in
            $$binom82binom624!$$
            ways.



            A pair of $A$s are adjacent and a pair of $M$s are adjacent: We have eight objects to arrange: $AA, A, MM, T, T, E, I, K$. Choose two of the eight positions for the $T$s and arrange the six distinct objects $AA, A, MM, E, I, K$ in the remaining six positions in
            $$binom826!$$
            ways.



            A pair of $A$s are adjacent and a pair of $T$s are adjacent: By symmetry, there are
            $$binom826!$$
            such arrangements.



            A pair of $M$s are adjacent and a pair of $T$s are adjacent: We have eight objects to arrange: $A, A, A, MM, TT, E, I, K$. Choose three of the eight positions for the $A$s and then arrange the remaining five distinct objects $MM, TT, E, I, K$ in the remaining five positions in
            $$binom835!$$
            ways.



            Arrangements with three pairs of adjacent identical letters: We again consider cases.



            Two pairs of $A$s are adjacent and a pair of $M$s are adjacent: We have seven objects to arrange, $AAA, MM, T, T, E, I, K$. Choose two of the seven positions for the $T$s and arrange the five distinct objects $AAA, MM, E, I, K$ in the remaining five positions in
            $$binom725!$$
            ways.



            Two pairs of $A$s are adjacent and a pair of $T$s are adjacent: By symmetry, there are
            $$binom725!$$
            such arrangements.



            A pair of $A$s are adjacent, a pair of $M$s are adjacent, and a pair of $T$s are adjacent: We have seven objects to arrange: $AA, A, MM, TT, E, I, K$. Since all the objects are distinct, there are
            $$7!$$
            such arrangements.



            Arrangements containing four pairs of adjacent identical letters: We have six objects to arrange: $AAA, MM, TT, E, I, K$. Since all the objects are distinct, there are
            $$6!$$
            such arrangements.



            By the Inclusion-Exclusion Principle, there are
            $$binom103binom72binom523! - binom92binom725! - binom93binom624! - binom93binom624! + binom82binom624! + binom826! + binom826! + binom835! - binom725! - binom725! - 7! + 6!=47760$$
            arrangements in which no two adjacent letters are identical.






            share|cite|improve this answer











            $endgroup$



            As you observed, there are $10$ letters, of which $3$ are $A$s, $2$ are $M$s, $2$ are $T$s, $1$ is an $E$, $1$ is an $I$, and $1$ is a $K$.



            If there were no restrictions, we would choose three of the ten positions for the $A$s, two of the remaining seven positions for the $M$s, two of the remaining five positions for the $T$s, and arrange the $E$, $I$, $K$ in the remaining three positions in
            $$binom103binom72binom523! = frac10!3!7! cdot frac7!2!5! cdot frac5!2!3! cdot 3! = frac10!3!2!2!$$
            in agreement with your answer.



            From these, we must subtract those arrangements in which or more pairs of identical letters are adjacent.



            Arrangements with a pair of adjacent identical letters: We have to consider cases, depending on whether the identical letters are $A$s, $M$s, or $T$s.



            A pair of $A$s are adjacent: We have nine objects to arrange: $AA, A, M, M, T, T, E, I, K$. Choose two of the nine positions for the $M$s, two of the remaining seven positions for the $T$s, and then arrange the five distinct objects $AA$, $A$, $E$, $I$, $K$ in the remaining five positions, which can be done in
            $$binom92binom725!$$
            ways.



            A pair of $M$s are adjacent: We have nine objects to arrange: $A, A, A, MM, T, T, E, I, K$. Choose three of the nine positions for the $A$s, two of the remaining six positions for the $T$s, and arrange the four distinct objects $MM, E, I, K$ in the remaining four positions, which can be done in
            $$binom93binom624!$$
            ways.



            A pair of $T$s are adjacent: By symmetry, there are
            $$binom93binom624!$$
            such arrangements.



            Arrangements with two pairs of adjacent identical letters: This can occur in two ways. Either the pairs are disjoint or they overlap.



            Two pairs of $A$s are adjacent: This can only occur if the three $A$s are consecutive. Thus, we have eight objects to arrange: $AAA, M, M, T, T, E, I, K$. Choose two of the eight positions for the $M$s, two of the remaining six positions for the $T$s, and arrange the four distinct objects $AAA, E, I, K$ in the remaining four positions, which can be done in
            $$binom82binom624!$$
            ways.



            A pair of $A$s are adjacent and a pair of $M$s are adjacent: We have eight objects to arrange: $AA, A, MM, T, T, E, I, K$. Choose two of the eight positions for the $T$s and arrange the six distinct objects $AA, A, MM, E, I, K$ in the remaining six positions in
            $$binom826!$$
            ways.



            A pair of $A$s are adjacent and a pair of $T$s are adjacent: By symmetry, there are
            $$binom826!$$
            such arrangements.



            A pair of $M$s are adjacent and a pair of $T$s are adjacent: We have eight objects to arrange: $A, A, A, MM, TT, E, I, K$. Choose three of the eight positions for the $A$s and then arrange the remaining five distinct objects $MM, TT, E, I, K$ in the remaining five positions in
            $$binom835!$$
            ways.



            Arrangements with three pairs of adjacent identical letters: We again consider cases.



            Two pairs of $A$s are adjacent and a pair of $M$s are adjacent: We have seven objects to arrange, $AAA, MM, T, T, E, I, K$. Choose two of the seven positions for the $T$s and arrange the five distinct objects $AAA, MM, E, I, K$ in the remaining five positions in
            $$binom725!$$
            ways.



            Two pairs of $A$s are adjacent and a pair of $T$s are adjacent: By symmetry, there are
            $$binom725!$$
            such arrangements.



            A pair of $A$s are adjacent, a pair of $M$s are adjacent, and a pair of $T$s are adjacent: We have seven objects to arrange: $AA, A, MM, TT, E, I, K$. Since all the objects are distinct, there are
            $$7!$$
            such arrangements.



            Arrangements containing four pairs of adjacent identical letters: We have six objects to arrange: $AAA, MM, TT, E, I, K$. Since all the objects are distinct, there are
            $$6!$$
            such arrangements.



            By the Inclusion-Exclusion Principle, there are
            $$binom103binom72binom523! - binom92binom725! - binom93binom624! - binom93binom624! + binom82binom624! + binom826! + binom826! + binom835! - binom725! - binom725! - 7! + 6!=47760$$
            arrangements in which no two adjacent letters are identical.







            share|cite|improve this answer














            share|cite|improve this answer



            share|cite|improve this answer








            edited 2 days ago









            Oldboy

            8,67911036




            8,67911036










            answered Mar 11 at 16:33









            N. F. TaussigN. F. Taussig

            44.7k103358




            44.7k103358







            • 1




              $begingroup$
              I have added the final result, it matches perfectly with my computations. So +1
              $endgroup$
              – Oldboy
              2 days ago












            • 1




              $begingroup$
              I have added the final result, it matches perfectly with my computations. So +1
              $endgroup$
              – Oldboy
              2 days ago







            1




            1




            $begingroup$
            I have added the final result, it matches perfectly with my computations. So +1
            $endgroup$
            – Oldboy
            2 days ago




            $begingroup$
            I have added the final result, it matches perfectly with my computations. So +1
            $endgroup$
            – Oldboy
            2 days ago











            0












            $begingroup$

            If I calculated everything correctly, your answer is 446880.



            I used the following program to check it:



            public class PermutationCounter 
            public static int[] duplicate(int[] source)
            int[] dest = new int[source.length];
            System.arraycopy(source, 0, dest, 0, source.length);
            return dest;


            public static boolean allLettersExhausted(int[] source)
            for(int i = 0; i < source.length; i++)
            if(source[i] != 0)
            return false;


            return true;


            private char[] letters;
            private int[] count;

            public PermutationCounter(char[] letters, int[] count)
            this.letters = letters;
            this.count = count;


            public int countPermutations()
            return countPermutations(-1, count, "");


            private int countPermutations(int last, int[] alphabet, String permutation)
            if(allLettersExhausted(alphabet))
            System.out.println(permutation);
            return 1;

            int sum = 0;
            for(int i = 0; i < alphabet.length; i++)
            if(i != last && alphabet[i] > 0)
            int[] alphabetCopy = duplicate(alphabet);
            alphabetCopy[i]--;
            sum += countPermutations(i, alphabetCopy, permutation + letters[i]);


            return sum;


            public static void main(String[] args)
            char[] letters = new char[] 'M', 'A', 'T', 'E', 'I', 'K';
            int[] count = new int[] 2, 3, 2, 1, 1, 1;
            PermutationCounter counter = new PermutationCounter(letters, count);
            System.out.println("TOTAL PERMUTATIONS: " + counter.countPermutations());




            My answer is 47760 (much lower number) and the full list of all permutations can be found here (yes, the word "MATEMATIKA" is also there).



            The code starts with two lists. The first contains the list of letters, the second list contains the number of appearances of each letter in the final word. The code is recursive: it tracks the last letter and counts all shorter words starting with a different letter.



            I know this is not the answer you were hoping for but it might help you to conclude if your answer is right or wrong.






            share|cite|improve this answer









            $endgroup$

















              0












              $begingroup$

              If I calculated everything correctly, your answer is 446880.



              I used the following program to check it:



              public class PermutationCounter 
              public static int[] duplicate(int[] source)
              int[] dest = new int[source.length];
              System.arraycopy(source, 0, dest, 0, source.length);
              return dest;


              public static boolean allLettersExhausted(int[] source)
              for(int i = 0; i < source.length; i++)
              if(source[i] != 0)
              return false;


              return true;


              private char[] letters;
              private int[] count;

              public PermutationCounter(char[] letters, int[] count)
              this.letters = letters;
              this.count = count;


              public int countPermutations()
              return countPermutations(-1, count, "");


              private int countPermutations(int last, int[] alphabet, String permutation)
              if(allLettersExhausted(alphabet))
              System.out.println(permutation);
              return 1;

              int sum = 0;
              for(int i = 0; i < alphabet.length; i++)
              if(i != last && alphabet[i] > 0)
              int[] alphabetCopy = duplicate(alphabet);
              alphabetCopy[i]--;
              sum += countPermutations(i, alphabetCopy, permutation + letters[i]);


              return sum;


              public static void main(String[] args)
              char[] letters = new char[] 'M', 'A', 'T', 'E', 'I', 'K';
              int[] count = new int[] 2, 3, 2, 1, 1, 1;
              PermutationCounter counter = new PermutationCounter(letters, count);
              System.out.println("TOTAL PERMUTATIONS: " + counter.countPermutations());




              My answer is 47760 (much lower number) and the full list of all permutations can be found here (yes, the word "MATEMATIKA" is also there).



              The code starts with two lists. The first contains the list of letters, the second list contains the number of appearances of each letter in the final word. The code is recursive: it tracks the last letter and counts all shorter words starting with a different letter.



              I know this is not the answer you were hoping for but it might help you to conclude if your answer is right or wrong.






              share|cite|improve this answer









              $endgroup$















                0












                0








                0





                $begingroup$

                If I calculated everything correctly, your answer is 446880.



                I used the following program to check it:



                public class PermutationCounter 
                public static int[] duplicate(int[] source)
                int[] dest = new int[source.length];
                System.arraycopy(source, 0, dest, 0, source.length);
                return dest;


                public static boolean allLettersExhausted(int[] source)
                for(int i = 0; i < source.length; i++)
                if(source[i] != 0)
                return false;


                return true;


                private char[] letters;
                private int[] count;

                public PermutationCounter(char[] letters, int[] count)
                this.letters = letters;
                this.count = count;


                public int countPermutations()
                return countPermutations(-1, count, "");


                private int countPermutations(int last, int[] alphabet, String permutation)
                if(allLettersExhausted(alphabet))
                System.out.println(permutation);
                return 1;

                int sum = 0;
                for(int i = 0; i < alphabet.length; i++)
                if(i != last && alphabet[i] > 0)
                int[] alphabetCopy = duplicate(alphabet);
                alphabetCopy[i]--;
                sum += countPermutations(i, alphabetCopy, permutation + letters[i]);


                return sum;


                public static void main(String[] args)
                char[] letters = new char[] 'M', 'A', 'T', 'E', 'I', 'K';
                int[] count = new int[] 2, 3, 2, 1, 1, 1;
                PermutationCounter counter = new PermutationCounter(letters, count);
                System.out.println("TOTAL PERMUTATIONS: " + counter.countPermutations());




                My answer is 47760 (much lower number) and the full list of all permutations can be found here (yes, the word "MATEMATIKA" is also there).



                The code starts with two lists. The first contains the list of letters, the second list contains the number of appearances of each letter in the final word. The code is recursive: it tracks the last letter and counts all shorter words starting with a different letter.



                I know this is not the answer you were hoping for but it might help you to conclude if your answer is right or wrong.






                share|cite|improve this answer









                $endgroup$



                If I calculated everything correctly, your answer is 446880.



                I used the following program to check it:



                public class PermutationCounter 
                public static int[] duplicate(int[] source)
                int[] dest = new int[source.length];
                System.arraycopy(source, 0, dest, 0, source.length);
                return dest;


                public static boolean allLettersExhausted(int[] source)
                for(int i = 0; i < source.length; i++)
                if(source[i] != 0)
                return false;


                return true;


                private char[] letters;
                private int[] count;

                public PermutationCounter(char[] letters, int[] count)
                this.letters = letters;
                this.count = count;


                public int countPermutations()
                return countPermutations(-1, count, "");


                private int countPermutations(int last, int[] alphabet, String permutation)
                if(allLettersExhausted(alphabet))
                System.out.println(permutation);
                return 1;

                int sum = 0;
                for(int i = 0; i < alphabet.length; i++)
                if(i != last && alphabet[i] > 0)
                int[] alphabetCopy = duplicate(alphabet);
                alphabetCopy[i]--;
                sum += countPermutations(i, alphabetCopy, permutation + letters[i]);


                return sum;


                public static void main(String[] args)
                char[] letters = new char[] 'M', 'A', 'T', 'E', 'I', 'K';
                int[] count = new int[] 2, 3, 2, 1, 1, 1;
                PermutationCounter counter = new PermutationCounter(letters, count);
                System.out.println("TOTAL PERMUTATIONS: " + counter.countPermutations());




                My answer is 47760 (much lower number) and the full list of all permutations can be found here (yes, the word "MATEMATIKA" is also there).



                The code starts with two lists. The first contains the list of letters, the second list contains the number of appearances of each letter in the final word. The code is recursive: it tracks the last letter and counts all shorter words starting with a different letter.



                I know this is not the answer you were hoping for but it might help you to conclude if your answer is right or wrong.







                share|cite|improve this answer












                share|cite|improve this answer



                share|cite|improve this answer










                answered Mar 11 at 15:58









                OldboyOldboy

                8,67911036




                8,67911036



























                    draft saved

                    draft discarded
















































                    Thanks for contributing an answer to Mathematics Stack Exchange!


                    • Please be sure to answer the question. Provide details and share your research!

                    But avoid


                    • Asking for help, clarification, or responding to other answers.

                    • Making statements based on opinion; back them up with references or personal experience.

                    Use MathJax to format equations. MathJax reference.


                    To learn more, see our tips on writing great answers.




                    draft saved


                    draft discarded














                    StackExchange.ready(
                    function ()
                    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f3143471%2fhow-many-permutations-are-there-of-m-m-a-a-a-t-t-e-i-k-so-that-no-two%23new-answer', 'question_page');

                    );

                    Post as a guest















                    Required, but never shown





















































                    Required, but never shown














                    Required, but never shown












                    Required, but never shown







                    Required, but never shown

































                    Required, but never shown














                    Required, but never shown












                    Required, but never shown







                    Required, but never shown







                    Popular posts from this blog

                    Solar Wings Breeze Design and development Specifications (Breeze) References Navigation menu1368-485X"Hang glider: Breeze (Solar Wings)"e

                    Kathakali Contents Etymology and nomenclature History Repertoire Songs and musical instruments Traditional plays Styles: Sampradayam Training centers and awards Relationship to other dance forms See also Notes References External links Navigation menueThe Illustrated Encyclopedia of Hinduism: A-MSouth Asian Folklore: An EncyclopediaRoutledge International Encyclopedia of Women: Global Women's Issues and KnowledgeKathakali Dance-drama: Where Gods and Demons Come to PlayKathakali Dance-drama: Where Gods and Demons Come to PlayKathakali Dance-drama: Where Gods and Demons Come to Play10.1353/atj.2005.0004The Illustrated Encyclopedia of Hinduism: A-MEncyclopedia of HinduismKathakali Dance-drama: Where Gods and Demons Come to PlaySonic Liturgy: Ritual and Music in Hindu Tradition"The Mirror of Gesture"Kathakali Dance-drama: Where Gods and Demons Come to Play"Kathakali"Indian Theatre: Traditions of PerformanceIndian Theatre: Traditions of PerformanceIndian Theatre: Traditions of PerformanceIndian Theatre: Traditions of PerformanceMedieval Indian Literature: An AnthologyThe Oxford Companion to Indian TheatreSouth Asian Folklore: An Encyclopedia : Afghanistan, Bangladesh, India, Nepal, Pakistan, Sri LankaThe Rise of Performance Studies: Rethinking Richard Schechner's Broad SpectrumIndian Theatre: Traditions of PerformanceModern Asian Theatre and Performance 1900-2000Critical Theory and PerformanceBetween Theater and AnthropologyKathakali603847011Indian Theatre: Traditions of PerformanceIndian Theatre: Traditions of PerformanceIndian Theatre: Traditions of PerformanceBetween Theater and AnthropologyBetween Theater and AnthropologyNambeesan Smaraka AwardsArchivedThe Cambridge Guide to TheatreRoutledge International Encyclopedia of Women: Global Women's Issues and KnowledgeThe Garland Encyclopedia of World Music: South Asia : the Indian subcontinentThe Ethos of Noh: Actors and Their Art10.2307/1145740By Means of Performance: Intercultural Studies of Theatre and Ritual10.1017/s204912550000100xReconceiving the Renaissance: A Critical ReaderPerformance TheoryListening to Theatre: The Aural Dimension of Beijing Opera10.2307/1146013Kathakali: The Art of the Non-WorldlyOn KathakaliKathakali, the dance theatreThe Kathakali Complex: Performance & StructureKathakali Dance-Drama: Where Gods and Demons Come to Play10.1093/obo/9780195399318-0071Drama and Ritual of Early Hinduism"In the Shadow of Hollywood Orientalism: Authentic East Indian Dancing"10.1080/08949460490274013Sanskrit Play Production in Ancient IndiaIndian Music: History and StructureBharata, the Nāṭyaśāstra233639306Table of Contents2238067286469807Dance In Indian Painting10.2307/32047833204783Kathakali Dance-Theatre: A Visual Narrative of Sacred Indian MimeIndian Classical Dance: The Renaissance and BeyondKathakali: an indigenous art-form of Keralaeee

                    Method to test if a number is a perfect power? Announcing the arrival of Valued Associate #679: Cesar Manara Planned maintenance scheduled April 23, 2019 at 00:00UTC (8:00pm US/Eastern)Detecting perfect squares faster than by extracting square rooteffective way to get the integer sequence A181392 from oeisA rarely mentioned fact about perfect powersHow many numbers such $n$ are there that $n<100,lfloorsqrtn rfloor mid n$Check perfect squareness by modulo division against multiple basesFor what pair of integers $(a,b)$ is $3^a + 7^b$ a perfect square.Do there exist any positive integers $n$ such that $lfloore^nrfloor$ is a perfect power? What is the probability that one exists?finding perfect power factors of an integerProve that the sequence contains a perfect square for any natural number $m $ in the domain of $f$ .Counting Perfect Powers