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 yesterday









      Tianlalu

      2,574632




      2,574632










      asked yesterday









      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
            yesterday


















          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










          New contributor




          Erik Cristian Seulean is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
          Check out our Code of Conduct.


















          • I have edited the question.
            – Sameer Thakur
            yesterday











          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
            yesterday















          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
            yesterday













          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 yesterday









          Sameer Thakur

          142




          142












          • Can someone guide me as to whether this is a correct approach?
            – Sameer Thakur
            yesterday


















          • Can someone guide me as to whether this is a correct approach?
            – Sameer Thakur
            yesterday
















          Can someone guide me as to whether this is a correct approach?
          – Sameer Thakur
          yesterday




          Can someone guide me as to whether this is a correct approach?
          – Sameer Thakur
          yesterday










          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










          New contributor




          Erik Cristian Seulean is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
          Check out our Code of Conduct.


















          • I have edited the question.
            – Sameer Thakur
            yesterday















          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










          New contributor




          Erik Cristian Seulean is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
          Check out our Code of Conduct.


















          • I have edited the question.
            – Sameer Thakur
            yesterday













          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










          New contributor




          Erik Cristian Seulean is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
          Check out our Code of Conduct.









          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










          New contributor




          Erik Cristian Seulean is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
          Check out our Code of Conduct.









          share|cite|improve this answer



          share|cite|improve this answer








          edited yesterday





















          New contributor




          Erik Cristian Seulean is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
          Check out our Code of Conduct.









          answered yesterday









          Erik Cristian Seulean

          385




          385




          New contributor




          Erik Cristian Seulean is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
          Check out our Code of Conduct.





          New contributor





          Erik Cristian Seulean is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
          Check out our Code of Conduct.






          Erik Cristian Seulean is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
          Check out our Code of Conduct.












          • I have edited the question.
            – Sameer Thakur
            yesterday


















          • I have edited the question.
            – Sameer Thakur
            yesterday
















          I have edited the question.
          – Sameer Thakur
          yesterday




          I have edited the question.
          – Sameer Thakur
          yesterday


















           

          draft saved


          draft discarded



















































           


          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

          android studio warns about leanback feature tag usage required on manifest while using Unity exported app?

          SQL update select statement

          'app-layout' is not a known element: how to share Component with different Modules