# Complex potential / conformal mapping

1. Jul 2, 2008

### Omri

Hi everyone,

(I hope I'm posting it in the right place, please feel free to move this thread to the appropriate place)

My high school graduation project is about the application of the theory of complex variables in physics. Specifically, I am learning about the complex potential, its existence and its use in hydrodynamical problems.
I'm having a little bit of trouble understanding some of the theory behind the project. For one thing, I didn't fully understand the physical meaning of streamlines and equipotential lines - I know how to find them from the complex potential, but I don't understand what they actually mean. And the other important thing is that I don't know how to take a given physical situation and find the complex potential that describes it. Clearly there are the simple cases of pointlike sources or sinks, which are easy to describe, but is there a general method of finding a complex potential when I know the settings of the physical system?
If you could answer these questions, or maybe give me some relevant textbooks or articles, that would be great.

Thank you very much!

2. Jul 2, 2008

### Crosson

Without getting into the mathematics, streamlines are parallel to the velocity of the flow. In a smooth flow without turbulence you can get small objects to travel down the streamlines. The small object will stay on the streamline that it started on, since it has no component of velocity perpendicular to the streamline.

The 'hydrodynamical potential' is analyzed without some effects that real fluids have. A potential flow is incompressible (it has constant uniform density) and it is irrotational (so there can be no small vortices or turbulence).

If we further restrict the potential flow to occur in two dimensions, then it can be analyzed with conformal mapping. The problem is then reduced to nothing other then curve fitting e.g. what function expresses a particular curve. We cannot use this technique for fully 3d flows.

3. Jul 3, 2008

### Omri

About streamlines - apart from being "carriers" of small objects, do they have an interpretation simply in terms of the flow (without placing any objects on them)?
And also, what do you mean by reducing the problem to curve fitting? I thought the problem was to determine the curve, starting with the complex potential function - I just didn't understand how to find this function, when you know what the system looks like, e.g. flow around a corner.

Thanks again!

4. Jul 4, 2008

### vanesch

Staff Emeritus
That's very ambitious for a high school project ! I know many 2nd or 3rd year physics or engineering students who would have difficulties doing so

As Crosson said, it only applies to very specific cases in hydrodynamics: 2-dimensional potential flow. There are other applications of conformal mapping: electrostatics in 2 dimensions for instance. The real reason is that the real part and the imaginary part of an analytic complex function, when seen as just a real function of two real variables, obeys the Laplace equation in two dimensions: http://en.wikipedia.org/wiki/Laplace's_equation
So all physical problems that can, by approximation or by specificity, be reduced to a Laplace equation will be able to use conformal mapping as a solution technique.

As to stream lines, if you have a vector field defined over a plane (so, "little arrows at every point in the plane"), then you can pick an arbitrary point, and follow the little arrow at that point for a very small bit. You are now at a second point. You follow the arrow at *that* point a little bit. You are now at a third point. Again you follow the arrow at that third point a bit. Etc... You will obtain a well-defined set of points that way. Now make the steps smaller and smaller, and you will end up having a set of points that approximates a curve in the plane. That's a stream line. http://en.wikipedia.org/wiki/Stream_line
As at any point on the stream line, it "follows" the direction of the little arrows, streamlines are tangent at every point to the vectors.

As to "how to find the right complex function for a given physical situation", that's the whole art of conformal mapping ! Usually you start with a known catalog of specific cases, which have been studied. That's usually done by first writing down an analytic function, and then seeing what it actually does. Next, you try to combine (essentially by intuition, guessing, etc...) functions in order to come closer and closer to the physical situation you are trying to describe. There are some general techniques known for specific cases, like for polygons: the technique is called the Schwarz-Christoffel transformation
http://en.wikipedia.org/wiki/Schwarz-Christoffel_mapping

Concerning conformal mapping in general, there's this:
http://mathworld.wolfram.com/ConformalMapping.html

hope this helps you a bit. Honestly, at high school level, that's really a tough subject, simply because there's so much math behind it you normally haven't seen yet...

5. Jul 4, 2008

### Omri

First of all I'd like to say thanks for the detailed reply!

I realize that this is not what people conventionally do as their high school projects. But my tutor offered me this subject, and it looked fascinating - sure, I might not manage to finish it (I hope I will though), but I will enjoy the experience and hopefully learn a lot.
In addition, I have taken a course (not formally but with my tutor) in complex analysis, so the general concepts of Cauchy-Riemann equations and Lapalce's equation are familiar to me.

About finding the complex potential, I realize it's not supposed to be easy - but I'm interested in understanding the basics. Take for example the case of a single source at some point, say the origin. How do you start analyzing such situations, and similar ones?

Thanks a lot for your help!

6. Jul 4, 2008

### vanesch

Staff Emeritus
Wow !

Ok, then we can shift gears

You take a book with a lot of transformations in it, and you look which one(s) can help you for your particular situation.

Be careful: the conformal transformations don't give you the solutions of elementary problems, like a point source. The conformal transformations allow you to transform "difficult" boundary conditions into simpler ones, like "upper half plane" or "disk". You are then supposed to be able to solve your transformed problem in that simpler situation, and then you can use your transformation to transform your solution in the simple setting, into the more complicated one.

But for that, you need to know the solutions to the simple problems in one or other way.

Take a point source S in the origin. Then consider the function V(r) = ln(r). If you plot that, you will see that you have concentric equipotentials. The derivative (the gradient) is a vector which is radial, and which amplitude goes as 1/r. Now, that's exactly the flow out of a point source in 2 dimensions. So V(r) = ln(r) represents a good potential if it is the real part of an analytic function. What analytic function ? Well, ln(z) ! The complex logarithm
ln(z) = ln(r) + i theta in polar representation.

So now you have: real part: ln(r). It's the potential. ln(r) = constant gives you circles, the equipotential lines. Imaginary part: theta. theta = constant gives you radial lines: the stream lines ! Indeed, out of a point source, the stuff flows out along the radial lines!

Next, two sources. Very simple: the SUM OF BOTH !

V_tot(z) = S1 x ln[ z - z1 ] + S2 x ln [ z - z2 ]

where S1 and S2 are the relative strengths of the two sources, and z1 and z2 the two positions (as complex numbers).

A source and a wall: we take the wall to be the x-axis.

There's a trick here: take away the wall, and pretend that there is a second source on the mirror point of the source. If the source is at (x1,y1), pretend that there is a second equivalent source at (x1, -y1). The reason for this is that for every point on the x-axis (the wall), theta1 = - theta2 because the angle between source 1 and that point on the x-axis is the same angle as the one between the source 2 and that same point. So the difference between both will give you 0. So the imaginary part of the potential along the x-axis will be 0 all the way. So it is constant (0) on the x-axis, which means that the x-axis is a stream line. Nothing penetrates the x-axis. That's exactly what a wall does.

So, you have a source and a wall, you can replace it by two sources and no wall. It will give you the same solution above the x-axis.

There are other tricks. We now know how we can find the complex potential of several point sources scattered in a free plane, or scattered in an upper half plane with a wall at the x-axis (by using the trick with the mirror sources).

That's usually enough. If you now have point sources scattered in a geometry with walls, and the surface limited by the walls can, through conformal mapping, be changed into an upper half plane and a wall at the x-axis, then you can find the complex potential there (using the above solutions), and transform it back into a complex potential in the specific geometry.

Actually, it is pretty funny, I had once to solve the electrostatic potential in a regular polygonal prism (which was in fact a mechanical approximation to a cylinder, and I wanted to find out the small errors introduced by using a polygon and not a perfect cylinder) inside a particle detector. Turns out I managed to do that by using conformal mapping using the Schwarz-Christoffel transformation, which reduces to a pretty simple expression if you work it out. This transformed a polygon with n sides into a disk. In a disk, it is simple to solve electrostatic problems. But next, I wanted to consider one single sector of the polygon because our setup is symmetrical in every sector. A single sector of a polygon transforms into a sector of a disk (1/n of 360 degrees). And then z^n transforms that sector of a disk into an entire disk, and so I got rid of the "walls" as I had now a full disk representing a sector of my polygon. So that was fun! While my collegues were running finite-element software for hours, I had a neat analytic expression with which I could show off for a few days :tongue2:

7. Jul 4, 2008

### Omri

About the single source - I understand you guessed ln(r) because you wanted to achieve (1/r). Sorry for the stupid question, but why does that describe 2D flow? And even though you know that the real part is ln(r), you could define the imaginary part as you wish - I realize that the complex logarithm with Im(ln(z))=i*arg(z) is the simplest choice, but why would you pick it?

About the two sources - that was one nice trick. :) But when you take a point that is not on the x-axis, isn't it affected by the mirror source you added?

