Calculating no. of solutions within some bounds











up vote
0
down vote

favorite












Find the total number of non-negative integral ordered triplets for-
$$x_1+x_2+x_3=11$$
under the bounds,




  • $x_1in (2,6)$ and


  • $x_2 in (3,7)$.



I was generally able to solve such problems involving bounds by introducing a new variable but that was only in case of a single boundary condition.
How do I proceed when there are two?










share|cite|improve this question




























    up vote
    0
    down vote

    favorite












    Find the total number of non-negative integral ordered triplets for-
    $$x_1+x_2+x_3=11$$
    under the bounds,




    • $x_1in (2,6)$ and


    • $x_2 in (3,7)$.



    I was generally able to solve such problems involving bounds by introducing a new variable but that was only in case of a single boundary condition.
    How do I proceed when there are two?










    share|cite|improve this question


























      up vote
      0
      down vote

      favorite









      up vote
      0
      down vote

      favorite











      Find the total number of non-negative integral ordered triplets for-
      $$x_1+x_2+x_3=11$$
      under the bounds,




      • $x_1in (2,6)$ and


      • $x_2 in (3,7)$.



      I was generally able to solve such problems involving bounds by introducing a new variable but that was only in case of a single boundary condition.
      How do I proceed when there are two?










      share|cite|improve this question















      Find the total number of non-negative integral ordered triplets for-
      $$x_1+x_2+x_3=11$$
      under the bounds,




      • $x_1in (2,6)$ and


      • $x_2 in (3,7)$.



      I was generally able to solve such problems involving bounds by introducing a new variable but that was only in case of a single boundary condition.
      How do I proceed when there are two?







      combinatorics discrete-mathematics






      share|cite|improve this question















      share|cite|improve this question













      share|cite|improve this question




      share|cite|improve this question








      edited Nov 19 at 15:41









      Tianlalu

      2,9901936




      2,9901936










      asked Nov 19 at 14:52









      Sameer Thakur

      142




      142






















          2 Answers
          2






          active

          oldest

          votes

















          up vote
          0
          down vote













          I have figured out an approach using Multinomial Theorem-
          We can find the coefficient of x^11 in (x^3+x^4+x^5)(x^4+x^5++x^6)(x^1+x^2+x^3+x^4).



          This comes out to be 8.






          share|cite|improve this answer





















          • Can someone guide me as to whether this is a correct approach?
            – Sameer Thakur
            Nov 19 at 16:10


















          up vote
          0
          down vote













          This can be solved using Bose-Einstein, which is also known as Bars and Stars https://en.wikipedia.org/wiki/Stars_and_bars_(combinatorics).



          In your case, you have 11 dots, and basically you want to put this 11 dots into 3 boxes. You only care how many dots are going in each box. For this you can use:
          $$binom{n + k - 1}{k-1}$$ and in your case: $$binom{11 + 3 - 1}{2}$$ This is including the solutions where you have 0 as possible value for some variables, so you might want to exclude those.



          First let's get all the possible solutions that match the lower bound.
          Smallest value for x1 is 3 and for x2 is 4. We can mark x1 and x2 as:
          $$x1 = y1 + 3\
          x2 = y2 + 4
          $$



          The new equation becomes: $$ y1 + 3 + y2 + 4 + x3 = 11 <=> y1 + y2 + x3 = 4 $$
          Now all the possible values are:
          $$ binom{4 + 3 - 1}{3 - 1}$$
          From this ones you need to substract all the values that have either x1 > 6 or x2 > 7. (They can't be both greater since the sum would be over the boundaries). So you can replace x1 with y1 + 6 and x2 with y2 + 7 and apply the same principle. After that you can substract these results from the total.






          share|cite|improve this answer























          • I have edited the question.
            – Sameer Thakur
            Nov 19 at 15:32











          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',
          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%2f3005023%2fcalculating-no-of-solutions-within-some-bounds%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








          up vote
          0
          down vote













          I have figured out an approach using Multinomial Theorem-
          We can find the coefficient of x^11 in (x^3+x^4+x^5)(x^4+x^5++x^6)(x^1+x^2+x^3+x^4).



          This comes out to be 8.






          share|cite|improve this answer





















          • Can someone guide me as to whether this is a correct approach?
            – Sameer Thakur
            Nov 19 at 16:10















          up vote
          0
          down vote













          I have figured out an approach using Multinomial Theorem-
          We can find the coefficient of x^11 in (x^3+x^4+x^5)(x^4+x^5++x^6)(x^1+x^2+x^3+x^4).



          This comes out to be 8.






          share|cite|improve this answer





















          • Can someone guide me as to whether this is a correct approach?
            – Sameer Thakur
            Nov 19 at 16:10













          up vote
          0
          down vote










          up vote
          0
          down vote









          I have figured out an approach using Multinomial Theorem-
          We can find the coefficient of x^11 in (x^3+x^4+x^5)(x^4+x^5++x^6)(x^1+x^2+x^3+x^4).



          This comes out to be 8.






          share|cite|improve this answer












          I have figured out an approach using Multinomial Theorem-
          We can find the coefficient of x^11 in (x^3+x^4+x^5)(x^4+x^5++x^6)(x^1+x^2+x^3+x^4).



          This comes out to be 8.







          share|cite|improve this answer












          share|cite|improve this answer



          share|cite|improve this answer










          answered Nov 19 at 16:05









          Sameer Thakur

          142




          142












          • Can someone guide me as to whether this is a correct approach?
            – Sameer Thakur
            Nov 19 at 16:10


















          • Can someone guide me as to whether this is a correct approach?
            – Sameer Thakur
            Nov 19 at 16:10
















          Can someone guide me as to whether this is a correct approach?
          – Sameer Thakur
          Nov 19 at 16:10




          Can someone guide me as to whether this is a correct approach?
          – Sameer Thakur
          Nov 19 at 16:10










          up vote
          0
          down vote













          This can be solved using Bose-Einstein, which is also known as Bars and Stars https://en.wikipedia.org/wiki/Stars_and_bars_(combinatorics).



          In your case, you have 11 dots, and basically you want to put this 11 dots into 3 boxes. You only care how many dots are going in each box. For this you can use:
          $$binom{n + k - 1}{k-1}$$ and in your case: $$binom{11 + 3 - 1}{2}$$ This is including the solutions where you have 0 as possible value for some variables, so you might want to exclude those.



          First let's get all the possible solutions that match the lower bound.
          Smallest value for x1 is 3 and for x2 is 4. We can mark x1 and x2 as:
          $$x1 = y1 + 3\
          x2 = y2 + 4
          $$



          The new equation becomes: $$ y1 + 3 + y2 + 4 + x3 = 11 <=> y1 + y2 + x3 = 4 $$
          Now all the possible values are:
          $$ binom{4 + 3 - 1}{3 - 1}$$
          From this ones you need to substract all the values that have either x1 > 6 or x2 > 7. (They can't be both greater since the sum would be over the boundaries). So you can replace x1 with y1 + 6 and x2 with y2 + 7 and apply the same principle. After that you can substract these results from the total.






          share|cite|improve this answer























          • I have edited the question.
            – Sameer Thakur
            Nov 19 at 15:32















          up vote
          0
          down vote













          This can be solved using Bose-Einstein, which is also known as Bars and Stars https://en.wikipedia.org/wiki/Stars_and_bars_(combinatorics).



          In your case, you have 11 dots, and basically you want to put this 11 dots into 3 boxes. You only care how many dots are going in each box. For this you can use:
          $$binom{n + k - 1}{k-1}$$ and in your case: $$binom{11 + 3 - 1}{2}$$ This is including the solutions where you have 0 as possible value for some variables, so you might want to exclude those.



          First let's get all the possible solutions that match the lower bound.
          Smallest value for x1 is 3 and for x2 is 4. We can mark x1 and x2 as:
          $$x1 = y1 + 3\
          x2 = y2 + 4
          $$



          The new equation becomes: $$ y1 + 3 + y2 + 4 + x3 = 11 <=> y1 + y2 + x3 = 4 $$
          Now all the possible values are:
          $$ binom{4 + 3 - 1}{3 - 1}$$
          From this ones you need to substract all the values that have either x1 > 6 or x2 > 7. (They can't be both greater since the sum would be over the boundaries). So you can replace x1 with y1 + 6 and x2 with y2 + 7 and apply the same principle. After that you can substract these results from the total.






          share|cite|improve this answer























          • I have edited the question.
            – Sameer Thakur
            Nov 19 at 15:32













          up vote
          0
          down vote










          up vote
          0
          down vote









          This can be solved using Bose-Einstein, which is also known as Bars and Stars https://en.wikipedia.org/wiki/Stars_and_bars_(combinatorics).



          In your case, you have 11 dots, and basically you want to put this 11 dots into 3 boxes. You only care how many dots are going in each box. For this you can use:
          $$binom{n + k - 1}{k-1}$$ and in your case: $$binom{11 + 3 - 1}{2}$$ This is including the solutions where you have 0 as possible value for some variables, so you might want to exclude those.



          First let's get all the possible solutions that match the lower bound.
          Smallest value for x1 is 3 and for x2 is 4. We can mark x1 and x2 as:
          $$x1 = y1 + 3\
          x2 = y2 + 4
          $$



          The new equation becomes: $$ y1 + 3 + y2 + 4 + x3 = 11 <=> y1 + y2 + x3 = 4 $$
          Now all the possible values are:
          $$ binom{4 + 3 - 1}{3 - 1}$$
          From this ones you need to substract all the values that have either x1 > 6 or x2 > 7. (They can't be both greater since the sum would be over the boundaries). So you can replace x1 with y1 + 6 and x2 with y2 + 7 and apply the same principle. After that you can substract these results from the total.






          share|cite|improve this answer














          This can be solved using Bose-Einstein, which is also known as Bars and Stars https://en.wikipedia.org/wiki/Stars_and_bars_(combinatorics).



          In your case, you have 11 dots, and basically you want to put this 11 dots into 3 boxes. You only care how many dots are going in each box. For this you can use:
          $$binom{n + k - 1}{k-1}$$ and in your case: $$binom{11 + 3 - 1}{2}$$ This is including the solutions where you have 0 as possible value for some variables, so you might want to exclude those.



          First let's get all the possible solutions that match the lower bound.
          Smallest value for x1 is 3 and for x2 is 4. We can mark x1 and x2 as:
          $$x1 = y1 + 3\
          x2 = y2 + 4
          $$



          The new equation becomes: $$ y1 + 3 + y2 + 4 + x3 = 11 <=> y1 + y2 + x3 = 4 $$
          Now all the possible values are:
          $$ binom{4 + 3 - 1}{3 - 1}$$
          From this ones you need to substract all the values that have either x1 > 6 or x2 > 7. (They can't be both greater since the sum would be over the boundaries). So you can replace x1 with y1 + 6 and x2 with y2 + 7 and apply the same principle. After that you can substract these results from the total.







          share|cite|improve this answer














          share|cite|improve this answer



          share|cite|improve this answer








          edited Nov 19 at 19:29

























          answered Nov 19 at 15:04









          Erik Cristian Seulean

          456




          456












          • I have edited the question.
            – Sameer Thakur
            Nov 19 at 15:32


















          • I have edited the question.
            – Sameer Thakur
            Nov 19 at 15:32
















          I have edited the question.
          – Sameer Thakur
          Nov 19 at 15:32




          I have edited the question.
          – Sameer Thakur
          Nov 19 at 15:32


















          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%2f3005023%2fcalculating-no-of-solutions-within-some-bounds%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

          How to change which sound is reproduced for terminal bell?

          Title Spacing in Bjornstrup Chapter, Removing Chapter Number From Contents

          Can I use Tabulator js library in my java Spring + Thymeleaf project?