# Preview for editing tables

In this editor you can enter or edit tables in YAML format, and you can get a preview of how numberdb would render it. You cannot save changes here. Once everything looks good, upload it to the git repository numberdb-data.
— preview —
Values of the arithmetic-geometric mean
edit on github
Numbers
$a$
$b$
$\text{agm}(a,b)$
INPUT{numbers.yaml} (not shown in preview)
Definition
The arithmetic-geometric mean $\text{agm}(a,b)$ of two non-negative real numbers $a$ and $b$ is defined as the simultaneous limit $\lim a_n = \lim g_n$ of the sequences $(a_n)$ and $(g_n)$ given by $a_0 = a$, $g_0 = b$, $a_{n+1} = (a_n + g_n)/2$, $g_{n+1} = \sqrt{a_n g_n}$. This table lists values of $\text{agm}(a,b)$ for certain pairs of integers $a$ and $b$.
Parameters
$a$
—   real number ($a \geq 0$)
$b$
—   real number ($b \geq 0$)
Formulas
(1)
$\text{agm}(a,b) = \frac{(a+b)\pi}{4K((a-b)/(a+b))}$, where $K(k) = \int_0^{\pi/2} \frac{d\theta}{\sqrt{1-k^2\sin^2\theta}}$ is the complete elliptic integral of the first kind .
(2)
$\text{agm}(a,b) = \text{agm}(b,a)$
(3)
$\text{agm}(a,a) = a$
(4)
$\text{agm}(0,a) = 0$
Due to the symmetry (2) and trivial cases (3), (4), we only list values for $a < b$.