W Lambert W Function Calculator
Enter x >= -1/e to compute W(x).

The Product Logarithm

The Lambert W function, often called the product logarithm, solves equations of the form wew=x. In other words, Wx is the number w such that wew equals x. This special function appears in combinatorics, delay differential equations, and anywhere an unknown variable occurs both inside and outside an exponential.

Branches and Domain

The equation wew=x generally has two real solutions when x lies between -1e and 0. These are denoted W0 and W-1, representing the principal and lower branches. For x greater than or equal to 0, only the principal branch exists. This calculator focuses on that branch, ensuring a real solution for all x above -1e.

Newton Iteration

The Lambert W function lacks a simple closed form, so numerical methods are typically used. One approach is Newton's method, which refines guesses by iterating

wn+1=wn-wnewn-xewnwn+1

We start with an initial guess like w=\lnx when x is positive. Repeated iterations quickly converge, granting a solution that solves wew=x to high precision.

Why It Matters

The Lambert W function unravels problems that defy elementary algebra. For instance, the solution to yey=a can be written as y=Wa. This makes W valuable in combinatorics for analyzing the growth of trees or networks, and in delay differential equations describing feedback systems.

Worked Example

If x=1, we seek w satisfying wew=1. Newton's method with an initial guess of 0.5 converges to 0.567143. You can verify that 0.567143e0.567143 is indeed very close to 1.

Using This Tool

Type a value for x above and press "Compute". The script performs Newton iterations until the change falls below a small tolerance. Results are rounded to six decimal places for readability. Try values like x=0.1, x=1, or x=-1e to explore the behavior near the branch point.

Related Calculators

Conjugate Gradient Solver - Efficient SPD Linear Systems

Approximate solutions of symmetric positive-definite systems using the conjugate gradient algorithm.

conjugate gradient calculator iterative linear solver SPD matrix

Lagrange Interpolation Calculator - Fit Polynomials to Data Points

Compute the Lagrange interpolating polynomial that passes through a set of points.

Lagrange interpolation calculator polynomial interpolation

Bernoulli Number Calculator - Compute B_n Quickly

Generate Bernoulli numbers using the Akiyama-Tanigawa algorithm.

Bernoulli number calculator special numbers