# Combinations

• May 30th 2009, 06:40 PM
kurac
Combinations
Im doing more work on this. I have no answers so id like to see if someone can go over my mine.

1) How many binary strings length 7 begin with 2 0's or end with 3 1's.
2^5 + 2^4.

2)
x1 x2 x3 are not negative numbers.
we have: x1 + x2 + x3 = 11

How many solutions would there be for the equation?
ok so im thinking this:

11! * 3.

3) let x1 <equal to 3, x2 <equal to 4 and x3 <equal to 6.

Im thinking if my idea of answering question 2 is correct, then the same would be for this one.

3! + 4! + 6!

Any confirmation from math helpers appreciated.
• May 30th 2009, 06:49 PM
wytiaz
Quote:

Originally Posted by kurac
Im doing more work on this. I have no answers so id like to see if someone can go over my mine.

1) How many binary strings length 7 begin with 2 0's or end with 3 1's.
2^5 + 2^4.

Since the string can begin with 00 and also end with 111, this is an example of an inclusive problem. So you'll need to add the two amounts together but then subtract their intersection.

2^5 + 2^4 - 2^2
(the 2^2 are the number of strings that look like this: 00**111)

Quote:

2)
x1 x2 x3 are not negative numbers.
we have: x1 + x2 + x3 = 11

How many solutions would there be for the equation?
ok so im thinking each x can have numbers 0 -11.

so 11 * 11 * 11 different solutions.
Infinitely many if the numbers are not restricted to being integers.
• May 30th 2009, 07:00 PM
kurac
Oh I forgot 2 minus the 2^2 thanks for the reminder.

I edited my above post again. I dont think it was correct.
And im puzzled by yours below regarding Q2. How can it be infinitely many? you mean we can have .9999999999 etc and so on.

If we assume the numbers are restricted to being integers, is my theory correct?
• May 30th 2009, 07:04 PM
wytiaz
a + b + c = 11

Case 0:
Let a = 0.
b + c = 11. There are 12 integer values for b, c will be chosen by 11 - b.

so case 0 has 12 solutions.

Case 1:
Let a = 1.
b + c = 10. There are 11 integer values for b, c will be chosen by 10 - b.

so case 1 has 11 solutions.

I leave it to you to decide how many more cases there are and what to do with them in the end.
• May 30th 2009, 07:31 PM
Soroban
Hello, kurac!

Quote:

1) How many binary strings length 7 begin with two 0's or end with three 1's?

Begin with two 0's: . $0\;0\;\_\;\_\;\_\;\_\;\_$
. . There are: . $2^5$ strings.

End with three 1's: . $\_\;\_\;\_\;\_\;1\;1\;1$
. . There are: . $2^4$ strings.

But there are strings that begin with two 0's and end with three 1's: . $0\;0\;\_\;\_\;1\;1\;1$
. . And we have counted them twice.
There are: . $2^2$ such strings.

Answer: . $2^5 + 2^4 - 2^2 \:=\:32 + 16 - 4 \;=\;44$

Quote:

2) We have: . $x_1 + x_2 + x_3 \:=\: 11\;\text{ for }x_1,x_2,x_3 \geq 0$ (integers!)

How many solutions would there be for the equation?

Consider a board comprised of eleven unit blocks:. . $\square\square\square\square\square\square \square\square\square \square\square$

We will place two "dividers" before, after, or between these blocks.

So that: . $\square\square\square\bigg|\square \square\bigg|\square\square\square\square\square\s quare$ .represents: . $3 + 2 + 6$

. . and: . $\square\square\square\square\square\square \square\square\bigg| \square\square\square\bigg|$ .represents: . $8+3+0$

. . and: . $\bigg|\square\square\square\square\square\square\s quare \bigg| \square\square\square\square$ .represents: . $0 + 7 + 4$

. . and: . $\square\square\square\square\square\square\bigg|\b igg|
\square\square\square\square\square$
.represents: . $6 + 0 + 5$

. . and:. . $\square\square\square\square\square\square \square\square\square \square\square\bigg|\bigg|$ .represents: . $11 + 0 + 0$

For each of the two dividers, there are 12 choices of position.
. . Hence, there are: . $12^2 \:=\:144$ ways to place the dividers.

Therefore, there are $144$ solutions to the equation.

• May 30th 2009, 08:01 PM
Random Variable
I would use generating functions for (2) and (3).

For (3) expand $(1+x+x^{2}+x^{3})(1+x+x^{2}+x^{3}+x^{4})(1+x+x^{2} +x^{3}+x^{4}+x^{5}+x^{6})$ and your answer is the coefficent of $x^{11}$

EDIT: Oh wait! That's only true if all integers are nonnegative.
• May 30th 2009, 09:14 PM
kurac
Thanks thats a great way to visualise the question.
If we use the same idea to answer question 3 then it may be something like this:
(4 + 5 + 7)^2 = 256.