I've never been the best with combinatorics, but I could always at least get by. I thought of a problem that has really sparked an interest with me, though.
(I will start with a specific example, then move on to generalize)
Say you are doing laundry and get to the part where you are matching socks. Assume that you have 4 pairs of white socks, 3 pairs of black socks, 2 pairs of red socks, and 1 pair of yellow socks. You proceed to match socks in the following way:
You start with all of the socks in a basket (and every sock has a matching pair!). You randomly pull the first sock out and lay it in front of you. One at a time, you randomly pull each sock from the basket and do one of two things. If there is no sock laying in front of you that matches that sock, you also lay it in front of you. However, if there is a sock laying in front of you that matches it, you put those two together and put them away into your drawer. (Here, we assume that any two white socks will match each other, any two black sock will match each other, etc.)
What is the expected value of the largest number of socks you will have in front of you throughout this entire process?
To generalize, say we have pairs of socks of the first color, pairs of socks of the second color, up to pairs of socks of the th color, and you match your socks by the same method described above. What is the expected value of the largest number of socks you will have laying in front of you for this process? Is there a general method to determine this expected value?
I have attempted this question myself, but find my mediocrity within the subject of Combinatorics to prove to strong for me to work with more than 3 different colors of socks. Any help?
Easy Math Editor
This discussion board is a place to discuss our Daily Challenges and the math and science related to those challenges. Explanations are more than just a solution — they should explain the steps and thinking strategies that you used to obtain the solution. Comments should further the discussion of math and science.
When posting on Brilliant:
*italics*
or_italics_
**bold**
or__bold__
paragraph 1
paragraph 2
[example link](https://brilliant.org)
> This is a quote
\(
...\)
or\[
...\]
to ensure proper formatting.2 \times 3
2^{34}
a_{i-1}
\frac{2}{3}
\sqrt{2}
\sum_{i=1}^3
\sin \theta
\boxed{123}
Comments
Thanks for sharing! I've found that some of my favorite combinatorics and expected value problems come from pondering situations like this...
I haven't worked it out, but here's a framework that I suspect will help:
You could use this framework to construct a probability function for Xk. In other words, for all k, what is the probability that Xk=0,1,2,…,n? (It can't exceed n since you can't have more than 1 unpaired sock per color.)
However, you are looking for the expected value of the maximum Xk. This gets a bit trickier because the Xk aren't independent, so having their individual distributions won't get you directly to the EV of the maximum Xk.
That being said... I think this general framework is still probably useful. After k socks, there is some subset of colors C which are unpaired, so Xk=∣C∣. Then, after k+1 socks, Xk+1=Xk−1 if the color of the k+1 sock was in C and Xk+1=Xk+1 otherwise. Maybe stringing together the Xk in this way will give better insights into the distribution of the maximum value.
Anyone have ideas for next steps or an alternate approach? :)
Log in to reply
Another approach (that I started, but didn't get to work too much with) would be writing a recursion for each case. Like, writing the number of situations of sock size n with largest size k as a function of situations of smaller socks and other largest sizes. Again, I need to find time to actually work out with that kind of calculation.
I think, the largest value would be n, in case the first n socks chosen are all different by color.Indeed, it's a very rare case, but the number of socks laying in front of you can't be more than n, because the (n+1)'st sock's color would mach one from the others(Dirchlet's theorem)
Log in to reply
While that is true, my question is asking what the expected value for the largest number is. That is, over all possible orders of choosing socks, what is the average of each "largest number" in each case.
Log in to reply
that's indeed a more difficult question to answer