VectorDisplacementPlot

VectorDisplacementPlot[{vx,vy},{x,xmin,xmax},{y,ymin,ymax}]

generates a displacement plot for the vector field {vx,vy} as a function of x and y.

VectorDisplacementPlot[{vx,vy},{x,y}reg]

plots the displacement over the geometric region reg.

VectorDisplacementPlot[{{vx,vy},s},]

uses the scalar field s to style the displacement.

Details and Options

Examples

open allclose all

Basic Examples  (5)

Plot a reference region and the corresponding (scaled) deformed region for a specified displacement field:

Include a legend for the norms of the displacements:

Show a sampling of displacement vectors that extend from points in the reference region to corresponding points in the deformed region:

Use a scalar field other than the norm of the displacement field to color the deformed region:

Plot the displacement for a bracket anchored along the bottom that is being pulled laterally:

Color the displacement according to the shear stress for the bracket:

Scope  (19)

Sampling  (12)

Visualize a scaled displacement field by comparing a reference and a deformed region:

Vectors are drawn from points in the reference region to corresponding points in the (scaled) deformed region:

Restrict vectors to points on the boundary:

Specify other vectors:

Displacements can be drawn to scale:

Use the displacement field over a specified region:

The domain may be specified by a region:

The domain may be a curve:

The domain may be an ImplicitRegion:

The domain may be a ParametricRegion:

The domain may be a MeshRegion:

The domain may be a BoundaryMeshRegion:

Presentation  (7)

Specify the ColorFunction for the deformed region:

Specify the VectorColorFunction independently of the ColorFunction:

Use a single color for the arrows:

Include a legend for the norms of the displacements:

Include a legend for the optional scalar field:

Include a Mesh:

Draw displacements to scale:

Options  (64)

AspectRatio  (2)

By default, the aspect ratio is Automatic:

Set the aspect ratio:

BoundaryStyle  (3)

By default, the boundary style matches the interior colors in the deformed region:

Specify the BoundaryStyle:

BoundaryStyle applies to regions cut by RegionFunction:

ColorFunction  (4)

By default, the deformed region is colored by the norm of the field:

Specify a scalar field for the colors:

Use a named color gradient:

Specify a custom ColorFunction:

ColorFunctionScaling  (2)

Use the natural range of norm values:

Control the scaling of the individual arguments of the ColorFunction:

Mesh  (6)

Specify a Mesh to visualize the displacements:

Show the initial and final sampling mesh:

Specify 10 mesh lines in the direction and 5 in the direction:

Use mesh lines at specific values:

Highlight specific mesh lines:

Mesh lines are suppressed in the reference region if the boundary and filling of the reference region are removed:

MeshFunctions  (2)

By default, the mesh lines are in the and directions:

Use circular and radial mesh lines:

MeshStyle  (2)

Style the mesh lines:

Style the mesh lines differently in different directions:

PlotLegends  (3)

Include a legend to show the color range of vector norms:

Include a legend for the optional scalar field:

Control the placement of the legend:

PlotPoints  (1)

Use more points to get smoother regions:

PlotRange  (3)

The full PlotRange is used by default:

Specify an explicit limit that is shared by the and directions:

Specify different plot ranges in the and directions:

PlotStyle  (4)

Remove the filling for the deformed region:

Apply a Texture to the deformed region:

Use PatternFilling to style the deformed region:

ColorFunction has precedence over PlotStyle:

RegionBoundaryStyle  (2)

Specify the boundary color of the reference region:

Remove the boundary of the reference region:

RegionFillingStyle  (2)

Specify the filling of the reference region:

Remove the filling for the reference region:

RegionFunction  (1)

Use a RegionFunction to specify the reference region:

VectorAspectRatio  (2)

The default aspect ratio for a vector marker is 1/4:

Specify the relative width of a vector marker:

VectorColorFunction  (3)

By default, if VectorColorFunction is Automatic, then the VectorColorFunction matches the ColorFunction:

Specify a VectorColorFunction that is different from the ColorFunction:

Use no VectorColorFunction:

VectorColorFunctionScaling  (1)

Use the natural range of norm values for vector colors:

VectorMarkers  (3)