Finally, could you please show me an example of how to use conformal mapping in order to solve a "complicated" problem?

Thanks for all the help!

8. Jul 4, 2008

### Count Iblis

Have you studied contour integration, residue theorem etc? If not, then you should learn this (takes just half an hour or so if you just want a heuristic introduction).

Sources and sinks are most easily understood in terms of poles and residues (of the complex derivative of the potential).

9. Jul 4, 2008

### Omri

I learned contour integration and residues calculus quite intensively, so feel free to use them when explaining... :)

10. Jul 4, 2008

### Count Iblis

Suppose we introduce the complex potential:

$$V(z) = \phi(x,y) + i \psi(x,y)$$

The velocity is given by the gradient of $$\phi$$:

$$v_x = \frac{\partial\phi}{\partial x}$$

$$v_y = \frac{\partial\phi}{\partial y}$$

Then you should do this exercise:

Show that

$$\frac{dV}{dz}= v_x - i v_y$$

So, the (complex) derivative of the potential is the complex conjugate of the velocity vector considered as a complex number. The derivative of V is usually called "the complex velocity". So, you need to be aware that "complex velocity" is actually the complex conjugate of the actual velocity.

Next, we want a simple formula to compute the amount of fluid that passes through some boundary, or flows out of a closed contour per unit time. If we denote the path by P, show that this can be written as:

