LAMBERT W FUNCTION

Added May 15, 2026: Sample problems with solutions provided at end of essay. The Editors

Can anyone calculate by hand (without a calculator) the square root of 5.71 ?  How about the two-dimensional complex number (4 + 2.53 i ) ?  

Of course not. Normal people who are not mathematicians punch these numbers into calculators or math apps on their iPads and computers to calculate the answers.

Without iterating — that is: guessing, deriving a result, and then zeroing in with better guesses) — finding the square root of 5.71 requires knowledge of some arcane mathematics. No one labors by hand to find the answer, which is 2.38956… .  It’s the principal square root, of course. 

How does anyone iterate to derive the square root of the complex number (4 + 2.53 i ), which happens to be (2.0896… + .606375…i ) ?  It is also a principal square root.  What are the others?  Is there more than two? People use calculators and pewters to find out; there is no easier way. 

In high school and basic college math courses, people typically learn to solve algebraic equations. A typical algebraic equation looks like

2x^2=4  …right?

They have polynomials with integer coefficients. The solution is x= \sqrt{2} , which in this case is an algebraic irrational number. Equations like trig and log functions that transcend algebra (called transcendental equations) are taught maybe to engineers and science majors; math majors, of course, don’t struggle with this stuff. It’s why they are math majors.

Several categories of transcendental equations are commonly encountered in the sciences. Many simple problems can be solved by Newton’s Method, which is taught in basic calculus. I won’t explain the method in this essay. Folks can click on links to learn more if they want. 

A category of transcendental equations that can get complicated is of the general form

y = {xe^x}

The biggest problems arise when “y” is known, but “x” isn’t. How to solve for “x”?

Any transcendental equation that is able to be transformed into the form xex can be solved for “x” using the Lambert W function. The equation can be inverted into the form,  x = W(y).  People are going to have to take my word, for now.  

The math behind the Lambert function is mind-bogglingly complicated to most people. The function can sometimes require unusual and involved “series expansions” and transcendental-styled integrals that are not possible to solve easily or quickly without a computer.  

The Lambert W function (sometimes called the omega (ω) function or the product-logarithm function) is not a key or button that can be pushed on most calculators. However, math apps like Wolfram Alpha and Mathematica use it, sometimes to solve transcendental problems in the background when equations that need solving aren’t so easy. 

Omega functions are almost always many valued, because once an equation is inverted there are usually many paths that lead back to the original equation. The useful solution requires picking the principal solution, which is the number identified by subscript 0.

I ran across a transcendental equation on the web that is perfectly suited to teach the “ω” method. Here it is:

\frac{x^3}{24} - ln(x) =0

I want to solve it to demonstrate how to use the ω method for transcendental functions that aren’t otherwise so easy to work out.  I challenge anyone to solve this equation using Newton’s Method or other iterative techniques. Most will struggle to the point of pulling out their hair, probably. And they will waste time. Yes, it can be solved by those techniques. 

We will solve this equation step by step using the Lambert method shortly. Meanwhile, here is the strategy:

1. Substitute an exponent function (et) for “x” everywhere in the expression.

2. Manipulate the equation into the form: 

                    y = e^t(e^{e^t)} 

3. Invert the equation to introduce the ω function. 

4. Use the ω function to solve for “t”.

5. Write out x = et  using the expression derived for “t”.

6. Solve ω(y) using WolframAlpha or any other app with the capability. 

7. Use the value of ω(y) to solve for “x”. 

Each step of the strategy will be identified by numbers 1-7 in the solution below. 

Here’s the thing:

In this problem it turns out that there are four ω values of y, which will generate two real solutions and two complex solutions. These omega values are:

ω0(y)
ω-1(y)
ω2(y)
ω1(y)


Inverting the equation to introduce the omega function creates solution branches, some real, some complex, which are layered sequentially and labeled by integers from minus ∞ to plus ∞.  In the example, real solutions lie on grey and yellow spiral surfaces numbered 0 and -1.  Complex solutions lie on red and green spiral surfaces numbered -2 and 1. Omega subscripts in the list above this graphic identify the spiral layer where the solution for its omega value is located.

WolframAlpha will generate all the solutions automatically; no need for the user to understand anything. People can punch in the original equation and trust the answers the app returns.

