# Thread: Envelopes and Paychecks Problems

1. ## Envelopes and Paychecks Problems

This is the first problem which I solved:
You have 3 envelopes and 3 paychecks addressed to 3 different people. The paychecks are randomly inserted into the envelopes. What is the probability that at least one paycheck is inserted in the correct envelope.
The answer is: 4/3!= 2/3

Then I tried to make a general rule for the problem without success. Can anybody help me?
New problem will be: You have n envelopes and n paychecks addressed to n different people...

2. you can do this with a tree diagram, where each branch has 2 possible outcome (correct, not correct).
I wouldn't try and draw the whole thing, but its good to ahve in the back of your head.

Step 1:
Find the probability that no paycheck is in the correct envelope:

P(0) = $\frac{n-1}{n} \times \frac{n-2}{n-3} \times .... \frac{1}{2}$

$= \frac{(n-1)(n-2)....2}{n (n-1) (n-2)....2 \times 1}$

$=\frac{1}{n}$

Step 2:
P(at least 1) = 1-P(0)
$=\frac{n-1}{n}$

Check for n=3:
$\frac{3-1}{3} = \frac{2}{3}$, which you said was correct

3. Originally Posted by SpringFan25
you can do this with a tree diagram, where each branch has 2 possible outcome (correct, not correct).
I wouldn't try and draw the whole thing, but its good to ahve in the back of your head.
Step 1:
Find the probability that no paycheck is in the correct envelope:
P(0) = $\frac{n-1}{n} \times \frac{n-2}{n-3} \times .... \frac{1}{2}$
$= \frac{(n-1)(n-2)....2}{n (n-1) (n-2)....2 \times 1}$
$=\frac{1}{n}$
Step 2:
P(at least 1) = 1-P(0)
$=\frac{n-1}{n}$
Check for n=3:
$\frac{3-1}{3} = \frac{2}{3}$, which you said was correct
SpringFan25, that method does not work.
Try it for $n=4$.
In that case the correct answer is $1-\frac{9}{4!}$.

4. Originally Posted by Plato
SpringFan25, that method does not work.
Try it for $n=4$.
In that case the correct answer is $1-\frac{9}{4!}$.
that gives 0.625.

Assuming his computation of n=3 was correct (0.66666666) you are saying that the answer for n=4 is lower than for n=3? that doesn't sound right

5. Yes I am telling you that.
If we have $n$ things to arrange at random, the probability that at least one will end in the correct place is $1-\frac{D(n)}{n!}$.
$D(n)$ is the number of derangements of $n$ items.

6. I know what Plato mentioned about. However, what I want to know is what is the rule for this type of problem. "Derangement" is too general.

Above all, thank you Plato and SpringFan25 for your attemps.

7. Originally Posted by hungthinh92
I know what Plato mentioned about. However, what I want to know is what is the general formula for this type of problem. "Derangement" is too general".
You may think that, but that is the way these problem are done.
You should read the webpage I posted.
A derangement is a permutation in which every element is active( no tern remains fixed).
The number of derangements on $n$ items is $D_n = n! \cdot \sum\limits_{k = 0}^n {\frac{{\left( { - 1} \right)^k }}{{k!}}} \approx \frac{{n!}}{e}$.
The probability that at least one term of a permutation remained fixed is $1 - \frac{{D_n }}{{n!}} \approx \frac{{e - 1}}{e} = {0.63212}$.

8. Sorry but I don't trust wikipedia, so I didn't want to read those stuffs. Then I checked and had the answers.

Thanks Plato again!

9. Originally Posted by hungthinh92
Sorry but I don't trust wikipedia
Well that was correct four years ago. Then there were many mathematical errors there.
But today it is almost always mathematically correct.
Now there will always be disagreements about notation and definition.