Duncan Davidson
Tuesday, March 19, 2019

Props to Emma Haruka and her work with the Google Cloud Platform Developer Advocacy team to calculate 31.4 trillion digits of π.

They don’t say how much it would cost to do this yourself, but Corey Quinn estimates it’s about a quarter of a million dollars. Now that it’s been generated, however, you can just grab the data by accessing the delivery.pi API:

$ curl "https://api.pi.delivery/v1/pi?numberOfDigits=10"
{"content":"3.14159265"}

Or, you can clone off your own copy of their cloud disk image. The dataset is big enough, however, that it’ll cost you $40 a day.