But the solution steps that follow are fashioned to demonstrate how the problem is solved when all anyone has is an algorithm to generate the values of the omega functions. Omega functions are difficult to solve without using certain algorithms involving integrals and expansion series on robust computers.

The process that surrounds the computation of omega values, which permit the working out of the appropriate values (the right answers) to the kind of equation I will soon solve is interesting and enlightening, at least for me, and hopefully for certain readers. 

Some folks will appreciate the insights this exercise provides. 

Having knowledge will make the Lambert process that is used to solve certain transcendental functions less mysterious. Of course, one can always take the time to learn the expansion series and integrals. In some cases, Newton’s Method can generate the values.

Unless humankind loses the technology of computers, I don’t think it is a good use of time and resources to learn the series, integrals, and algorithms that generate omega values.

Let’s face an unpleasant fact: most of us aren’t going to live more than 80 years or so. We don’t have time to waste. For some folks, knowing how to use and apply the functionality that surrounds the Lambert function to give it power is enough to make life worth living. Count me in.

No one needs to wade through the jungles of series expansions and transcendental integrals. Let math apps do the tedious work, knowing full well that any interested person can master whatever they choose if necessary, but someone already did the work. Why duplicate the effort?

I want to solve novel functions — complicated formulas that transcend algebra. Understanding the process that solves these equations is fascinating. It’s not as rewarding to tread over mathematically esoteric ground already mapped by experts who are far more able than people who spend most of their time working in other fields.

Here is the solution process:

What we know:

IF              y = f(x) = xex  
THEN     x = ω(y)   [where “ω” is the Lambert W function] 

Solve:
\frac{x^3}{24} - ln(x) =0

LET                  x = et

(1)   THEN         \frac{e^{3t}}{24} - ln(e^t) =0

                              \frac{e^{3t}}{24} - t =0

                              \frac{e^{3t}}{24}  = t

                              (\frac{1}{24})e^{3t} = t

                              \frac{1}{24} = te^{-3t} 

(2)                         (-\frac{1}{8}) = (-3t)e^{-3t} 

Referring to “what we know“, the equation is now in the desired form 

y  =  xe
x  

where “y” is equal to (-\frac{1}{8})   and “x” is equal to “-3t “, right? 

We are now free to use the omega operator to “invert” the equation into the following form:  x = ω(y)

(3)                         (-3t) = ω (-\frac{1}{8})

(4)                   t = (\frac{-\omega(-\frac{1}{8})}{3})

Notice that we have worked through step (4) of the strategy.  I don’t like the way the formula generator writes the Greek letter omega (ω), because it’s hard to read. From here on, I will sometimes use “W” instead of “ω” for readability. It shouldn’t confuse anyone.  In this essay, consider W and ω the same symbol, please. 

On to step (5).

SINCE                           x = et

(5)  THEN                    x = e^{(\frac{-W(-\frac{1}{8})}{3})}

I need to know what 0(-1/8) equals so that I can use it to compute one of the values of “x”.  As mentioned above, three more omegas with three other subscripts (-1, -2, and 1) are needed to compute all four of the solutions to this equation.

How does anyone know how many solutions the original function has? How does anyone know what subscripts are required? 

This is where someone who doesn’t have a masters degree in mathematics  needs a math app like Wolfram Alpha or its cousin, Mathematica. Otherwise, they have to work series expansions or difficult integrals to derive the omega values associated with (-1/8).  Who wants that?  Not me. 


Here’s the series expansion for ω0(-1/8) according to Wolfram Alpha. Who wants to compute it?

Here are two integrals for ω0(-1/8). My advice is to use the second integral, anyone who has the guts.

OK. In WolframAlpha, you get the omega value ω0 for (-1/8) by writing the expression -W[0,-1/8] in the input line at the top of the page. It shoots out the answer and links to its derivation.

It’s so simple. Other math apps might use different notation. I don’t know, because I don’t use other apps. 

Inside the brackets, the “0” is the subscript on ω, and the “-1/8” is the “y” value, right?  So, in addition to -W[0,-1/8]  it is necessary to input:   
-W[-1,-1/8] 
-W[-2,-1/8] 
-W[1,-1/8]
to obtain the three other omega values, right?

The omega values returned are the following:

1.4442135…
3.2616856…

4.21446… + 7.33231…i
4.21446… – 7.33231…i