$$Q = \int_{P} v_x dy - v_y dx = \text{Im}\int_{P}\frac{dV}{dz} dz$$

Here we have taken the density equal to 1 and we count a flow that crosses a path element in the drection you obtain by rotating the path element 90 degrees clockwise, positive.

So, the difference in the imaginary part of V between two points gives you the amount of fluid that flows per unit time throgh any curve that joins the two points. In case of a cosed contour C the total amount of fluid that moves out of the contour is given by:

$$\text{Im}\oint_{C}\frac{dV}{dz} dz$$

This will be zero unless the complex velocity $$\frac{dV}{dz}$$ has poles inside the contour. From a physical point of view, fa net amount of fluid flowing out of a closed contour means that there is a source in the contour. So, this formula gives you the answer to your question: At a source the complex velocity must have a pole with a nonzero residue. So, 1/z will do, yielding Log(z) for the potential.

Let's see if you can solve the following problem. We want to find the flow around an infinite cylinder. The flow is assumed to be perpendicular to the length of the cylinder, so we can model this as a 2d potential flow. At infinity the flow has a velocity of U in the x-direction. The boundary is a circle of radius R with the origin as the center. Show that the complex potential is given by:

$$V(z) = U \left(z + \frac{R^2}{z}\right)$$

The problems like finding the flow around some object using conformal mappings when sources and the boundary conditions at infinity are given are essentially trivial. The boundary of the object is then a streamline. In case of a polygon you can apply the Riemann mapping theorem. It thus amounts to writing down the answer as the complex potential what you want to know.

Problems involving free boundaries are far more interesting. They also have a lot more practical applications. Consider e.g. water in a reservoir that streams out of a hole. The boundaries of the reservoir are streamlines, but then the water streams out and we want to solve for the boundary of the water that streams out. So, we don't know how the stream line that eminates from the given boundary progresses beyond the hole.

