Mesh

Mesh

is an option for Plot3D, DensityPlot, and other plotting functions that specifies what mesh should be drawn.

Details

  • The following settings can be given for Mesh:
  • Noneno mesh drawn
    nn equally spaced mesh divisions
    Allmesh divisions between all elements
    Fullmesh divisions between regular data points
    {spec1,spec2,}separate specifications for each mesh function
  • For surfaces, as generated for example by Plot3D, mesh divisions are lines. The same is true for regions, as generated for example by ContourPlot or RegionPlot.
  • For curves, as generated for example by Plot, mesh divisions are points.
  • There can be several families of mesh divisions in a single plot. Each family is associated with a mesh function in the list given as the setting for MeshFunctions.
  • For Plot3D and ListPlot3D, the default mesh functions are the x and y coordinates.
  • For ContourPlot3D and RegionPlot3D, the default mesh functions are the x, y, and z coordinates.
  • For ParametricPlot3D, the default mesh functions for surfaces are the u and v parameter values.
  • In 2D, and for curves in 3D, the default is not to draw meshes.
  • Mesh divisions are by default taken to be equally spaced between the minimum and maximum values achieved by a particular mesh function.
  • Mesh divisions are by default taken to be drawn with the style specified by MeshStyle.
  • The following explicit specifications can be associated with each mesh function:
  • nn equally spaced divisions
    {a1,a2,}divisions at values ai
    {{a1,g1},}divisions drawn with graphics directive gi
  • Mesh->All draws mesh divisions between every line or polygon generated by a plotting function.
  • For functions like ListPlot3D and ListDensityPlot with regular arrays of data, Mesh->Full draws mesh divisions that cross at the position of each data point.
  • The gi can be color, Opacity, Thickness, Dashing, or other directives. Combinations of directives can be given using Directive.
  • For ArrayPlot, Mesh->True draws mesh divisions between every cell.
  • Mesh->False is equivalent to Mesh->None.

Examples

Basic Examples  (6)

Use no mesh:

Use 5 mesh lines in each direction:

Show all mesh elements used in the sampling:

Show underlying data points:

Include a mesh in an array plot:

Specify specific mesh lines:

Wolfram Research (1988), Mesh, Wolfram Language function, https://reference.wolfram.com/language/ref/Mesh.html (updated 2007).

Text

Wolfram Research (1988), Mesh, Wolfram Language function, https://reference.wolfram.com/language/ref/Mesh.html (updated 2007).

CMS

Wolfram Language. 1988. "Mesh." Wolfram Language & System Documentation Center. Wolfram Research. Last Modified 2007. https://reference.wolfram.com/language/ref/Mesh.html.

APA

Wolfram Language. (1988). Mesh. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/Mesh.html

BibTeX

@misc{reference.wolfram_2023_mesh, author="Wolfram Research", title="{Mesh}", year="2007", howpublished="\url{https://reference.wolfram.com/language/ref/Mesh.html}", note=[Accessed: 19-March-2024 ]}

BibLaTeX

@online{reference.wolfram_2023_mesh, organization={Wolfram Research}, title={Mesh}, year={2007}, url={https://reference.wolfram.com/language/ref/Mesh.html}, note=[Accessed: 19-March-2024 ]}