"PI Unleashed" of Jorg Arndt and Christoph Haenel's has seventeen chapters, one appendix, and one CDROM. The first chapter presents a brief history on pi calculation. Generally speaking, we are in the 3rd era of pi calculation, which began around 1980. This era has three major developments. They are the development of high speed: (1) multiplications of large numbers, (2) algorithms on calculating pi, and (3) computers. Since 1980, the number of known pi digits grows twice (200%) per year. The new goal now is to calculate individual digits at the far end of pi. By BBP algorithm, one is able to calculate any digits of pi without calculating any prior digits. The 2nd era began around 1650. Since then the arc tan method dominated the pi calculation until 1980. The method of the 1st era (250BC-1650) is to calculate the circumferences of the two regular polygons placed inside and outside of a circle.
The methods on high speed multiplication for large numbers are introduced on chapter 11. They are the Fast Fourier Transform and Karatsuba multiplication. Chapter 6 through 10 introduces the algorithms. They are the spigot algorithm, Gauss AGM algorithm (a popular algorithm), Ramanujan's algorithm (50 correct decimal places per term), Borweins' algorithms (every iteration generates four to five times more digits than the previous iteration), and the BBP algorithm. Other than supercomputer, the Internet is a valuable computing resource. The binsplit algorithm enables pi to be distribute computed by the computers on the Internet.
The CDROM comes with a few extreme precision library packages. One of them is hfloat. The author of hfloat is Jorg Arndt, which is also one of the authors of the book. The appendix of the book documents the hfloat library. By utilizing the library and the provided algorithms, one is able to calculate pi up to million of digits with ease. The high precision arithmetic is generally the most difficult and the most challenging part of a pi program. The CDROM also comes with a tutorial on how to write a C program on calculating pi without using somebody else high precision library. In such a scenario, one has to write his own high precision function on addition, subtraction, multiplication, division, and square root. Other tutorial includes fast Fourier transform.
One may wonder the motivations on calculating trillion of digits of pi. Other than the world record, the digits can be used to test computer system and as a source of new discoveries. In addition, pi appears in many branches of mathematics.