Skip to content

LogBarnesG ​

The logarithm of the Barnes G-function, ln⁡G(z)\ln G(z), as an analytic continuation — the form that stays finite where GG itself overflows.

✓ checked against that system · ! checked, with disagreements (hover a chip)WikipediaBarnes G-functionMathWorldBarnesG-FunctionWikidataQ808463DLMF5.17FungrimLogBarnesG✓Fungrim entryWolfram LanguageLogBarnesG!
LogBarnesG(z)the log-Barnes function ln⁡G(z)\ln G(z), analytically continued.
Juliaenumeratio_ball(log_barnes_g, z)
Typed signatures
TypePackageApplies
(complex | infinity) -> numberanalyticreplaces compute-enginealways
(complex | infinity) -> numbercompute-enginealways

Domain: Special functions

Details
  • ln⁡G(z+1)∼(z22−112)ln⁡z−3z24+z2ln⁡2π+ζ′(−1)+∑k≥1B2k+24k(k+1) z2k\ln G(z+1) \sim \left(\tfrac{z^2}{2} - \tfrac{1}{12}\right)\ln z - \tfrac{3z^2}{4} + \tfrac{z}{2}\ln 2\pi + \zeta'(-1) + \sum_{k\ge1} \dfrac{B_{2k+2}}{4k(k+1)\,z^{2k}} as Re⁡(z)→∞\operatorname{Re}(z) \to \infty, with ζ′(−1)=112−ln⁡A\zeta'(-1) = \tfrac{1}{12} - \ln A (AA Glaisher's constant). This is the numeric kernel, reached through ln⁡G(z)=ln⁡G(z+n)−∑k<nln⁡Γ(z+k)\ln G(z) = \ln G(z+n) - \sum_{k<n} \ln\Gamma(z+k).
  • It is the continuation, not ln⁡\ln of the value: on the negative real axis its imaginary part is a multiple of π\pi fixed by continuity from above, so LogBarnesG(−2.5)=−2.5747…+6πi\mathrm{LogBarnesG}(-2.5) = -2.5747\ldots + 6\pi i while ln⁡G(−2.5)\ln G(-2.5) taken literally would be real. This matches Wolfram's LogBarnesG\mathrm{LogBarnesG}.
  • At positive integers it reduces through the exact superfactorial: ln⁡G(4)=ln⁡2\ln G(4) = \ln 2, ln⁡G(3)=0\ln G(3) = 0.
  • −∞-\infty at the nonpositive integers, where GG vanishes.

Plot

ComplexPlot
real slice

Examples

2 more kept as data, checked against the oracles
Basic #

ln⁡G(4)=ln⁡2\ln G(4) = \ln 2

live ↗
InLogBarnesG(4)\mathrm{LogBarnesG}(4)Outln⁡(2)\ln(2)

ln⁡G(3)=ln⁡1=0\ln G(3) = \ln 1 = 0

live ↗
InLogBarnesG(3)\mathrm{LogBarnesG}(3)Out00

Numeric for a floating-point argument

live ↗
InLogBarnesG(10.5)\mathrm{LogBarnesG}(10.5)Out42.278 883 636 795 242.278\,883\,636\,795\,2

ln⁡G(12)\ln G(\tfrac12)

live ↗
InLogBarnesG(0.5)\mathrm{LogBarnesG}(0.5)Out−0.505 433 054 489 458 3-0.505\,433\,054\,489\,458\,3

ln⁡G(0.7)\ln G(0.7) — negative, since G<1G < 1 on (0,1)(0, 1)

live ↗
InLogBarnesG(0.7)\mathrm{LogBarnesG}(0.7)Out−0.214 589 897 075 086 36-0.214\,589\,897\,075\,086\,36
Scope #

Complex arguments

live ↗
InLogBarnesG(1.7+i)\mathrm{LogBarnesG}(1.7+i)Out0.121 378 662 628 899 29−0.313 561 761 336 856 65i0.121\,378\,662\,628\,899\,29-0.313\,561\,761\,336\,856\,65i

Threads elementwise over an array: −∞-\infty at the zeros of GG

live ↗
InLogBarnesG([[4,−1],[0,3]])\mathrm{LogBarnesG}(\bigl\lbrack\bigl\lbrack4, -1\bigr\rbrack, \bigl\lbrack0, 3\bigr\rbrack\bigr\rbrack)Out[[ln⁡(2),−∞],[−∞,0]]\bigl\lbrack\bigl\lbrack\ln(2), -∞\bigr\rbrack, \bigl\lbrack-∞, 0\bigr\rbrack\bigr\rbrack

Huge arguments, straight from the asymptotic series: ln⁡G(101000)≈1.1505×102003\ln G(10^{1000}) \approx 1.1505\times10^{2003}

live ↗
InN(LogBarnesG(101 000))N(\mathrm{LogBarnesG}(10^{1\,000}))Out1.150 542 546 497 022 842 01⋅1020031.150\,542\,546\,497\,022\,842\,01\cdot10^{2003}

Interval arithmetic over an increasing stretch, proven by the certified derivative

live ↗
InLogBarnesG(Interval(0.111,0.112))\mathrm{LogBarnesG}(\mathrm{Interval}(0.111, 0.112))OutInterval(−2.106 284 277 112 4,−2.096 646 198 881 46)\mathrm{Interval}(-2.106\,284\,277\,112\,4, -2.096\,646\,198\,881\,46)

Uncertainty propagation through ln⁡G\ln G

live ↗
InLogBarnesG(Around(1.2,0.01))\mathrm{LogBarnesG}(\mathrm{Around}(1.2, 0.01))OutAround(0.056 208 855 599 105 68,0.001 611 305 538 862 350 7)\mathrm{Around}(0.056\,208\,855\,599\,105\,68, 0.001\,611\,305\,538\,862\,350\,7)

ln⁡G(∞)=∞\ln G(\infty) = \infty

live ↗
InLogBarnesG(∞)\mathrm{LogBarnesG}(∞)Out∞∞
Properties #

G(0)=0G(0) = 0, so its logarithm is −∞-\infty

live ↗
InLogBarnesG(0)\mathrm{LogBarnesG}(0)Out−∞-∞

Exact at the integers: ln⁡G(10)=ln⁡5056584744960000\ln G(10) = \ln 5056584744960000, split into logarithms of its factors

live ↗
InLogBarnesG(10)\mathrm{LogBarnesG}(10)Out2ln⁡(14)+3ln⁡(10)+9ln⁡(3)+18ln⁡(2)+ln⁡(5)2\ln(14)+3\ln(10)+9\ln(3)+18\ln(2)+\ln(5)
Possible issues #

The continuation, not ln⁡\ln of the value: G(−2.5)>0G(-2.5) > 0, yet the imaginary part is 6π6\pi

live ↗
InLogBarnesG(−2.5)\mathrm{LogBarnesG}(-2.5)Out−2.574 748 476 853 131+18.849 555 921 538 76i-2.574\,748\,476\,853\,131+18.849\,555\,921\,538\,76i
About
Examples16
Checked againstWolfram Language 12 agree4 differJulia 9 agree3 error
CrosswalkWikipediaMathWorldWikidataDLMFFungrimFungrim entry ×18Wolfram LanguageJulia

Implementation

referenceenginenotatio

The Weierstrass product in logarithms. Its terms are O(w³/k²), so it converges — slowly: a few hundred terms for a dozen digits, against the kernel's asymptotic series.

nativeenginetypescriptpackages/ce-patches/src/compute-engine/numerics/barnes-g.ts
mappedjuliapackages/oracle/src/mappings.ts

See also: BarnesG, LogGamma, Gamma