VECTOR_PLOT is a FORTRAN90 program which plots a 2D vector field at scattered points.
VECTOR_PLOT reads a file of (X,Y) locations, and a file of (U,V) vector values, and draws a plot of the corresponding vector field (U(X,Y), V(X,Y)), and of the normalized direction field.
VECTOR_PLOT requires the user to specify a "scale factor" for the size of the vectors. A factor of 1.0 is normal, and corresponds to drawing the trail of particles that have traveled for one time unit under the influence of the given velocity. A factor of 0.5 or 2.0 might be used to shorten or lengthen the vectors.
VECTOR_PLOT requires the user to specify a "thinning factor" to discard some of the data. A factor of 1 keeps all the data. A factor of 2 should throw away about every other column and every other row of data (if the (X,Y) coordinates fall on a regular grid.) Thinning the data is a crude but useful tool, because most data files contain far too many vectors to plot.
vector_plot xy_file uv_filewhere
The computer code and data files made available on this web page are distributed under the GNU LGPL license.
VECTOR_PLOT is available in a FORTRAN90 version
BUMP, a FORTRAN90 program which uses the finite element method to study the influence of an obstacle in channel flow. The velocity field can be plotted by VECTOR_PLOT.
CASE1_FLOW, a dataset directory which contains a sequence of velocity vector fields that can be plotted by VECTOR_PLOT.
CAVITY_FLOW, a dataset directory which contains a sequence of velocity vector fields that can be plotted by VECTOR_PLOT.
CHANNEL, a FORTRAN90 program which uses the finite element method to study flow in a channel. The velocity field can be plotted by VECTOR_PLOT.
DIRECTION_ARROWS, a MATLAB program which can plot direction fields.
DIRECTION_ARROWS_GRID, a MATLAB program which reads files of node and velocity data, and, using interpolation, creates a velocity direction plot with arrows place on a uniform grid of the user's specification.
DIRECTION_ARROWS_SEQUENCE, a MATLAB program which can plot a sequence of direction fields for an animation.
DIRECTION_ARROWS_SEQUENCE2, a MATLAB program which can plot a sequence of direction fields for an animation.
DIRECTION_ARROWS2, a MATLAB program which can plot direction fields.
INOUT_FLOW, a dataset directory which contains a sequence of velocity vector fields that can be plotted by VECTOR_PLOT.
INOUT_FLOW2, a dataset directory which contains a sequence of velocity vector fields that can be plotted by VECTOR_PLOT.
MHD_FLOW, a FORTRAN90 program which computes velocity fields which can be plotted by VECTOR_PLOT.
TCELL_FLOW, a dataset directory which contains a sequence of velocity vector fields that can be plotted by VECTOR_PLOT.
VECTOR_MAGNITUDE_GRID, a MATLAB program which reads node and vector data from a file, computes an interpolatory function, evaluates on a uniform grid of points specified by the user, and displays a contour plot of the vector magnitude.
VECTOR_STREAM_GRID, a MATLAB program which reads node and vector data from a file, computes an interpolatory function, evaluates on a uniform grid of points specified by the user, and displays a streamline plot of the vector field.
VELOCITY_ARROWS, a MATLAB program which can plot velocity fields.
VELOCITY_ARROWS_GRID, a MATLAB program which reads files of node and velocity data, and, using interpolation, creates a vector plot with arrows place on a uniform grid of the user's specification.
VELOCITY_ARROWS_GRID2, a MATLAB program which reads a single file of node and velocity data, and using interpolation is able to display a velocity vector field along any uniform grid of points specified by the user.
VELOCITY_ARROWS_SEQUENCE, a MATLAB program which can plot a sequence of velocity fields for an animation.
VELOCITY_ARROWS_SEQUENCE2, a MATLAB program which can plot a sequence of velocity fields for an animation.
VELOCITY_ARROWS2, a MATLAB program which can plot velocity fields.
Here is some data from a tcell_flow calculation:
Here is some test data from the MHD_FLOW program. Test files you may copy include:
Here is some spiral test data. Test files you may copy include:
You can go up one level to the FORTRAN90 source codes.