The ω function values for -1/8 are two real numbers and two complex numbers. I am going to solve the original equation for only the first real number omega value to demonstrate the method.

Here it is:

INPUT                                       -W(-1/8) or -W[0,-1/8], both work for ω0

(6)  OUTPUT                          +0.14442135…

COMPUTE                              t =  (\frac{-W(-\frac{1}{8})}{3})

                                                      t = \frac{1.4442135}{3} = .04814…

SINCE                                       x = et

THEN                                        x = e.04814…

 (7)  SOLUTION                    x = 1.04931755…

CHECKING                             \frac{x^3}{24} - ln(x) =0

BY SUBSTITUTION          \frac{1.0493...^3}{24} - ln(1.0493...) = 0

VERIFICATION                     .04814… – .04814… = 0

CONCLUSION:  The transcendental equation which is the focus of this essay can easily be solved and verified by simply punching the equation into the input field of a math app like Wolfram Alpha or Mathematica and reading off the answers.

We didn’t perform the simple procedure, because I wanted to share how the Lambert W function fits into the solution process for solving equations. 

In truth, all four ω values must be gathered so that the three other “x” values of the original equation can be derived. 

In this example, one of the other solutions will be real; the other two, complex. The screenshot below from Wolfram Alpha demonstrates how these four values are displayed. Of course, by clicking links the app will reveal much more.

Wolfram Alpha enables users to input transcendental equations and quickly view answer-sets and methods of computation.

I would be remiss to not mention a famous formula for calculating to what number a fraction raised to successive powers of the same fraction converges.

(The range of numbers where this formula actually works is between e−e and e1/e,  that is, between .065988… and 1.444667861… .)

Take a number like ½ (0.5).  Raise it to the 0.5 power; raise it again and again to the same power over and over an infinite number of times; the number will converge to a specific value.

What number? How in the world could anyone figure it out without repeating the power-raising process an annoying number of times? 

It turns out that a formula involving the Lambert W Function yields up the answer easily. 

The formula is:

# = \frac {-W[0,(-ln(x)]}{ln(x)}

Put the following expression into the INPUT line of WolframAlpha: 

-W[0,-ln(.5)] / [ln(.5)]

Click ” = ” — or hit “ENTER”. 

The OUTPUT is: 0.6411857445049859844862…

Compare this result by taking the exponent (0.5) of 0.5 twenty times by hand (on a calculator). The answers will agree to 7 decimal places. Fifty “tetrations” will bring greater agreement if your calculator can parse the answer.

Who has the time?  

Billy Lee

NOTE from the EDITORIAL BOARD: Billy Lee was unable to find an appropriate video about the Lambert function on YouTube, or we would have posted it. Most folks capitalize the Greek letter omega (Ω), but in this essay, Billy Lee didn’t, preferring instead to use little (ω), because it looks more like (W).

Who on the BOARD  would dare argue?

Apparently, no one. 

Another reason is that Ω is sometimes given the value 0.567143… , which is known as the omega constant. Why confuse things?

The video above starts a discussion of the Ω function at 16:30.  The Lambert W function is derived for ΩeΩ  = 1  at 18:00.  The first sixteen minutes and thirty seconds show how to use Newton’s Method to solve the equation. Some readers might want to skip the first 16 minutes; others will enjoy them.

Who knows?


ADDED April 25, 2026

Recently Facebook, in its feed, published math puzzles like this one:

xx = 9

What does “x” equal?

X is exponent in transcendental equations like these, which are easily solved using Lambert. 

xx = 9

x ln x = ln 9

LET  x = et

SUBSTITUTING   eln et = ln 9   {~2.1972, right?}

THEREFORE   et t = 2.1972

 OR  t et = 2.1972

LAMBERT SAYS   t = W [0, 2.1972]

ENTER  W [0, 2.1972] into Wolfram Alpha to get ~.8965

t = .8965, right?

BUT  x = et

THEREFORE  x = e.8965 = ~2.7183.8965 = 2.451

ANSWER  x = 2.451

CHECK  xx = 2.4512.451 = 9

QED


Here’s another cool problem. What does k equal?

49 = k14

k ln 49 = 14 ln k

k ln 72 = 14 ln k

2k ln 7 = 14 ln k

\frac{2k ln 7}{14} = ln k

\frac{k ln 7}{7} = ln k

LET k = ex

ex \frac{ln 7}{7} = ln ex

