[Math] Why is $\frac{\sqrt{6}}{32}(29 + \sqrt{145}) \approx \pi$

algebraic-number-theoryanalytic-number-theorynt.number-theory

Apologies in advance if this is a stupid question; also, disclaimer: this is purely for fun; but:

Why is $\frac{\sqrt{6}}{32}(29 + \sqrt{145})$ such a good approximation to $\pi$?

(Correct to 8 decimal places if my calculator is to be believed).

Is it just a numerical coincidence, or is there actually some deep explanation (like the famous almost-integer $e^{\pi\sqrt{163}}$ related to Heegner numbers)?

[Not my observation, though; this is taken directly from a comment by the user "unknown (yahoo)" in the closed question

https://mathoverflow.net/questions/67161

…who noticed that $\frac{9}{8\pi} + \frac{8\pi}{29} \approx \sqrt{3/2}$, which is equivalent to the approximate equation above; although he/she didn't give any further explanation].

My knowledge of number theory is extremely limited, but it looks like standard methods like continued fractions etc. won't work here – or will they?

* EDIT: after some more numerical searches: *

$(\sqrt{a} + \sqrt{b})/c$ with integer $a,b,c$ can approximate a bit better for certain $c$ than for others; e.g. for $c=32$ as above, the error of the best approximation is (very) roughly $1/100$ of the error for $c= 23,26,29,30$ and $1/10$ of the error for $27,28,33,34$, etc.

But all values of $c$ seem to be not too bad; the worst values have errors still within a factor of roughly $100$ of the best values. Results with $e$ and random numbers instead of $\pi$ seem vaguely similar.

So, this approximation is maybe not as striking as I first thought; but anyway, maybe there is still something deeper lurking behind it. Maybe, also, it's nothing to do with $\pi$.

Best Answer

This is not a a well posed question because the rules of what expressions are allowed have not been specified. If, for example, the domain is expressions of the form $\frac{\sqrt{a}+\sqrt{b}}{c}$ with $a,b,c$ non-negative integers then one could call an expression a best approximation (to $\pi \approx 3.1415926536$) if it has smaller error than any $\frac{\sqrt{a'}+\sqrt{b'}}{c'}$ with $c' \le c.$ Then one could ask how to find the best approximations, is your expression one of these and , if so, is it a better approximation than one might expect for a bound $c \le n?$ For rational numbers $\frac{p}{q}$ it is known how to find the best (rational) approximations and that one can expect from them that the approximation will have error roughly $\frac{1}{q^2}.$ A particular best rational approximation mentioned by Pietro is $\frac{355}{113}.$ See my comment for why it could be considered surprisingly good. I previously guessed that for your problem (as I have framed it) one might expect $\frac{1}{q^6}$ error but now I think that is wrong. See below. By this measure, the expression given ,$$\frac{29\sqrt{6}+\sqrt{870}}{32}=\frac{\sqrt{5046}+\sqrt{870}}{32}\approx 3.1415926546$$ is fairly good but $$\frac{3\sqrt{41}+\sqrt{149}}{10}=\frac{\sqrt{123}+\sqrt{149}}{10} \approx 3.1415928328$$ is better (relative to the denominator) as are $\frac{10+\sqrt{229}}{8}$ and $\frac{1+\sqrt{71}}{3}.$ None of these impress me as much as $355/133$ though.

later thoughts This is fun as a puzzle but not much more. $\pi$ is an exceptional number and has particular approximation expressions, but these are not among them. Best rational approximation and continued fractions are quite special. The approximations are easy to find, can actually be useful, and certain accuracy can be certain. They have even been suggested as a possible alternative to floating point for use in computer computations with reals. The arithmetic and geometry are beautiful and the mathematical connections are deep. It is not a coincidence that the first few approximations to $\pi$ are $\frac31,\frac{22}{7}=\frac{1+7\cdot 3}{0+7\cdot 1},\frac{333}{106}=\frac{3+22\cdot 15}{1+7\cdot 15}$ and $\frac{355}{113}=\frac{22+333}{7+106}$. The accuracy of an approximation depends only on the fractional part (so it as easy or hard to get $\pi$ with a denominator under $n$ as to get $100+\pi$ ). None of these things seem to be true for $\frac{\sqrt{a}+\sqrt{b}}{c}$ nor for roots of degree 4 polynomials.

That said, I now think that to approximate a positive target real $T$ with denominator exactly $c$ one can expect an error of order $\frac{1}{c^4T^3}$ This because the number of expressions $\sqrt{a}+\sqrt{b}$ in an interval $(x-1/2,x+1/2)$ is almost exactly $\frac{x^3}{3}$ so we would expect to be able to approximate $cT$ by $\sqrt{a}+\sqrt{b}$ with error of order $\frac{1}{c^3T^3}$ and hence $T$ by $\frac{ \sqrt{a}+\sqrt{b}}{c}$ with accuracy as given. So I propose defining the virtue of an approximation $\frac{ \sqrt{a}+\sqrt{b}}{c}$ to $T=\pi$ to be $-log_{c\pi}|\pi-\frac{ \sqrt{a}+\sqrt{b}}{c}|$ and expect it to be about $3$. I can report that for $3 \le c \le 200$ the $198$ virtue values of the best approximations (one for each $c$) are best fitted by the line $3.0339-0.000014c$ so that certainly seems satisfyingly flat. I find (in accordance with more extensive reports by others here) that the approximations which beat any previous one (with regard to absolute error) are for these triples $[c,a,b]=$ $\small [3, 1, 71], [4, 38, 41], [5, 45, 81], [6, 2, 304], [6, 5, 276], [7, 18, 315], [8, 100, 229], [10, 149, 369], [14, 181, 932]$

$\small [21, 469, 1964], [24, 120, 4153], [27, 937, 2939], [28, 1724, 2157], [31, 576, 5386], [32, 870, 5046], [59, 2027, 19693]$

$ \small [69, 930, 34698] [80, 697, 50592], [91, 9774, 34977], [98, 2377, 67144], [120, 2010, 110329]$

$\small [132, 1311, 143249], [142, 14503, 106066], [152, 36835, 81566], [181, 67364, 95532]$

For these 24 best approximations the virtues get up to 3.83837,3.80356,3.734 at c=10,8,32 respectively. However these are relatively early so it is hard to say what to expect.