ReImPlot

ReImPlot[f,{x,xmin,xmax}]

generates a plot of Re[f] and Im[f] as functions of x from xmin to xmax.

ReImPlot[{f1,f2,},{x,xmin,xmax}]

plots several functions.

ReImPlot[{,w[fi],},]

plots fi with features defined by the symbolic wrapper w.

ReImPlot[,{x}reg]

takes the variable x to be in the geometric region reg.

Details and Options

Examples

open allclose all

Basic Examples  (3)

Plot the real and imaginary parts of a complex-valued function of a real variable:

Plot several functions:

Label each curve:

Scope  (23)

Sampling  (9)

More points are sampled where the function changes quickly:

The plot range is selected automatically:

Use PlotRange to focus in on areas of interest:

The curve is split when there are discontinuities in the function:

Use ExclusionsNone to draw connected curves:

Use PlotPoints and MaxRecursion to control adaptive sampling:

The domain can be specified by a region:

Specify a domain using a MeshRegion:

Plot over an infinite domain:

Labeling and Legending  (8)

There are two standard legends:

Show the legends together:

Use legends with combined styles:

Explicitly label the individual curves:

Identify curves with wrappers:

Curves usually have interactive callouts showing the coordinates when you mouse over them:

Choose from multiple interactive highlighting effects:

Use Highlighted to emphasize specific points in a plot:

Highlight multiple points:

Presentation  (6)

Multiple pairs of curves are automatically colored to be distinct:

Provide explicit styling to different curves:

Add labels and a legend:

Create filled plots:

Use a plot theme:

Use ScalingFunctions to scale the axes:

Options  (65)

ClippingStyle  (2)

Omit clipped regions of the plot:

Show clipped regions with red lines:

ColorFunction  (4)

Color by a scaled coordinate and scaled coordinate, respectively:

Use a named color gradient:

ColorFunction has higher priority than PlotStyle:

Highlight part of the plot:

ColorFunctionScaling  (1)

No argument scaling on the left; automatic scaling on the right:

Exclusions  (2)

In this case, the exclusion comes from a branch cut discontinuity:

Indicate that no exclusions should be computed:

ExclusionStyle  (1)

Use red lines to connect portions of the curve and black points to indicate exclusions:

Filling  (4)

Use symbolic or explicit values:

Fill between curve 1 and the axis:

Fill between curves 1 and 2:

Fill between the real and imaginary parts of each function:

FillingStyle  (3)

Use different fill colors:

Fill with red below the axis and blue above:

Use a variable filling style obtained from a ColorFunction:

MaxRecursion  (1)

Each level of MaxRecursion adaptively subdivides the initial mesh into a finer mesh:

Mesh  (3)

Show the initial and final sampling meshes:

Use 10 mesh points evenly spaced in the direction:

Use an explicit list of values for the mesh in the direction:

MeshFunctions  (2)

Use a mesh evenly spaced in the and directions:

Show seven mesh levels in the direction (red) and 15 in the direction (blue):

MeshShading  (3)

Alternate red and blue arcs in the direction:

MeshShading has higher priority than PlotStyle for styling:

Use PlotStyle for some segments by setting MeshShading to Automatic:

MeshStyle  (2)

Use a red mesh in the direction:

Use a red mesh in the direction and a blue mesh in the direction:

PerformanceGoal  (2)

Generate a higher-quality plot:

Emphasize performance, possibly at the cost of quality:

PlotHighlighting  (8)

Plots have interactive coordinate callouts with the default setting PlotHighlightingAutomatic:

Use PlotHighlightingNone to disable the highlighting for the entire plot:

Use Highlighted[,None] to disable highlighting for a single curve:

Move the mouse over the curve to highlight it with a ball and label:

Use a ball and label to highlight a specific point on the curve:

Move the mouse over the curve to highlight it with a label and droplines to the axes:

Use a ball and label to highlight a specific point on the curve:

Move the mouse over the plot to highlight it with a slice showing values corresponding to the position:

Highlight the curves at a fixed value:

Move the mouse over the plot to highlight it with a slice showing values corresponding to the position:

Use a component that shows the points on the curve closest to the position of the mouse cursor:

Specify the style for the points:

Use a component that shows the coordinates on the curve closest to the mouse cursor:

Use Callout options to change the appearance of the label:

Combine components to create a custom effect:

PlotLabel  (1)

Add an overall label to the plot:

PlotLabels  (6)

Specify text to label curves:

Modify the appearance of the labels:

Place the labels differently for each curve:

PlotLabels"Expressions" uses functions as curve labels:

Use callouts to identify the curves:

Use None to not add a label:

PlotLegends  (7)

Create a legend based on the functions:

Use "ReIm" to distinguish between the real and imaginary parts of the function:

Use "ReImExpressions" to show both:

Use a legend showing all the style combinations:

Make two different legends:

Modify the legend labels:

Generate a third legend:

PlotPoints  (1)

Use more initial points to get smoother curves:

PlotRange  (1)

The plot range is selected automatically:

Focus on a specified range of values:

PlotStyle  (3)

Explicitly specify the style for different curves and regions:

ReImStyle takes precedence over PlotStyle:

Combine with ReImStyle:

PlotTheme  (3)

Use a theme with bright colors:

Add a theme with a legend:

Change plot styles:

RegionFunction  (1)

Show the curve where :

ReImLabels  (2)

Modify the labels for the real and imaginary parts of a function using predetermined option values:

Specify custom labels for the real and imaginary parts of a function:

ReImStyle  (2)

By default, the real and imaginary parts are solid and dashed, respectively:

Modify the real and imaginary styles:

Applications  (7)

Plot Fourier transforms:

Plot the solution of a complex differential equation with initial conditions:

Plot the eigenvalues of a matrix as a function of a parameter:

Plot solutions of an equation as a function of a parameter:

Graph special functions:

Plot fractional derivatives of :

Plot the complex solution of the Schrödinger equation for a particle in a box:

Properties & Relations  (8)

ReImPlot is a special case of Plot:

Use AbsArgPlot to plot the magnitude and argument over the real numbers:

ComplexPlot shows the argument and magnitude of a function using color:

Use ComplexPlot3D to use the z axis for the magnitude:

Use ComplexListPlot to show the location of complex numbers in the plane:

ComplexContourPlot plots curves over the complexes:

ComplexRegionPlot plots regions over the complexes:

ComplexStreamPlot and ComplexVectorPlot treat complex numbers as directions:

Possible Issues  (1)

ScalingFunctions applies to the real and imaginary parts:

Wolfram Research (2019), ReImPlot, Wolfram Language function, https://reference.wolfram.com/language/ref/ReImPlot.html (updated 2023).

Text

Wolfram Research (2019), ReImPlot, Wolfram Language function, https://reference.wolfram.com/language/ref/ReImPlot.html (updated 2023).

CMS

Wolfram Language. 2019. "ReImPlot." Wolfram Language & System Documentation Center. Wolfram Research. Last Modified 2023. https://reference.wolfram.com/language/ref/ReImPlot.html.

APA

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

BibTeX

@misc{reference.wolfram_2024_reimplot, author="Wolfram Research", title="{ReImPlot}", year="2023", howpublished="\url{https://reference.wolfram.com/language/ref/ReImPlot.html}", note=[Accessed: 22-November-2024 ]}

BibLaTeX

@online{reference.wolfram_2024_reimplot, organization={Wolfram Research}, title={ReImPlot}, year={2023}, url={https://reference.wolfram.com/language/ref/ReImPlot.html}, note=[Accessed: 22-November-2024 ]}