e \frac{ln 7}{7} = x

e = x \frac{7}{ln 7}

1 = x / ex  \frac{7}{ln 7}

-1 = -x e-x \frac{7}{ln 7}

\frac{-ln 7}{7} = -x e-x

LET -x = t

\frac{-ln 7}{7} = t et

equation is now in correct form. 

t = W \frac{-ln 7}{7}

PUT W[0, \frac{-ln 7}{7}] INTO WOLFRAM ALPHA

t = -.42536…

BUT x = -t

x = .42536…

BUT k = ex

 THEREFORE  k = e .42536

ANSWER  k = 1.53014

CHECK   49 1.53014 = 1.53014 14

385.688… = 385.688…

QED

Should be mentioned that there are many solutions to this equation as anyone would assume after reading essay above. Wolfram will provide them. However, an integer answer exists that can be solved by inspection. 

k ln 49 = 14 ln k

Make the base 49 to make ln 49 disappear.

k ln49 49 = 14 ln49 k

k = 14 ln49 k

Since by definition logs are exponents acting on a base (in this case 49), a sharp-eyed reader might notice that base 49 is the square of the number 7.  The square root of a number is its 1/2 power, right?

491/2 = 7

IF   ln k = 1/2

THEN   14 * 1/2 =7 = k

ANSWER   k = 7

CHECK  49= 714 = 6.78223…E11

QED


Billy Lee

 

WHAT IS e exp (-i π) ?

What is e^{-i\pi} ?

I posted a long answer on Quora.com where it sort of didn’t do well.

Answers given by others were much shorter but they seemed, at least to me, to lack geometric insights. After two days my answer was ranked as the most read, but for some reason no one upvoted it. It did receive a few positive replies though.

I can’t help but believe that there must be nerds in cyberspace who might enjoy my answer. Why not post it on my blog? Maybe someday one of my grandkids will get interested in math and read it.

Who knows?

Anyway, below is a pic and a working GIF, which should help folks understand better. Anyone who doesn’t understand something can always click on a link for more information. 

Here is the drawing I added and the answer:


This diagram is excellent but contains a mystery point not on the unit circle — {i^i}. The point is shown at .2078… on the real number line.  An imaginary number raised to the power of an imaginary number yields a result that is a real number. How can that be? It’s something to ponder; something to think about. The Editorial Board 

What is e^{-i\pi} ?

The expression evaluates to minus one; the answer is (-1). Why?

Numbers like these are called complex numbers. They are two-dimensional numbers that can be drawn on graph-paper instead of on a one-dimensional number line, like the counting numbers. They are used to analyze wave functions — i.e. phenomenon that are repetitive — like alternating current in the field of electrical engineering, for example.


A simplified explanation of {i^i} starts at 02:30.


“e” is a number that cannot be written as a fraction (or a ratio of whole numbers). It is an irrational number (like π, for instance). It can be approximated by adding up an arbitrary number of terms in a certain infinite series to reach whatever level of precision one wants. To work with “e” in practical problems, it must be rounded off to some convenient number of decimal places.

Punch “e” into a calculator and it returns the value 2.7182…. The beauty of working with “e” is that derivatives and integrals of functions based on exponential powers of “e” are easy to calculate. Both the integral and the derivative of e is ex  — a happy circumstance that makes the number “e” unusually curious and extraordinarily useful in every discipline where calculus is necessary for analysis. 

What is “e” raised to the power of (-iπ) ?



A wonderful feature of the mathematics of complex numbers is that all the values of expressions that involve the number “e” raised to the power of “i” times anything lie on the edge (or perimeter) of a circle of radius 1. This feature makes understanding the expressions easy.

I should mention that any point in the complex plane can be reached by adding a number in front of e^{i\theta} to stretch or shrink the unit circle of values. We aren’t going to go there. In this essay “e” is always preceded by the number “one“, which by convention is never shown.

The number next to the letter “i” is simply the angle in radians where the answer lies on the circle. What is a radian?  It’s the radius of the circle, of course, which in a unit circle is always “one”, right? 

Wrap that distance around the circle starting at the right and working counter-clockwise to the left. Draw a line from the center of the circle at the angle (the number of radius pieces) specified in the exponent of “e” and it will intersect the circle at the value of the expression. What could be easier?

For the particular question we are struggling to answer, the number in the exponent next to “i” is (-π), correct?

