COMPLEX ANALYSIS: Mathematica 4.1 Notebooks
(c) John H. Mathews, and
Russell W. Howell, 2002
Complimentary software to accompany our textbook:

COMPLEX ANALYSIS: for Mathematics and Engineering, 
4th Edition,  2001,  ISBN: 0-7637-1425-9
Jones & Bartlett Publishers, Inc.  
40 Tall Pine Drive, Sudbury, MA 01776  
Tele.  (800) 832-0034, FAX:  (508)  443-8000  
E-mail:  mkt@jbpub.com  
Internet:  http://www.jbpub.com/  
This free software is compliments of the authors.
John H. Mathews,   mathews@fullerton.edu 
Russell W. Howell,  howell@westmont.edu

CHAPTER 10  APPLICATIONS of HARMONIC FUNCTIONS

a = A = b = B = c = k = R = T = u = U = v = V = w = W = x = X = y = Y = z = Z = 
                                        0; 
Clear[a, a0, a1, a2, a3, A, b, B, 
        CR, Δx, Δy, eq1, eq2, eqns, f, f1, F, F1, 
        F2, F3, F4, g, G, lines, n, P, Ψ, ϕ, Φ, 
        r, r0, solset, θ, t, T, T1, T2, Q, u, u0, U, U1, v, v0, V, V1, 
        w, w0, W, W1, x, x1, x2, x3, y, z, z1, z2, z3, 
        z4]; 
Needs["Graphics`ComplexMap`"]; 
Needs["Graphics`ParametricPlot3D`"]
Needs["Graphics`Colors`"];

Section 10.1	Preliminaries

Section 10.2	Invariance of Laplace's Equation and the Dirichlet Problem

Section 10.3	Poisson's Integral Formula for the Upper Half Plane

Section 10.4	Two Dimensional Mathematical Models

Section 10.5	Steady State Temperatures

Section 10.6	Two-Dimensional Electrostatics

Section 10.7	Two-Dimensional Fluid Flow

Section 10.8	The Joukowski Airfoil

Section 10.9  Schwarz-Christoffel Transformation

To proceed further, we must review the rotational effect of a conformal mapping w=f(z) at a point (Subscript[z, 0]).

Many applications involving conformal mappings require the construction of a one-to-one conformal mapping from the upper half plane  Im (z) > 0  onto a domain  G  in the w-plane where the boundary consists of straight line segments.  Let us consider the case where  G  is the interior of a polygon  P  with vertices  (Subscript[w, 1]), (Subscript[w, 2]),  ... , (Subscript[w, n])  specified in the positive (counterclockwise) sense.  We want to find a function  w = f (z)  with the property  

	(Subscript[w, k]) = f ((Subscript[x, n]))  for  k = 1, 2,  ... , n - 1, and  

	(Subscript[w, n]) = f (∞)  where (Subscript[x, 1]) < (Subscript[x, 2]) <  ...  < 
          (Subscript[x, n - 1]) < ∞.  

Two German mathematicians Herman Amandus Schwarz (1843-1921) and Elwin Bruno Christoffel (1829-1900) independently discovered a method for finding f, and that is our next theorem.

Theorem 10.6 (Schwarz-Christoffel Formula), Page 455. Let P be a polygon in the w plane with vertices (Subscript[w, 1]),(Subscript[w, 2]),⋯,(Subscript[w, n]) and exterior angles  (Subscript[α, 1]),(Subscript[α, 2]),⋯,(Subscript[α, n]), where -π<(Subscript[α, k])<π,  for  k = 1, 2, ⋯, n.  There exists a one-to-one conformal mapping  w = f (z)  from the upper half plane Im (z) > 0  onto  G  that satisfies the boundary conditions  

	(Subscript[w, k]) = f ((Subscript[x, k]))   for   k = 1, 2, , 
      n - 1    and
(Subscript[w, n])=f(∞)     where   (Subscript[x, 1])<(Subscript[x, 2])<⋯<(Subscript[x, n - 1])<∞.  