By default, vectors are drawn from points in the reference region to corresponding points in the deformed region:

Center the markers at the sampled points:

Use a named appearance to draw the vectors:

VectorPoints  (9)

No vectors are shown by default:

Show vectors sampled from the entire original region:

Sample vectors from the boundary of the region:

Use symbolic names to specify the density of vectors:

Use symbolic names to specify the arrangement of vectors:

Specify the number of vectors in the and directions:

Specify a different number of vectors in the and directions:

Give specific locations for vectors:

Along a curve, vectors are equally spaced by default:

VectorRange  (2)

Specify the range of vector norms:

Style the clipped vectors:

VectorScaling  (2)

By default, vectors extend from points in the reference region to corresponding points in the deformed region:

Set all vectors to have the same size:

VectorSizes  (4)

By default, vectors extend from points in the reference region to corresponding points in the deformed region:

Specify the range of arrow lengths:

Suppress scaling of the displacement vectors so that a rotation of 45° looks appropriate:

Suppress scaling of the displacement vectors even if no vectors are displayed:

VectorStyle  (1)

VectorColorFunction has precedence over VectorStyle:

Applications  (24)

Basic Applications  (16)

A constant displacement field moves each point in the reference region by the same amount:

Note that the displacements are automatically scaled so that very small and very large displacements are both visible:

Use VectorSizesFull to display the actual sizes of displacements:

Color is used to indicate the magnitude of the displacements:

Color the region by a different scalar function:

Use arrows to indicate initial and final locations for a sample points:

Visualize a dilation in the direction:

Visualize a contraction in the direction:

Visualize a dilation in the direction and a contraction in the direction:

Visualize a shear in the direction:

Visualize a shear in the direction:

Visualize a combined shear in the and directions:

Visualize a rotation about the origin:

Combine a rotation, a shear and a dilation:

Visualize a rotation for points near the origin:

Visualize a shear for points near the origin:

Visualizing Eigenvalues and Eigenvectors  (1)

Define a 2×2 matrix:

Compute its eigenvalues and eigenvectors. Eigenvectors and eigenvalues solve the eigenvalue problem , , which can be interpreted here as finding directions that are not rotated by the matrix under multiplication:

The unit disk is stretched by a factor of 3 in the direction and a factor of 2 in the direction:

The original disk has area :

The area of the interior of the resulting ellipse is the product of the eigenvalues times the original area:

Note that multiplication by rotates all vectors except those in the eigenvector directions:

Define a matrix with one positive and one negative eigenvalue:

Use arrows to visualize how the region turns inside out in the direction because of the negative eigenvalue:

Define a matrix with a zero eigenvalue:

Observe that the original disk is stretched by a factor of 5 in the direction, but completely collapsed in the direction:

Define a matrix with a repeated real eigenvalue:

Observe that the vectors are rotated unless they point in the direction:

Define a matrix with complex eigenvalues:

The real part of the eigenvalues causes a uniform dilation and the imaginary part causes every vector to rotate:

Solid Mechanics  (5)

Consider a linearly elastic bar of length and height subjected to a moment of magnitude at both ends:

Specify Young's modulus and Poisson's ratio:

Specify the magnitude of the applied moment:

The resulting displacement vector is:

Visualize the deformed bar:

The only nontrivial stress is the normal stress in the direction:

Color the deformed bar by :

An elastica is a thin, elastic rod that bends without stretching. Consider an initially straight, vertical elastica that is clamped at the bottom end at and loaded with a weight at the top end that is sufficiently large to make the elastica parallel to the ground at the loaded end. Jacob Bernoulli famously found that the arc length is given by:

The total length of the elastica is:

Similarly, the height of a point on the deformed elastica is given by:

In terms of the parameter , the resulting displacement field is:

Create a ParametricRegion for the undeformed elastica:

Visualize the deformed elastica with the weight attached:

Consider an infinite, linearly elastic, thin plate with a hole of radius at the origin with a uniform tensile load in the horizontal direction:

Specify Young's modulus and Poisson's ratio :

Specify the magnitude of the applied tensile load:

Compute the horizontal () and vertical () displacements assuming a state of plane stress:

