FLINT3.7.0-dev

arb_lambertw

Synopsis#include <flint/arb.h>
void arb_lambertw(arb_t res, const arb_t x, int flags, slong prec)source

Sets res to the Lambert W function, the solution ww of wew=xw e^w = x: the principal branch W0W_0 if flags is 0, and the branch W−1W_{-1} if flags is 1.

W0W_0 is real for x≥−1/ex \ge -1/e, with values in [−1,+∞)[-1, +\infty), and W−1W_{-1} is real for −1/e≤x<0-1/e \le x < 0, with values in (−∞,−1](-\infty, -1]. Elsewhere the function is complex; use acb_lambertw. The algorithm computes a floating-point approximation heuristically and then certifies an enclosure around it, with special code for asymptotic cases; it is described in [Joh2017b] and follows [CGHJK1996]. See also The Lambert W function.

References#

  • [Joh2017b] F. Johansson, "Computing the Lambert W function in arbitrary-precision complex interval arithmetic", preprint (2017), https://arxiv.org/abs/1705.03266
  • [CGHJK1996] R. M. Corless, G. H. Gonnet, D. E. Hare, D. J. Jeffrey and D. E. Knuth, "On the Lambert W function", Advances in Computational Mathematics, 5(1) (1996), 329-359
Cite this page

The FLINT team, “arb_lambertw (arb.h),” FLINT: Fast Library for Number Theory, documentation, version 3.7.0-dev, 2026. https://flintlib.org/doc/arb/arb_lambertw.html (generated 2026-11-02).