# Steepest descent path of complex saddle

I am trying to understand a certain function on the complex plane, and in particular the contours of steepest descent associated to the saddles of such function. Using ContourPlot I can easily draw the path of steepest descent and ascent. Is there a way to tell Mathematica to only draw in ContourPlot the path of steepest descent?

Below you can see a working example:

f[z_] := z^3 + 2 z + 4
sa = z /. Solve[f'[z] == 0, z];
Show[ContourPlot[Re[f[x + I y]], {x, -3, 3}, {y, -3, 3},
Contours -> {0}, PlotRange -> All],
ContourPlot[Im[f[x + I y]] == Im[f[sa[[1]]]], {x, -3, 3}, {y, -3, 3},
Contours -> {0}, PlotRange -> All],
ListPlot[Transpose[{Re[sa], Im[sa]}],
PlotStyle -> {PointSize[Large], Red}]]
Clear[f, sa]


Only one of the paths shown is of steepest descent, and I would like M to just keep that particular case.

• A concrete example (i.e. code) might be helpful in illustrating your problem. Feb 13, 2021 at 23:00
• Thanks for the hint! I added some simple code that illustrates my problem. Feb 13, 2021 at 23:08
• I'm working on four hours sleep. But I'm curious. Steepest descent from where? Surely you need to specify a starting point? Could this starting point be the highest point on your surface (in the region $x\in[-3,3], y\in[-3,3]$ )? Feb 14, 2021 at 9:45
• Would this be along the lines you have in mind (if it could be cleaned up a bit)?: StreamPlot[ -D[ReIm[f[x + I*y]] // ComplexExpand, {{x, y}}] // Evaluate, {x, -3, 3}, {y, -3, 3}] Feb 14, 2021 at 18:41

Try something along these lines:

f[z_] := z^3 + 2 z + 4;
sa = z /. Solve[f'[z] == 0, z];
g[x_, y_] :=
If[y < 1 && Re[f[x + I y]] <= Re[f[sa[[1]]]],
Im[f[x + I y]] - Im[f[sa[[1]]]], 1];
Show[ContourPlot[Re[f[x + I y]], {x, -3, 3}, {y, -3, 3},
Contours -> {0}, PlotRange -> All],
ContourPlot[g[x, y] == 0, {x, -3, 3}, {y, -3, 3}, Contours -> {0},
PlotRange -> All],
ListPlot[Transpose[{Re[sa], Im[sa]}],
PlotStyle -> {PointSize[Large], Red}]]


The hard-coded condition y < 1 is not nice, but you can omit it if your purpose is to visually find the contour going through the saddle point.