matlab使用插值进行着色处理Z must be a matrix,not a scalar or vector
来源:学生作业帮 编辑:大师作文网作业帮 分类:综合作业 时间:2024/11/17 20:09:13
matlab使用插值进行着色处理Z must be a matrix,not a scalar or vector
z应该怎么改?
>> [x,y]=meshgrid(-5:0.1:5);
>> z=5;
>> surf(x,y,z);shading interp;
Error using surf (line 75)
Z must be a matrix,not a scalar or vector
z应该怎么改?
>> [x,y]=meshgrid(-5:0.1:5);
>> z=5;
>> surf(x,y,z);shading interp;
Error using surf (line 75)
Z must be a matrix,not a scalar or vector
z应该这样写:z=5*ones(size(x));
surf和mesh中x,y,z必须是同样维度的矩阵.
完整代码如下:
clear
clc
[x,y]=meshgrid(-5:0.1:5);
z=5*ones(size(x));
surf(x,y,z);
shading interp;
运行出来的结果如下:
surf和mesh中x,y,z必须是同样维度的矩阵.
完整代码如下:
clear
clc
[x,y]=meshgrid(-5:0.1:5);
z=5*ones(size(x));
surf(x,y,z);
shading interp;
运行出来的结果如下:
matlab使用插值进行着色处理Z must be a matrix,not a scalar or vector
matlab报错Z must be a matrix, not a scalar or vector,哪里出错了?
matlab程序运行错误 “Z must be a matrix,not a scalar or vector.”
matlab 为什么会出现Z must be a matrix,not a scalar or vector
Error using ==> surf at 78 Z must be a matrix,not a scalar o
matlab 急救 Inputs must be a scalar and a square matrix.
Matlab求助:Inputs must be a scalar and a square matrix
Is pressure a vector or scalar quantity?
matlab Error using ==> mpower Inputs must be a scalar and a
matlab错误 Error using ==> mpower Inputs must be a scalar and
matlab报错?Error using ==> mpower Inputs must be a scalar and
matlab计算时出现“ Error using ==> mpower Inputs must be a scalar