Oh. I looked at the lowercase l's in dir(), so I didn't see it. It would be great if solve(x*exp(x)-y,x) returned LambertW(y) (now it raises NotImplemented), and then we could expand it to solve the equation below.
Aaron Meurer On Jun 24, 2009, at 12:54 PM, Ondrej Certik wrote: > > On Wed, Jun 24, 2009 at 12:51 PM, Aaron S. > Meurer<[email protected]> wrote: >> >> Or you could use the LambertW function. Maple gives >> > solve(exp(x*(x-3))=2*(x-1)*(x-2),x); >> 3/2+(1/2)*sqrt(1-4*LambertW(-(1/2)*exp(-2))), 3/2- >> (1/2)*sqrt(1-4*LambertW(-(1/2)*exp(-2))), >> 3/2+(1/2)*sqrt(1-4*LambertW(-1, -(1/2)*exp(-2))), 3/2- >> (1/2)*sqrt(1-4*LambertW(-1, -(1/2)*exp(-2))) >> >> from ?LambertW: >> >> •The LambertW function satisfies >> LambertW(x) * exp(LambertW(x)) = x . >> •As the equation y exp(y) = x has an infinite number of solutions y >> for each (non-zero) value of x, LambertW has an infinite number of >> branches. Exactly one of these branches is analytic at 0. In Maple >> this branch is referred to as the principal branch of LambertW, and >> is >> denoted by LambertW(x). The other branches all have a branch point at >> 0, and these branches are denoted in Maple by LambertW(k, x), where k >> is any non-zero integer. (The principal branch can also be referred >> to >> as LambertW(0, x)). >> See also http://en.wikipedia.org/wiki/Lambertw >> >> I am surprized that mathematica does not use it. >> >> It doesn't look like SymPy has the LambertW function, unless I am >> missing it. > > Just do: > > In [1]: LambertW? > > > Ondrej > > > --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "sympy" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/sympy?hl=en -~----------~----~----~----~------~----~------~--~---
