# Bellard’s exotic formula for π\pi

In his webpage, Fabrice Bellard mentions an exotic formula for $\pi$ as follows where

and he further adds that this was obtained while testing some numerical relations with PSLQ Algorithm which is a kind of integer relation algorithm.

My point here is not to ask a proof of the formula $(1)$ because it is based on a computer algorithm, but rather to understand how can be we be so sure of accuracy of such formulas obtained via these algorithms unless we have some other proof based on analytical arguments. Fundamentally a computer algorithm can’t operate on a real number. The most we can hope for is operations on algebraic numbers. To deal with arbitrary real numbers one does not need “arbitrary precision arithmetic” but rather “infinite precision arithmetic” which is kind of impossible to achieve via computers.

How does one guarantee a computer generated formula like $(1)$ involving transcendental numbers ($\pi$) to be true?

Update: Just so as to highlight the computer based calculations done for algebraic numbers I refer to my answer regarding a Ramanujan’s formula for $\pi$.

At some point you need to tell the computer what $\pi$ is. One option is to give an integral representation: for example, you might tell the computer that

From here, the computer can try to prove statements about $\pi$ by manipulating the integral on the right. For example, $\sqrt{1 - x^2}$ has a power series expansion

and integrating this power series expansion term by term gives

See, that wasn’t so hard! Even a computer could’ve done it. Computers are in fact quite good at manipulating expressions like these formally, and can rigorously prove many things about them; see, for example, Petkovsek, Wilf, and Zeilberger’s A=B.

There are no issues involving infinite precision because the computer is not at any point attempting to evaluate the numerical value of both sides or anything like that; instead, it’s starting from a fact we tell it about $\pi$ and formally deducing other facts about $\pi$ from it. (I mean, I don’t know how to compute $\pi$ to infinite precision, but that’s never stopped me from proving facts about $\pi$, and I think anything I can do, a computer could in principle do.)

Edit: Okay, so I actually read a little about the PSLQ algorithm. It does not prove anything: as far as I can tell, what it actually does is give a very clever way to guess integer relations between real numbers which you provide it by providing a very large number of their digits. Once you have such a guess, you can verify it to as high a precision as you want by computing more digits. That’s not a proof, but it’s very good evidence, and the more digits you compute the better evidence it is. Then you can look for a proof.