1
<?xml version="1.0" encoding="UTF-8"?>
2
<!DOCTYPE MAN SYSTEM "../../manrev.dtd">
4
<LANGUAGE>eng</LANGUAGE>
8
<TYPE>Scilab Function</TYPE>
10
<DATE>April 1993</DATE>
12
<SHORT_DESCRIPTION name="champ">2D vector field plot</SHORT_DESCRIPTION>
15
<CALLING_SEQUENCE_ITEM>champ(x,y,fx,fy,[arfact,rect,strf])</CALLING_SEQUENCE_ITEM>
17
<CALLING_SEQUENCE_ITEM>champ(x,y,fx,fy,<opt_args>)</CALLING_SEQUENCE_ITEM>
23
<PARAM_NAME>x,y</PARAM_NAME>
26
<SP>: two vectors which define the grid.</SP>
31
<PARAM_NAME>fx</PARAM_NAME>
34
<SP>: a matrix which describes the x component of the vector field.
35
<VERB>fx(i,j)</VERB> is the x component of the vector field at point
36
<VERB>(x(i),y(j))</VERB>.</SP>
41
<PARAM_NAME>fy</PARAM_NAME>
44
<SP>: a matrix which describes the y component of the vector field.
45
<VERB>fy(i,j)</VERB> is the y component of the vector field at point
46
<VERB>(x(i),y(j))</VERB>.</SP>
51
<PARAM_NAME><opt_args></PARAM_NAME>
54
<SP>: This represents a sequence of statements <VERB>key1=value1,
55
key2=value2</VERB>,... where <VERB>key1</VERB>,
56
<VERB>key2,...</VERB> can be one of the following: arfact, rect,
57
strf (see below).</SP>
62
<PARAM_NAME>arfact</PARAM_NAME>
65
<SP>: an optional argument of type real which gives a scale factor
66
for the display of the arrow heads on the plot (default value is
72
<PARAM_NAME>rect</PARAM_NAME>
75
<SP>: a vector <VERB>rect=[xmin,ymin,xmax,ymax]</VERB> which gives
76
the boundaries of the graphics frame to use.</SP>
81
<PARAM_NAME>strf</PARAM_NAME>
84
<SP>: a string of length 3 "xyz" which has the same meaning as the
85
<VERB>strf</VERB> parameter of <VERB>plot2d</VERB>. The first
86
character x has no effect with <VERB>champ</VERB>.</SP>
93
<P><VERB>champ</VERB> draws a 2D vector field. The length of the arrows is
94
proportional to the intensity of the field.</P>
96
<P>If you want colored arrows with the color of the arrows depending on
97
the intensity of the field, use <VERB>champ1</VERB>.</P>
99
<P>Enter the command <VERB>champ()</VERB> to see a demo.</P>
104
// using rect as plot boundaries
105
champ(-5:5,-5:5,rand(11,11),rand(11,11),rect=[-10,-10,10,10],arfact=2)
106
// using (x,y) to get boundaries
108
champ(-5:5,-5:5,rand(11,11),rand(11,11),2,[-10,-10,10,10],"021")
126
<AUTHOR>J.Ph.C.</AUTHOR>
b'\\ No newline at end of file'