Trisha Shetty (Editor)

Buffon's needle

Updated on
Share on FacebookTweet on TwitterShare on LinkedInShare on Reddit
Buffon's needle

In mathematics, Buffon's needle problem is a question first posed in the 18th century by Georges-Louis Leclerc, Comte de Buffon:


Suppose we have a floor made of parallel strips of wood, each the same width, and we drop a needle onto the floor. What is the probability that the needle will lie across a line between two strips?

Buffon's needle was the earliest problem in geometric probability to be solved; it can be solved using integral geometry. The solution, in the case where the needle length is not greater than the width of the strips, can be used to design a Monte Carlo method for approximating the number π, although that was not the original motivation for de Buffon's question.


The problem in more mathematical terms is: Given a needle of length l dropped on a plane ruled with parallel lines t units apart, what is the probability that the needle will cross a line?

Let x be the distance from the center of the needle to the closest line, let θ be the acute angle between the needle and the lines.

The uniform probability density function of x between 0 and t /2 is

{ 2 t :   0 x t 2 0 : elsewhere.

The uniform probability density function of θ between 0 and π/2 is

{ 2 π :   0 θ π 2 0 : elsewhere.

The two random variables, x and θ, are independent, so the joint probability density function is the product

{ 4 t π :   0 x t 2 ,   0 θ π 2 0 : elsewhere.

The needle crosses a line if

x l 2 sin θ .

Now there are two cases.

Case 1: Short needle

Integrating the joint probability density function gives the probability that the needle will cross a line:

P = θ = 0 π 2 x = 0 ( l / 2 ) sin θ 4 t π d x d θ = 2 l t π .

A particularly nice argument for this result can alternatively be given using "Buffon's noodle".

Case 2: Long needle

Suppose l > t . In this case, integrating the joint probability density function, we obtain:

θ = 0 π 2 x = 0 m ( θ ) 4 t π d x d θ ,

where m ( θ ) is the minimum between ( l / 2 ) sin θ and t / 2 .

Thus, performing the above integration, we see that, when t < l , the probability that the needle will cross a line is

2 l t π 2 t π { l 2 t 2 + t sin 1 ( t l ) } + 1


2 π cos 1 t l + 2 π l t { 1 1 ( t l ) 2 } .

In the second expression, the first term represents the probability of the angle of the needle being such that it will always cross at least one line. The right term represents the probability that, the needle falls at an angle where its position matters, and it crosses the line.

Using elementary calculus

The following solution for the "short needle" case, while equivalent to the one above, has a more visual flavor, and avoids iterated integrals.

We can calculate the probability P as the product of 2 probabilities: P = P 1 P 2 , where P 1 is the probability that the center of the needle falls close enough to a line for the needle to possibly cross it, and P 2 is the probability that the needle actually crosses the line, given that the center is within reach.

Looking at the illustration in the above section, it is apparent that the needle can cross a line if the center of the needle is within l / 2 units of either side of the strip. Adding l 2 + l 2 from both sides and dividing by the whole width t , we obtain P 1 = l t .

Now, we assume that the center is within reach of the edge of the strip, and calculate P 2 . To simplify the calculation, we can assume that l = 2 .

Let x and θ be as in the illustration in this section. Placing a needle's center at x, the needle will cross the vertical axis if it falls within a range of 2θ radians, out of π radians of possible orientations. This represents the gray area to the left of x in the figure. For a fixed x, we can express θ as a function of x: θ ( x ) = cos 1 ( x ) . Now we can let x move from 0 to 1, and integrate:

P 2 = 0 1 2 θ ( x ) π d x = 2 π 0 1 cos 1 ( x ) d x = 2 π 1 = 2 π .

Multiplying both results, we obtain P = P 1 P 2 = l t 2 π = 2 l t π , as above.

There is an even more elegant and simple method of calculating the "short needle case". The end of the needle farthest away from any one of the two lines bordering its region must be located within a horizontal (perpendicular to the bordering lines) distance of l cos θ (where θ is the angle between the needle and the horizontal) from this line in order for the needle to cross it. The farthest this end of the needle can move away from this line horizontally in its region is t . The probability that the farthest end of the needle is located no more than a distance l cos θ away from the line (and thus that the needle crosses the line) out of the total distance t it can move in its region for 0 θ π / 2 is given by

P = 0 π 2 l cos θ d θ 0 π 2 t d θ = l t 0 π 2 cos θ d θ 0 π 2 d θ = l t 1 π 2 = 2 l t π , as above.

Estimating π

In the first, simpler case above, the formula obtained for the probability P can be rearranged to: π = 2 l t P . Thus, if we conduct an experiment to estimate P , we will also have an estimate for π.

Suppose we drop n needles and find that h of those needles are crossing lines, so P is approximated by the fraction h / n . This leads to the formula:

π 2 l n t h .

In 1901, Italian mathematician Mario Lazzarini performed Buffon's needle experiment. Tossing a needle 3408 times, he obtained the well-known approximation 355/113 for π, accurate to six significant digits. Lazzarini's "experiment" is an example of confirmation bias, as it was set up to replicate the already well-known approximation of 355/113 (in fact, there is no better rational approximation with fewer than five digits in the numerator and denominator), yielding a more accurate "prediction" of π than would be expected from the number of trials, as follows:

Lazzarini chose needles whose length was 5/6 of the width of the strips of wood. In this case, the probability that the needles will cross the lines is 5 3 π . Thus if one were to drop n needles and get x crossings, one would estimate π as

π ≈ 5/3 · n/x.

So if Lazzarini was aiming for the result 355/113, he needed n and x such that:

355/113 = 5/3 · n/x

or equivalently,

x = 113n/213

This is easily arranged. To do this, one should pick n as a multiple of 213, because then 113n/213 is an integer; one then drops n needles, and hopes for exactly x = 113n/213 successes.

If one drops 213 needles and happens to get 113 successes, then one can triumphantly report an estimate of π accurate to six decimal places. If not, one can just do 213 more trials and hope for a total of 226 successes; if not, just repeat as necessary. Lazzarini performed 3408 = 213 · 16 trials, making it seem likely that this is the strategy he used to obtain his "estimate."

The above description of strategy might even be considered charitable to Lazzarini. A statistical analysis of intermediate results he reported for fewer tosses leads to a very low probability of achieving such close agreement to the expected value all through the experiment. This makes it very possible that the "experiment" itself was never physically performed, but based on numbers concocted from imagination to match statistical expectations, but too well, as it turns out.


Buffon's needle Wikipedia

Similar Topics
Il tenente dei carabinieri
Nicola Mingazzini
Neten Chokling