In mathematics, the arithmetic–geometric mean (AGM or agM[1]) of two positive real numbers x and y is the mutual limit of a sequence of arithmetic means and a sequence of geometric means.
The arithmetic–geometric mean is used in fast algorithms for exponential, trigonometric functions, and other special functions, as well as some mathematical constants, in particular, computing π.
The AGM is defined as the limit of the interdependent sequences
These two sequences converge to the same number, the arithmetic–geometric mean of x and y; it is denoted by M(x, y), or sometimes by agm(x, y) or AGM(x, y).
The arithmetic–geometric mean can be extended to complex numbers and, when the branches of the square root are allowed to be taken inconsistently, generally it is a multivalued function.
[1] To find the arithmetic–geometric mean of a0 = 24 and g0 = 6, iterate as follows:
The first five iterations give the following values: The number of digits in which an and gn agree (underlined) approximately doubles with each iteration.
The arithmetic–geometric mean of 24 and 6 is the common limit of these two sequences, which is approximately 13.4581714817256154207668131569743992430538388544.
[2] The first algorithm based on this sequence pair appeared in the works of Lagrange.
Its properties were further analyzed by Gauss.
[1] Both the geometric mean and arithmetic mean of two positive numbers x and y are between the two numbers.
[3] So the geometric means are an increasing sequence g0 ≤ g1 ≤ g2 ≤ ...; the arithmetic means are a decreasing sequence a0 ≥ a1 ≥ a2 ≥ ...; and gn ≤ M(x, y) ≤ an for any n. These are strict inequalities if x ≠ y. M(x, y) is thus a number between x and y; it is also between the geometric and arithmetic mean of x and y.
where K(k) is the complete elliptic integral of the first kind:
Since the arithmetic–geometric process converges so quickly, it provides an efficient way to compute elliptic integrals, which are used, for example, in elliptic filter design.
The arithmetic–geometric mean is connected to the Jacobi theta function
The reciprocal of the arithmetic–geometric mean of 1 and the square root of 2 is Gauss's constant.
In 1799, Gauss proved[note 1] that
) was proved transcendental by Theodor Schneider.
(where the prime denotes the derivative with respect to the second variable) is not algebraically independent over
The geometric–harmonic mean GH can be calculated using analogous sequences of geometric and harmonic means, and in fact GH(x, y) = 1/M(1/x, 1/y) = xy/M(x, y).
The arithmetic–geometric mean can be used to compute – among others – logarithms, complete and incomplete elliptic integrals of the first and second kind,[13] and Jacobi elliptic functions.
[14] The inequality of arithmetic and geometric means implies that
that is, the sequence gn is nondecreasing and bounded above by the larger of x and y.
Changing the variable of integration to
Finally, we obtain the desired result
, which can be computed without loss of precision using
where K(k) is a complete elliptic integral of the first kind:
That is to say that this quarter period may be efficiently computed through the AGM,
Using this property of the AGM along with the ascending transformations of John Landen,[16] Richard P. Brent[17] suggested the first AGM algorithms for the fast evaluation of elementary transcendental functions (ex, cos x, sin x).
Subsequently, many authors went on to study the use of the AGM algorithms.