# How to draw a 2D curve as epilog on a 3D surface plot?

I'd like to draw

Plot[Re@Sin[x+I*2], {x, -10, 10}]


as an epilog on

Plot3D[Re@Sin[x + I*y], {x, -10, 10}, {y, -10, 10}]


and position it at y=2.

What's intuitive to me doesn't work:

epilogData = Table[{x, 2, Re@Sin[x + 2*I]}, {x, -10, 10, 0.1}];

Plot3D[Re@Sin[x + I*y], {x, -10, 10}, {y, -10, 10},
Epilog -> {Red, PointSize[Large], Point[epilogData]}]


Using

epilogData2D = Table[{x, Re@Sin[x + 2*I]}, {x, -10, 10, 0.1}];


will draws something, but not what i want (What's that anyway?).

I've also played with Inset and got no luck so far.

-
The function Make3d can be useful. – b.gatessucks Oct 27 '12 at 15:57

Maybe it helps to use Mesh:

Plot3D[Re@Sin[x + I*y], {x, -10, 10}, {y, -10, 10},
Mesh -> {{{0, None}}, {{2, {Red, Thick}}}}]


With a varying y:

frames = Table[
Plot3D[Re@Sin[x + I*y], {x, -10, 10}, {y, -10, 10},
Mesh -> {{{0, None}}, {{i, {Red, Thick}}}}], {i, -10, 10, .5}];
Export["animation.gif", frames]


-
How to make the animation? – qazwsx Oct 27 '12 at 16:09
@MonkeyKing See update. – VLC Oct 27 '12 at 16:33

Like this?

With[{y0 = 2},
Show[Plot3D[Re@Sin[x + I*y], {x, -10, 10}, {y, -10, 10}],
Graphics3D[{AbsoluteThickness[4],
First[Plot[Re@Sin[x + I y0], {x, -10, 10}]] /.
v : {__?NumericQ} :> Insert[v, y0, 2]}]]]


The use of Mesh, as in VLC's answer, is much easier, tho.

-