Assumptions:n∈Z≥1
References:
- R. Brent and F. Johansson. A bound for the error term in the Brent-McMillan algorithm. Mathematics of Computation 2015, 84(295). DOI: 10.1090/S0025-5718-2015-02931-7
TeX:
\left|\gamma - \left(\frac{S}{I} - \frac{T}{{I}^{2}} - \log(n)\right)\right| < 24 {e}^{-8 n}\; \text{ where } \left(S, I, T\right) = \left(\sum_{k=0}^{5 n} \frac{H_{k} {n}^{2 k}}{{\left(k !\right)}^{2}}, \sum_{k=0}^{5 n} \frac{{n}^{2 k}}{{\left(k !\right)}^{2}}, \frac{1}{4 n} \sum_{k=0}^{2 n - 1} \frac{{\left(\left(2 k\right)!\right)}^{3}}{{\left(k !\right)}^{4} \cdot {8}^{2 k} {\left(2 n\right)}^{2 k}}\right)
n \in \mathbb{Z}_{\ge 1}
Definitions:
Fungrim symbol | Notation | Short description |
---|
Abs | ∣z∣
| Absolute value |
ConstGamma | γ
| The constant gamma (0.577...) |
Pow | ab
| Power |
Log | log(z)
| Natural logarithm |
Exp | ez
| Exponential function |
Sum | ∑nf(n)
| Sum |
Factorial | n!
| Factorial |
ZZGreaterEqual | Z≥n
| Integers greater than or equal to n |
Source code for this entry:
Entry(ID("014c4e"),
Formula(Where(Less(Abs(Sub(ConstGamma, Sub(Sub(Div(S, I), Div(T, Pow(I, 2))), Log(n)))), Mul(24, Exp(Neg(Mul(8, n))))), Equal(Tuple(S, I, T), Tuple(Sum(Div(Mul(HarmonicNumber(k), Pow(n, Mul(2, k))), Pow(Factorial(k), 2)), For(k, 0, Mul(5, n))), Sum(Div(Pow(n, Mul(2, k)), Pow(Factorial(k), 2)), For(k, 0, Mul(5, n))), Mul(Div(1, Mul(4, n)), Sum(Div(Pow(Factorial(Mul(2, k)), 3), Mul(Mul(Pow(Factorial(k), 4), Pow(8, Mul(2, k))), Pow(Mul(2, n), Mul(2, k)))), For(k, 0, Sub(Mul(2, n), 1)))))))),
Variables(n),
Assumptions(Element(n, ZZGreaterEqual(1))),
References("R. Brent and F. Johansson. A bound for the error term in the Brent-McMillan algorithm. Mathematics of Computation 2015, 84(295). DOI: 10.1090/S0025-5718-2015-02931-7"))