Note to Macintosh Users: To see this page correctly, you need to change your Font Encodings in Netscape/Explorer to MacRoman
The Applied Mathematics Coffee Mug Design
The Applied Mathematics Coffee Mug Design
Robert M. Corless
Department of Applied Mathematics
University of Western Ontario
http://www.apmaths.uwo.ca/~rcorless/
Rob.Corless@uwo.ca
February, 1998
The design on the Department of Applied Mathematics ``official coffee mug'' is, on one side, the crest of the University of Western Ontario, and on the
other side, the following picture.
FigureThis picture is the image of circles and radial lines under the (conformal) map z ® W(z), where W(z) is
the Lambert W function, which is of surprisingly widespread current interest [1]. This function is the (multivalued) inverse of w ® wexpw,
so it satisfies
Because this is such a simple transcendental equation, it occurs in a very wide variety of applications, from
delay differential equations to the analysis of algorithms. You should plot this function to see its two real branches
(parametrically, with x = wexpw and y = w).
Equivalently, then, this picture is the inverse image of circles and radial lines under the map w ® wexpw.
Parametric Description
The image was constructed by means of a parametric solution. We put
and if w = u + iv, then z = wexp(w) implies
r e^{iq} = (u+iv)e^{u + iv} 
 (2) 
or
u + iv = r e^{u} e^{i(qv)} . 
 (3) 
Separating real and imaginary parts we have
Dividing equation (4) by equation (5) we get, if v ¹ 0,
The case v = 0, which turns out to be an image of 1/e £ z < ¥, is left as an exercise.
Squaring and adding equations (4) and (5), we also get
u^{2} + v^{2} = r^{2} e^{2u} , 

or
v = ± 
æ Ö
 
r^{2} e^{2u}  u^{2}

. 
 (7) 
To plot an image of a radial line, with constant q, we choose a range of values of v and plot
equation (6). To plot an image of a circular arc, with constant r, we choose a range of u
and plot equation (7). This equation is difficult to plot accurately when r^{2}exp(2u) u^{2} is
small, unless a lot of points are used. A superior parametric description of the curve in this region is



 (8)  

tanfW(rcosf) , for p £ f £ p , 
 (9) 
 
 
the derivation of which we leave as an exercise. [Hint: put u = tv for some parameter t,
and then later change parameters to t = cotf.] Interestingly, this makes f the
phase angle in the wplane, since t = u/v. This gives us a nice polar coordinate parameterization:
using u = rcosf, we have
Note that both real branches of W must be used to get
all the lines, either with the parametric or the polar version.
Nothing is perfect, however, and these parameterizations require a lot of points near rcosf = 1/e.
The design on the mug was done by choosing radii of circles, and radial lines, that were spaced widely enough that
the resulting picture was aesthetically pleasing. The most important lines, namely the images of the circle with radius 1/e
and the radial line q = ±p, were naturally included. This gives the crossing at w = 1. At every other point
except w = 0, we have orthogonal crossings; because the branch point for W(z) is a secondorder point, at z = 1/e
or w = 1, the angles of the crossings at w = 1 are ±p/4 or ±45^{°}.
Acknowledgements
The MATLAB program for drawing the picture was written by John Drozd. The main difficulty was in preventing
MATLAB from `connecting the dots' across the singularities in equation (6). This was dealt with by splitting
the picture into pieces with kp < q v < (k+1)p. The difficulty of nearvertical slopes in equation (7)
near the real axis was dealt with by brute force, using a lot of evaluation points.
The idea for an `official coffee mug', and all the necessary arrangments to make it actually happen, are due to
Lindsay Dennison and Peter Poole.
References
 [1]

Robert M. Corless, Gaston H. Gonnet, David E. G. Hare, David J. Jeffrey, and Donald E. Knuth,
``On the Lambert W function'',
Advances in Computational Mathematics, volume 5, 1996, pp. 329359.