The derivative is   

	f'(z)= \(A \(\((z - x\_1)\)\^\(\(-α\_1\)/π\)\) \(\((z - 
                  x\_2)\)\^\(\(-α\_2\)/π\)\) ⋯ \((z - x\_\(n - 1\))\)\^\(\(-α\_\(n - 1\)\)/π\)\)  

and the function  f(z)  can be expressed as an indefinite integral,  

	f (z)=B+A∫\(\(\((z - 
                        x\_1)\)\^\(\(-α\_1\)/π\)\) \(\((z - 
                        x\_2)\)\^\(\(-α\_2\)/π\)\) ⋯ \(\((z - 
                        x\_\(n - 1\))\)\^\(\(-α\_\(n - 1\)\)/π\)\) dz\) 

where  A  and  B  are suitably chosen constants.  Two of the points  {(Subscript[x, k])}  may be chosen arbitrarily, and the constants  A  and  B  determine the size and position of  P.

Proof of Theorem 10.6, see text Page 455.

Example 10.26,  Page 457.  Use the Schwarz Christoffel formula to verify that  w = Arcsin(z)  maps the upper half plane  Im[z] > 0  onto the semi infinite strip  ((-π)/2) < u < (π/2),  v > 0.

Solution 10.26.

Enter the formula f'[z] = (( A)/(Sqrt[(z^2)  -  1])) and integrate it to construct  f(z).

Remove[A, B, z]; 
Clear[f, f1]; 
f1[z_]  = (( A)/(Sqrt[(z^2)  -  1])); 
f[z_]  =  
        B  +  ∫(( A)/(Sqrt[(z^2)  -  1])) \[DifferentialD]z; 
Print["f'[z] = ", f1[z]]; 
Print[""]; 
Print[" f[z] = B + ∫ ", 
        f1[z], " \[DifferentialD]z"]; 
Print[""]; 
Print[" f[z] = ", f[z]];

Remark.   No matter how tempting the integrand  B + A Log[z + (Sqrt[-1 + (z^2)])]  may seem, the logarithm does not have the proper branch cut for this problem, and we must use the familiar integrand  B  +  A  ArcSin[z].  Switching the order of terms in the square root will solve this problem.

Clear[eq1, eq2, f, f1, F]; 
f1[z_]  =  (A/(Sqrt[1  -  (z^2)])); 
F[z_]  =  
        B  +  ∫(A/(Sqrt[1  -  (z^2)])) \[DifferentialD]z; 
Print["f'[z] = ", f1[z]]; 
Print[""]; 
Print[" f[z] = B + ∫ ", 
        f1[z], " \[DifferentialD]z"]; 
Print[""]; 
Print[" f[z] = ", F[z]];

Now solve for the coefficients  A  and  B.

\(
\(eq1\  = \ 
        F[\(-1\)]\  == \(\(\ \)\(-π\)\)\/2;\)\ \)
eq2  =  F[1]  ==   (π/2); 
solset  =  Solve[{eq1, eq2}, {A, B}]; 
f[z_]  =  
        ReplaceAll[F[z], 
          (Subscript[solset, [[1]]])]; 
Print[eq1]; 
Print[eq2]; 
Print[
        (Subscript[solset, [[1]]])]; 
Print[""]; 
Print["f[z] = B + A ArcSin[z]"]; 
Print[""]; 
Print["f[z] = ", f[z]];

Use Mathematica to graph conformal mapping  w = f(z).

CartesianMap[
        f, {-2, 2, 0.25}, {0.000001, 4.000001, 
          0.25}, 
Ticks -> {Range[-1, 1, 1], 
            Range[0, 2, 1]}, AxesLabel -> {"u", "v"}, 
        PlotStyle -> {DarkGreen, 
            Green}];  
Print["The image of the upper half plane Im[z] > 0,"]; 
\(\(Print[\*""is the semi infinite strip ((-π)/2)< u < (π/2), v > 0,""];\)\ \)
Print["where  w = f[z] = ", f[z]];

We see that  w = Arcsin(z)  maps the upper half plane  Im[z] > 0  onto the semi infinite strip  ((-π)/2) < u < (π/2),  v > 0.

