用matlab画出这个函数的图像 z=0.5-(sin(x.^2+y.^2)-0.5).^2/(1+0.001*(x.^2+y.^2)).^2

问题描述:

用matlab画出这个函数的图像 z=0.5-(sin(x.^2+y.^2)-0.5).^2/(1+0.001*(x.^2+y.^2)).^2
z=0.5-(sin(x.^2+y.^2)-0.5).^2/(1+0.001*(x.^2+y.^2)).^2
X>=-4;Y

>> [x,y]=meshgrid(-2:0.1:2);
>> z=0.5-(sin(x.^2+y.^2)-0.5).^2./(1+(x.^2+y.^2)).^2;
>> mesh(x,y,z)也可以
还可以这样
>> [x,y]=meshgrid(-2:0.1:2);
>> z=0.5-(sin(x.^2+y.^2)-0.5).^2./(1+(x.^2+y.^2)).^2;
>> imshow(mat2gray(z));