1 |
<TITLE>/</TITLE> |
---|
2 |
<BODY> |
---|
3 |
<A HREF = "index.html">[Index for ./mat4]</A> |
---|
4 |
<A HREF = "../index.html">[Return to Master Index]</A> |
---|
5 |
<H1>vecplot2</H1> |
---|
6 |
<H2>(./mat4/vecplot2.m)</H2> |
---|
7 |
<HR><H3>Function Synopsis</H3> |
---|
8 |
<pre>retval=vecplot2(xin,yin,uin,vin,sc,sclab,scale_xor,scale_yor)</pre> |
---|
9 |
<HR><H3>Help text</H3> |
---|
10 |
<pre> |
---|
11 |
VECPLOT2 routine to plot vectors. |
---|
12 |
VECPLOT2 draws vectors on the current figure, at (x,y) |
---|
13 |
locations determined in one of two ways. If the first |
---|
14 |
argument to VECPLOT is a fem_grid_struct, then VECPLOT |
---|
15 |
extracts the FEM domain coordinates as the vector origins. |
---|
16 |
Otherwise, the user supplies the (x,y) coordinates |
---|
17 |
explicitly. This flexibility exists because vector |
---|
18 |
plotting does not require any knowledge of nodal |
---|
19 |
connectivity, and perhaps the (u,v) data are not |
---|
20 |
from a FEM model output. |
---|
21 |
|
---|
22 |
VECPLOT scales the magnitude of |
---|
23 |
(u,v) by the magnitude of max(abs(u,v)) and then |
---|
24 |
forces a vector of magnitude sc to be 10% of the x data |
---|
25 |
range. By default, sc = 1., so that a 1 m/s vector will |
---|
26 |
be scaled to 10% of the x data range. If sc=.5, then |
---|
27 |
a vector magnitude of 50 cm/s will be scaled to 10% of the |
---|
28 |
x data range. Decreasing sc serves to make the vectors |
---|
29 |
appear larger. VECPLOT then prompts the user to place |
---|
30 |
the vector scale on the figure, unless scale_xor,scale_yor |
---|
31 |
is specified (see below). |
---|
32 |
|
---|
33 |
hv=vecplot(x,y,u,v,sc,sclab) |
---|
34 |
OR |
---|
35 |
hv=vecplot(fem_grid_struct,u,v,sc,sclab) |
---|
36 |
|
---|
37 |
|
---|
38 |
INPUT: fem_grid_struct (from LOADGRID, see FEM_GRID_STRUCT) |
---|
39 |
OR |
---|
40 |
x,y - vector origins |
---|
41 |
u,v - vector amplitudes |
---|
42 |
These inputs are optional, but if one is needed, all |
---|
43 |
preceeding it wil be required. |
---|
44 |
sc - vector scaler; (optional; default = 1.) |
---|
45 |
sclab - label for vector scale; (optional; default = 'cm/s') |
---|
46 |
scale_xor,scale_yor - location to place vector scale |
---|
47 |
|
---|
48 |
OUTPUT: h - vector of handles to the vector lines drawn, the |
---|
49 |
scale vector, and the scale vector text. |
---|
50 |
|
---|
51 |
NOTES: VECPLOT requires atleast 2 coordinates and vectors. |
---|
52 |
|
---|
53 |
CALL: hv=vecplot(x,y,u,v,sc,sclab) |
---|
54 |
or |
---|
55 |
hv=vecplot(fem_grid_struct,u,v,sc,sclab) |
---|
56 |
|
---|
57 |
Written by : Brian O. Blanton |
---|
58 |
|
---|
59 |
</pre> |
---|
60 |
<HR> |
---|
61 |
Produced by <A HREF="http://www.nd.edu/Courses/kantor/matlab/mat2html">mat2html</A> on Tue Feb 2 16:15:45 EST 1999 |
---|
62 |
<BR> |
---|
63 |
Cross-Directory links are: OFF<BR> |
---|
64 |
</BODY> |
---|