Welcome Guest [Log In] [Register]
Welcome to The New Coffee Room. We hope you enjoy your visit.


You're currently viewing our forum as a guest. This means you are limited to certain areas of the board and there are some features you can't use. If you join our community, you'll be able to access member-only sections, and use many member-only features such as customizing your profile, sending personal messages, and voting in polls. Registration is simple, fast, and completely free.


Join our community!


If you're already a member please log in to your account to access all of our features:

Username:   Password:
Add Reply
another puzzle; responding to my critics
Topic Started: Jul 14 2016, 06:09 AM (272 Views)
jon-nyc
Member Avatar
Cheers
Ok, this one is new, I'm making it up on the fly.

Consider a dart board of radius R. You throw two darts at it. Each throw hits the board at a random spot. Both throws are independent. All points on board have equal probability of being hit.

What is the probability that the two darts will hit within R/4 of each other?

Assume perfect circle board, infinitesimal dart tip, etc.


(If you brute force a solution with code, somewhere a kitten cries after failing his SAT test)



In my defense, I was left unsupervised.
Online Profile Quote Post Goto Top
 
Klaus
Member Avatar
HOLY CARP!!!
Interesting. I predict that the solution contains some weird integral.

But could you clarify what you mean by "All points on board have equal probability of being hit"? The probability of hitting a concrete point is 0.
I guess what you mean here is this:

If A is a subset of the unit circle, then the probability of hitting a point in A is P(A) = |A| / 3.1416, where |A| is the size/area of A.

(in maths geek speech, one would also need to assume that A is a member of the Borel σ-algebra of the unit circle).
Trifonov Fleisher Klaus Sokolov Zimmerman
Online Profile Quote Post Goto Top
 
Klaus
Member Avatar
HOLY CARP!!!
Spoiler: click to toggle
Trifonov Fleisher Klaus Sokolov Zimmerman
Online Profile Quote Post Goto Top
 
jon-nyc
Member Avatar
Cheers
Yes on the probability clarification.

And show your work!
In my defense, I was left unsupervised.
Online Profile Quote Post Goto Top
 
Klaus
Member Avatar
HOLY CARP!!!
Spoiler: click to toggle
Trifonov Fleisher Klaus Sokolov Zimmerman
Online Profile Quote Post Goto Top
 
jon-nyc
Member Avatar
Cheers
Spoiler: click to toggle
In my defense, I was left unsupervised.
Online Profile Quote Post Goto Top
 
George K
Member Avatar
Finally
I love it when you guys talk dirty.
A guide to GKSR: Click

"Now look here, you Baltic gas passer... "
- Mik, 6/14/08


Nothing is as effective as homeopathy.

I'd rather listen to an hour of Abba than an hour of The Beatles.
- Klaus, 4/29/18
Online Profile Quote Post Goto Top
 
Klaus
Member Avatar
HOLY CARP!!!
Spoiler: click to toggle
Trifonov Fleisher Klaus Sokolov Zimmerman
Online Profile Quote Post Goto Top
 
jon-nyc
Member Avatar
Cheers
Does this help?

Spoiler: click to toggle
In my defense, I was left unsupervised.
Online Profile Quote Post Goto Top
 
Klaus
Member Avatar
HOLY CARP!!!
jon-nyc
Jul 14 2016, 02:30 PM
Does this help?

Spoiler: click to toggle
How does the step from (4) to (5) work? Looks like magic to me.
Trifonov Fleisher Klaus Sokolov Zimmerman
Online Profile Quote Post Goto Top
 
jon-nyc
Member Avatar
Cheers
It does seem pretty slick. Like James Bond came in and solved your calculus problem for you.
In my defense, I was left unsupervised.
Online Profile Quote Post Goto Top
 
Klaus
Member Avatar
HOLY CARP!!!
Show us the solution then, Jon!
Trifonov Fleisher Klaus Sokolov Zimmerman
Online Profile Quote Post Goto Top
 
Klaus
Member Avatar
HOLY CARP!!!
By the way, Jon, maybe you'll find it interesting that there are dedicated programming languages to solve these kinds of problems, "probabilistic programming languages".

Just for fun, here's a model of your problem in Church. I've asked it to display a histogram of the distances in addition to computing the percentage of throws with distance smaller than R/4.

Posted Image

If you ignore the funny LISP-style prefix syntax, you can see that it's rather straightforward. I just draw Cartesian coordinates uniformly, ask for their distance (line starting with "sqrt") but then condition the model to only consider coordinates in the unit circle (line starting with "and").

If you'd like to play around with this, you can try it in your browser here.

This particular example doesn't show-case the real strength of these kinds of languages, namely if you have a very high-dimensional problem space (many random variables) and a very low acceptance rate (i.e. the conditioning rejects, say, 99.999999% of all runs - in your example only 100/pi percent are rejected). Then you need sophisticated sampling algorithms. In this case I used a so-called "Metropolis-Hastings" algorithm - that's what "mh-query" means.
Trifonov Fleisher Klaus Sokolov Zimmerman
Online Profile Quote Post Goto Top
 
jon-nyc
Member Avatar
Cheers
I haven't solved it yet! I made it up on the fly, remember.
In my defense, I was left unsupervised.
Online Profile Quote Post Goto Top
 
Klaus
Member Avatar
HOLY CARP!!!
Ah, so the real challenge is that there may not even be an analytic solution, or that an analytic solution requires to solve some Fields-medalesque problem! :lol2:
Trifonov Fleisher Klaus Sokolov Zimmerman
Online Profile Quote Post Goto Top
 
jon-nyc
Member Avatar
Cheers
Did you see the probability function at the bottom of my link? You just integrate that from s= 0->0.25 and you'll get the answer. But I haven't yet figured out how they derived that function.
In my defense, I was left unsupervised.
Online Profile Quote Post Goto Top
 
Klaus
Member Avatar
HOLY CARP!!!
(by the way, I get the same result for "disk line picking" than in your link, see updated screenshot)
Trifonov Fleisher Klaus Sokolov Zimmerman
Online Profile Quote Post Goto Top
 
jon-nyc
Member Avatar
Cheers
Nice.
In my defense, I was left unsupervised.
Online Profile Quote Post Goto Top
 
Klaus
Member Avatar
HOLY CARP!!!
jon-nyc
Jul 15 2016, 02:05 AM
Did you see the probability function at the bottom of my link? You just integrate that from s= 0->0.25 and you'll get the answer. But I haven't yet figured out how they derived that function.
In addition to integration, you'd also need to divide the result by some constant, I guess.

The book where they derive that formula is just $69. I think you owe it to the community here to buy that book and show us how to derive the formula ;)
Trifonov Fleisher Klaus Sokolov Zimmerman
Online Profile Quote Post Goto Top
 
jon-nyc
Member Avatar
Cheers
I don't think a constant is needed.
In my defense, I was left unsupervised.
Online Profile Quote Post Goto Top
 
Klaus
Member Avatar
HOLY CARP!!!
The integral on that web page does seem to have an analytic solution.

Posted Image

And the result agrees with my numerical solution: 0.055.

Heureka!?
Trifonov Fleisher Klaus Sokolov Zimmerman
Online Profile Quote Post Goto Top
 
jon-nyc
Member Avatar
Cheers
Let's call this puppy solved!

You can see his derivation on pp 128-129 of his book on Google books.
In my defense, I was left unsupervised.
Online Profile Quote Post Goto Top
 
« Previous Topic · The New Coffee Room · Next Topic »
Add Reply