gusucode.com > 《精通matlab 7》包括配套光盘 > 配套光盘里的程序附件/Ex-25/Ex2506.m
%例25-6 shading模式 %Ex25-6 Shading mode clear close all [x,y]=meshgrid(-3:0.5:3); z=x.*y+sin(x*pi)+cos(y*pi); subplot(2,2,1) surf(x,y,z) title('no shading') subplot(2,2,2) surf(x,y,z) shading flat title('shading flat') subplot(2,2,3) surf(x,y,z) shading faceted title('shading faceted') subplot(2,2,4) surf(x,y,z) shading interp title('shading interp')