factory-0.3.0.0: Rational arithmetic in an irrational world.

Factory.Math.ArithmeticGeometricMean

Description

AUTHOR
Dr. Alistair Ward
DESCRIPTION
Determines the Arithmetic-geometric mean; https://en.wikipedia.org/wiki/Arithmetic-geometric_mean.

Synopsis

# Types

## Type-synonyms

The type of the arithmetic mean; https://en.wikipedia.org/wiki/Arithmetic_mean.

The type of the geometric mean; https://en.wikipedia.org/wiki/Geometric_mean.

Encapsulates both arithmetic and geometric means.

# Functions

convergeToAGM :: Algorithmic squareRootAlgorithm => squareRootAlgorithm -> DecimalDigits -> AGM -> [AGM] Source #

Returns an infinite list which converges on the Arithmetic-geometric mean.

Returns the bounds within which the AGM has been constrained.

Accessor.

Accessor.

## Predicates

Checks that both means are positive, as required for the geometric mean to be consistently real.