# probability that two positive integers are relatively prime

The probability that two positive integers chosen randomly are relatively prime is

 $\frac{6}{\pi^{2}}=0.60792710185\dots.$

At first glance this “naked” result is beautiful, but no suitable definition is there: there isn’t a probability space  defined. Indeed, the word “probability” here is an abuse of language. So, now, let’s write the mathematical statement.

For each $n\in\mathbb{Z}^{+}$, let $S_{n}$ be the set $\{1,2,\dots,n\}\times\{1,2,\dots,n\}$ and define $\Sigma_{n}$ to be the powerset of $S_{n}$. Define $\mu\colon\Sigma_{n}\to\mathbb{R}$ by $\mu(E)=|E|/|S_{n}|$. This makes $(S_{n},\Sigma_{n},\mu)$ into a probability space.

We wish to consider the event of some $(x,y)\in S_{n}$ also being in the set $A_{n}=\{(a,b)\in S_{n}\colon\gcd(a,b)=1\}$. The probability of this event is

 $P((x,y)\in A_{n})=\int_{S_{n}}\chi_{A_{n}}\,d\mu=\frac{|A_{n}|}{|S_{n}|}.$

Our statement is thus the following. For each $n\in\mathbb{Z}^{+}$, select random integers $x_{n}$ and $y_{n}$ with $1\leq x_{n},y_{n}\leq n$. Then the limit $\lim_{n\to\infty}P((x_{n},y_{n})\in A_{n})$ exists and

 $\lim_{n\to\infty}P((x_{n},y_{n})\in A_{n})=\frac{6}{\pi^{2}}.$

In other words, as $n$ gets large, the fraction of $|S_{n}|$ consisting of relatively prime pairs of positive integers tends to $6/\pi^{2}$.

## References

• 1 Challenging Mathematical Problems with Elementary Solutions, A.M. Yaglom and I.M. Yaglom, Vol. 1, Holden-Day, 1964. (See Problems 92 and 93)
Title probability that two positive integers are relatively prime ProbabilityThatTwoPositiveIntegersAreRelativelyPrime 2013-03-22 14:56:08 2013-03-22 14:56:08 mps (409) mps (409) 21 mps (409) Result msc 11A41 msc 11A05 msc 11A51