exercise:942a808a15: Difference between revisions
(Created page with "<div class="d-none"><math> \newcommand{\NA}{{\rm NA}} \newcommand{\mat}[1]{{\bf#1}} \newcommand{\exref}[1]{\ref{##1}} \newcommand{\secstoprocess}{\all} \newcommand{\NA}{{\rm NA}} \newcommand{\mathds}{\mathbb}</math></div> Here is another way to pick a chord ''at random'' on the circle of unit radius. Imagine that we have a card table whose sides are of length 100. We place coordinate axes on the table in such a way that each side of the table is parallel to one o...") |
No edit summary |
||
Line 5: | Line 5: | ||
\newcommand{\secstoprocess}{\all} | \newcommand{\secstoprocess}{\all} | ||
\newcommand{\NA}{{\rm NA}} | \newcommand{\NA}{{\rm NA}} | ||
\newcommand{\mathds}{\mathbb}</math></div> Here is another way to pick a chord ''at random'' | \newcommand{\mathds}{\mathbb}</math></div> Here is another way to pick a chord ''at random'' on the circle of unit radius. Imagine that we have a card table whose sides are of | ||
on the circle of unit radius. Imagine that we have a card table whose sides are of | |||
length 100. We place coordinate axes on the table in such a way that each side of | length 100. We place coordinate axes on the table in such a way that each side of | ||
the table is parallel to one of the axes, and so that the center of the table is the | the table is parallel to one of the axes, and so that the center of the table is the | ||
Line 31: | Line 30: | ||
Write a program to simulate this experiment 10000 times and estimate the | Write a program to simulate this experiment 10000 times and estimate the | ||
probability that the length of the chord is greater than <math>\sqrt3</math>. How does | probability that the length of the chord is greater than <math>\sqrt3</math>. How does | ||
your estimate compare with the results of [[guide:A070937c41#exam 2.1.5 |Example | your estimate compare with the results of [[guide:A070937c41#exam 2.1.5 |Example]]? |
Latest revision as of 21:32, 12 June 2024
Here is another way to pick a chord at random on the circle of unit radius. Imagine that we have a card table whose sides are of
length 100. We place coordinate axes on the table in such a way that each side of the table is parallel to one of the axes, and so that the center of the table is the origin. We now place a circle of unit radius on the table so that the center of the circle is the origin. Now pick out a point [math](x_0,y_0)[/math] at random in the square, and an angle [math]\theta[/math] at random in the interval [math](-\pi/2,\pi/2)[/math]. Let [math]m = \tan\theta[/math]. Then the equation of the line passing through [math](x_0,y_0)[/math] with slope [math]m[/math] is
and the distance of this line from the center of the circle (i.e., the origin) is
We can use this distance formula to check whether the line intersects the circle (i.e., whether [math]d \lt 1[/math]). If so, we consider the resulting chord a random chord. This describes an experiment of dropping a long straw at random on a table on which a circle is drawn. Write a program to simulate this experiment 10000 times and estimate the probability that the length of the chord is greater than [math]\sqrt3[/math]. How does your estimate compare with the results of Example?