mm2734.m

来自「matlab7.0这本书的源代码」· M 代码 · 共 15 行

M
15
字号
fstr=['3*(1-x).^2.*exp(-(x.^2) - (y+1).^2)' ...   ' - 10*(x/5 - x.^3 - y.^5).*exp(-x.^2-y.^2)' ...   ' - 1/3*exp(-(x+1).^2 - y.^2)'];
subplot(2,2,1)
ezmesh(fstr)
title('Figure 27.34a: Mesh of peaks(x,y)')
subplot(2,2,2)
ezsurf(fstr)
title('Figure 27.34b: Surf of peaks(x,y)')
subplot(2,2,3)
ezcontour(fstr)
title('Figure 27.34c: Contour of peaks(x,y)')
subplot(2,2,4)
ezcontourf(fstr)
title('Figure 27.34d: Contourf of peaks(x,y)')

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?