MATLAB Function Reference    
interpstreamspeed

Interpolate stream line vertices from flow speed

Syntax

Description

interpstreamspeed(X,Y,Z,U,V,W,vertices) interpolates stream line vertices based on the magnitude of the vector data U, V, W. The arrays X, Y, Z define the coordinates for U, V, W and must be monotonic and 3-D plaid (as if produced by meshgrid).

interpstreamspeed(U,V,W,vertices) assumes X, Y, and Z are determined by the expression:

where [m n p] = size(U).

interpstreamspeed(X,Y,Z,speed,vertices) uses the 3-D array speed for the speed of the vector field.

interpstreamspeed(speed,vertices) assumes X, Y, and Z are determined by the expression:

where [m n p]=size(speed).

interpstreamspeed(X,Y,U,V,vertices) interpolates streamline vertices based on the magnitude of the vector data U, V. The arrays X, Y define the coordinates for U, V and must be monotonic and 2-D plaid (as if produced by meshgrid)

interpstreamspeed(U,V,vertices) assumes X and Y are determined by the expression:

where [M N]=size(U).

interpstreamspeed(X,Y,speed,vertices) uses the 2-D array speed for the speed of the vector field.

interpstreamspeed(speed,vertices) assumes X and Y are determined by the expression:

where [M,N]= size(speed)

interpstreamspeed(...,sf) uses sf to scale the magnitude of the vector data and therefore controls the number of interpolated vertices. For example, if sf is 3, then interpstreamspeed creates only one third of the vertices.

vertsout = interpstreamspeed(...) returns a cell array of vertex arrays.

Examples

This example draws stream lines using the vertices returned by interpstreamspeed. Dot markers indicate the location of each vertex. This example enables you to visualize the relative speeds of the flow data. Stream lines having widely space vertices indicate faster flow; those with closely spaced vertices indicate slower flow.

This example plots stream lines whose vertex spacing indicates the value of the gradient along the stream line.

See Also

stream2, stream3, streamline, streamslice, streamparticles

Volume Visualization for related functions


  interpn intersect