MATLAB Function Reference    
streamribbon

Creates a 3-D stream ribbon plot

Syntax

Description

streamribbon(X,Y,Z,U,V,W,startx,starty,startz) draws stream ribbons from vector volume 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). startx, starty, and startz define the starting positions of the stream ribbons at the center of the ribbons. The section Starting Points for Stream Plots in Visualization Techniques provides more information on defining starting points.

The twist of the ribbons is proportional to the curl of the vector field. The width of the ribbons is calculated automatically.

Generally, you should set the DataAspectRatio (daspect) before calling streamribbon.

streamribbon(U,V,W,startx,starty,startz) assumes X, Y, and Z are determined by the expression:

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

streamribbon(vertices,X,Y,Z,cav,speed) assumes precomputed streamline vertices, curl angular velocity, and flow speed. vertices is a cell array of stream line vertices (as produced by stream3). X, Y, Z, cav, and speed are 3-D arrays.

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

where [m,n,p] = size(cav)

streamribbon(vertices,twistangle) uses the cell array of vectors twistangle for the twist of the ribbons (in radians). The size of each corresponding element of vertices and twistangle must be equal.

streamribbon(...,width) sets the width of the ribbons to width.

h = streamribbon(...) returns a vector of handles (one per start point) to surface objects.

Examples

This example uses stream ribbons to indicate the flow in the wind data set. Inputs include the coordinates, vector field components, and starting location for the stream ribbons.

This example uses precalculated vertex data (stream3), curl average velocity (curl), and speed (

). Using precalculated data enables you to use values other than those calculated from the single data source. In this case, the speed is reduced by a factor of 10 compared to the previous example.

This example specifies a twist angle for the stream ribbon.

This example combines cone plots (coneplot) and stream ribbon plots in one graph.

See also

curl, streamtube, streamline, stream3


 streamparticles streamslice