RegionPlot3D
RegionPlot3D[pred,{x,xmin,xmax},{y,ymin,ymax},{z,zmin,zmax}]
makes a plot showing the three-dimensional region in which pred is True.
RegionPlot3D[{pred1,pred2,…},…]
plots several regions corresponding to the predi.
Details and Options
- The predicate pred can be any logical combination of inequalities.
- The region plotted by RegionPlot3D can contain disconnected parts.
- RegionPlot3D treats the variables x, y and z as local, effectively using Block.
- RegionPlot3D has attribute HoldAll and evaluates pred after assigning numerical values to x, y and z. In some cases, it may be more efficient to use Evaluate to evaluate pred symbolically first.
- RegionPlot3D has the same options as Graphics3D, with the following additions and changes: [List of all options]
-
Axes True whether to draw axes BoundaryStyle Automatic how to draw boundaries of regions BoxRatios {1,1,1} bounding 3D box ratios ColorFunction Automatic how to color surfaces ColorFunctionScaling True whether to scale arguments to ColorFunction EvaluationMonitor None expression to evaluate at every function evaluation MaxRecursion Automatic the maximum number of recursive subdivisions allowed Mesh Automatic how many mesh lines in each direction to draw MeshFunctions {#1&,#2&,#3&} how to determine the placement of mesh lines MeshShading None how to shade regions between mesh lines MeshStyle Automatic the style for mesh lines Method Automatic the method to use for refining surfaces NormalsFunction Automatic how to determine effective surface normals PerformanceGoal $PerformanceGoal aspects of performance to try to optimize PlotLegends None legends for surfaces PlotPoints Automatic the initial number of sample points in each direction PlotRange Full the range of values to include in the plot PlotStyle Automatic graphics directives for the style of the surface of each region PlotTheme $PlotTheme overall theme for the plot ScalingFunctions None how to scale individual coordinates TextureCoordinateFunction Automatic how to determine texture coordinates TextureCoordinateScaling True whether to scale arguments to TextureCoordinateFunction WorkingPrecision MachinePrecision the precision used in internal computations - RegionPlot3D initially evaluates pred at a 3D grid of equally spaced sample points specified by PlotPoints. Then it uses an adaptive algorithm to subdivide at most MaxRecursion times, attempting to find the boundaries of all regions in which pred is True.
- You should realize that since it uses only a finite number of sample points, it is possible for RegionPlot3D to miss regions in which pred is True. To check your results, you should try increasing the settings for PlotPoints and MaxRecursion.
- With the default setting PlotRange->Full, RegionPlot3D will explicitly include the full ranges xmin to xmax, etc.
- With Mesh->All, RegionPlot3D will explicitly draw mesh lines to indicate the subdivisions it used to find each region.
- RegionPlot3D can in general only find regions of positive measure; it cannot find regions that are just lines or points.
- The arguments supplied to functions in MeshFunctions are x, y, and z. Functions in ColorFunction and TextureCoordinateFunction are by default supplied with scaled versions of these arguments.
- RegionPlot3D returns Graphics3D[GraphicsComplex[data]].
- Possible settings for ScalingFunctions include:
-
{sx,sy,sz} scale x, y and z axes - Common built-in scaling functions s include:
-
"Log" log scale with automatic tick labeling "Log10" base-10 log scale with powers of 10 for ticks "SignedLog" log-like scale that includes 0 and negative numbers "Reverse" reverse the coordinate direction -
AlignmentPoint Center the default point in the graphic to align with AspectRatio Automatic ratio of height to width Axes True whether to draw axes AxesEdge Automatic on which edges to put axes AxesLabel None axes labels AxesOrigin Automatic where axes should cross AxesStyle {} graphics directives to specify the style for axes Background None background color for the plot BaselinePosition Automatic how to align with a surrounding text baseline BaseStyle {} base style specifications for the graphic BoundaryStyle Automatic how to draw boundaries of regions Boxed True whether to draw the bounding box BoxRatios {1,1,1} bounding 3D box ratios BoxStyle {} style specifications for the box ClipPlanes None clipping planes ClipPlanesStyle Automatic style specifications for clipping planes ColorFunction Automatic how to color surfaces ColorFunctionScaling True whether to scale arguments to ColorFunction ContentSelectable Automatic whether to allow contents to be selected ControllerLinking False when to link to external rotation controllers ControllerPath Automatic what external controllers to try to use Epilog {} 2D graphics primitives to be rendered after the main plot EvaluationMonitor None expression to evaluate at every function evaluation FaceGrids None grid lines to draw on the bounding box FaceGridsStyle {} style specifications for face grids FormatType TraditionalForm default format type for text ImageMargins 0. the margins to leave around the graphic ImagePadding All what extra padding to allow for labels, etc. ImageSize Automatic absolute size at which to render the graphic LabelStyle {} style specifications for labels Lighting Automatic simulated light sources to use MaxRecursion Automatic the maximum number of recursive subdivisions allowed Mesh Automatic how many mesh lines in each direction to draw MeshFunctions {#1&,#2&,#3&} how to determine the placement of mesh lines MeshShading None how to shade regions between mesh lines MeshStyle Automatic the style for mesh lines Method Automatic the method to use for refining surfaces NormalsFunction Automatic how to determine effective surface normals PerformanceGoal $PerformanceGoal aspects of performance to try to optimize PlotLabel None a label for the plot PlotLegends None legends for surfaces PlotPoints Automatic the initial number of sample points in each direction PlotRange Full the range of values to include in the plot PlotRangePadding Automatic how much to pad the range of values PlotRegion Automatic final display region to be filled PlotStyle Automatic graphics directives for the style of the surface of each region PlotTheme $PlotTheme overall theme for the plot PreserveImageOptions Automatic whether to preserve image options when displaying new versions of the same graphic Prolog {} 2D graphics primitives to be rendered before the main plot RotationAction "Fit" how to render after interactive rotation ScalingFunctions None how to scale individual coordinates SphericalRegion Automatic whether to make the circumscribing sphere fit in the final display area TextureCoordinateFunction Automatic how to determine texture coordinates TextureCoordinateScaling True whether to scale arguments to TextureCoordinateFunction Ticks Automatic specification for ticks TicksStyle {} style specification for ticks TouchscreenAutoZoom False - whether to zoom to fullscreen when activated on a touchscreen
ViewAngle Automatic angle of the field of view ViewCenter Automatic point to display at the center ViewMatrix Automatic explicit transformation matrix ViewPoint {1.3,-2.4,2.} viewing position ViewProjection Automatic projection method for rendering objects distant from the viewer ViewRange All range of viewing distances to include ViewVector Automatic position and direction of a simulated camera ViewVertical {0,0,1} direction to make vertical WorkingPrecision MachinePrecision the precision used in internal computations
List of all options
Examples
open allclose allBasic Examples (4)
Scope (12)
Sampling (3)
Areas where the function is not True are excluded:
Presentation (9)
Provide an explicit PlotStyle for the region:
Specify styles for each region:
Style the areas between mesh lines:
Color the region with an overlay density:
Options (54)
BoundaryStyle (3)
Boundary lines are black by default:
Use None to not draw any boundary lines:
ColorFunction (5)
Color regions by scaled , , and values:
Named color functions use the scaled direction:
Color regions according to a function of unscaled , , and values:
ColorFunction has higher priority than PlotStyle:
ColorFunction has lower priority than MeshShading:
Mesh (7)
MeshShading (5)
Alternate red and blue sections:
MeshShading has higher priority than ContourStyle for styling:
Use the PlotStyle for some segments by setting MeshShading to Automatic:
MeshShading can be used with ColorFunction:
MeshStyle (2)
NormalsFunction (4)
Normals are automatically calculated:
Use None to get flat shading for all the polygons:
Vary the effective normals used on the surface:
The NormalsFunction does not get applied to clipped regions:
PerformanceGoal (2)
PlotLegends (3)
Identify regions with a legend:
Use legends for color gradients:
Use Placed to put legends above the plot:
PlotStyle (5)
Use None to show a wireframe of the bounding surfaces:
ColorFunction has higher priority than PlotStyle:
MeshShading has higher priority than PlotStyle:
ScalingFunctions (5)
By default, plots have linear scales in all directions:
Apply a log scale to the z axis:
Use a shifted log scale to show a function with negative values:
Use ScalingFunctions to reverse the coordinate direction in the direction:
TextureCoordinateFunction (4)
Applications (3)
Find the intersection of two half-spaces:
Simple regions including a cube:
Combine PolyhedronData regions with other inequalities:
Properties & Relations (8)
Use RegionPlot for areas:
Use ContourPlot and ContourPlot3D for systems of equalities:
Use ComplexRegionPlot for regions in the complex plane:
Use RegionFunction to constrain other plots:
Use ParametricPlot3D for parametric curves and surfaces:
Use Integrate or NIntegrate to integrate over regions:
Use Maximize, NMaximize, or FindMaximum to optimize over regions:
Use Reduce to get a cylindrical representation of the region:
Use FindInstance to find specific samples in regions:
Text
Wolfram Research (2007), RegionPlot3D, Wolfram Language function, https://reference.wolfram.com/language/ref/RegionPlot3D.html (updated 2022).
CMS
Wolfram Language. 2007. "RegionPlot3D." Wolfram Language & System Documentation Center. Wolfram Research. Last Modified 2022. https://reference.wolfram.com/language/ref/RegionPlot3D.html.
APA
Wolfram Language. (2007). RegionPlot3D. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/RegionPlot3D.html