Example 10.27,  Page 458.  Use the Schwarz Christoffel formula to verify that  w = (Sqrt[(z^2) - 1])  maps the upper half plane  Im[z] > 0  onto the upper half plane  Im[w] > 0  slit along the line segment from  w = 0  to  (Subscript[w, 2]) = i .

Solution 10.27.

Enter the formula f'[
          z] = (( A z)/((Sqrt[z  +  1]) (Sqrt[z  -  1]))) and integrate it to construct  f(z).

Remove[A, B, z]; 
Clear[f1, F]; 
f1[
          z_]  = (( A z)/((Sqrt[z  +  1]) (Sqrt[z  -  1]))); 
f[z_]  =  
        B  +  ∫(( A z)/((Sqrt[z  +  1]) (Sqrt[z  -  1]))) \[DifferentialD]z; 
Print["f'[z] = ", f1[z]]; 
Print[""]; 
Print[" f[z] = B + ∫ ", 
        f1[z], " \[DifferentialD]z"]; 
Print[""]; 
Print[" f[z] = ", f[z]];

This is one, formula for the integral.   However, we will use the following form of the integral to continue the computations.

Clear[f1, F]; 
f1[z_]  =  ((A z)/(Sqrt[(z^2)  -  1])); 
F[z_]  =  
        B  +  ∫((A z)/(Sqrt[(z^2)  -  1])) \[DifferentialD]z; 
Print["f'[z] = ", f1[z]]; 
Print[""]; 
Print[" f[z] = B + ∫ ", 
        f1[z], " \[DifferentialD]z"]; 
Print[""]; 
Print[" f[z] = ", F[z]];

Now solve for the coefficients  A  and  B.

eq1  =  F[1] == 0; 
eq2  =  F[0] == I; 
solset  =  Solve[{eq1, eq2}, {A, B}]
f[z_]  =  
        ReplaceAll[F[z], 
          (Subscript[solset, [[1]]])]; 
Print[eq1]; 
Print[eq2]; 
Print[
        (Subscript[solset, [[1]]])]; 
Print[""]; 
\(\(Print[\*""f[z] = B + A \!\(\@\(z\^2 - 1\)\)""];\)\ \)
Print[""]; 
Print["f[z] = ", f[z]];

Use Mathematica to graph conformal mapping  w = f(z).  We will need to use two branches of f(z) to form the graph.

Clear[f1, f2, z]; 
f1[z_]  =    (Sqrt[(z^2)  -  1]); 
f2[z_]  =  I (Sqrt[1  -  (z^2)]); 
gr1  =  
        CartesianMap[f1, {0, 2, 0.2}, {0.00001, 1.00001, 0.1}, 
          PlotRange -> {{-2, 2}, {0, 1.5}}, 
          PlotStyle -> {Blue, Cyan}, 
          DisplayFunction -> Identity]; 
gr2  =  
        CartesianMap[f2, {-2, 0, 0.2}, {0.00001, 1.00001, 0.1}, 
          PlotRange -> {{-2, 2}, {0, 1.5}}, 
          PlotStyle -> {Blue, Cyan}, 
          DisplayFunction -> Identity]; 
\(\(Show[gr1, gr2, PlotRange -> {{\(-2\), 2}, {0, 1.5}}, 
        AxesLabel -> {"u", "v"}, 
Ticks -> {Range[\(-2\), 2, 1], Range[0, 2, 1]}, 
        DisplayFunction -> $DisplayFunction];\)\ \)
Print["The image of the upper half plane Im[z] > 0,"]; 
Print["is upper half plane Im[w] > 0 slit"]; 
\(\(Print[\*""along the line segment from w = 0 to (Subscript[w, 2]) = I,""];\)\ \)
Print["where  w = f[z] = ", f[z]];

We see that  w = (Sqrt[(z^2) - 1])  maps the upper half plane  Im[z] > 0  onto the upper half plane  Im[w] > 0  slit along the line segment from  w = 0  to  (Subscript[w, 2]) = i .

Example 10.28,  Page 459.  Show that  w = (1/π) ArcSin[z] + (i/π) 
            ArcSin[(1/z)] + ((1  +  i)/2)   maps the upper half plane  Im[z] > 0  onto the channel in the right half plane bounded by the coordinate axes and rays  x ≥ 0, y = 1  and  y ≥ 1, x = 1.

