I have a little problem with the Plot3D function. Depending on how I define my variables, the shape of the plot is not exactly the same.
The first way I use is for instance:
Plot3D[If[Sin[xyz] > 1/2, Sin[xyz], 0] /. z -> 1, {x, -1, 1}, {y, -1, 1}]
You can see that the graph is continued which should not be the case.
And the second is:
z = 1; Plot3D[If[Sin[xyz] > 1/2, Sin[xyz], 0], {x, -1, 1}, {y, -1, 1}]
Here the graph is not continued but now I have defined a global z.
I prefer using the first way because in this case z is only defined for the plot, yet I prefer the shape of the second way. How could I have a discontinued graph but without defining a global z ?
{}
button above the edit window. The edit window help button?
is useful for learning how to format your questions and answers. You may also find this meta Q&A helpful $\endgroup$