Please show us what you have tried and exactly where you are stuck.Please help with an explained solution to the following:
20 people sits in a circle. They are told to look at another person. What is the probability that two random people look at each other?
Nice idea, but I'm not quite convinced of the 18^20. Can you explain that in detail?I was thinking something like:
There is 19^20 ways they can look at each other.
18^20 are 2 people who are not looking at each other. Giving 19^20-18^20 looks at each other from a total of 19^20=0,66.
...and if the latter, then which of the following applies:Is it this:
If two people are picked at random, what is the probability they are looking at each other?
or
What is the probability that there are two people that are looking at each other?
My thoughts exactly--are exactly two people looking at one another?...and if the latter, then which of the following applies:
What is the probability that there are exactly two people (and no more) looking at each other?
or
What is the probability that at least two people (one, two, three, or more pairs) are looking at each other?
I took the OP in #3 to be taking it as "at least one pair", which is how I take it as well. "One randomly chosen pair" seems too easy....and if the latter, then which of the following applies:
What is the probability that there are exactly two people (and no more) looking at each other?
or
What is the probability that at least two people (one, two, three, or more pairs) are looking at each other?
I read it as at least one pair.I took the OP in #3 to be taking it as "at least one pair", which is how I take it as well. "One randomly chosen pair" seems too easy.
But I'll allow anyone to convince me of an answer to either of these two interpretations ...
Can you justify your formula for n=20, other than by analogy? What did you get when you took n=4? (My impression is that n=3 is a special case, and n=4 introduces new considerations as I suggested in #7.I tried with 3 people and drew all the possibilities (2 * 2 * 2 = 8), and then counted the favorable outcomes (2 * 2 + 2 * 1 + 2 * 0 = 6), and then calculated 6/8 = 75% as the expression can be reduced by dividing by 2, ie it becomes 2 + 1 + 0/2 * 2 = 3/4 = 75%, all major expressions can be reduced down. I also tried with 4 people.
Finally I came up with:
(19+18+17+16…..+0)/(19*19). Giving 190/361=52,63% ...................... added REQUIRED parentheses in the denominator.
Dr.Peterson seems to know me Here are the first few results before computation time becomes excessive. I hope this helps to find an exact answer. If not, then I could write a Monte-Carlo simulation to obtain an approximate answer for the 20 people case.I'm expecting someone here to try a simulation.
Num count/ways simplified as approx decimal
2 1/1 1 1.0000
3 6/8 3/4 0.7500
4 51/81 17/27 0.6296
5 580/1024 145/256 0.5664
6 8265/15625 1653/3125 0.5290
7 141246/279936 7847/15552 0.5046
8 2810437/5764801 401491/823543 0.4875
9 63748728/134217728 7968591/16777216 0.4750
from fractions import Fraction
numPeople=4 # Setting to 20 would take too long
ways=0
eye2eyeCount=0
p=[1]
for j in range(numPeople-1):
p.append(0)
done=0
while done==0:
e=0
for j in range(numPeople):
if j == p[ p[j] ]:
e = 1
break
if e==1: eye2eyeCount += 1
# print(p,e)
ways += 1
# increment p
for j in range(20):
p[j] += 1
if p[j] == j: p[j] += 1
if p[j] < numPeople:
break
else:
if j==numPeople-1:
done=1
break
p[j] = 0
if j==0: p[j] = 1
print(eye2eyeCount,"/",ways)
print(Fraction(eye2eyeCount, ways))
Please do soDr.Peterson seems to know me Here are the first few results before computation time becomes excessive. I hope this helps to find an exact answer. If not, then I could write a Monte-Carlo simulation to obtain an approximate answer for the 20 people case.
Code:Num count/ways simplified as approx decimal 2 1/1 1 1.0000 3 6/8 3/4 0.7500 4 51/81 17/27 0.6296 5 580/1024 145/256 0.5664 6 8265/15625 1653/3125 0.5290 7 141246/279936 7847/15552 0.5046 8 2810437/5764801 401491/823543 0.4875 9 63748728/134217728 7968591/16777216 0.4750
Python:from fractions import Fraction numPeople=4 # Setting to 20 would take too long ways=0 eye2eyeCount=0 p=[1] for j in range(numPeople-1): p.append(0) done=0 while done==0: e=0 for j in range(numPeople): if j == p[ p[j] ]: e = 1 break if e==1: eye2eyeCount += 1 # print(p,e) ways += 1 # increment p for j in range(20): p[j] += 1 if p[j] == j: p[j] += 1 if p[j] < numPeople: break else: if j==numPeople-1: done=1 break p[j] = 0 if j==0: p[j] = 1 print(eye2eyeCount,"/",ways) print(Fraction(eye2eyeCount, ways))
here's my thinking...
1000 1 3210 2 2001 1 1311 1 3002 2312
2000 1 1310 3001 2311 1 1202 3312
3000 1 2310 1201 3311 1 2202 1 1032 2
1200 3310 1 2201 1 1031 1 3202 2032 1
2200 1 1030 1 3201 2031 1302 3032 1
3200 1 2030 1301 1 3031 2302 1 1232 1
1300 3030 1 2301 2 1231 3302 2232 1
2300 1 1230 3301 1 2231 1012 1 3232 1
3300 1 2230 1011 1 3231 2012 1332 1
1010 1 3230 1 2011 1331 1 3012 2332 1
2010 1330 3011 2331 1 1212 1 3332 1
3010 1 2330 1211 1 3331 1 2212 1
1210 1 3330 1 2211 1 1002 1 3212 1
2210 1 1001 1 3211 1 2002 1 1312