I am aware that this issue has come up before in a number of posts. However, my question is a little different and as far as I can see not answered previously.

If I run the following code taken directly from the Mathematica documentation

Plot3D[CosineWindow[x] CosineWindow[y], {x, -1, 1}, {y, -1, 1}, PlotRange -> All]

I get

enter image description here

Note the white lines.

This is not consistent with the image shown in the documentation.

enter image description here

If I re-run the code in the documentation notebook I get the plot with the white lines.

I am fully aware that using Exclusions -> None removes the white lines. As in

Plot3D[CosineWindow[x] CosineWindow[y], {x, -1, 1}, {y, -1, 1}, PlotRange -> All, Exclusions -> None]

My questions

  1. Why is the image shown in the documentation inconsistent with the actual output of the code shown in the documentation. I would have expected the image in the documentation to match the actual output of the code.

  2. For this specific example using CosineWindow are the white lines meant to be there? I can semi understand the lines directly around the perimeter of the "bump", presumably due to a discontinuity(?). But I am not clear why the lines span the whole plot, where the function should be zero.

I am running "12.1.1 for Mac OS X x86 (64-bit) (June 19, 2020)"

  • $\begingroup$ ExclusionsStyle -> Yellow $\endgroup$ – cvgmt Aug 13 '20 at 10:55
  • $\begingroup$ The white lines are there for me too on 12.1 for Linux. The discrepancy with the documentation can happen because they generated that on a system / version of Mathematica where these white lines did not appear. $\endgroup$ – C. E. Aug 13 '20 at 11:18
  • $\begingroup$ So, has some internal behaviour of Mathematica changed? Are the lines meant to be there? Particularly there spanning the whole plot? $\endgroup$ – flyingmind Aug 13 '20 at 11:46
  • $\begingroup$ Options[Plot3D, Exclusions] evaluates to {Exclusions->Automatic}. Presumably, the code that decides what is Automatic for a given case changed and now concludes that it should mean True for this specific case. As you pointed out, you can override its decision. $\endgroup$ – Bob Hanlon Aug 13 '20 at 13:08
  • $\begingroup$ Are the white lines spanning the whole plot mathematically correct? Why not just around the "bump"? $\endgroup$ – flyingmind Aug 13 '20 at 13:57

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.