Professional Documents
Culture Documents
:
-1- - plot3
plot3 .
plot . .
: :
x=t
tR
)y= sin(t
)z=cos(t
:
-1- -
;>>t=0: pi/50:10*pi
)>>plot3(sin(t) , cos(t) , t); xlabel(sin(x)); ylabel(cos(x)); zlabel(x
:
-2-1
Rotate 3D view
. Tools Camera
Motion .
view :
)]view([az , el
az el xy y
.
:
-3-1 : mesh, meshc, meshz
( ) . mesh :
)mesh(x,y,z
z x y . z
y x x . y
x y
y x . .
meshgrid :
;)[x_new,y_new]=meshgrid(x,y
meshc .
meshz x-y .
:
-3-1 --
: 1 peaks :
:
-3-1 --
:
-3-1 --
. hidden :
>>hidden off
>> hidden on
>> hidden
:
-4-1 surf : surfl surfc
.
surf mesh .
surfl surf .
surfc meshc
:
-4-1 -
: shading
shading . surf
:
shading flat
shading interp
shading faceted
:
-4-1 -
: colormap
:
hsv, cool , hot, prism, gray
:
-5-11
camorbit
:
)camorbit(theta,phi
:theta
:phi
:
;) camorbit(theta,phi,
z
.
-
:
-5-11 -...
:
)surf(peaks
axis vis3d
axis off
for i=1:360
)'camorbit(2,0,'data
drawnow
end
:
-6-11
campos :
)]campos([x,y,z
.
:
)surf(peaks
axis vis3d off
for x = -200:5:200
)]campos([x,5,10
drawnow
end
-
:
-7-11
colorbar
:
)>> surf(peaks
>> colorbar
(
)z .
:
-8-1 contour , contour3-
.
.
contour contour3 mesh.
:
[c,h] = contour(peaks); clabel(c,h), colorbar
:
-9-11 pcolor
( )z
. surf.
:
)>>pcolor(peaks
:
;))t=tril(ones(10
;])ts=[t,fliplr(t
;]tss=[flipud(ts);ts
))pcolor(tss); colormap(gray(2
:
-9-11
demo Graphics .
Start Demo-> Graphics .