Question

In: Advanced Math

This is a Combinatorics Problem Consider the problem of finding the number of ways to distribute...

This is a Combinatorics Problem

Consider the problem of finding the number of ways to distribute 7 identical pieces of candy to 3 children so that no
child gets more than 4 pieces. Except Stanley (one of the 3 children) has had too much candy already, so he’s only
allowed up to 2 pieces. Write a generating function & use your generating function to solve this problem.

Solutions

Expert Solution

Suppose there are 3 childrens namely Stanley, A and B.

Here we can give almost 2 candy to Stanley.

Suppose we have given 0 candy to Stanley then we have to distribute 7 candies into A and B so if we give 3 candies to A then we have to give to 4 candies to B vice versa. (2 ways)

Now if we give 1 candy to Stanley then we have to distribute 6 candies in A and B so suppose if we give 4 candies to A to A the we have to give 2 candies to B or vice versa. Or if we give 3 candies to A then we can give 3 candies to B also. So total ( 3 ways) in this case.

Now lastly if we give 2 candies to Stanley then we have remaining 5 candies to distribute in A and B. If we give 4 candies to A then we can give 1 candy to B and vice versa. Similarly if we give 3 candies to A then we can give 2 candies to B and vice versa. So total(4 ways)

So total number of ways are 2+3+4=7 ways we can distribute candies among these 3 children.


Related Solutions

This is a combinatorics problem Suppose we wish to find the number of integer solutions to...
This is a combinatorics problem Suppose we wish to find the number of integer solutions to the equation below, where 3 ≤ x1 ≤ 9, 0 ≤ x2 ≤ 8, and 7 ≤ x3 ≤ 17. x1 + x2 + x3 = r Write a generating function for this problem, and use it to solve this problem for r = 20.
What is the number of ways to distribute 12 identical balls in 8 different urns, so...
What is the number of ways to distribute 12 identical balls in 8 different urns, so that two of the urns will contain together at least 10 balls?
find the number of ways to distribute 18 balls, three each of six different colors, into...
find the number of ways to distribute 18 balls, three each of six different colors, into three boxes
*Combinatorics* Prove bell number B(n)<n!
*Combinatorics* Prove bell number B(n)<n!
This is a Combinatorics question. Find a generating function for a sub r, the number of...
This is a Combinatorics question. Find a generating function for a sub r, the number of ways: (1) To distribute ridentical objects into seven distinct boxes with an odd numbet of objects not exceeding nine in the first three boxes and between four and ten in the other boxes.
Consider the problem of finding if an array contains a pair of integers with a sum...
Consider the problem of finding if an array contains a pair of integers with a sum of 100. The array contains n integers. a. Define the signature (header) of a C++ function that solves this problem (hint: inputs/outputs of function) b. Write the pseudocode or C++ body of the function (extra credit: write the most efficient algorithm) c. What is the asymptotic complexity of your algorithm? d. What would be the complexity of the best algorithm for this problem if...
The n th Triangle Problem Write a code for finding the n th triangle number of...
The n th Triangle Problem Write a code for finding the n th triangle number of triangle sequences: 1, 3, 6, 10, ..., n. That is, your code should accept an integer number, which indicates the triangle levels, and returns how many dots we need to form a triangle with respect to the given level. For example, consider the Fig 1. For n = 3 (can be also written as T3), your code should returns 6. Provide a single program...
How many ways are there to distribute 15 cookies between 5 children such that: a. zero...
How many ways are there to distribute 15 cookies between 5 children such that: a. zero or more cookies? b. at least 1 cookie?
(b) Describe five ways in which a liquidator could distribute the assets of a company in...
(b) Describe five ways in which a liquidator could distribute the assets of a company in a compulsory winding up.
Consider Cardano's problem of finding two numbers whose sum is 10 and whose product is 40....
Consider Cardano's problem of finding two numbers whose sum is 10 and whose product is 40. a) Cardano knew beforehand that no such (real) numbers existed. How did he know? Can you prove it? b) Solve the system of equations x+y=10 and xy=40 to find Cardano's complex solution. c) Check that this solution does work-that is, thatb the sum of your complex numbers is 10 and that their product is 40.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT