HOME

TheInfoList



OR:

Approximations for the
mathematical constant A mathematical constant is a number whose value is fixed by an unambiguous definition, often referred to by a special symbol (e.g., an Letter (alphabet), alphabet letter), or by mathematicians' names to facilitate using it across multiple mathem ...
pi () in the
history of mathematics The history of mathematics deals with the origin of discoveries in mathematics and the History of mathematical notation, mathematical methods and notation of the past. Before the modern age and the worldwide spread of knowledge, written examples ...
reached an accuracy within 0.04% of the true value before the beginning of the
Common Era Common Era (CE) and Before the Common Era (BCE) are year notations for the Gregorian calendar (and its predecessor, the Julian calendar), the world's most widely used calendar era. Common Era and Before the Common Era are alternatives to the ...
. In
Chinese mathematics Mathematics emerged independently in China by the 11th century BCE. The Chinese independently developed a real number system that includes significantly large and negative numbers, more than one numeral system (base 2, binary and base 10, decima ...
, this was improved to approximations correct to what corresponds to about seven decimal digits by the 5th century. Further progress was not made until the 14th century, when
Madhava of Sangamagrama Mādhava of Sangamagrāma (Mādhavan) Availabl/ref> () was an Indian mathematician and astronomer who is considered to be the founder of the Kerala school of astronomy and mathematics in the Late Middle Ages. Madhava made pioneering contributio ...
developed approximations correct to eleven and then thirteen digits.
Jamshīd al-Kāshī Ghiyāth al-Dīn Jamshīd Masʿūd al-Kāshī (or al-Kāshānī) ( ''Ghiyās-ud-dīn Jamshīd Kāshānī'') (c. 1380 Kashan, Iran – 22 June 1429 Samarkand, Transoxiana) was a Persian astronomer and mathematician during the reign of Tamerlane. ...
achieved sixteen digits next. Early modern mathematicians reached an accuracy of 35 digits by the beginning of the 17th century (
Ludolph van Ceulen Ludolph van Ceulen (, ; 28 January 1540 – 31 December 1610) was a German- Dutch mathematician from Hildesheim. He emigrated to the Netherlands. Biography Van Ceulen moved to Delft most likely in 1576 to teach fencing and mathematics and in 1 ...
), and 126 digits by the 19th century ( Jurij Vega). The record of manual approximation of is held by William Shanks, who calculated 527 decimals correctly in 1853. Since the middle of the 20th century, the approximation of has been the task of electronic digital computers (for a comprehensive account, see Chronology of computation of ). On April 2, 2025, the current record was established by Linus Media Group and
Kioxia Kioxia Holdings Corporation () is a Japanese multinational computer memory manufacturer headquartered in Tokyo, Japan. The company was spun off from the Toshiba conglomerate in June 2018 and gained its current name in October 2019; it is curren ...
with Alexander Yee's y-cruncher with 300 trillion (3×) digits.


Early history

The best known approximations to dating to before the Common Era were accurate to two decimal places; this was improved upon in
Chinese mathematics Mathematics emerged independently in China by the 11th century BCE. The Chinese independently developed a real number system that includes significantly large and negative numbers, more than one numeral system (base 2, binary and base 10, decima ...
in particular by the mid-first millennium, to an accuracy of seven decimal places. After this, no further progress was made until the late medieval period. Some Egyptologists have claimed that the
ancient Egypt Ancient Egypt () was a cradle of civilization concentrated along the lower reaches of the Nile River in Northeast Africa. It emerged from prehistoric Egypt around 3150BC (according to conventional Egyptian chronology), when Upper and Lower E ...
ians used an approximation of as = 3.142857 (about 0.04% too high) from as early as the
Old Kingdom In ancient Egyptian history, the Old Kingdom is the period spanning –2200 BC. It is also known as the "Age of the Pyramids" or the "Age of the Pyramid Builders", as it encompasses the reigns of the great pyramid-builders of the Fourth Dynast ...
(c. 2700–2200 BC). This claim has been met with skepticism.
Babylonian mathematics Babylonian mathematics (also known as Assyro-Babylonian mathematics) is the mathematics developed or practiced by the people of Mesopotamia, as attested by sources mainly surviving from the Old Babylonian period (1830–1531 BC) to the Seleucid ...
usually approximated to 3, sufficient for the architectural projects of the time (notably also reflected in the description of
Solomon's Temple Solomon's Temple, also known as the First Temple (), was a biblical Temple in Jerusalem believed to have existed between the 10th and 6th centuries Common Era, BCE. Its description is largely based on narratives in the Hebrew Bible, in which it ...
in the
Hebrew Bible The Hebrew Bible or Tanakh (;"Tanach"
. '' Susa Susa ( ) was an ancient city in the lower Zagros Mountains about east of the Tigris, between the Karkheh River, Karkheh and Dez River, Dez Rivers in Iran. One of the most important cities of the Ancient Near East, Susa served as the capital o ...
in 1936 (dated to between the 19th and 17th centuries BCE) gives a better approximation of as = 3.125, about 0.528% below the exact value. At about the same time, the Egyptian
Rhind Mathematical Papyrus The Rhind Mathematical Papyrus (RMP; also designated as papyrus British Museum 10057, pBM 10058, and Brooklyn Museum 37.1784Ea-b) is one of the best known examples of ancient Egyptian mathematics. It is one of two well-known mathematical papyri ...
(dated to the
Second Intermediate Period The Second Intermediate Period dates from 1700 to 1550 BC. It marks a period when ancient Egypt was divided into smaller dynasties for a second time, between the end of the Middle Kingdom and the start of the New Kingdom. The concept of a Secon ...
, c. 1600 BCE, although stated to be a copy of an older, Middle Kingdom text) implies an approximation of as ≈ 3.16 (accurate to 0.6 percent) by calculating the area of a circle via approximation with the
octagon In geometry, an octagon () is an eight-sided polygon or 8-gon. A '' regular octagon'' has Schläfli symbol and can also be constructed as a quasiregular truncated square, t, which alternates two types of edges. A truncated octagon, t is a ...
. Astronomical calculations in the ''
Shatapatha Brahmana The Shatapatha Brahmana (, , abbreviated to 'SB') is a commentary on the Yajurveda, Śukla Yajurveda. It is attributed to the Vedic sage Yajnavalkya. Described as the most complete, systematic, and important of the Brahmanas (commentaries on the ...
'' (c. 6th century BCE) use a fractional approximation of . The
Mahabharata The ''Mahābhārata'' ( ; , , ) is one of the two major Sanskrit Indian epic poetry, epics of ancient India revered as Smriti texts in Hinduism, the other being the ''Ramayana, Rāmāyaṇa''. It narrates the events and aftermath of the Kuru ...
(500 BCE – 300 CE) offers an approximation of 3, in the ratios offered in Bhishma Parva verses: 6.12.40–45. In the 3rd century BCE,
Archimedes Archimedes of Syracuse ( ; ) was an Ancient Greece, Ancient Greek Greek mathematics, mathematician, physicist, engineer, astronomer, and Invention, inventor from the ancient city of Syracuse, Sicily, Syracuse in History of Greek and Hellenis ...
proved the sharp inequalities  <  < , by means of regular 96-gons (accuracies of 2·10−4 and 4·10−4, respectively). In the 2nd century CE,
Ptolemy Claudius Ptolemy (; , ; ; – 160s/170s AD) was a Greco-Roman mathematician, astronomer, astrologer, geographer, and music theorist who wrote about a dozen scientific treatises, three of which were important to later Byzantine science, Byzant ...
used the value , the first known approximation accurate to three decimal places (accuracy 2·10−5). It is equal to 3+8/60+30/60^2, which is accurate to two
sexagesimal Sexagesimal, also known as base 60, is a numeral system with 60 (number), sixty as its radix, base. It originated with the ancient Sumerians in the 3rd millennium BC, was passed down to the ancient Babylonians, and is still used—in a modified fo ...
digits. The Chinese mathematician
Liu Hui Liu Hui () was a Chinese mathematician who published a commentary in 263 CE on ''Jiu Zhang Suan Shu ( The Nine Chapters on the Mathematical Art).'' He was a descendant of the Marquis of Zixiang of the Eastern Han dynasty and lived in the state ...
in 263 CE computed to between and by inscribing a 96-gon and 192-gon; the average of these two values is (accuracy 9·10−5). He also suggested that 3.14 was a good enough approximation for practical purposes. He has also frequently been credited with a later and more accurate result, π ≈ = 3.1416 (accuracy 2·10−6), although some scholars instead believe that this is due to the later (5th-century) Chinese mathematician
Zu Chongzhi Zu Chongzhi (; 429 – 500), courtesy name Wenyuan (), was a Chinese astronomer, inventor, mathematician, politician, and writer during the Liu Song and Southern Qi dynasties. He was most notable for calculating pi as between 3.1415926 and 3.1415 ...
. Zu Chongzhi is known to have computed to be between 3.1415926 and 3.1415927, which was correct to seven decimal places. He also gave two other approximations of : π ≈ and π ≈ , which are not as accurate as his decimal result. The latter fraction is the best possible rational approximation of using fewer than five decimal digits in the numerator and denominator. Zu Chongzhi's results surpass the accuracy reached in Hellenistic mathematics, and would remain without improvement for close to a millennium. In Gupta-era India (6th century), mathematician
Aryabhata Aryabhata ( ISO: ) or Aryabhata I (476–550 CE) was the first of the major mathematician-astronomers from the classical age of Indian mathematics and Indian astronomy. His works include the '' Āryabhaṭīya'' (which mentions that in 3600 ' ...
, in his astronomical treatise
Āryabhaṭīya ''Aryabhatiya'' (IAST: ') or ''Aryabhatiyam'' ('), a Indian astronomy, Sanskrit astronomical treatise, is the ''Masterpiece, magnum opus'' and only known surviving work of the 5th century Indian mathematics, Indian mathematician Aryabhata. Philos ...
stated: Approximating to four decimal places: π ≈ = 3.1416,How Aryabhata got the earth's circumference right
Aryabhata stated that his result "approximately" (' "approaching") gave the circumference of a circle. His 15th-century commentator
Nilakantha Somayaji Keļallur Nīlakaṇṭha Somayāji (14 June 1444 – 1544), also referred to as Keļallur Comatiri, was a mathematician and astronomer of the Kerala school of astronomy and mathematics. One of his most influential works was the comprehens ...
(
Kerala school of astronomy and mathematics The Kerala school of astronomy and mathematics or the Kerala school was a school of Indian mathematics, mathematics and Indian astronomy, astronomy founded by Madhava of Sangamagrama in Kingdom of Tanur, Tirur, Malappuram district, Malappuram, K ...
) has argued that the word means not only that this is an approximation, but that the value is incommensurable (irrational).


Middle Ages

Further progress was not made for nearly a millennium, until the 14th century, when Indian mathematician and astronomer
Madhava of Sangamagrama Mādhava of Sangamagrāma (Mādhavan) Availabl/ref> () was an Indian mathematician and astronomer who is considered to be the founder of the Kerala school of astronomy and mathematics in the Late Middle Ages. Madhava made pioneering contributio ...
, founder of the
Kerala school of astronomy and mathematics The Kerala school of astronomy and mathematics or the Kerala school was a school of Indian mathematics, mathematics and Indian astronomy, astronomy founded by Madhava of Sangamagrama in Kingdom of Tanur, Tirur, Malappuram district, Malappuram, K ...
, found the
Maclaurin series Maclaurin or MacLaurin is a surname. Notable people with the surname include: * Colin Maclaurin (1698–1746), Scottish mathematician * Normand MacLaurin (1835–1914), Australian politician and university administrator * Henry Normand MacLaurin ...
for arctangent, and then two
infinite series In mathematics, a series is, roughly speaking, an addition of infinitely many terms, one after the other. The study of series is a major part of calculus and its generalization, mathematical analysis. Series are used in most areas of mathemati ...
for . One of them is now known as the Madhava–Leibniz series, based on \pi=4\arctan(1): :\pi=4\left(1-\frac 13+\frac 15-\frac 17 +\cdots\right) The other was based on \pi=6\arctan(1/\sqrt 3): : \pi = \sqrt\sum^\infty_ \frac = \sqrt\sum^\infty_ \frac = \sqrt\left(1-+-+\cdots\right) He used the first 21 terms to compute an approximation of correct to 11 decimal places as . He also improved the formula based on arctan(1) by including a correction: :\pi/4\approx 1-\frac 13+\frac 15-\frac 17+ \cdots -\frac\pm\frac It is not known how he came up with this correction. Using this he found an approximation of to 13 decimal places of accuracy when  = 75. Indian mathematician Bhaskara II used regular polygons with up to 384 sides to obtain a close approximation of π, calculating it as 3.141666.
Jamshīd al-Kāshī Ghiyāth al-Dīn Jamshīd Masʿūd al-Kāshī (or al-Kāshānī) ( ''Ghiyās-ud-dīn Jamshīd Kāshānī'') (c. 1380 Kashan, Iran – 22 June 1429 Samarkand, Transoxiana) was a Persian astronomer and mathematician during the reign of Tamerlane. ...
(Kāshānī), a Persian astronomer and
mathematician A mathematician is someone who uses an extensive knowledge of mathematics in their work, typically to solve mathematical problems. Mathematicians are concerned with numbers, data, quantity, mathematical structure, structure, space, Mathematica ...
, correctly computed the fractional part of 2 to 9
sexagesimal Sexagesimal, also known as base 60, is a numeral system with 60 (number), sixty as its radix, base. It originated with the ancient Sumerians in the 3rd millennium BC, was passed down to the ancient Babylonians, and is still used—in a modified fo ...
digits in 1424, and translated this into 16 decimal digits after the decimal point: : 2\pi \approx 6.2831853071795864, which gives 16 correct digits for π after the decimal point: : \pi \approx 3.1415926535897932 He achieved this level of accuracy by calculating the perimeter of a
regular polygon In Euclidean geometry, a regular polygon is a polygon that is Equiangular polygon, direct equiangular (all angles are equal in measure) and Equilateral polygon, equilateral (all sides have the same length). Regular polygons may be either ''convex ...
with 3 × 228 sides.


16th to 19th centuries

In the second half of the 16th century, the French mathematician
François Viète François Viète (; 1540 – 23 February 1603), known in Latin as Franciscus Vieta, was a French people, French mathematician whose work on new algebra was an important step towards modern algebra, due to his innovative use of letters as par ...
discovered an infinite product that converged on known as
Viète's formula In mathematics, Viète's formula is the following infinite product of nested radicals representing twice the Multiplicative inverse, reciprocal of the mathematical constant pi, : \frac2\pi = \frac2 \cdot \frac2 \cdot \frac2 \cdots It can also b ...
. The German-Dutch mathematician
Ludolph van Ceulen Ludolph van Ceulen (, ; 28 January 1540 – 31 December 1610) was a German- Dutch mathematician from Hildesheim. He emigrated to the Netherlands. Biography Van Ceulen moved to Delft most likely in 1576 to teach fencing and mathematics and in 1 ...
(''circa'' 1600) computed the first 35 decimal places of with a 262-gon. He was so proud of this accomplishment that he had them inscribed on his
tombstone A gravestone or tombstone is a marker, usually stone, that is placed over a grave. A marker set at the head of the grave may be called a headstone. An especially old or elaborate stone slab may be called a funeral stele, stela, or slab. The us ...
. In ''Cyclometricus'' (1621),
Willebrord Snellius Willebrord Snellius (born Willebrord Snel van Royen) (13 June 158030 October 1626) was a Dutch astronomer and mathematician, commonly known as Snell. His name is usually associated with the law of refraction of light known as Snell's law. The ...
demonstrated that the perimeter of the inscribed polygon converges on the circumference twice as fast as does the perimeter of the corresponding circumscribed polygon. This was proved by
Christiaan Huygens Christiaan Huygens, Halen, Lord of Zeelhem, ( , ; ; also spelled Huyghens; ; 14 April 1629 – 8 July 1695) was a Dutch mathematician, physicist, engineer, astronomer, and inventor who is regarded as a key figure in the Scientific Revolution ...
in 1654. Snellius was able to obtain seven digits of from a 96-sided polygon. In 1656,
John Wallis John Wallis (; ; ) was an English clergyman and mathematician, who is given partial credit for the development of infinitesimal calculus. Between 1643 and 1689 Wallis served as chief cryptographer for Parliament and, later, the royal court. ...
published the Wallis product: \frac = \prod_^ \frac = \prod_^ \left(\frac \cdot \frac\right) = \Big(\frac \cdot \frac\Big) \cdot \Big(\frac \cdot \frac\Big) \cdot \Big(\frac \cdot \frac\Big) \cdot \Big(\frac \cdot \frac\Big) \cdot \; \cdots In 1706, John Machin used Gregory's series (the
Taylor series In mathematics, the Taylor series or Taylor expansion of a function is an infinite sum of terms that are expressed in terms of the function's derivatives at a single point. For most common functions, the function and the sum of its Taylor ser ...
for
arctangent In mathematics, the inverse trigonometric functions (occasionally also called ''antitrigonometric'', ''cyclometric'', or ''arcus'' functions) are the inverse functions of the trigonometric functions, under suitably restricted domains. Specific ...
) and the identity \tfrac14\pi = 4\arccot 5 - \arccot 239 to calculate 100 digits of (see below).

Reprinted in

In 1719, Thomas de Lagny used a similar identity to calculate 127 digits (of which 112 were correct). In 1789, the Slovene mathematician Jurij Vega improved John Machin's formula to calculate the first 140 digits, of which the first 126 were correct. In 1841, William Rutherford calculated 208 digits, of which the first 152 were correct. The magnitude of such precision (152 decimal places) can be put into context by the fact that the circumference of the largest known object, the observable universe, can be calculated from its diameter (93billion
light-year A light-year, alternatively spelled light year (ly or lyr), is a unit of length used to express astronomical distances and is equal to exactly , which is approximately 9.46 trillion km or 5.88 trillion mi. As defined by the International Astr ...
s) to a precision of less than one
Planck length In particle physics and physical cosmology, Planck units are a system of units of measurement defined exclusively in terms of four universal physical constants: '' c'', '' G'', '' ħ'', and ''k''B (described further below). Expressing one of ...
(at , the shortest unit of length expected to be directly measurable) using expressed to just 62 decimal places. The English amateur mathematician William Shanks calculated to 530 decimal places in January 1853, of which the first 527 were correct (the last few likely being incorrect due to round-off errors). He subsequently expanded his calculation to 607 decimal places in April 1853, but an error introduced right at the 530th decimal place rendered the rest of his calculation erroneous; due to the nature of Machin's formula, the error propagated back to the 528th decimal place, leaving only the first 527 digits correct once again. Twenty years later, Shanks expanded his calculation to 707 decimal places in April 1873. Due to this being an expansion of his previous calculation, most of the new digits were incorrect as well. Shanks was said to have calculated new digits all morning and would then spend all afternoon checking his morning's work. This was the longest expansion of until the advent of the electronic digital computer three-quarters of a century later.


20th and 21st centuries

In 1910, the Indian mathematician
Srinivasa Ramanujan Srinivasa Ramanujan Aiyangar (22 December 188726 April 1920) was an Indian mathematician. Often regarded as one of the greatest mathematicians of all time, though he had almost no formal training in pure mathematics, he made substantial con ...
found several rapidly converging infinite series of , including : \frac = \frac \sum^\infty_ \frac which computes a further eight decimal places of with each term in the series. His series are now the basis for the fastest algorithms currently used to calculate . Evaluating the first term alone yields a value correct to seven decimal places: :\pi\approx\frac\approx 3.14159273 See Ramanujan–Sato series. From the mid-20th century onwards, all improvements in calculation of have been done with the help of
calculators An electronic calculator is typically a portable electronic device used to perform calculations, ranging from basic arithmetic to complex mathematics. The first solid-state electronic calculator was created in the early 1960s. Pocket-siz ...
or
computers A computer is a machine that can be programmed to automatically carry out sequences of arithmetic or logical operations ('' computation''). Modern digital electronic computers can perform generic sets of operations known as ''programs'', ...
. In 1944−45, D. F. Ferguson, with the aid of a mechanical desk calculator, found that William Shanks had made a mistake in the 528th decimal place, and that all succeeding digits were incorrect. In the early years of the computer, an expansion of to decimal places was computed by Maryland mathematician Daniel Shanks (no relation to the aforementioned William Shanks) and his team at the
United States Naval Research Laboratory The United States Naval Research Laboratory (NRL) is the corporate research laboratory for the United States Navy and the United States Marine Corps. Located in Washington, DC, it was founded in 1923 and conducts basic scientific research, appl ...
in Washington, D.C. In 1961, Shanks and his team used two different power series for calculating the digits of . For one, it was known that any error would produce a value slightly high, and for the other, it was known that any error would produce a value slightly low. And hence, as long as the two series produced the same digits, there was a very high confidence that they were correct. The first 100,265 digits of were published in 1962. The authors outlined what would be needed to calculate to 1 million decimal places and concluded that the task was beyond that day's technology, but would be possible in five to seven years. In 1989, the
Chudnovsky brothers David Volfovich Chudnovsky (born January 22, 1947) and Gregory Volfovich Chudnovsky (born April 17, 1952) are American mathematicians and engineers known for their world-record mathematical calculations and developing the Chudnovsky algorithm us ...
computed to over 1 billion decimal places on the
supercomputer A supercomputer is a type of computer with a high level of performance as compared to a general-purpose computer. The performance of a supercomputer is commonly measured in floating-point operations per second (FLOPS) instead of million instruc ...
IBM 3090 The IBM 3090 family is a family of mainframe computers that was a high-end successor to the IBM System/370 series, and thus indirectly the successor to the IBM System/360 launched 25 years earlier. Announced on 12 February 1985, the press releas ...
using the following variation of Ramanujan's infinite series of : : \frac = 12 \sum^\infty_ \frac. Records since then have all been accomplished using the
Chudnovsky algorithm The Chudnovsky algorithm is a fast method for calculating the digits of , based on Ramanujan's formulae. Published by the Chudnovsky brothers in 1988, it was used to calculate to a billion decimal places. It was used in the world record calcu ...
. In 1999, Yasumasa Kanada and his team at the
University of Tokyo The University of Tokyo (, abbreviated as in Japanese and UTokyo in English) is a public research university in Bunkyō, Tokyo, Japan. Founded in 1877 as the nation's first modern university by the merger of several pre-westernisation era ins ...
computed to over 200 billion decimal places on the supercomputer HITACHI SR8000/MPP (128 nodes) using another variation of Ramanujan's infinite series of . In November 2002, Yasumasa Kanada and a team of 9 others used the Hitachi SR8000, a 64-node supercomputer with 1 terabyte of main memory, to calculate to roughly 1.24 trillion digits in around 600 hours (25days).


Recent records

# In August 2009, a Japanese supercomputer called the T2K Open Supercomputer more than doubled the previous record by calculating to roughly 2.6 trillion digits in approximately 73 hours and 36 minutes. # In December 2009,
Fabrice Bellard Fabrice Bellard (; born 1972) is a French computer programmer known for writing FFmpeg, QEMU, and the Tiny C Compiler. He developed Bellard's formula for calculating single digits of pi. In 2012, Bellard co-founded Amarisoft, a telecommunica ...
used a home computer to compute 2.7 trillion decimal digits of . Calculations were performed in base 2 (binary), then the result was converted to base 10 (decimal). The calculation, conversion, and verification steps took a total of 131 days. # In August 2010, Shigeru Kondo used Alexander Yee's y-cruncher to calculate 5 trillion digits of . This was the world record for any type of calculation, but significantly it was performed on a home computer built by Kondo. The calculation was done between 4 May and 3 August, with the primary and secondary verifications taking 64 and 66 hours respectively. # In October 2011, Shigeru Kondo broke his own record by computing ten trillion (1013) and fifty digits using the same method but with better hardware. # In December 2013, Kondo broke his own record for a second time when he computed 12.1 trillion digits of . # In October 2014, Sandon Van Ness, going by the pseudonym "houkouonchi" used y-cruncher to calculate 13.3 trillion digits of . # In November 2016, Peter Trueb and his sponsors computed on y-cruncher and fully verified 22.4 trillion digits of (22,459,157,718,361 ( × 1012)). The computation took (with three interruptions) 105 days to complete, the limitation of further expansion being primarily storage space. # In March 2019, Emma Haruka Iwao, an employee at
Google Google LLC (, ) is an American multinational corporation and technology company focusing on online advertising, search engine technology, cloud computing, computer software, quantum computing, e-commerce, consumer electronics, and artificial ...
, computed 31.4 (approximately 10) trillion digits of pi using y-cruncher and Google Cloud machines. This took 121 days to complete. # In January 2020, Timothy Mullican announced the computation of 50 trillion digits over 303 days. #On 14 August 2021, a team (DAViS) at the University of Applied Sciences of the Grisons announced completion of the computation of to 62.8 (approximately 20) trillion digits. # On 8 June 2022, Emma Haruka Iwao announced on the Google Cloud Blog the computation of 100 trillion (1014) digits of over 158 days using Alexander Yee's y-cruncher. # On 14 March 2024, Jordan Ranous, Kevin O’Brien and Brian Beeler computed to 105 trillion digits, also using y-cruncher. # On 28 June 2024, the StorageReview Team computed to 202 trillion digits, also using y-cruncher. # On 2 April 2025, Linus Media Group and
Kioxia Kioxia Holdings Corporation () is a Japanese multinational computer memory manufacturer headquartered in Tokyo, Japan. The company was spun off from the Toshiba conglomerate in June 2018 and gained its current name in October 2019; it is curren ...
computed to 300 trillion digits, also using y-cruncher.


Practical approximations

Depending on the purpose of a calculation, can be approximated by using fractions for ease of calculation. The most notable such approximations are (
relative error The approximation error in a given data value represents the significant discrepancy that arises when an exact, true value is compared against some approximation derived for it. This inherent error in approximation can be quantified and express ...
of about 4·10−4) and (relative error of about 8·10−8). In Chinese mathematics, the fractions 22/7 and 355/113 are known as Yuelü () and Milü ().


Non-mathematical "definitions" of

Of some notability are legal or historical texts purportedly "defining " to have some rational value, such as the " Indiana Pi Bill" of 1897, which stated "the ratio of the diameter and circumference is as five-fourths to four" (which would imply "") and a passage in the
Hebrew Bible The Hebrew Bible or Tanakh (;"Tanach"
. '' squaring the circle Squaring the circle is a problem in geometry first proposed in Greek mathematics. It is the challenge of constructing a square (geometry), square with the area of a circle, area of a given circle by using only a finite number of steps with a ...
". The bill was nearly passed by the
Indiana General Assembly The Indiana General Assembly is the state legislature, or legislative branch, of the U.S. state of Indiana. It is a bicameral legislature that consists of a lower house, the Indiana House of Representatives, and an upper house, the Indiana Sena ...
in the U.S., and has been claimed to imply a number of different values for , although the closest it comes to explicitly asserting one is the wording "the ratio of the diameter and circumference is as five-fourths to four", which would make , a discrepancy of nearly 2 percent. A mathematics professor who happened to be present the day the bill was brought up for consideration in the Senate, after it had passed in the House, helped to stop the passage of the bill on its second reading, after which the assembly thoroughly ridiculed it before postponing it indefinitely.


Imputed biblical value

It is sometimes claimed that the
Hebrew Bible The Hebrew Bible or Tanakh (;"Tanach"
. '' round basin located in front of the
Temple in Jerusalem The Temple in Jerusalem, or alternatively the Holy Temple (; , ), refers to the two religious structures that served as the central places of worship for Israelites and Jews on the modern-day Temple Mount in the Old City of Jerusalem. Accord ...
as having a diameter of 10
cubit The cubit is an ancient unit of length based on the distance from the elbow to the tip of the middle finger. It was primarily associated with the Sumerians, Egyptians, and Israelites. The term ''cubit'' is found in the Bible regarding Noah ...
s and a circumference of 30 cubits. The issue is discussed in the
Talmud The Talmud (; ) is the central text of Rabbinic Judaism and the primary source of Jewish religious law (''halakha'') and Jewish theology. Until the advent of Haskalah#Effects, modernity, in nearly all Jewish communities, the Talmud was the cen ...
and in
Rabbinic literature Rabbinic literature, in its broadest sense, is the entire corpus of works authored by rabbis throughout Jewish history. The term typically refers to literature from the Talmudic era (70–640 CE), as opposed to medieval and modern rabbinic ...
. Among the many explanations and comments are these: * Rabbi Nehemiah explained this in his ''Mishnat ha-Middot'' (the earliest known
Hebrew Hebrew (; ''ʿÎbrit'') is a Northwest Semitic languages, Northwest Semitic language within the Afroasiatic languages, Afroasiatic language family. A regional dialect of the Canaanite languages, it was natively spoken by the Israelites and ...
text on
geometry Geometry (; ) is a branch of mathematics concerned with properties of space such as the distance, shape, size, and relative position of figures. Geometry is, along with arithmetic, one of the oldest branches of mathematics. A mathematician w ...
, ca. 150 CE) by saying that the diameter was measured from the ''outside'' rim while the circumference was measured along the ''inner'' rim. This interpretation implies a brim about 0.225 cubit (or, assuming an 18-inch "cubit", some 4 inches), or one and a third "
handbreadth The palm is an obsolete anthropic unit of length, originally based on the width of the human palm and then variously standardized. The same name is also used for a second, rather larger unit based on the length of the human hand. The width of t ...
s," thick (cf. and ). *
Maimonides Moses ben Maimon (1138–1204), commonly known as Maimonides (, ) and also referred to by the Hebrew acronym Rambam (), was a Sephardic rabbi and Jewish philosophy, philosopher who became one of the most prolific and influential Torah schola ...
states (ca. 1168 CE) that can only be known approximately, so the value 3 was given as accurate enough for religious purposes. This is taken by some as the earliest assertion that is irrational. There is still some debate on this passage in biblical scholarship. Many reconstructions of the basin show a wider brim (or flared lip) extending outward from the bowl itself by several inches to match the description given in In the succeeding verses, the rim is described as "a handbreadth thick; and the brim thereof was wrought like the brim of a cup, like the flower of a lily: it received and held three thousand baths" , which suggests a shape that can be encompassed with a string shorter than the total length of the brim, e.g., a
Lilium ''Lilium'' ( ) is a genus of Herbaceous plant, herbaceous flowering plants growing from bulbs, all with large and often prominent flowers. Lilies are a group of flowering plants which are important in culture and literature in much of the world ...
flower or a
Teacup A teacup is a cup for drinking tea. It generally has a small handle (grip), handle that may be grasped with the thumb and one or two fingers. It is typically made of a ceramic material and is often part of a set which is composed of a cup and ...
.


Development of efficient formulae


Polygon approximation to a circle

Archimedes, in his ''Measurement of a Circle'', created the first algorithm for the calculation of based on the idea that the perimeter of any (convex) polygon inscribed in a circle is less than the circumference of the circle, which, in turn, is less than the perimeter of any circumscribed polygon. He started with inscribed and circumscribed regular hexagons, whose perimeters are readily determined. He then shows how to calculate the perimeters of regular polygons of twice as many sides that are inscribed and circumscribed about the same circle. This is a recursive procedure which would be described today as follows: Let and denote the perimeters of regular polygons of sides that are inscribed and circumscribed about the same circle, respectively. Then, :P_ = \frac, \quad \quad p_ = \sqrt. Archimedes uses this to successively compute and . Using these last values he obtains :3 \frac < \pi < 3 \frac. It is not known why Archimedes stopped at a 96-sided polygon; it only takes patience to extend the computations.
Heron Herons are long-legged, long-necked, freshwater and coastal birds in the family Ardeidae, with 75 recognised species, some of which are referred to as egrets or bitterns rather than herons. Members of the genus ''Botaurus'' are referred to as bi ...
reports in his ''Metrica'' (about 60 CE) that Archimedes continued the computation in a now lost book, but then attributes an incorrect value to him. Archimedes uses no trigonometry in this computation and the difficulty in applying the method lies in obtaining good approximations for the square roots that are involved. Trigonometry, in the form of a table of chord lengths in a circle, was probably used by Claudius Ptolemy of Alexandria to obtain the value of given in the ''Almagest'' (circa 150 CE). Advances in the approximation of (when the methods are known) were made by increasing the number of sides of the polygons used in the computation. A trigonometric improvement by Willebrord Snell (1621) obtains better bounds from a pair of bounds obtained from the polygon method. Thus, more accurate results were obtained from polygons with fewer sides.
Viète's formula In mathematics, Viète's formula is the following infinite product of nested radicals representing twice the Multiplicative inverse, reciprocal of the mathematical constant pi, : \frac2\pi = \frac2 \cdot \frac2 \cdot \frac2 \cdots It can also b ...
, published by
François Viète François Viète (; 1540 – 23 February 1603), known in Latin as Franciscus Vieta, was a French people, French mathematician whose work on new algebra was an important step towards modern algebra, due to his innovative use of letters as par ...
in 1593, was derived by Viète using a closely related polygonal method, but with areas rather than perimeters of polygons whose numbers of sides are powers of two. The last major attempt to compute by this method was carried out by Grienberger in 1630 who calculated 39 decimal places of using Snell's refinement.


Machin-like formula

For fast calculations, one may use formulae such as Machin's: : \frac = 4 \arctan\frac - \arctan\frac together with the
Taylor series In mathematics, the Taylor series or Taylor expansion of a function is an infinite sum of terms that are expressed in terms of the function's derivatives at a single point. For most common functions, the function and the sum of its Taylor ser ...
expansion of the function
arctan In mathematics, the inverse trigonometric functions (occasionally also called ''antitrigonometric'', ''cyclometric'', or ''arcus'' functions) are the inverse functions of the trigonometric functions, under suitably restricted domains. Specific ...
(''x''). This formula is most easily verified using
polar coordinates In mathematics, the polar coordinate system specifies a given point (mathematics), point in a plane (mathematics), plane by using a distance and an angle as its two coordinate system, coordinates. These are *the point's distance from a reference ...
of
complex number In mathematics, a complex number is an element of a number system that extends the real numbers with a specific element denoted , called the imaginary unit and satisfying the equation i^= -1; every complex number can be expressed in the for ...
s, producing: (5+i)^4\cdot(239-i)=2^2 \cdot 13^4(1+i). ((),() = is a solution to the
Pell equation Pell is a surname shared by several notable people, listed below * Albert Pell * Axel Rudi Pell (born 1960), German heavy metal guitar player and member of Steeler and founder of his own eponymous band * Barney Pell * Benjamin Pell * Charles P ...
2 − 22 = −1.) Formulae of this kind are known as '' Machin-like formulae''. Machin's particular formula was used well into the computer era for calculating record numbers of digits of , but more recently other similar formulae have been used as well. For instance, Shanks and his team used the following Machin-like formula in 1961 to compute the first 100,000 digits of : : \frac = 6 \arctan\frac + 2 \arctan\frac + \arctan\frac and they used another Machin-like formula, : \frac = 12 \arctan\frac + 8 \arctan\frac - 5 \arctan\frac as a check. The record as of December 2002 by Yasumasa Kanada of Tokyo University stood at 1,241,100,000,000 digits. The following Machin-like formulae were used for this: : \frac = 12 \arctan\frac + 32 \arctan\frac - 5 \arctan\frac + 12 \arctan\frac K. Takano (1982). : \frac = 44 \arctan\frac + 7 \arctan\frac - 12 \arctan\frac + 24 \arctan\frac F. C. M. Størmer (1896).


Other classical formulae

Other formulae that have been used to compute estimates of include:
Liu Hui Liu Hui () was a Chinese mathematician who published a commentary in 263 CE on ''Jiu Zhang Suan Shu ( The Nine Chapters on the Mathematical Art).'' He was a descendant of the Marquis of Zixiang of the Eastern Han dynasty and lived in the state ...
(see also
Viète's formula In mathematics, Viète's formula is the following infinite product of nested radicals representing twice the Multiplicative inverse, reciprocal of the mathematical constant pi, : \frac2\pi = \frac2 \cdot \frac2 \cdot \frac2 \cdots It can also b ...
): : \begin \pi &\approx 768 \sqrt\\ &\approx 3.141590463236763. \end Madhava: :\pi = \sqrt\sum^\infty_ \frac = \sqrt\sum^\infty_ \frac = \sqrt\left(-+-+\cdots\right) Newton / Euler Convergence Transformation: :\begin \arctan x &= \frac \sum_^\infty \frac = \frac + \frac23\frac + \frac\frac + \cdots \\ 0mu\frac &= \sum_^\infty\frac= \sum_^ \cfrac = 1+\frac\left(1+\frac\left(1+\frac\left(1+\cdots\right)\right)\right) \end :where is the
double factorial In mathematics, the double factorial of a number , denoted by , is the product of all the positive integers up to that have the same Parity (mathematics), parity (odd or even) as . That is, n!! = \prod_^ (n-2k) = n (n-2) (n-4) \cdots. Restated ...
, the product of the positive integers up to with the same parity.
Euler Leonhard Euler ( ; ; ; 15 April 170718 September 1783) was a Swiss polymath who was active as a mathematician, physicist, astronomer, logician, geographer, and engineer. He founded the studies of graph theory and topology and made influential ...
: : = 20 \arctan\frac + 8 \arctan\frac :(Evaluated using the preceding series for ) Ramanujan: : \frac = \frac \sum^\infty_ \frac David Chudnovsky and Gregory Chudnovsky: : \frac = 12 \sum^\infty_ \frac Ramanujan's work is the basis for the
Chudnovsky algorithm The Chudnovsky algorithm is a fast method for calculating the digits of , based on Ramanujan's formulae. Published by the Chudnovsky brothers in 1988, it was used to calculate to a billion decimal places. It was used in the world record calcu ...
, the fastest algorithms used, as of the turn of the millennium, to calculate .


Modern algorithms

Extremely long decimal expansions of are typically computed with iterative formulae like the
Gauss–Legendre algorithm The Gauss–Legendre algorithm is an algorithm to compute the digits of . It is notable for being rapidly convergent, with only 25 iterations producing 45 million correct digits of . However, it has some drawbacks (for example, it is computer ...
and Borwein's algorithm. The latter, found in 1985 by Jonathan and Peter Borwein, converges extremely quickly: For y_0=\sqrt2-1,\ a_0=6-4\sqrt2 and :y_=(1-f(y_k))/(1+f(y_k)) ~,~ a_ = a_k(1+y_)^4 - 2^ y_(1+y_+y_^2) where f(y)=(1-y^4)^, the sequence 1/a_k converges quartically to , giving about 100 digits in three steps and over a trillion digits after 20 steps. Even though the Chudnovsky series is only linearly convergent, the Chudnovsky algorithm might be faster than the iterative algorithms in practice; that depends on technological factors such as memory sizes and access times. For breaking world records, the iterative algorithms are used less commonly than the Chudnovsky algorithm since they are memory-intensive. The first one million digits of and are available from
Project Gutenberg Project Gutenberg (PG) is a volunteer effort to digitize and archive cultural works, as well as to "encourage the creation and distribution of eBooks." It was founded in 1971 by American writer Michael S. Hart and is the oldest digital li ...
. A former calculation record (December 2002) by Yasumasa Kanada of
Tokyo University The University of Tokyo (, abbreviated as in Japanese and UTokyo in English) is a public research university in Bunkyō, Tokyo, Japan. Founded in 1877 as the nation's first modern university by the merger of several pre-westernisation era ins ...
stood at 1.24 trillion digits, which were computed in September 2002 on a 64-node
Hitachi () is a Japanese Multinational corporation, multinational Conglomerate (company), conglomerate founded in 1910 and headquartered in Chiyoda, Tokyo. The company is active in various industries, including digital systems, power and renewable ener ...
supercomputer A supercomputer is a type of computer with a high level of performance as compared to a general-purpose computer. The performance of a supercomputer is commonly measured in floating-point operations per second (FLOPS) instead of million instruc ...
with 1 terabyte of main memory, which carries out 2 trillion operations per second, nearly twice as many as the computer used for the previous record (206 billion digits). The following Machin-like formulae were used for this: : \frac = 12 \arctan\frac + 32 \arctan\frac - 5 \arctan\frac + 12 \arctan\frac ( Kikuo Takano (1982)) : \frac = 44 \arctan\frac + 7 \arctan\frac - 12 \arctan\frac + 24 \arctan\frac ( F. C. M. Størmer (1896)). These approximations have so many digits that they are no longer of any practical use, except for testing new supercomputers. Properties like the potential normality of will always depend on the infinite string of digits on the end, not on any finite computation.


Miscellaneous approximations

As well as the formulas and approximations such as \tfrac and \tfrac discussed elsewhere in this article, The following expressions have been used to estimate : * Accurate to three digits: \sqrt + \sqrt = 3.146^+.
Karl Popper Sir Karl Raimund Popper (28 July 1902 – 17 September 1994) was an Austrian–British philosopher, academic and social commentator. One of the 20th century's most influential philosophers of science, Popper is known for his rejection of the ...
conjectured that
Plato Plato ( ; Greek language, Greek: , ; born  BC, died 348/347 BC) was an ancient Greek philosopher of the Classical Greece, Classical period who is considered a foundational thinker in Western philosophy and an innovator of the writte ...
knew this expression, that he believed it to be exactly , and that this is responsible for some of Plato's confidence in the universal power of geometry and for Plato's repeated discussion of special
right triangle A right triangle or right-angled triangle, sometimes called an orthogonal triangle or rectangular triangle, is a triangle in which two sides are perpendicular, forming a right angle ( turn or 90 degrees). The side opposite to the right angle i ...
s that are either
isosceles In geometry, an isosceles triangle () is a triangle that has two sides of equal length and two angles of equal measure. Sometimes it is specified as having ''exactly'' two sides of equal length, and sometimes as having ''at least'' two sides ...
or halves of
equilateral An equilateral triangle is a triangle in which all three sides have the same length, and all three angles are equal. Because of these properties, the equilateral triangle is a regular polygon, occasionally known as the regular triangle. It is the ...
triangles. * Accurate to four digits: 1+e-\gamma= 3.1410^+, where e is the natural logarithmic base and \gamma is Euler's constant, and \sqrt = 3.1413^+. * Accurate to four digits (or five significant figures): \sqrt = 3.1416^+. * An approximation by Ramanujan, accurate to 4 digits (or five significant figures): \frac+\sqrt = 3.1416^+. * Accurate to five digits: \frac = 3.14156^+ , \sqrt 3.14155^+, and (by Kochański) \sqrt = 3.14153^+. * accurate to six digits: \left(2 - \frac\right)^2 = 3.14159\ 6^+. * accurate to eight digits: ::\left(\frac-\frac\right)^ = \frac = 3.14159\ 263^+ :This is the case that cannot be obtained from Ramanujan's approximation (22). *accurate to nine digits: :: \sqrt =\sqrt = 3.14159\ 2652^+ : This is from Ramanujan, who claimed the Goddess of Namagiri appeared to him in a dream and told him the true value of . * accurate to ten digits (or eleven significant figures): \sqrt 93= 3.14159\ 26536^+ This approximation follows the observation that the 193rd power of 1/ yields the sequence 1122211125... Replacing 5 by 2 completes the symmetry without reducing the correct digits of , while inserting a central decimal point remarkably fixes the accompanying magnitude at 10100. * accurate to 12 decimal places: ::\left(\frac-\frac\right)^ = 3.14159\ 26535\ 89^+ :This is obtained from the Chudnovsky series (truncate the series (1.4) at the first term and let = 151931373056001/151931373056000 ≈ 1). * accurate to 16 digits: ::\frac = 3.14159\ 26535\ 89793\ 9^+ - inverse of sum of first two terms of Ramanujan series. ::\frac=3.14159\ 26535\ 89793\ 4^+ * accurate to 18 digits: ::\left(\frac-\frac-\frac\right)^ = 3.14159\ 26535\ 89793\ 2387^+ :This is the approximation (22) in Ramanujan's paper Reprinted in with = 253. * accurate to 19 digits: ::\frac = 3.14159\ 26535\ 89793\ 2382^+ - improved inverse of sum of first two terms of Ramanujan series. * accurate to 24 digits: ::\frac = 3.14159\ 26535\ 89793\ 23846\ 2649^+ - inverse of sum of first three terms of Ramanujan series. * accurate to 25 decimal places: ::\frac\ln\left(\frac+24\right) = 3.14159\ 26535\ 89793\ 23846\ 26433\ 9^+ :This is derived from Ramanujan's class invariant . * accurate to 30 decimal places: ::\frac = 3.14159\ 26535\ 89793\ 23846\ 26433\ 83279^+ : Derived from the closeness of Ramanujan constant to the integer 6403203+744. This does not admit obvious generalizations in the integers, because there are only finitely many
Heegner number In number theory Number theory is a branch of pure mathematics devoted primarily to the study of the integers and arithmetic functions. Number theorists study prime numbers as well as the properties of mathematical objects constructed from int ...
s and negative
discriminant In mathematics, the discriminant of a polynomial is a quantity that depends on the coefficients and allows deducing some properties of the zero of a function, roots without computing them. More precisely, it is a polynomial function of the coef ...
s ''d'' with class number ''h''(−''d'') = 1, and d = 163 is the largest one in
absolute value In mathematics, the absolute value or modulus of a real number x, is the non-negative value without regard to its sign. Namely, , x, =x if x is a positive number, and , x, =-x if x is negative (in which case negating x makes -x positive), ...
. * accurate to 52 decimal places: ::\frac :Like the one above, a consequence of the
j-invariant In mathematics, Felix Klein's -invariant or function is a modular function of weight zero for the special linear group \operatorname(2,\Z) defined on the upper half-plane of complex numbers. It is the unique such function that is holomorphic a ...
. Among negative discriminants with class number 2, this ''d'' the largest in absolute value. * accurate to 52 decimal places: ::\frac :This is derived from Ramanujan's class invariant . * accurate to 161 decimal places: ::\frac :where ''u'' is a product of four simple quartic units, ::u = (a+\sqrt)^2(b+\sqrt)^2(c+\sqrt)(d+\sqrt) :and, :: \begin a &= \tfrac(23+4\sqrt)\\ b &= \tfrac(19\sqrt+7\sqrt)\\ c &= (429+304\sqrt)\\ d &= \tfrac(627+442\sqrt) \end :Based on one found by Daniel Shanks. Similar to the previous two, but this time is a quotient of a
modular form In mathematics, a modular form is a holomorphic function on the complex upper half-plane, \mathcal, that roughly satisfies a functional equation with respect to the group action of the modular group and a growth condition. The theory of modul ...
, namely the
Dedekind eta function In mathematics, the Dedekind eta function, named after Richard Dedekind, is a modular form of weight 1/2 and is a function defined on the upper half-plane of complex numbers, where the imaginary part is positive. It also occurs in bosonic string ...
, and where the argument involves \tau = \sqrt. The discriminant ''d'' = 3502 has ''h''(−''d'') = 16. * accurate to 256 digits: ::\frac... ::...\frac - improved inverse of sum of the first nineteen terms of Chudnovsky series. * The continued fraction representation of can be used to generate successive best rational approximations. These approximations are the best possible rational approximations of relative to the size of their denominators. Here is a list of the first thirteen of these: :: \frac, \frac, \frac, \frac, \frac, \frac, \frac, \frac, \frac, \frac, \frac, \frac :Of these, \frac is the only fraction in this sequence that gives more exact digits of (i.e. 7) than the number of digits needed to approximate it (i.e. 6). The accuracy can be improved by using other fractions with larger numerators and denominators, but, for most such fractions, more digits are required in the approximation than correct significant figures achieved in the result.


Summing a circle's area

Pi can be obtained from a circle if its radius and area are known using the relationship: : A = \pi r^2. If a circle with radius is drawn with its center at the point , any point whose distance from the origin is less than will fall inside the circle. The
Pythagorean theorem In mathematics, the Pythagorean theorem or Pythagoras' theorem is a fundamental relation in Euclidean geometry between the three sides of a right triangle. It states that the area of the square whose side is the hypotenuse (the side opposite t ...
gives the distance from any point to the center: :d=\sqrt. Mathematical "graph paper" is formed by imagining a 1×1 square centered around each cell , where and are
integer An integer is the number zero (0), a positive natural number (1, 2, 3, ...), or the negation of a positive natural number (−1, −2, −3, ...). The negations or additive inverses of the positive natural numbers are referred to as negative in ...
s between − and . Squares whose center resides inside or exactly on the border of the circle can then be counted by testing whether, for each cell , :\sqrt \le r. The total number of cells satisfying that condition thus approximates the area of the circle, which then can be used to calculate an approximation of . Closer approximations can be produced by using larger values of . Mathematically, this formula can be written: :\pi = \lim_ \frac \sum_^ \; \sum_^ \begin 1 & \text \sqrt \le r \\ 0 & \text \sqrt > r. \end In other words, begin by choosing a value for . Consider all cells (, ) in which both and are integers between − and . Starting at 0, add 1 for each cell whose distance to the origin is less than or equal to . When finished, divide the sum, representing the area of a circle of radius , by 2 to find the approximation of . For example, if is 5, then the cells considered are: : The 12 cells (0, ±5), (±5, 0), (±3, ±4), (±4, ±3) are ''exactly on'' the circle, and 69 cells are ''completely inside'', so the approximate area is 81, and is calculated to be approximately 3.24 because = 3.24. Results for some values of are shown in the table below: Similarly, the more complex approximations of given below involve repeated calculations of some sort, yielding closer and closer approximations with increasing numbers of calculations.


Continued fractions

Besides its simple
continued fraction A continued fraction is a mathematical expression that can be written as a fraction with a denominator that is a sum that contains another simple or continued fraction. Depending on whether this iteration terminates with a simple fraction or not, ...
representation ; 7, 15, 1, 292, 1, 1,... which displays no discernible pattern, has many
generalized continued fraction A continued fraction is a mathematical expression that can be written as a fraction with a denominator that is a sum that contains another simple or continued fraction. Depending on whether this iteration terminates with a simple fraction or not, ...
representations generated by a simple rule, including these two. : \pi= : \pi = \cfrac = 3 + \cfrac The remainder of the Madhava–Leibniz series can be expressed as generalized continued fraction as follows. : \pi = 4\sum_^\frac+\cfrac \qquad (m=1,2,3,\ldots) Note that Madhava's correction term is : \frac = 4\frac . The well-known values and are respectively the second and fourth continued fraction approximations to π.


Trigonometry


Gregory–Leibniz series

The Gregory–Leibniz series : \pi = 4\sum_^ \cfrac = 4\left( \frac - \frac + \frac - \frac +- \cdots\right) is the power series for
arctan In mathematics, the inverse trigonometric functions (occasionally also called ''antitrigonometric'', ''cyclometric'', or ''arcus'' functions) are the inverse functions of the trigonometric functions, under suitably restricted domains. Specific ...
(x) specialized to  = 1. It converges too slowly to be of practical interest. However, the power series converges much faster for smaller values of x, which leads to formulae where \pi arises as the sum of small angles with rational tangents, known as Machin-like formulae.


Arctangent

Knowing that 4 arctan 1 = , the formula can be simplified to get: : \begin \pi &= 2\left( 1 + \cfrac + \cfrac + \cfrac + \cfrac + \cfrac + \cdots\right) \\ &= 2\sum_^ \cfrac = \sum_^ \cfrac = \sum_^ \cfrac \\ &= 2 + \frac + \frac + \frac + \frac + \frac + \frac + \frac + \frac + \frac + \cdots \end with a convergence such that each additional 10 terms yields at least three more digits. : \pi=2+\frac\left(2+\frac\left(2+\frac\left(2+\cdots\right)\right)\right) :This series is the basis for a decimal spigot algorithm by Rabinowitz and Wagon. : Another formula for \pi involving arctangent function is given by : \frac=\arctan \frac, \qquad\qquad k\geq 2, where a_k=\sqrt such that a_1=\sqrt . Approximations can be made by using, for example, the rapidly convergent
Euler Leonhard Euler ( ; ; ; 15 April 170718 September 1783) was a Swiss polymath who was active as a mathematician, physicist, astronomer, logician, geographer, and engineer. He founded the studies of graph theory and topology and made influential ...
formula :\arctan(x) = \sum_^\infty \frac \; \frac. Alternatively, the following simple expansion series of the arctangent function can be used : \arctan(x)=2\sum_^, where : \begin & a_1(x)=2/x,\\ & b_1(x)=1,\\ & a_n(x)=a_(x)\,\left(1-4/x^2\right)+4b_(x)/x,\\ & b_n(x)=b_(x)\,\left(1-4/x^2\right)-4a_(x)/x, \end to approximate \pi with even more rapid convergence. Convergence in this arctangent formula for \pi improves as integer k increases. The constant \pi can also be expressed by infinite sum of arctangent functions as :\frac = \sum_^\infty \arctan\frac = \arctan\frac + \arctan\frac + \arctan\frac + \arctan\frac + \cdots and : \frac=\sum_ \arctan \frac, where F_n is the ''n''-th
Fibonacci number In mathematics, the Fibonacci sequence is a Integer sequence, sequence in which each element is the sum of the two elements that precede it. Numbers that are part of the Fibonacci sequence are known as Fibonacci numbers, commonly denoted . Many w ...
. However, these two formulae for \pi are much slower in convergence because of set of arctangent functions that are involved in computation.


Arcsine

Observing an equilateral triangle and noting that : \sin\left (\frac\right )=\frac yields : \begin \pi &= 6 \sin^ \left( \frac \right) = 6 \left( \frac + \frac + \frac + \frac + \cdots\! \right) \\ &= \frac + \frac + \frac + \frac + \cdots\! = \sum_^\infty \frac \\ &= 3 + \frac + \frac + \frac + \frac + \frac + \frac + \frac + \cdots \end with a convergence such that each additional five terms yields at least three more digits.


Digit extraction methods

The Bailey–Borwein–Plouffe formula (BBP) for calculating was discovered in 1995 by Simon Plouffe. Using a spigot algorithm, the formula can compute any particular digit of —returning the hexadecimal value of the digit—without computing the intervening digits. : \pi=\sum_^\infty \left(\frac-\frac-\frac-\frac\right)\left(\frac\right)^n In 1996, Plouffe derived an algorithm to extract the th decimal digit of (using base10 math to extract a base10 digit), and which can do so with an improved speed of time. The algorithm does not require memory for storage of a full n-digit result, so the one-millionth digit of could in principle be computed using a pocket calculator. (However, it would be quite tedious and impractical to do so.) : \pi+3=\sum_^\infty \frac The calculation speed of Plouffe's formula was improved to by
Fabrice Bellard Fabrice Bellard (; born 1972) is a French computer programmer known for writing FFmpeg, QEMU, and the Tiny C Compiler. He developed Bellard's formula for calculating single digits of pi. In 2012, Bellard co-founded Amarisoft, a telecommunica ...
, who derived an alternative formula (albeit only in base2 math) for computing . : \pi=\frac\sum_^\infty \frac \left (-\frac-\frac+\frac-\frac-\frac-\frac+\frac\right )


Efficient methods

Many other expressions for were developed and published by Indian mathematician
Srinivasa Ramanujan Srinivasa Ramanujan Aiyangar (22 December 188726 April 1920) was an Indian mathematician. Often regarded as one of the greatest mathematicians of all time, though he had almost no formal training in pure mathematics, he made substantial con ...
. He worked with mathematician Godfrey Harold Hardy in England for a number of years. Extremely long decimal expansions of are typically computed with the
Gauss–Legendre algorithm The Gauss–Legendre algorithm is an algorithm to compute the digits of . It is notable for being rapidly convergent, with only 25 iterations producing 45 million correct digits of . However, it has some drawbacks (for example, it is computer ...
and Borwein's algorithm; the Salamin–Brent algorithm, which was invented in 1976, has also been used. In 1997, David H. Bailey, Peter Borwein and Simon Plouffe published a paper (Bailey, 1997) on a new formula for as an
infinite series In mathematics, a series is, roughly speaking, an addition of infinitely many terms, one after the other. The study of series is a major part of calculus and its generalization, mathematical analysis. Series are used in most areas of mathemati ...
: : \pi = \sum_^\infty \frac \left( \frac - \frac - \frac - \frac\right). This formula permits one to fairly readily compute the ''k''th
binary Binary may refer to: Science and technology Mathematics * Binary number, a representation of numbers using only two values (0 and 1) for each digit * Binary function, a function that takes two arguments * Binary operation, a mathematical op ...
or
hexadecimal Hexadecimal (also known as base-16 or simply hex) is a Numeral system#Positional systems in detail, positional numeral system that represents numbers using a radix (base) of sixteen. Unlike the decimal system representing numbers using ten symbo ...
digit of , without having to compute the preceding ''k'' − 1 digits. Bailey's website contains the derivation as well as implementations in various
programming language A programming language is a system of notation for writing computer programs. Programming languages are described in terms of their Syntax (programming languages), syntax (form) and semantics (computer science), semantics (meaning), usually def ...
s. The
PiHex PiHex was a distributed computing project organized by Colin Percival to calculate specific bits of pi, . 1,246 contributors used idle time slices on almost two thousand computers to make its calculations. The software used for the project made use ...
project computed 64 bits around the
quadrillion Depending on context (e.g. language, culture, region), some large numbers have names that allow for describing large quantities in a textual form; not mathematical. For very large values, the text is generally shorter than a decimal numeric repres ...
th bit of (which turns out to be 0).
Fabrice Bellard Fabrice Bellard (; born 1972) is a French computer programmer known for writing FFmpeg, QEMU, and the Tiny C Compiler. He developed Bellard's formula for calculating single digits of pi. In 2012, Bellard co-founded Amarisoft, a telecommunica ...
further improved on BBP with his formula: :\pi = \frac \sum_^ \frac \left( - \frac - \frac + \frac - \frac - \frac - \frac + \frac \right) Other formulae that have been used to compute estimates of include: : \frac=\sum_^\infty\frac=\sum_^\frac =1+\frac\left(1+\frac\left(1+\frac\left(1+\cdots\right)\right)\right) : Newton. : : \frac = \frac \sum^\infty_ \frac :
Srinivasa Ramanujan Srinivasa Ramanujan Aiyangar (22 December 188726 April 1920) was an Indian mathematician. Often regarded as one of the greatest mathematicians of all time, though he had almost no formal training in pure mathematics, he made substantial con ...
. This converges extraordinarily rapidly. Ramanujan's work is the basis for the fastest algorithms used, as of the turn of the millennium, to calculate . In 1988, David Chudnovsky and Gregory Chudnovsky found an even faster-converging series (the
Chudnovsky algorithm The Chudnovsky algorithm is a fast method for calculating the digits of , based on Ramanujan's formulae. Published by the Chudnovsky brothers in 1988, it was used to calculate to a billion decimal places. It was used in the world record calcu ...
): : \frac = \frac \sum^\infty_ \frac. The speed of various algorithms for computing pi to n correct digits is shown below in descending order of asymptotic complexity. M(n) is the complexity of the multiplication algorithm employed.


Projects


Pi Hex

Pi Hex was a project to compute three specific binary digits of using a distributed network of several hundred computers. In 2000, after two years, the project finished computing the five trillionth (5*1012), the forty trillionth, and the quadrillionth (1015) bits. All three of them turned out to be 0.


Software for calculating

Over the years, several programs have been written for calculating to many digits on
personal computer A personal computer, commonly referred to as PC or computer, is a computer designed for individual use. It is typically used for tasks such as Word processor, word processing, web browser, internet browsing, email, multimedia playback, and PC ...
s.


General purpose

Most
computer algebra system A computer algebra system (CAS) or symbolic algebra system (SAS) is any mathematical software with the ability to manipulate mathematical expressions in a way similar to the traditional manual computations of mathematicians and scientists. The de ...
s can calculate and other common
mathematical constant A mathematical constant is a number whose value is fixed by an unambiguous definition, often referred to by a special symbol (e.g., an Letter (alphabet), alphabet letter), or by mathematicians' names to facilitate using it across multiple mathem ...
s to any desired precision. Functions for calculating are also included in many general
libraries A library is a collection of Book, books, and possibly other Document, materials and Media (communication), media, that is accessible for use by its members and members of allied institutions. Libraries provide physical (hard copies) or electron ...
for
arbitrary-precision arithmetic In computer science, arbitrary-precision arithmetic, also called bignum arithmetic, multiple-precision arithmetic, or sometimes infinite-precision arithmetic, indicates that calculations are performed on numbers whose digits of precision are po ...
, for instance Class Library for Numbers,
MPFR The GNU Multiple Precision Floating-Point Reliable Library (GNU MPFR) is a GNU portable C (programming language), C Library (computing), library for Arbitrary-precision arithmetic, arbitrary-precision binary Floating-point arithmetic, floating-po ...
and
SymPy SymPy is an open-source Python library for symbolic computation. It provides computer algebra capabilities either as a standalone application, as a library to other applications, or live on the web as SymPy Live or SymPy Gamma. SymPy is simple ...
.


Special purpose

Programs designed for calculating may have better performance than general-purpose mathematical software. They typically implement checkpointing and efficient disk swapping to facilitate extremely long-running and memory-expensive computations. * TachusPi by Fabrice Bellard is the program used by himself to compute world record number of digits of pi in 2009. * -cruncher by Alexander Yee is the program which every world record holder since Shigeru Kondo in 2010 has used to compute world record numbers of digits. -cruncher can also be used to calculate other constants and holds world records for several of them. * PiFast by Xavier Gourdon was the fastest program for
Microsoft Windows Windows is a Product lining, product line of Proprietary software, proprietary graphical user interface, graphical operating systems developed and marketed by Microsoft. It is grouped into families and subfamilies that cater to particular sec ...
in 2003. According to its author, it can compute one million digits in 3.5 seconds on a 2.4 GHz
Pentium 4 Pentium 4 is a series of single-core central processing unit, CPUs for Desktop computer, desktops, laptops and entry-level Server (computing), servers manufactured by Intel. The processors were shipped from November 20, 2000 until August 8, 20 ...
. PiFast can also compute other irrational numbers like and . It can also work at lesser efficiency with very little memory (down to a few tens of megabytes to compute well over a billion (109) digits). This tool is a popular benchmark in the
overclocking In computing, overclocking is the practice of increasing the clock rate of a computer to exceed that certified by the manufacturer. Commonly, operating voltage is also increased to maintain a component's operational stability at accelerated sp ...
community. PiFast 4.4 is available fro
Stu's Pi page
PiFast 4.3 is available from Gourdon's page. * QuickPi by Steve Pagliarulo for Windows is faster than PiFast for runs of under 400 million digits. Version 4.5 is available on Stu's Pi Page below. Like PiFast, QuickPi can also compute other irrational numbers like , , and . The software may be obtained from the Pi-Hacks Yahoo! forum, or fro

* Super PI by Kanada Laboratory in the University of Tokyo is the program for Microsoft Windows for runs from 16,000 to 33,550,000 digits. It can compute one million digits in 40 minutes, two million digits in 90 minutes and four million digits in 220 minutes on a Pentium 90 MHz. Super PI version 1.9 is available fro
Super PI 1.9 page


See also

*
Diophantine approximation In number theory, the study of Diophantine approximation deals with the approximation of real numbers by rational numbers. It is named after Diophantus of Alexandria. The first problem was to know how well a real number can be approximated ...
* Milü * Madhava's correction term * Pi is 3


Notes


References

* * * * * * {{DEFAULTSORT:Approximations of Pi Approximations History of mathematics Pi Pi algorithms Real transcendental numbers