Google Cloud Calculates Pi to 100 Trillion Digits, Setting World Record

The Google logo on a background of circles
(Image credit: Google, Malte Luk)

Google has announced a new world record score for the working out of Pi, the famously irrational mathematical constant that represents the ratio of a circle's circumference to its diameter. When 3.141592653589793 will no longer do, Google’s got you covered to 100 trillion digits. 

Google engineer Roger at the Oklahoma data center

(Image credit: Google)

Quite why the Mountain View ad company felt the need to do this, beyond bragging rights, remains unknown. However, we do know that it used a single Google Cloud compute node made up of 128 vCPUs and 864GB of RAM, running Debian Linux. This crunched the delicious numbers for 157 days, 23 hours, 31 minutes and 7.651 seconds before spitting out the figures.

Google immediately took to its Cloud Blog to boast of the feat, pointing out the advances its Compute Engine N2 machine family had made since it last had a crack at the orbicular infinite series in 2019. In that run, it calculated a 31.4 trillion-digit slice of Pi in 111.8 days using 25 of the compute nodes of the time (a total of 96 vCPUs with 1.4TB of RAM). In 2021, scientists at the University of Applied Sciences of the Grisons brought the total up to 62.8 trillion digits using two AMD Epyc 32-core processors and 1TB of RAM. 

The fact every team has used different hardware makes it very difficult to compare and decide who the best Pi-cruncher is, but they all use the same software, Y-cruncher by Alexander J. Yee, running the Chudnovsky algorithm. A feature of this algorithm is "that the time and resources necessary to calculate digits increase more rapidly than the digits themselves," Google blogged back in 2019. Luckily, Google Cloud’s computing power has increased significantly in just two years. 

There were of course enormous amounts of storage used to hold such a large number and the components used in its calculation. Out of 663TB available to the compute node, 515TB were used, and the total disk I/O came to 82PB of data. If you’ve got a spare million years or so, you can read through the whole 100 trillion digits at pi.delivery - or listen to it converted into piano music. Alternatively, you can just go ahead and download the entire thing from here, but you’ll need a lot of time and hard drive space. There's a lot more detail on the way the compute node and software were configured on the Google Cloud blog.

The enthusiasts at computing news site The Register took their shoes and socks off to work out that this many digits would have cost a normal Google Cloud user $70,000 in fees to calculate - though we’re not sure if  this takes into account the $300 in credit new users receive. Either way, it’s worth noting that Pi to 15 digits - the number at the top of this story - is good enough for NASA to plot interplanetary spacecraft with.

Ian Evenden
Freelance News Writer

Ian Evenden is a UK-based news writer for Tom’s Hardware US. He’ll write about anything, but stories about Raspberry Pi and DIY robots seem to find their way to him.