Pi Calculator — Approximate π with Infinite Series
Explore how π is computed numerically using infinite series. Choose a series, set the number of terms and see the approximation, absolute error and convergence curve — a visual way to understand why more terms always gets you closer to 3.14159265…
Series / method
Computed using the selected infinite series
Kako radi ovaj kalkulator?
Infinite series like Nilakantha π = 3 + Σ (−1)ⁿ·4/[(2n+2)(2n+3)(2n+4)] and Leibniz π = 4·Σ (−1)ᵏ/(2k+1) converge to π as more terms are added. Nilakantha reaches ~6 correct decimal places in 50 terms; Leibniz needs ~10,000 terms for 4 correct places.
Formula
How this is calculated
The number π is irrational and transcendental — it cannot be expressed as a ratio of integers or as the root of a polynomial with rational coefficients, and its decimal expansion never repeats. To compute numerical approximations, mathematicians use infinite series that converge to π.
The Gregory-Leibniz series π = 4 × (1 − 1/3 + 1/5 − 1/7 + …) is elegant but converges very slowly — you need about 10,000 terms to get π accurate to 4 decimal places. The Nilakantha series π = 3 + 4/(2·3·4) − 4/(4·5·6) + … converges much faster, reaching 6 correct decimal places in just 50 terms. The Machin formula π/4 = 4·arctan(1/5) − arctan(1/239) converges even faster, because arctan of a small number is well-approximated by its Taylor series.
All three approaches compute the same constant — they differ only in efficiency. In practice, modern software computes π using algorithms like Borwein or Chudnovsky that can generate billions of decimal digits, but the series-based methods here are historically important and illustrate the core idea of using convergence to define and compute irrational constants.
Često postavljana pitanja
The Leibniz series subtracts fractions like 1/3, 1/5, 1/7 — these shrink slowly, so the alternating cancellation converges slowly. Nilakantha terms shrink as 1/n³, and the Machin arctan series uses 1/5 and 1/239 as base values, so they get tiny very quickly. The speed of convergence is determined by how fast the individual terms go to zero.
π appears in geometry (circumference = 2πr, area = πr²), trigonometry (full circle = 2π radians), probability (Gaussian bell curve), signal processing (Fourier transforms), physics (wave equations) and many other fields. It is one of the most ubiquitous constants in mathematics.
As of 2024, over 100 trillion decimal digits of π have been computed — far more than any physical application needs. The record is held by specialised algorithms (Chudnovsky) running on supercomputers. In everyday engineering, 15 significant figures (the precision of a 64-bit floating-point number) is always more than sufficient.
Poznato i kao
TG we-Calculate Editorial Team. (2026). Pi Calculator — Approximate π with Infinite Series [Online calculator]. TG we-Calculate. https://we-calculate.com/hr/calculator/pi-calculator
TG we-Calculate Editorial Team. "Pi Calculator — Approximate π with Infinite Series." TG we-Calculate. 2026. https://we-calculate.com/hr/calculator/pi-calculator.
TG we-Calculate Editorial Team, "Pi Calculator — Approximate π with Infinite Series," TG we-Calculate, 2026. [Online]. Available: https://we-calculate.com/hr/calculator/pi-calculator
@misc{wecalculate_pi_calculator, title = {Pi Calculator — Approximate π with Infinite Series}, author = {{TG we-Calculate Editorial Team}}, howpublished = {\url{https://we-calculate.com/hr/calculator/pi-calculator}}, year = {2026}, note = {TG we-Calculate} }
Je li vam ovaj kalkulator pomogao?
