jane st
prompt
Two random points, one red and one blue, are chosen uniformly and independently from the interior of a square. To ten decimal places1, what is the probability that there exists a point on the side of the square closest to the blue point that is equidistant to both the blue point and the red point?
(Or, if you want to send in the exact answer, that’s fine too!) ↩
think about the shape of satisfying points
for a point chosen a what is the space B of points that satisfy?
Via symmetry we will only evaluate B for values of a bounded by x=0, y = x, and y = 1 - x and then will multiply by 4 at the end.
B is the region where the perpindicular bisector of a and b crosses the side closest to a.
this leads to B that is the XOR of the quarter circles defined by the radius of a to <0,0> and a to <0,1>.
map out the space to get an intuition
reset # Set the range for x and y axes set xrange [0:1] set yrange [0:1] set xlabel "x" set ylabel "y" set size ratio -1 set margin 0 dynamic_title = "Range B for x_a = " . x_a . " and y_a = " . y_a set title dynamic_title set key off x_a = x_a y_a = y_a r_0 = x_a**2 + y_a**2 r_1 = x_a**2 + (1 - y_a)**2 f1(x) = (x <= x_a) ? sqrt(r_0 - x**2) : 1/0 f2(x) = (x <= x_a) ? 1 - sqrt(r_1 - x**2) : 1/0 f3(x) = (x > x_a) ? 1 - sqrt(r_1 - x**2) : 1/0 f4(x) = (x > x_a) ? sqrt(r_0 - x**2) : 1/0 set style fill solid 0.2 noborder set arrow from 0,0 to x_a,y_a nohead lw 2 lc rgb "red" set arrow from 0,0 to sqrt(r_0),0 nohead lw 2 lc rgb "red" set arrow from 0,0 to 0,sqrt(r_0) nohead lw 2 lc rgb "red" set label "r_0" at x_a, y_a offset -0.1,-0.7 tc rgb "red" font ",12" set arrow from 0,1 to x_a,y_a nohead lw 2 lc rgb "blue" set arrow from 0,1 to sqrt(r_1),1 nohead lw 2 lc rgb "blue" set arrow from 0,1 to 0,1-sqrt(r_1) nohead lw 2 lc rgb "blue" set label "r_1" at x_a, y_a offset -0.1,0.7 tc rgb "blue" font ",12" plot \ f1(x) with filledcurves y1=1 lc rgb "#add8e6" notitle, \ f2(x) with filledcurves y1=0 lc rgb "#add8e6" notitle, \ f3(x) with filledcurves y1=1 lc rgb "#add8e6" notitle, \ f4(x) with filledcurves y1=0 lc rgb "#add8e6" notitle
break up the piecewise shape
reset set xrange [0:1] set yrange [0:1] set xlabel "x" set ylabel "y" set size ratio -1 set margin 0 set key off dynamic_title = "Range B for x_a = " . x_a . " and y_a = " . y_a set title dynamic_title x_a = x_a y_a = y_a r_0 = x_a**2 + y_a**2 r_1 = x_a**2 + (1 - y_a)**2 f1(x) = (x <= x_a) ? sqrt(r_0 - x**2) : 1/0 f2(x) = (x <= x_a) ? 1 - sqrt(r_1 - x**2) : 1/0 f3(x) = (x > x_a) ? 1 - sqrt(r_1 - x**2) : 1/0 f4(x) = (x > x_a) ? sqrt(r_0 - x**2) : 1/0 set label "a" at x_a/2, 0.82 rgb "black" font ",12" set label "b" at 0.6, 0.82 tc rgb "black" font ",12" set label "c" at x_a/2, 0.18 tc rgb "black" font ",12" set label "d" at 0.6, 0.18 tc rgb "black" font ",12" set style fill solid 0.2 noborder set label "(u,v)" at x_a, y_a offset 1,0 tc rgb "white" font ",12" plot \ f1(x) with filledcurves y1=1 lc rgb "#add8e6" notitle, \ f2(x) with filledcurves y1=0 lc rgb "#add8e6" notitle, \ f3(x) with filledcurves y1=1 lc rgb "#add8e6" notitle, \ f4(x) with filledcurves y1=0 lc rgb "#add8e6" notitle
Since the prompt calls for 10 decimal places we will assume a closed form solution exists.
Integration by polar or cartesian coordinates yields a closed form solution for almost none of the consituent shapes.
I spent a lot of time trying to use Aabcd = AC0/4 + AC1/4 - 2A(half lens between a and c) which never went anywhere.
via symmetry
reset
set xrange [0:1]
set yrange [0:1]
set xlabel "x"
set ylabel "y"
set size ratio -1
set margin 0
set key off
dynamic_title = "A_{ad} for x_a = " . x_a . " and y_a = " . y_a
set title dynamic_title
x_a = x_a
y_a = y_a
r_0 = x_a**2 + y_a**2
r_1 = x_a**2 + (1 - y_a)**2
f1(x) = (x <= x_a) ? sqrt(r_0 - x**2) : 1/0
f2(x) = (x <= x_a) ? 1 - sqrt(r_1 - x**2) : 1/0
f3(x) = (x > x_a) ? 1 - sqrt(r_1 - x**2) : 1/0
f4(x) = (x > x_a) ? sqrt(r_0 - x**2) : 1/0
set label "a" at x_a/2, 0.82 rgb "black" font ",12"
set label "d" at 0.6, 0.18 tc rgb "black" font ",12"
set style fill solid 0.2 noborder
set label "(u,v)" at x_a, y_a offset 1,0 tc rgb "white" font ",12"
plot \
f1(x) with filledcurves y1=1 lc rgb "#add8e6" notitle, \
f4(x) with filledcurves y1=0 lc rgb "#add8e6" notitle
defining some more sub shapes
a
d
use our sub-shapes
I will argue that Aa = Aa0 - Aa1 - Aa2.
I will argue that Ad = Ad0 - Aa2.
and AC0/4 = Aa1 + Ad0
where C0 is the circle defined by r0