Number of ways to divide n people into k groups with at least 2 people in each group












2














I'm trying to figure out the number of ways to divide n people into k groups with at least 2 people in each group. Should I first decide a recurrence relation of the number? I don't know how I could prove such a relation.










share|cite|improve this question






















  • I reckon that the persons are distinguishable. Are the groups also distinguishable (I suspect only on cardinality, but it is essential information and must be given)?
    – drhab
    Nov 29 at 13:13












  • The groups are indistinguishable
    – Jingting931015
    Nov 29 at 13:21






  • 1




    Let $G(n,k)$ be the desired number. When we add a new person, we can either add him to an existing group, or we can pair him with one of the $n$ persons, and group the remaining $n-1$ persons into $k-1$ groups of at least two people.$$G(n+1,k)=k(G(n,k)+nG(n-1,k-1)$$
    – saulspatz
    Nov 29 at 13:56


















2














I'm trying to figure out the number of ways to divide n people into k groups with at least 2 people in each group. Should I first decide a recurrence relation of the number? I don't know how I could prove such a relation.










share|cite|improve this question






















  • I reckon that the persons are distinguishable. Are the groups also distinguishable (I suspect only on cardinality, but it is essential information and must be given)?
    – drhab
    Nov 29 at 13:13












  • The groups are indistinguishable
    – Jingting931015
    Nov 29 at 13:21






  • 1




    Let $G(n,k)$ be the desired number. When we add a new person, we can either add him to an existing group, or we can pair him with one of the $n$ persons, and group the remaining $n-1$ persons into $k-1$ groups of at least two people.$$G(n+1,k)=k(G(n,k)+nG(n-1,k-1)$$
    – saulspatz
    Nov 29 at 13:56
















2












2








2


1





I'm trying to figure out the number of ways to divide n people into k groups with at least 2 people in each group. Should I first decide a recurrence relation of the number? I don't know how I could prove such a relation.










share|cite|improve this question













I'm trying to figure out the number of ways to divide n people into k groups with at least 2 people in each group. Should I first decide a recurrence relation of the number? I don't know how I could prove such a relation.







combinatorics stirling-numbers






share|cite|improve this question













share|cite|improve this question











share|cite|improve this question




share|cite|improve this question










asked Nov 29 at 12:58









Jingting931015

828




828












  • I reckon that the persons are distinguishable. Are the groups also distinguishable (I suspect only on cardinality, but it is essential information and must be given)?
    – drhab
    Nov 29 at 13:13












  • The groups are indistinguishable
    – Jingting931015
    Nov 29 at 13:21






  • 1




    Let $G(n,k)$ be the desired number. When we add a new person, we can either add him to an existing group, or we can pair him with one of the $n$ persons, and group the remaining $n-1$ persons into $k-1$ groups of at least two people.$$G(n+1,k)=k(G(n,k)+nG(n-1,k-1)$$
    – saulspatz
    Nov 29 at 13:56




















  • I reckon that the persons are distinguishable. Are the groups also distinguishable (I suspect only on cardinality, but it is essential information and must be given)?
    – drhab
    Nov 29 at 13:13












  • The groups are indistinguishable
    – Jingting931015
    Nov 29 at 13:21






  • 1




    Let $G(n,k)$ be the desired number. When we add a new person, we can either add him to an existing group, or we can pair him with one of the $n$ persons, and group the remaining $n-1$ persons into $k-1$ groups of at least two people.$$G(n+1,k)=k(G(n,k)+nG(n-1,k-1)$$
    – saulspatz
    Nov 29 at 13:56


















I reckon that the persons are distinguishable. Are the groups also distinguishable (I suspect only on cardinality, but it is essential information and must be given)?
– drhab
Nov 29 at 13:13






I reckon that the persons are distinguishable. Are the groups also distinguishable (I suspect only on cardinality, but it is essential information and must be given)?
– drhab
Nov 29 at 13:13














The groups are indistinguishable
– Jingting931015
Nov 29 at 13:21




The groups are indistinguishable
– Jingting931015
Nov 29 at 13:21




1




1




Let $G(n,k)$ be the desired number. When we add a new person, we can either add him to an existing group, or we can pair him with one of the $n$ persons, and group the remaining $n-1$ persons into $k-1$ groups of at least two people.$$G(n+1,k)=k(G(n,k)+nG(n-1,k-1)$$
– saulspatz
Nov 29 at 13:56






Let $G(n,k)$ be the desired number. When we add a new person, we can either add him to an existing group, or we can pair him with one of the $n$ persons, and group the remaining $n-1$ persons into $k-1$ groups of at least two people.$$G(n+1,k)=k(G(n,k)+nG(n-1,k-1)$$
– saulspatz
Nov 29 at 13:56












4 Answers
4






active

oldest

votes


















2














Denote by $G(n,k)$ the number of partitions of $n$ people into $k$ groups of size $geq2$. It is obvious that $G(n,k)=0$ if $n<2k$. Furthermore
$$G(n,1)=left{eqalign{&0qquad(n<2)cr &1qquad(ngeq2) .cr}right.$$
A recursion with respect to $k$ is obtained as follows: The oldest person among the $n$ may choose the size $jgeq 2$ of his group and then the other members of his group in ${n-1choose j-1}$ ways. There are then $n-j$ people left over, which have to be partitioned into $k-1$ groups of size $geq2$. This enforces $n-jgeq 2(k-1)$, and leads to the recursion
$$G(n,k)=sum_{j=2}^{n+2-2k}{n-1choose j-1}G(n-j,k-1)qquad(ngeq2k, kgeq2) .$$
In the case $g(k):=G(2k,k)$ one obtains a closed formula with double factorials. By letting the oldest person make the first choice one immediately obtains the recursion $g(k)=(2k-1)g(k-1)$, so that $g(k)=1cdot3cdot5cdotldotscdot(2k-1)$.






share|cite|improve this answer























  • I see. This is really helpful! Suppose that I want to consider the special case where n=2k, is there a way to find a formula for rn,k?
    – Jingting931015
    Nov 29 at 15:15










  • Thanks a lot for the explanation!
    – Jingting931015
    Nov 29 at 15:53










  • Upvoted (+1). Matches the closed form.
    – Marko Riedel
    Nov 29 at 19:28



















2














We get more or less by inspection the combinatorial class



$$deftextsc#1{dosc#1csod}
defdosc#1#2csod{{rm #1{small #2}}}
textsc{SET}_{=k}(textsc{SET}_{ge 2}(mathcal{Z})).$$



This yields per the generating function



$$G_{n,k} = n! [z^n] frac{1}{k!} (exp(z)-z-1)^k
\ = n! [z^n] frac{1}{k!}
sum_{q=0}^k {kchoose q} (exp(z)-1)^q (-1)^{k-q} z^{k-q}
\ = n! frac{1}{k!}
sum_{q=0}^k {kchoose q}
[z^{n+q-k}] (exp(z)-1)^q (-1)^{k-q}
\ = n! frac{1}{k!}
sum_{q=0}^k {kchoose q} q!
[z^{n+q-k}] frac{(exp(z)-1)^q}{q!} (-1)^{k-q}
\ = n! frac{1}{k!}
sum_{q=0}^k {kchoose q} q!
frac{1}{(n+q-k)!} {n+q-kbrace q} (-1)^{k-q}.$$



This simplifies to



$$bbox[5px,border:2px solid #00A000]{ G_{n,k} =
sum_{q=0}^k {nchoose k-q} (-1)^{k-q} {n+q-kbrace q}.}$$



I.e. we get for $n=10$ the sequence



$$1, 501, 6825, 9450, 945, 0, ldots$$



which points us to OEIS A008299, where
these data are confirmed and, incidentally, shown to match the
accepted answer.






share|cite|improve this answer





























    1














    Here is a derivation of Marko Riedel's formula using the principle of inclusion-exclusion.



    Let $P$ be the set of partitions of your set of ${1,2,dots,n}$ elements into $k$ groups (without the $ge 2$ restriction). For each $iin {1,2,dots,n}$, let $P_i$ be the number of partitions where $i$ is in a group of size $1$. We want to count
    $$
    Big|Psetminus bigcup_{i=1}^n P_iBig|.
    $$

    Using inclusion exclusion, and the symmetry of the numbers, this is
    $$
    |P|-binom{n}1|P_1|+binom{n}2|P_1cap P_2|-dots+(-1)^jbinom{n}j|P_1cap P_2cap dots cap P_j|+dots
    $$

    To count $|P_1cap P_2cap dots cap P_j|$, note that elements $1,2,dots,k$ are all alone, so we must partition the remaining $n-j$ elements into $k-j$ parts. This can be done in ${n-j brace k-j}$ ways, by defintion of the Stirling numbers of the second kind. Therefore, the final result is
    $$
    sum_{j=0}^k(-1)^jbinom{n}j{n-j brace k-j}
    $$

    Reversing the order of summation (and changing $j$ to $q$) gives Marko's answer.






    share|cite|improve this answer





















    • Good work. Verified (+1). For some reason I did not complete the simplification at the end. I will leave my answer as is so that your observations / concluding remarks keep making sense.
      – Marko Riedel
      Nov 30 at 18:09





















    0














    The the number of ways in which n people can be divided into k groups of which first contain $r_1$ people, second contains $r_2$ people etc. is $frac{n!}{r_1!r_2!...r_k!}$



    Where $r_1,...r_k$ are integers such that $ r_1+r_2 +...+r_k=n, r_igeq 0$






    share|cite|improve this answer























      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%2f3018587%2fnumber-of-ways-to-divide-n-people-into-k-groups-with-at-least-2-people-in-each-g%23new-answer', 'question_page');
      }
      );

      Post as a guest















      Required, but never shown

























      4 Answers
      4






      active

      oldest

      votes








      4 Answers
      4






      active

      oldest

      votes









      active

      oldest

      votes






      active

      oldest

      votes









      2














      Denote by $G(n,k)$ the number of partitions of $n$ people into $k$ groups of size $geq2$. It is obvious that $G(n,k)=0$ if $n<2k$. Furthermore
      $$G(n,1)=left{eqalign{&0qquad(n<2)cr &1qquad(ngeq2) .cr}right.$$
      A recursion with respect to $k$ is obtained as follows: The oldest person among the $n$ may choose the size $jgeq 2$ of his group and then the other members of his group in ${n-1choose j-1}$ ways. There are then $n-j$ people left over, which have to be partitioned into $k-1$ groups of size $geq2$. This enforces $n-jgeq 2(k-1)$, and leads to the recursion
      $$G(n,k)=sum_{j=2}^{n+2-2k}{n-1choose j-1}G(n-j,k-1)qquad(ngeq2k, kgeq2) .$$
      In the case $g(k):=G(2k,k)$ one obtains a closed formula with double factorials. By letting the oldest person make the first choice one immediately obtains the recursion $g(k)=(2k-1)g(k-1)$, so that $g(k)=1cdot3cdot5cdotldotscdot(2k-1)$.






      share|cite|improve this answer























      • I see. This is really helpful! Suppose that I want to consider the special case where n=2k, is there a way to find a formula for rn,k?
        – Jingting931015
        Nov 29 at 15:15










      • Thanks a lot for the explanation!
        – Jingting931015
        Nov 29 at 15:53










      • Upvoted (+1). Matches the closed form.
        – Marko Riedel
        Nov 29 at 19:28
















      2














      Denote by $G(n,k)$ the number of partitions of $n$ people into $k$ groups of size $geq2$. It is obvious that $G(n,k)=0$ if $n<2k$. Furthermore
      $$G(n,1)=left{eqalign{&0qquad(n<2)cr &1qquad(ngeq2) .cr}right.$$
      A recursion with respect to $k$ is obtained as follows: The oldest person among the $n$ may choose the size $jgeq 2$ of his group and then the other members of his group in ${n-1choose j-1}$ ways. There are then $n-j$ people left over, which have to be partitioned into $k-1$ groups of size $geq2$. This enforces $n-jgeq 2(k-1)$, and leads to the recursion
      $$G(n,k)=sum_{j=2}^{n+2-2k}{n-1choose j-1}G(n-j,k-1)qquad(ngeq2k, kgeq2) .$$
      In the case $g(k):=G(2k,k)$ one obtains a closed formula with double factorials. By letting the oldest person make the first choice one immediately obtains the recursion $g(k)=(2k-1)g(k-1)$, so that $g(k)=1cdot3cdot5cdotldotscdot(2k-1)$.






      share|cite|improve this answer























      • I see. This is really helpful! Suppose that I want to consider the special case where n=2k, is there a way to find a formula for rn,k?
        – Jingting931015
        Nov 29 at 15:15










      • Thanks a lot for the explanation!
        – Jingting931015
        Nov 29 at 15:53










      • Upvoted (+1). Matches the closed form.
        – Marko Riedel
        Nov 29 at 19:28














      2












      2








      2






      Denote by $G(n,k)$ the number of partitions of $n$ people into $k$ groups of size $geq2$. It is obvious that $G(n,k)=0$ if $n<2k$. Furthermore
      $$G(n,1)=left{eqalign{&0qquad(n<2)cr &1qquad(ngeq2) .cr}right.$$
      A recursion with respect to $k$ is obtained as follows: The oldest person among the $n$ may choose the size $jgeq 2$ of his group and then the other members of his group in ${n-1choose j-1}$ ways. There are then $n-j$ people left over, which have to be partitioned into $k-1$ groups of size $geq2$. This enforces $n-jgeq 2(k-1)$, and leads to the recursion
      $$G(n,k)=sum_{j=2}^{n+2-2k}{n-1choose j-1}G(n-j,k-1)qquad(ngeq2k, kgeq2) .$$
      In the case $g(k):=G(2k,k)$ one obtains a closed formula with double factorials. By letting the oldest person make the first choice one immediately obtains the recursion $g(k)=(2k-1)g(k-1)$, so that $g(k)=1cdot3cdot5cdotldotscdot(2k-1)$.






      share|cite|improve this answer














      Denote by $G(n,k)$ the number of partitions of $n$ people into $k$ groups of size $geq2$. It is obvious that $G(n,k)=0$ if $n<2k$. Furthermore
      $$G(n,1)=left{eqalign{&0qquad(n<2)cr &1qquad(ngeq2) .cr}right.$$
      A recursion with respect to $k$ is obtained as follows: The oldest person among the $n$ may choose the size $jgeq 2$ of his group and then the other members of his group in ${n-1choose j-1}$ ways. There are then $n-j$ people left over, which have to be partitioned into $k-1$ groups of size $geq2$. This enforces $n-jgeq 2(k-1)$, and leads to the recursion
      $$G(n,k)=sum_{j=2}^{n+2-2k}{n-1choose j-1}G(n-j,k-1)qquad(ngeq2k, kgeq2) .$$
      In the case $g(k):=G(2k,k)$ one obtains a closed formula with double factorials. By letting the oldest person make the first choice one immediately obtains the recursion $g(k)=(2k-1)g(k-1)$, so that $g(k)=1cdot3cdot5cdotldotscdot(2k-1)$.







      share|cite|improve this answer














      share|cite|improve this answer



      share|cite|improve this answer








      edited Nov 29 at 15:35

























      answered Nov 29 at 14:05









      Christian Blatter

      172k7112325




      172k7112325












      • I see. This is really helpful! Suppose that I want to consider the special case where n=2k, is there a way to find a formula for rn,k?
        – Jingting931015
        Nov 29 at 15:15










      • Thanks a lot for the explanation!
        – Jingting931015
        Nov 29 at 15:53










      • Upvoted (+1). Matches the closed form.
        – Marko Riedel
        Nov 29 at 19:28


















      • I see. This is really helpful! Suppose that I want to consider the special case where n=2k, is there a way to find a formula for rn,k?
        – Jingting931015
        Nov 29 at 15:15










      • Thanks a lot for the explanation!
        – Jingting931015
        Nov 29 at 15:53










      • Upvoted (+1). Matches the closed form.
        – Marko Riedel
        Nov 29 at 19:28
















      I see. This is really helpful! Suppose that I want to consider the special case where n=2k, is there a way to find a formula for rn,k?
      – Jingting931015
      Nov 29 at 15:15




      I see. This is really helpful! Suppose that I want to consider the special case where n=2k, is there a way to find a formula for rn,k?
      – Jingting931015
      Nov 29 at 15:15












      Thanks a lot for the explanation!
      – Jingting931015
      Nov 29 at 15:53




      Thanks a lot for the explanation!
      – Jingting931015
      Nov 29 at 15:53












      Upvoted (+1). Matches the closed form.
      – Marko Riedel
      Nov 29 at 19:28




      Upvoted (+1). Matches the closed form.
      – Marko Riedel
      Nov 29 at 19:28











      2














      We get more or less by inspection the combinatorial class



      $$deftextsc#1{dosc#1csod}
      defdosc#1#2csod{{rm #1{small #2}}}
      textsc{SET}_{=k}(textsc{SET}_{ge 2}(mathcal{Z})).$$



      This yields per the generating function



      $$G_{n,k} = n! [z^n] frac{1}{k!} (exp(z)-z-1)^k
      \ = n! [z^n] frac{1}{k!}
      sum_{q=0}^k {kchoose q} (exp(z)-1)^q (-1)^{k-q} z^{k-q}
      \ = n! frac{1}{k!}
      sum_{q=0}^k {kchoose q}
      [z^{n+q-k}] (exp(z)-1)^q (-1)^{k-q}
      \ = n! frac{1}{k!}
      sum_{q=0}^k {kchoose q} q!
      [z^{n+q-k}] frac{(exp(z)-1)^q}{q!} (-1)^{k-q}
      \ = n! frac{1}{k!}
      sum_{q=0}^k {kchoose q} q!
      frac{1}{(n+q-k)!} {n+q-kbrace q} (-1)^{k-q}.$$



      This simplifies to



      $$bbox[5px,border:2px solid #00A000]{ G_{n,k} =
      sum_{q=0}^k {nchoose k-q} (-1)^{k-q} {n+q-kbrace q}.}$$



      I.e. we get for $n=10$ the sequence



      $$1, 501, 6825, 9450, 945, 0, ldots$$



      which points us to OEIS A008299, where
      these data are confirmed and, incidentally, shown to match the
      accepted answer.






      share|cite|improve this answer


























        2














        We get more or less by inspection the combinatorial class



        $$deftextsc#1{dosc#1csod}
        defdosc#1#2csod{{rm #1{small #2}}}
        textsc{SET}_{=k}(textsc{SET}_{ge 2}(mathcal{Z})).$$



        This yields per the generating function



        $$G_{n,k} = n! [z^n] frac{1}{k!} (exp(z)-z-1)^k
        \ = n! [z^n] frac{1}{k!}
        sum_{q=0}^k {kchoose q} (exp(z)-1)^q (-1)^{k-q} z^{k-q}
        \ = n! frac{1}{k!}
        sum_{q=0}^k {kchoose q}
        [z^{n+q-k}] (exp(z)-1)^q (-1)^{k-q}
        \ = n! frac{1}{k!}
        sum_{q=0}^k {kchoose q} q!
        [z^{n+q-k}] frac{(exp(z)-1)^q}{q!} (-1)^{k-q}
        \ = n! frac{1}{k!}
        sum_{q=0}^k {kchoose q} q!
        frac{1}{(n+q-k)!} {n+q-kbrace q} (-1)^{k-q}.$$



        This simplifies to



        $$bbox[5px,border:2px solid #00A000]{ G_{n,k} =
        sum_{q=0}^k {nchoose k-q} (-1)^{k-q} {n+q-kbrace q}.}$$



        I.e. we get for $n=10$ the sequence



        $$1, 501, 6825, 9450, 945, 0, ldots$$



        which points us to OEIS A008299, where
        these data are confirmed and, incidentally, shown to match the
        accepted answer.






        share|cite|improve this answer
























          2












          2








          2






          We get more or less by inspection the combinatorial class



          $$deftextsc#1{dosc#1csod}
          defdosc#1#2csod{{rm #1{small #2}}}
          textsc{SET}_{=k}(textsc{SET}_{ge 2}(mathcal{Z})).$$



          This yields per the generating function



          $$G_{n,k} = n! [z^n] frac{1}{k!} (exp(z)-z-1)^k
          \ = n! [z^n] frac{1}{k!}
          sum_{q=0}^k {kchoose q} (exp(z)-1)^q (-1)^{k-q} z^{k-q}
          \ = n! frac{1}{k!}
          sum_{q=0}^k {kchoose q}
          [z^{n+q-k}] (exp(z)-1)^q (-1)^{k-q}
          \ = n! frac{1}{k!}
          sum_{q=0}^k {kchoose q} q!
          [z^{n+q-k}] frac{(exp(z)-1)^q}{q!} (-1)^{k-q}
          \ = n! frac{1}{k!}
          sum_{q=0}^k {kchoose q} q!
          frac{1}{(n+q-k)!} {n+q-kbrace q} (-1)^{k-q}.$$



          This simplifies to



          $$bbox[5px,border:2px solid #00A000]{ G_{n,k} =
          sum_{q=0}^k {nchoose k-q} (-1)^{k-q} {n+q-kbrace q}.}$$



          I.e. we get for $n=10$ the sequence



          $$1, 501, 6825, 9450, 945, 0, ldots$$



          which points us to OEIS A008299, where
          these data are confirmed and, incidentally, shown to match the
          accepted answer.






          share|cite|improve this answer












          We get more or less by inspection the combinatorial class



          $$deftextsc#1{dosc#1csod}
          defdosc#1#2csod{{rm #1{small #2}}}
          textsc{SET}_{=k}(textsc{SET}_{ge 2}(mathcal{Z})).$$



          This yields per the generating function



          $$G_{n,k} = n! [z^n] frac{1}{k!} (exp(z)-z-1)^k
          \ = n! [z^n] frac{1}{k!}
          sum_{q=0}^k {kchoose q} (exp(z)-1)^q (-1)^{k-q} z^{k-q}
          \ = n! frac{1}{k!}
          sum_{q=0}^k {kchoose q}
          [z^{n+q-k}] (exp(z)-1)^q (-1)^{k-q}
          \ = n! frac{1}{k!}
          sum_{q=0}^k {kchoose q} q!
          [z^{n+q-k}] frac{(exp(z)-1)^q}{q!} (-1)^{k-q}
          \ = n! frac{1}{k!}
          sum_{q=0}^k {kchoose q} q!
          frac{1}{(n+q-k)!} {n+q-kbrace q} (-1)^{k-q}.$$



          This simplifies to



          $$bbox[5px,border:2px solid #00A000]{ G_{n,k} =
          sum_{q=0}^k {nchoose k-q} (-1)^{k-q} {n+q-kbrace q}.}$$



          I.e. we get for $n=10$ the sequence



          $$1, 501, 6825, 9450, 945, 0, ldots$$



          which points us to OEIS A008299, where
          these data are confirmed and, incidentally, shown to match the
          accepted answer.







          share|cite|improve this answer












          share|cite|improve this answer



          share|cite|improve this answer










          answered Nov 29 at 19:28









          Marko Riedel

          38.7k339107




          38.7k339107























              1














              Here is a derivation of Marko Riedel's formula using the principle of inclusion-exclusion.



              Let $P$ be the set of partitions of your set of ${1,2,dots,n}$ elements into $k$ groups (without the $ge 2$ restriction). For each $iin {1,2,dots,n}$, let $P_i$ be the number of partitions where $i$ is in a group of size $1$. We want to count
              $$
              Big|Psetminus bigcup_{i=1}^n P_iBig|.
              $$

              Using inclusion exclusion, and the symmetry of the numbers, this is
              $$
              |P|-binom{n}1|P_1|+binom{n}2|P_1cap P_2|-dots+(-1)^jbinom{n}j|P_1cap P_2cap dots cap P_j|+dots
              $$

              To count $|P_1cap P_2cap dots cap P_j|$, note that elements $1,2,dots,k$ are all alone, so we must partition the remaining $n-j$ elements into $k-j$ parts. This can be done in ${n-j brace k-j}$ ways, by defintion of the Stirling numbers of the second kind. Therefore, the final result is
              $$
              sum_{j=0}^k(-1)^jbinom{n}j{n-j brace k-j}
              $$

              Reversing the order of summation (and changing $j$ to $q$) gives Marko's answer.






              share|cite|improve this answer





















              • Good work. Verified (+1). For some reason I did not complete the simplification at the end. I will leave my answer as is so that your observations / concluding remarks keep making sense.
                – Marko Riedel
                Nov 30 at 18:09


















              1














              Here is a derivation of Marko Riedel's formula using the principle of inclusion-exclusion.



              Let $P$ be the set of partitions of your set of ${1,2,dots,n}$ elements into $k$ groups (without the $ge 2$ restriction). For each $iin {1,2,dots,n}$, let $P_i$ be the number of partitions where $i$ is in a group of size $1$. We want to count
              $$
              Big|Psetminus bigcup_{i=1}^n P_iBig|.
              $$

              Using inclusion exclusion, and the symmetry of the numbers, this is
              $$
              |P|-binom{n}1|P_1|+binom{n}2|P_1cap P_2|-dots+(-1)^jbinom{n}j|P_1cap P_2cap dots cap P_j|+dots
              $$

              To count $|P_1cap P_2cap dots cap P_j|$, note that elements $1,2,dots,k$ are all alone, so we must partition the remaining $n-j$ elements into $k-j$ parts. This can be done in ${n-j brace k-j}$ ways, by defintion of the Stirling numbers of the second kind. Therefore, the final result is
              $$
              sum_{j=0}^k(-1)^jbinom{n}j{n-j brace k-j}
              $$

              Reversing the order of summation (and changing $j$ to $q$) gives Marko's answer.






              share|cite|improve this answer





















              • Good work. Verified (+1). For some reason I did not complete the simplification at the end. I will leave my answer as is so that your observations / concluding remarks keep making sense.
                – Marko Riedel
                Nov 30 at 18:09
















              1












              1








              1






              Here is a derivation of Marko Riedel's formula using the principle of inclusion-exclusion.



              Let $P$ be the set of partitions of your set of ${1,2,dots,n}$ elements into $k$ groups (without the $ge 2$ restriction). For each $iin {1,2,dots,n}$, let $P_i$ be the number of partitions where $i$ is in a group of size $1$. We want to count
              $$
              Big|Psetminus bigcup_{i=1}^n P_iBig|.
              $$

              Using inclusion exclusion, and the symmetry of the numbers, this is
              $$
              |P|-binom{n}1|P_1|+binom{n}2|P_1cap P_2|-dots+(-1)^jbinom{n}j|P_1cap P_2cap dots cap P_j|+dots
              $$

              To count $|P_1cap P_2cap dots cap P_j|$, note that elements $1,2,dots,k$ are all alone, so we must partition the remaining $n-j$ elements into $k-j$ parts. This can be done in ${n-j brace k-j}$ ways, by defintion of the Stirling numbers of the second kind. Therefore, the final result is
              $$
              sum_{j=0}^k(-1)^jbinom{n}j{n-j brace k-j}
              $$

              Reversing the order of summation (and changing $j$ to $q$) gives Marko's answer.






              share|cite|improve this answer












              Here is a derivation of Marko Riedel's formula using the principle of inclusion-exclusion.



              Let $P$ be the set of partitions of your set of ${1,2,dots,n}$ elements into $k$ groups (without the $ge 2$ restriction). For each $iin {1,2,dots,n}$, let $P_i$ be the number of partitions where $i$ is in a group of size $1$. We want to count
              $$
              Big|Psetminus bigcup_{i=1}^n P_iBig|.
              $$

              Using inclusion exclusion, and the symmetry of the numbers, this is
              $$
              |P|-binom{n}1|P_1|+binom{n}2|P_1cap P_2|-dots+(-1)^jbinom{n}j|P_1cap P_2cap dots cap P_j|+dots
              $$

              To count $|P_1cap P_2cap dots cap P_j|$, note that elements $1,2,dots,k$ are all alone, so we must partition the remaining $n-j$ elements into $k-j$ parts. This can be done in ${n-j brace k-j}$ ways, by defintion of the Stirling numbers of the second kind. Therefore, the final result is
              $$
              sum_{j=0}^k(-1)^jbinom{n}j{n-j brace k-j}
              $$

              Reversing the order of summation (and changing $j$ to $q$) gives Marko's answer.







              share|cite|improve this answer












              share|cite|improve this answer



              share|cite|improve this answer










              answered Nov 30 at 17:20









              Mike Earnest

              20.1k11950




              20.1k11950












              • Good work. Verified (+1). For some reason I did not complete the simplification at the end. I will leave my answer as is so that your observations / concluding remarks keep making sense.
                – Marko Riedel
                Nov 30 at 18:09




















              • Good work. Verified (+1). For some reason I did not complete the simplification at the end. I will leave my answer as is so that your observations / concluding remarks keep making sense.
                – Marko Riedel
                Nov 30 at 18:09


















              Good work. Verified (+1). For some reason I did not complete the simplification at the end. I will leave my answer as is so that your observations / concluding remarks keep making sense.
              – Marko Riedel
              Nov 30 at 18:09






              Good work. Verified (+1). For some reason I did not complete the simplification at the end. I will leave my answer as is so that your observations / concluding remarks keep making sense.
              – Marko Riedel
              Nov 30 at 18:09













              0














              The the number of ways in which n people can be divided into k groups of which first contain $r_1$ people, second contains $r_2$ people etc. is $frac{n!}{r_1!r_2!...r_k!}$



              Where $r_1,...r_k$ are integers such that $ r_1+r_2 +...+r_k=n, r_igeq 0$






              share|cite|improve this answer




























                0














                The the number of ways in which n people can be divided into k groups of which first contain $r_1$ people, second contains $r_2$ people etc. is $frac{n!}{r_1!r_2!...r_k!}$



                Where $r_1,...r_k$ are integers such that $ r_1+r_2 +...+r_k=n, r_igeq 0$






                share|cite|improve this answer


























                  0












                  0








                  0






                  The the number of ways in which n people can be divided into k groups of which first contain $r_1$ people, second contains $r_2$ people etc. is $frac{n!}{r_1!r_2!...r_k!}$



                  Where $r_1,...r_k$ are integers such that $ r_1+r_2 +...+r_k=n, r_igeq 0$






                  share|cite|improve this answer














                  The the number of ways in which n people can be divided into k groups of which first contain $r_1$ people, second contains $r_2$ people etc. is $frac{n!}{r_1!r_2!...r_k!}$



                  Where $r_1,...r_k$ are integers such that $ r_1+r_2 +...+r_k=n, r_igeq 0$







                  share|cite|improve this answer














                  share|cite|improve this answer



                  share|cite|improve this answer








                  edited Nov 29 at 14:57

























                  answered Nov 29 at 14:31









                  Dhamnekar Winod

                  360414




                  360414






























                      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.





                      Some of your past answers have not been well-received, and you're in danger of being blocked from answering.


                      Please pay close attention to the following guidance:


                      • 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.


                      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%2f3018587%2fnumber-of-ways-to-divide-n-people-into-k-groups-with-at-least-2-people-in-each-g%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

                      Berounka

                      Sphinx de Gizeh

                      Different font size/position of beamer's navigation symbols template's content depending on regular/plain...