We thus cannot solve this problem by finding a conformal mapping that maps the complete streamlines to straigth lines, as we need to find the shape of the stream lines in the first place. One way to solve such problems is by finding a conformal mapping between the potential and the complex velocity. This can often be found from the given boundary conditions. You then need to solve a differential equation to find the potential.

11. Jul 5, 2008

### Omri

Again I have to begin with a silly question - why is $$v=\nabla\phi$$?

I also didn't really understand why the total amount of fluid through a path P should be given by
$$\int_P v_x dy - iv_y dx$$
It's easy to show that this equals to
$$\mathrm{Im} \int_P \frac{dV}{dz}dz$$
but why should it be this expression on the first place?

What you said about contours and poles is clear. But I don't know how to solve your question about the cylinder. I don't understand why data about the conditions in infinity should make the problem simpler.

Thanks for you help!

12. Jul 6, 2008

### Count Iblis

In potential flow theory one assumes that the flow is irrotational, i.e. the velocity satisfies:

$$\nabla\times\vec{v}=0$$

This then implies that there exists a scalar function $$\phi$$ such that:

$$\vec{v}=\nabla\phi$$

If the fluid is incompressible and we have a steady state flow, the general equation that expresses the fact that mass is conserved:

$$\frac{\partial\rho}{\partial t} + \nabla\cdot\left(\rho \vec{v}\right)=0$$

reduces to:

$$\nabla\cdot\vec{v}=0$$

Which implies:

$$\nabla^{2}\phi=0$$

13. Jul 6, 2008

### Count Iblis

About the flow crossing a line, consider some line segment which we denote by the infitesimal vector (dx, dy). Suppose that the velocity vector at that point is (vx, vy). The component of the velocity in the directon orthogonal to the line segment is the rate per unit length of the flow across the segment (assuming density equal to 1).

There are two normal directions of the segment, we have to choose one of these directions as the "positive direction", meaning thst flow in thst direction counts as positive. The usual convention is to choose the outward normal for a contour that is anti-clockwise oriented as the positve direction.

This means that you have to rotate the segment 90 degrees to the right to obtain the normal direction. So, this is then proportional to (dy, -dx). If we take the inner product of the velocity vecotr with
(dy, -dx) we obtain the total flow per unit time across the segment (note that (dy,-dx) has the same length as the line segment, so the inner product is the projection of the velocity vector in the normal direction times the length of the segment)

The inner product can be written as:

(vx, vy).(dy, -dx) = vx dy - vy dx

14. Jul 6, 2008

### Count Iblis

In the cylinder problem, first check if you understand that the imaginary part of V is constant along streamlines. Now, in general, solutions ofnthe Lapalce equation are inly unique once you specify the boundary conditions. If we don' say what the flow is like at infinity, we haven't defined the problem fully and there are then an infinite number of solutions.

Intuitively this is very clear. If you just say: "I have a cylinder in a fluid", then that statement alone doesn not say much about what the flow in the fluid is like. So, we have to specify situation such that the flow is determined completely. Suppose e.g. that the fluid is initially at rest. You then out the cilynder in the fluid and you move the cylinder with some velocity U relative to the fluid until some steady state is reached. Then, I think, it is untuitively clear that the flow relative to the cylinder should be some unique function.

If you are siting on the cylinder, then relative to you the velocity at infinity will be minus U. So, you could just as well say that the velocity of the cylinder is zero and that the fluid at infinity is moving at some velocity (minus) U.

Of course, you could have made some other assumption about the flow at infinity, but this particular condition is somehting that arises quite naturally.

To solve the problem you have to check if the circle is part of a flow line, i.e. if the imaginary part of V is constant on the circle (of radius R). Also, you have to check that the velocity at ininity is U.

15. Jul 10, 2008

### Omri

Thanks a lot for all of the explanations! I'm sorry I didn't reply sooner, but I couldn't read here for a while.

