1. ## A question about n choose k

Hi there,

I have a question about combinatorics.

I came to understand that "n choose k" means that I have a pool of n objects, and I want to know in how many ways I could combine them. (Assuming the order doesnt matter, yellow and green is green and yellow).

So if the pool is Pool = {red, green, blue}, then all possible combinations of 2 of these objects would be 3. So far so good.

But then I read about Bernoulli trials, where if I have a coin of Head probability of p, and Tail probability of 1-p, then the probability to get exactly k times Heads out of n tosses, is (n choose k)*(p^k)(1-p)^(n-k).

So the expression (p^k)(1-p)^(n-k) is understood, it is the probability that a single valid "branch" on the tree of possible outcomes will be chosen, and the coefficient (n choose k) is supposed to give the amount of those valid branches.

I dont understand why n choose k is the way to arrive at this amount!
What is my "pool" here? It would seem that the order of the tosses is very important, we must consider the branch "Head Head Tail" and also the branch "Tail Head Head", etc, to add them up and get the correct probability.

I realize I'm mixing something up here, but I cant tell what it is.

2. ## Re: A question about n choose k

After each coin flip, I record a H for heads and T for tails. Flipping the coin n times, I will get a sequence of letters like this: HHTHTTTH... with n letters in it. The probability that I get k heads in a row followed by n-k tails in a row is $\displaystyle p^k(1-p)^{n-k}$. What if I get k-1 heads, then a tails then a heads, then the rest are all tails is the same probability. In fact, any sequence of k H's and (n-k) T's corresponds to a sequence that results in exactly k heads flipped. It is not possible the have two different orders occur simultaneously, so they are disjoint cases. We just count the number of ways to order the k H's and (n-k) T's. Then, we multiply by the probability of getting k heads and (n-k) tails in a specific order. So, we have n positions and we choose k of them to be heads. Now we don't have any choices left. The remaining n-k positions must be tails.

3. ## Re: A question about n choose k

Originally Posted by sapsapz
Hi there,
I have a question about combinatorics.
I came to understand that "n choose k" means that I have a pool of n objects, and I want to know in how many ways I could combine them. (Assuming the order doesnt matter, yellow and green is green and yellow).
So if the pool is Pool = {red, green, blue}, then all possible combinations of 2 of these objects would be 3. So far so good.
But then I read about Bernoulli trials, where if I have a coin of Head probability of p, and Tail probability of 1-p, then the probability to get exactly k times Heads out of n tosses, is (n choose k)*(p^k)(1-p)^(n-k).
So the expression (p^k)(1-p)^(n-k) is understood, it is the probability that a single valid "branch" on the tree of possible outcomes will be chosen, and the coefficient (n choose k) is supposed to give the amount of those valid branches.
I dont understand why n choose k is the way to arrive at this amount!
What is my "pool" here? It would seem that the order of the tosses is very important, we must consider the branch "Head Head Tail" and also the branch "Tail Head Head", etc, to add them up and get the correct probability.
I realize I'm mixing something up here, but I cant tell what it is.
Let's use a die and say $\displaystyle 66XYZW$ represents two sixs and four other numbers.

The probability of that particular string is $\displaystyle {\left( {\frac{1}{6}} \right)^2}{\left( {\frac{5}{6}} \right)^4}$,
But how many strings of six in which exactly two sixes appear? Is it $\displaystyle \binom{6}{2}~?$ Six places choosing two.

4. ## Re: A question about n choose k

I understand that, I just dont understand why is n choose k the way to count the amount of valid ways to order the H's and T's.
I came to understand that n choose k is being used when the order doesnt matter, where here, it clearly does. Also, what is my pool of size n? It seems like n here plays not the role of number of possible outcomes for each tests, but the number of tests. And k is being used not to specify the number of tests I wish to assign a value from the pool to, but the number of correct tests.

5. ## Re: A question about n choose k

Solved, thanks!