Compute the hoop stress:

Plot the deformed solid region and color it by the dimensionless hoop stress. Note the stress concentration at the top and bottom of the hole:

The stress concentration factor is 3, regardless of the magnitude of the applied load:

Define an L-shaped region that is fixed at the bottom and has a uniform tensile load applied on the top-right edge:

Specify the governing equations for plane strain:

Specify the boundary conditions on the different edges of the region:

Solve the governing equations:

Plot the deformed region and note that the displacements are amplified to make them more visible:

Color the region by different stress components:

Compute the von Mises stress:

Color the region with the von Mises stress:

This example considers a sequence of deformations that correspond to an increasing load.

Consider a thin quarter-arch that is fixed at (red) with a variable vertical traction applied at (blue):

Assume a state of plane stress and define the displacement variables and the material parameters:

Specify a maximum load:

Compute the displacement and shear strain for the maximum load:

Compute the minimum and maximum values of the shear strain:

Create a color function for the strains that applies for all load values from zero load up to the maximum:

Create a legend that applies for all load values:

Compute and visualize the deformations for a sequence of load values, using the shear strain to color the deformed arch:

Click the following image to cycle through the loads. Note that the displacements are large because the arch is thin and that the colors are consistent across all of the load values:

Complex Variables  (1)

Define a complex function :

Compute the displacement field:

Visualize the complex transformation and note that lines are mapped to circles:

Use arrows to illustrate how points on the concentric circles TemplateBox[{z}, Abs]=1/2 and TemplateBox[{z}, Abs]=2 are transformed under :

Map Projections  (1)

Generate a number of disks and form their union:

Superimpose the disks on a map of the world with an equirectangular projection:

Specify the displacement from the equirectangular projection to a Mercator projection:

Show the deformed disks on a map with the Mercator projection:

Properties & Relations  (9)

Use ListVectorDisplacementPlot to visualize a deformation based on displacement field data:

Use VectorDisplacementPlot3D to visualize the deformation of a 3D region associated with a displacement vector field:

Use ListVectorDisplacementPlot3D to visualize the same deformation based on data:

Use VectorPlot to directly plot a vector field:

Use StreamPlot to plot with streamlines instead of vectors:

Use ListVectorPlot or ListStreamPlot for plotting data:

Use VectorDensityPlot to add a density plot of the scalar field:

Use StreamDensityPlot to plot streamlines instead of vectors:

Use ListVectorDensityPlot or ListStreamDensityPlot for plotting data:

Use LineIntegralConvolutionPlot to plot the line integral convolution of a vector field:

Use VectorPlot3D and StreamPlot3D to visualize 3D vector fields:

Use ListVectorPlot3D or ListStreamPlot3D to plot with data:

Plot vectors on surfaces with SliceVectorPlot3D:

Use ListSliceVectorPlot3D to plot with data:

Use ComplexVectorPlot or ComplexStreamPlot to visualize a complex function of a complex variable as a vector field or with streamlines:

Use GeoVectorPlot to plot vectors on a map:

Use GeoStreamPlot to plot streamlines instead of vectors:

Wolfram Research (2021), VectorDisplacementPlot, Wolfram Language function, https://reference.wolfram.com/language/ref/VectorDisplacementPlot.html.

Text

Wolfram Research (2021), VectorDisplacementPlot, Wolfram Language function, https://reference.wolfram.com/language/ref/VectorDisplacementPlot.html.

CMS

Wolfram Language. 2021. "VectorDisplacementPlot." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/VectorDisplacementPlot.html.

APA

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

BibTeX

@misc{reference.wolfram_2024_vectordisplacementplot, author="Wolfram Research", title="{VectorDisplacementPlot}", year="2021", howpublished="\url{https://reference.wolfram.com/language/ref/VectorDisplacementPlot.html}", note=[Accessed: 23-April-2024 ]}

BibLaTeX

@online{reference.wolfram_2024_vectordisplacementplot, organization={Wolfram Research}, title={VectorDisplacementPlot}, year={2021}, url={https://reference.wolfram.com/language/ref/VectorDisplacementPlot.html}, note=[Accessed: 23-April-2024 ]}