“π radians” is 3.14159… radius pieces — or 180° — right? The minus sign is simply a direction indicator that in this case tells us to move clockwise around the unit circle — instead of counter-clockwise were the sign positive.

After drawing a unit circle on graph paper, place your pencil at (1 + 0i)—located at zero radians (or zero degrees) — and trace 180° clockwise around the circle. Remember that the circle’s radius is one and its center is located at zero, which in two dimensional, complex space is (0 + 0i). You will end up at the value (-1 + 0i) on the opposite side of the circle, which is the answer, by the way.

[Trace the diagram several paragraphs above with your finger if you don’t have graph paper and a pencil. No worries.]

Notice that +π radians takes you to the same place as -π radians, right?  Counter clockwise or clockwise, the value you will land on is (-1 + 0i), which is -1. The answer is minus one.

Imagine that the number next to “i” is (π/2) radians (1.57… radius pieces). That’s 90°, agreed? The sign is positive, so trace the circle 90° counter-clockwise. You end at (0 + i), which is straight up. “i” in this case is a distance of one unit upward from the horizontal number line, so write the number as (0 + i) — zero distance in the horizontal direction and “plus one” distance in the “i” (or vertical) direction.

So, the “i” in the exponent of “e” says to “look here” to find the angle where the value of the answer lies on the unit circle; on the other hand, the “i” in the rectangular coordinates of a two-dimensional number like (0 + i) says “look here” to find the vertical distance above or below the horizontal number line.

When evaluating “e” raised to the power of “i” times anything, the angle next to “i”—call it “θ”—can be transformed into rectangular coordinates by using this expression: [cos(θ) + i sin(θ)].

For example: say that the exponent of “e” is i(π/3).  (π/3) radians (1.047… radius pieces) wraps around the circumference to 60°, right? The cosine of 60° is 0.5 and the sine of 60° is .866….

So the value of “e” raised to the power of i(π/3) is by substitution (0.5 + .866… i ). It is a two-dimensional number. And it lies on the unit circle.

The bigger the exponent on “e” the more times someone will have to trace around the circle to land at the answer. But they never leave the circle. The result is always found on the circle between 0 and 2π radians (or 0° and 360°) no matter how large the exponent.

It’s why these expressions involving “e” and “i” are ideal for working with repetitive, sinusoidal (wave-like) phenomenon.


In this essay Billy Lee uses θ in place of the Greek letter φ shown in this GIF.  Remember that ”r” equals ”one” in a unit circle, so it’s typically not shown. The Editorial Board

In case some readers are still wondering about what radians are, let’s review:

A radian is the radius of a circle, which can be lifted and bent to fit perfectly on the edge of the circle. It takes a little more than three radius pieces (3.14159… to be more precise) to wrap from zero degrees to half-way around any circle of any size. This number — 3.14159… — is the number called “π”.   2π radians are a little bit more than six-and-a-quarter radians (radius pieces), which will completely span the perimeter (or circumference) of a circle.

A radian is about 57.3° of arc. Multiply 3.1416 by 57.3° to see how close to 180° it is. I get 180.01… . The result is really close to 180° considering that both numbers are irrational and rounded off to only a few decimal places.

One of the rules of working with complex numbers is this: multiplying any number by “i” rotates that number by 90°. The number “i” is always located at 90° on the unit circle by definition, right? By the rule, multiplying “i” by “i” rotates it another 90° counter-clockwise, which moves it to 180° on the circle.

180° on the unit circle is the point (-1 + 0i), which is minus one, right?

So yes, absolutely, “i” times “i” is equal to -1.  It follows that the square root of minus one must be “i”. Thought of in this way, the square root of a minus one isn’t mysterious.

It is helpful to think of complex numbers as two dimensional numbers with real and imaginary components. There is nothing imaginary, though, about the vertical component of a two-dimensional number.

The people who came up with these numbers thought they were imagining things. The idea that two-dimensional numbers can exist on a plane was too radical at the time for anyone to believe.  Numbers, they believed, only existed on a one-dimensional number line of one dimension and no place else.

Of course they were mistaken.  Numbers can live in two, three, or even more dimensions. They can be as multi-dimensional as needed to solve whatever the mysteries of mathematical analysis might require.

Click the link, “What is Math?” for another explanation.

Billy Lee