I still need to think about the cylinder problem, but thank you for giving me the tools.

Now, my tutor wants me (at some stage before November) to use the complex potential tools in order to solve groundwater flow problems. The main thing he wants to do is study the flow around a dam. He told me to look for material about Darcy's law, and I read a little bit about it in wikipedia, but I can't quite connect it to what I learned about the complex potential. Could you please help me understand how to start thinking about such a thing?

Thanks again for everything!

16. Jul 10, 2008

### vanesch

Staff Emeritus
Sorry, I was away for a few days. This is not a continuation to Count Iblis's posts

That's right And the 1/r came from Gauss' theorem in 2 D (or, if you want, conservation of flow: the flux through a circle with radius r1 equals the flux through a bigger circle with radius r2, so the flux density must go in 1/r).

There's not much choice in the extension of a real function into a complex analytic function. In fact, most of the time it is unique, up to a constant. So if you find (by guessing) ONE solution, it is THE solution. The reason is the Cauchy-Riemann equations. If you know the real part over the complex plane, that means that the first derivative of the imaginary part is fixed everywhere, in both x and y direction. Pick a point somewhere where you fix the value of the imaginary part (that's the free constant), and then you have fixed the values along the parallel line with the y-axis (because you know the y-derivative). From every point along this y-axis, with the x-derivative, you find the values everywhere along all lines parallel with the x-axis, that start at a point on the y-line, in other words, everywhere. The only thing that can happen is that at some points, you diverge, and then you introduce cuts. That's like the choice of the "0" for the argument in the logarithm. But strictly speaking, at those cuts, your function is not analytic anymore.

No. The contributions to the flows of different sources are independent. The reason is that if you take a small circle around any source, what will flow in from another source in that circle will also flow out of it. So what flows out net is the contribution of the source INSIDE, and that's not affected by what is put in by any other source.

The point is again that you know that the solution to the problem is going to be unique. So if you find A solution, it is THE solution. The solution to the problem is the one that will satisfy:
1) Poisson's equation everywhere outside of the sources
2) Gauss' law
3) The boundary conditions (like a wall or something, which is represented by a streamline).
4) eventually some limit conditions if the region is open, such as the flow at infinity

Those conditions can be shown to fix the solution uniquely. That means that if you find A way to satisfy them, it is the unique solution.

Now, finding an analytic function (outside of the sources) guarantees (1). Taking the solution F. ln(z-z0) satisfies (2). If you can fiddle the stuff such that (3) and (4) are ok, then you have found the solution.

Right. In a previous message, I talked about sources. That's because in fact, most of my uses of conformal mappings are in the electrostatic domain, where I have charges which act as sources for the electric field. But we can consider other kinds of "simple" solutions, such as uniform flow. Consider the "potential": phi(z) = z. This means that the real potential is x, and the streamlines are given by the equation y = constant. We have constant, horizontal flow. We can eventually consider that this is only valid in the upper half plane. So the potential phi(z) = z gives us a solution of constant flow along a wall.

Now, consider the map w = z^n. This maps a sector in the z-plane with opening angle pi/n onto the upper half plane in the w-plane. And now the thing comes:
assume that you want to look at a flow in a "corner" with opening angle pi/n. Let us fix n, set it to 3. That means, you want to look at the flow in a corner with opening angle 60 degrees. You consider z a point in the z-plane (in the sector). The corresponding w in the w-plane will be w = z^3. The *potential* in the w-plane, phi_w(w) = w because it is a uniform flow in an upper half plane. We now take over that potential, but at the point z in the z-plane: phi_z(z) = phi_w(w) = w = z^3. So phi_z(z) = z^3 is a potential flow in the z-plane. It is an analytic function within the sector (theta = 0 to theta = 60 degrees), so that's already ok. The "walls" of the sector phi_z(r,theta=0) = cos(3x0) r^3 + i sin(3x0) r^3 give us 0 for the imaginary part, that's constant, so that's a stream line, ok, and for z = cos(60) r + i sin(60) r we have phi_z(z) = cos(180) r + i sin(180) r has also the imaginary part equal to 0, hence constant, so the wall at 60 degrees is also a stream line.

