4

Is it possible to draw a 3d plot as line art with tikz? For example, Is it possible to draw z=x*exp(-x^2-y^2) with smooth line art style? Something like the following figure for z=x^3-3x*y^2. enter image description here

  • 2
    This might help to get this started: Simulating hand-drawn lines. – Peter Grill Jan 11 at 7:08
  • @Peter Grill: I do not think that the OP is looking for a line style other than normal smooth curves. I believe the question is about drawing just significant lines of a 3d plot as in the example. – hpekristiansen Jan 11 at 9:53
  • @hpekristiansen: If that is the case then the reference to "line art" style should be removed from the question. – Peter Grill Jan 12 at 0:32
  • Something like this: eclecticcats.wordpress.com/2014/03/25/… – C.F.G Jan 13 at 4:49
2

Asymptote is probably the better tool for serious 3d functions:

enter image description here

import graph3;
size(200,0);
currentprojection=perspective(10,8,9);
real f(pair z) {return z.x*exp(-(z.x**2)-(z.y**2));}
surface s=surface(f,(-1.4,-1.4),(1.4,1.4),nx=20,Spline);
draw(s,lightgray,meshpen=black+thick(),nolight,render(merge=true));

If you have a full TeX installation, then it will be already installed. texdoc asy tells you how to run it, and then if you do asy to bring up the interactive prompt, typing help will open the manual. It's very powerful but there is a lot to learn.

As the relevant help page will tell you, asy can be integrated into your LaTeX source file.

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Not the answer you're looking for? Browse other questions tagged or ask your own question.