Solution 10.28.

Enter the formula f'[z] = ((A (z  -  1))/(z (Sqrt[((z^2)  -  1)]))) and integrate it to construct  f(z).

Remove[A, B, z]; 
Clear[f1, F]; 
f1[
          z_]  =  ((A (z  -  1))/(z (Sqrt[((z^2)  -  1)]))); 
f[z_]  =  
        B  +  ∫((A (z  -  
                        1))/(z (Sqrt[((z^2)  -  1)]))) \[DifferentialD]z; 
Print["f'[z] = ", f1[z]]; 
Print[""]; 
Print[" f[z] = B + ∫ ", 
        f1[z], " \[DifferentialD]z"]; 
Print[""]; 
Print[" f[z] = ", f[z]];

This is one, formula for the integral.   However, we will use the following form of the integral to continue the computations.

F[z_]  =  
        A (ArcSin[z]  +  I ArcSin[(1/z)])  +  
          B; 
Print["F[z] = ", F[z]];

Now solve for the coefficients  A  and  B.

eq1  =  F[-1]  ==  0; 
eq2  =  F[1]   ==  1 + I; 
solset  =  
        Solve[{F[-1] == 0, F[1] == 1 + I}, {A, 
            B}]; 
f[z_]  =  
        ReplaceAll[F[z], 
          (Subscript[solset, [[1]]])]; 
Print[eq1]; 
Print[eq2]; 
Print[
        (Subscript[solset, [[1]]])]; 
Print[""]; 
\(\(Print[\*""f[z] = B + A (ArcSin[z] + I ArcSin[(1/z)])""];\)\ \)
Print[""]; 
Print["f[z] = ", f[z]];

Use Mathematica to graph conformal mapping  w = f(z).

CartesianMap[
        f, {-4, 4, 0.5}, {0.00001, 4.00001, 
          0.4}, 
Ticks -> {Range[0, 2, 0.5], 
            Range[0, 2, 0.5]}, AxesLabel -> {"u", "v"}, 
        PlotStyle -> {Magenta, Pink}];  
Print["The image of the upper half plane Im[z] > 0,"]; 
\(\(Print["is the channel in the right half plane bounded by the"];\)\ \)
Print["coordinate axes and rays x ≥ 0, y = 1 and y \
≥ 1, x = 1."]; 
Print["where  w = f[z] = ", f[z]];

We see that  w = (1/π) ArcSin[z] + (i/π) 
            ArcSin[(1/z)] + ((1  +  i)/2)   maps the upper half plane  Im[z] > 0  onto the channel in the right half plane bounded by the coordinate axes and rays  x ≥ 0, y = 1  and  y ≥ 1, x = 1.

Library Research Experience for Undergraduates

Project I. Write a report on the Schwarz-Christoffel transformation.

1. Goodman, A. W., ''On the Schwarz-Christoffel Transformation and p-Valent Functions,'' Trans. of the Am. Math. Soc., Vol. 68, No. 2. (Mar., 1950), pp. 204-223, Jstor.   

2. Henrici, Peter, (1974), Applied and Computational Complex Analysis, Vol. I, N.Y., Wiley.

3. Saff, E. B. and A. D. Snider, (1993), Complex Analysis for Math., Science and Engineering, Englewood Cliffs, N.J., Prentice Hall.

4. Sanday, S. C., ''Evaluation of the Schwarz-Christoffel Mapping Function for Special Polygons,'' SIAM J. on Applied Math., Vol. 18, No. 4. (Jun., 1970), pp. 815-817, Jstor.   

5. Squire, William, (1975), ''Computer Implementation of the Schwarz-Christoffel Transformation,'' J. of the Franklin Inst., V. 299, No. 5, pp. 315-322.

Section 10.9  Exercises for Schwarz-Christoffel Transformation
See textbook page 460.

Section 10.10	Image of a Fluid Flow

Section 10.11	Sources and Sinks

GO TO  THE  Table of Contents