What we have is that we have an "incoming" flow from infinity along the 60 degree wall, which turns in the corner, and flows out towards infinity along the 0 degree wall (the positive x-axis).

17. Jul 10, 2008

### Omri

Wow, thanks for that long reply!

Could you please give me a brief overview of Gauss's law and the meaning of flux? I know what Gauss's theorem means in vector calculus, but I don't know how it relates to the subject. As for flux, it keeps coming up but I never studied it in an organized way.

What you said about the choice of ln(z) makes perfect sense, I'm sorry - I forgot all about analytic continuation! :-)

I think I'm starting to really understand the ideas. So all in all, the problem of flow around a corner of opening angle pi/n reduces to solving $$r^n sin(n\theta) = c$$ for the streamlines, is that true? Also, I'm sorry but I never studied electrodynamics, I'm only going to study it next year, so these examples don't mean much to me...

Thanks a lot!

18. Jul 10, 2008

### vanesch

Staff Emeritus
Well, it is related to Gauss' theorem. Gauss' theorem tells you that the surface integral of a vector field over a closed surface is equal to the volume integral inside that closed surface of the divergence of the vector field, right ?
It turns out that vector fields that describe a "conserved flow" are such that the divergence is zero everywhere, or almost so. So Gauss' theorem tells us then that the surface integral of the vector field over any closed surface should be 0, right ? But I said "almost so". The exception are the sources. A source has a divergence, which means that if we apply Gauss' law on a small closed surface around a source, you WILL find a finite value for the surface integral, equal to the total divergence of the source (the strength of the source). And if you now take a big surface, then the surface integral will be equal to the sum of the strengths of the sources inside the surface, independent of how big the surface is, or what specific form it has.

A surface integral of a vector field is also called a flux.

Indeed !

But that was just an example that came to mind. There are many others of course. As you've seen, it is easier to first think of a function, and then find out what geometry it describes, than to have a given geometry and find the function that can help you (which was one of your initial questions). But by just looking at many functions, you can establish a catalog of interesting cases. The funniest is probably the Joukowski transformation:

http://en.wikipedia.org/wiki/Joukowsky_transform

It looks like the cross section of a wing, and in fact, people designed wings that way exactly because with this transformation they could calculate the flow around it!

19. Jul 11, 2008

### Omri

I think I understood what you said. But many times people refer to the "physical" meaning of flux, so I assumed it's not just the surface integral, and maybe it means something.

I think now the procedure is clear to me: you solve the problem in a simple case (or simple geometry), and then you map it to the real problem's conditions. I found a resource for conformal maps:
http://math.fullerton.edu/mathews/c2003/ConformalMapDictionary.1.html" [Broken]
But I wondered, do you know a way to "view" the images of conformal maps? I mean, a computer program that can get the source (circle, rectangle or anything), the map f(z) and gives the image. I work with Mathematica and Maxima, but I couldn't figure out a way to do it. I once tried to program such a thing using C#, but I'm not sure it was good, and I hate C#. :-)

Also, it is possible to include you in the list of people who helped me with my project? My tutor has been "neglecting" my project for several months now, and you have been very helpful.

Thanks a lot!

Last edited by a moderator: May 3, 2017
20. Jul 11, 2008

### vanesch

Staff Emeritus
Of course it means something! The flux is the "amount of stuff" that crossed the surface (per unit of time, or in total, depending on whatever the vectorfield was representing). For instance, if the vector field is the velocity field of a fluid flow, then the surface integral of that vector field will be the quantity of fluid (in cubic meters per second) that has crossed the surface per unit of time. The flux over a closed surface is equal to the amount of stuff that has left net the volume enclosed by the surface (hence, source) per unit of time.

Looks great !

There is the Graphics`ComplexMap package in mathematica.

I don't mind, but don't feel obliged.

Last edited by a moderator: May 3, 2017