This example is taken from Stan Wagon's book "Mathematica in Action". The special feature of the plotted function f(x,y) = x y (x x - y y) / (x x + y y) and f(x,y) = 0 at (x,y) = (0,0) is the difference between its mixed partial derivatives at (0,0). Apart from that this plot shows axes with labels and tick marks. (See below for more details about its creation.) Sometimes LiveGraphics3D uses the color of the wrong face of a polygon; especially in this example because the polygons have four edges (not only three). This effect is however shared by Mathematica, thus I do not know whether I should try to remove it. |
Another example from Stan Wagon's book: This time it is a Moebius tube. This plot uses different "styles" (colors) for each polygon and "manually" chosen positions of the axes. One unsolved problem of LiveGraphics3D is its bad hidden line/surface algorithm. In this case the y-axis seems to intersect the tube for some special points of view. |
Here is how to create the Plot3D example within Mathematica:
f[x_,y_]:=x y (x^2-y^2)/(x^2+y^2); s = Plot3D[f[x,y],{x,-2,2},{y,-2,2}, PlotPoints->10, AxesStyle->{Thickness[0.01]}, AxesLabel->{StyleForm[x,FontSlant->"Italic",FontSize->16], StyleForm[y,FontSlant->"Italic",FontSize->16], StyleForm["f(x,y)",FontSlant->"Italic",FontSize->16]}, TextStyle->{FontFamily->"TimesRoman"}];
This will show the topmost picture within Mathematica. The following command is used to produce an appropriate InputForm of s:
NumberForm[InputForm[N[Graphics3D[s]]],4]
The additional function Graphics3D is needed because Plot3D returns a SurfaceGraphics object. The procedure to display the Graphics3D object with LiveGraphics3D is explained in the documentation.
The ParametricPlot3D example was produced with
rotate[t_]:={{Cos[t],-Sin[t],0},{Sin[t],Cos[t],0},{0,0,1}}; circle[t_]:={4,0,0}+s{Cos[t],0,Sin[t]}; g = ParametricPlot3D[ Append[rotate[theta].circle[theta/2],{Hue[theta/2/Pi]}], {s,-1,1},{theta,0,2 Pi}, Boxed->False, Axes->True, AxesLabel->{x,y,z}, AxesEdge->{{-1,-1},{-1,-1},{-1,-1}}, PlotPoints->{2,40}, Lighting->False, TextStyle->{FontFamily->"TimesRoman",FontSize->14}, ViewPoint->{-1.38959, -2.47066, 1.84794}, ViewVertical->{0.213801, 0.509831, 3.942}]
And the command
NumberForm[InputForm[N[g]],4]
to generate the InputForm.