Four pins are randomly nailed to a square board (according to a uniform probability distribution), and a rubber band is stretched completely around them to form a convex shape. What is the probability that the rubber band is in the shape of a triangle?
The problem is equivalent to finding the probability that the four pins will mark the vertices of a concave quadrilateral rather than a convex one. It's also equivalent to the probability that one of the pins will be within a triangle formed by the other three.
Considered as a concave quadrilateral, there can be only one vertex that's concave. That means that when the problem is considered as a single point within a triangle formed by the other three points, the cases of the first point placed, second point placed, etc. are mutually exclusive and of equal probability. So the probability is four times that of the fourth point's being within a triangle formed by the first three.
The probability of that event is equal to the expected value of the area of the triangle formed by the first three points divided by the area of the square board. So you'd just have to multiply that by four to get the total probability.
The area of the triangle might be found by Heron's formula, or the traditional b*h/2, whichever might produce easier integration, once we get probability distributions for the items that go into these formulae. Unfortunately they are not independent. If the first two points are taken as the base of the triangle, the probability distribution of the altitude (the distance of the third point from the line joining the first two) depends on where those first two are. Likewise, for Heron's formula, the distribution of the third point's distance from the first two depends on where they are.
The following simulation program uses Heron's formula and finds that four times the relative area of the triangle has an average value between .305 and .306, so the answer is somewhere in that range.
DEFDBL AZ
RANDOMIZE TIMER
FOR i = 1 TO 1000000
tr = tr + 1
x1 = RND(1): y1 = RND(1)
x2 = RND(1): y2 = RND(1)
x3 = RND(1): y3 = RND(1)
a = SQR((x1  x2) * (x1  x2) + (y1  y2) * (y1  y2))
b = SQR((x2  x3) * (x2  x3) + (y2  y3) * (y2  y3))
c = SQR((x3  x1) * (x3  x1) + (y3  y1) * (y3  y1))
s = (a + b + c) / 2
area = SQR(s * (s  a) * (s  b) * (s  c))
totArea = totArea + area
PRINT i, 4 * totArea / tr
NEXT

Posted by Charlie
on 20050210 18:07:01 