The Discovery That Transformed Pi



01/2 (1-x2)1/2 dx = [ 12 - 1213(12)3 - 1815(12)5 - 11617(12)7 - 512819(12)9 - … ]

π ≈ 12 [ 12 - 1213(12)3 - 1815(12)5 - 11617(12)7 - 512819(12)9 - … - 38 ]

609 digits of π from 1,000 terms in the series:
π ≈ 3.141592653589793238462643383279502884197169399375105820974944592307816406286208998628034825342117067982148086513282306647093844609550582231725359408128481117450284102701938521105559644622948954930381964428810975665933446128475648233786783165271201909145648566923460348610454326648213393607260249141273724587006606315588174881520920962829254091715364367892590360011330530548820466521384146951941511609433057270365759591953092186117381932611793105118548074462379962749567351885752724891227938183011949129833673362440656643086021394946395224737190702179860943702770539217176293176752384674818467669405132000568127…

taylor.txt (586K) - 1,000 terms used to calculate the approximation of π above.
taylor.txt.xz (26M, 57M uncompressed) - Compressed taylor.txt with first 10,000 terms.
newton.bc (610K) - bc script that uses the terms to calculate π. The lines in newton.bc to truncate π at the end of the script were manually added.
prepare_taylor.sh (0.8K) - Syntax highlighted - Bash script that reads taylor.txt and outputs newton.bc.
taylor.py (1K) - Syntax highlighted - Python script to generate taylor.txt - ./taylor.py >taylor.txt

sqrt3.sh (0.8K) - Syntax highlighted - If the sqrt(3) at the end feels a little handwavy, this script will generate √3 using taylor.txt. A small amount of precision will be lost (607 digits of √3 and 606 digits of π from 1,000 terms).

Most sources give the following formula for Newton's 1665 π calculation:
01⁄4 x1⁄2(1-x)1⁄2 dx = [ x1⁄2 - 12x3⁄2 - 18x5⁄2 - 116x7⁄2 - 5128x9⁄2 - 7256x11⁄2 - … ]

π ≈ 24 [ 23(12)3 - 1225(12)5 - 1827(12)7 - 11629(12)9 - 5128211(12)11 - 7256213(12)13 - … + 332 ]
or
π ≈ 3√34 + 24 [ … ]

This produces digits at the same rate as the equation given in the video.
newton-orig.sh (0.8K) - Syntax highlighted - Uses the integral from 0 to 1⁄4.