1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106
|
plot3d(2) Scilab Function plot3d(2)
NAME
plot3d - surface plotting
CALLING SEQUENCE
plot3d(x,y,z [,theta,alpha,leg [,flag,ebox]])
plot3d(xf,yf,zf [,theta,alpha,leg [,flag,ebox]])
plot3d(xf,yf,list(zf,colors) [,theta,alpha,leg [,flag,ebox]])
PARAMETERS
x,y : matrices of sizes (1,n1) and (1,n2) (point coordinates).
These coordinates must be monotone.
z : matrix of size (n1,n2) ( z(i,j) : value of f at the point
(x(i),y(j))
xf,yf,zf : (nf,n) matrices. xf(:,i),yf(:,i),zf(:,i) are respectively
the
x-axis,y-axis and z-axis coordinates of the ith facet.
Where nf is the size of the facets (nf must be greater than
2) and n the number of facets. One can use list(zf,colors),
with colors a vector of size n in order to give specific
colors for each facet.
theta, alpha : real values giving in degree the spherical coordinates of
the observation point
leg : string (captions for each axis. this is string with @ as a
field separator, for example : "X@Y@Z")
flag : is a real vector of size three flag=[mode,type,box]
mode
: string (treatment of hidden parts)
mode > 0
the hidden parts of the surface are removed and the sur-
face is painted with color mode.
mode = 0
the hidden parts of the surface are drawn.
mode < 0
only the shadow of the surface is painted with color or
pattern -mode.
type
: scaling
if type = 0 the plot is made using the current 3D
scaling ( set by a previous call to
param3d, plot3d, contour, plot3d1)
if type = 1 the boundaries are specified by the value
of the parameter
ebox=[xmin,xmax,ymin,ymax,zmin,zmax]
else the boundaries are computed with the given datas.
box
: frame display around the plot.
box=0
nothing is drawn around the plot
box=1
unimplemented ( like box=0 )
box=2
only the axes behind the surface are drawn
box=3
a box surrounding the surface is drawn and captions are
added
box=4
a box surrounding the surface is drawn, captions are
added and axes too.
DESCRIPTION
plot3d(x,y,z,theta,alpha,leg [,flag,ebox]) draw the surface z=f(x,y)
defined by a matrix of coordinates.
plot3d(xf,yf,zf,theta,alpha,leg [,flag,ebox]) draw the non projectable sur-
face 0=f(x,y,z) defined by a set of facets. xf(:,i),yf(:,i),zf(:,i) are
respectively the x-axis,y-axis and z-axis coordinates of the ith facet.
Enter the command plot3d() to see a demo.
EXAMPLE
plot3d(1:10,1:20,10*rand(10,20),35,45,"X@Y@Z",[2,2,3])
xbasc();
t=(0:0.3:2*%pi)';zmat=sin(t)*cos(t');
[xx,yy,zz]=genfac3d(t,t,zmat);
plot3d([xx xx],[yy yy],[zz 4+zz]);
xbasc();
plot3d([xx xx],[yy yy],list([zz zz+4],[4*ones(1,400) 5*ones(1,400)]))
SEE ALSO
plot3d1, genfac3d, hist3d, geom3d, param3d
AUTHOR
J.Ph.C.
|