Error using ==> surf at 78 Z must be a matrix,not a scalar o
来源:学生作业帮 编辑:大师作文网作业帮 分类:英语作业 时间:2024/11/11 13:07:49
Error using ==> surf at 78 Z must be a matrix,not a scalar or vector.怎么将i变为矩阵那
delta=0:0.1:1;
epsilon=0:0.1:1;
[xx,tt] = meshgrid(epsilon,delta);
i=-2*((1-delta).*(1-epsilon).*log2(1/2*(1-delta).*(1-epsilon))+delta.*(1-epsilon).*log2(1/2*delta.*(1-epsilon))+(1-delta).*epsilon.*log2(1/2*(1-delta).*epsilon)+delta.*epsilon.*log2(1/2*delta.*epsilon));
surf(xx,tt,i);
delta=0:0.1:1;
epsilon=0:0.1:1;
[xx,tt] = meshgrid(epsilon,delta);
i=-2*((1-delta).*(1-epsilon).*log2(1/2*(1-delta).*(1-epsilon))+delta.*(1-epsilon).*log2(1/2*delta.*(1-epsilon))+(1-delta).*epsilon.*log2(1/2*(1-delta).*epsilon)+delta.*epsilon.*log2(1/2*delta.*epsilon));
surf(xx,tt,i);
i表达式中的delta用tt替换,epsilon用xx替换,就ok了.
再问: 太感谢了!
再问: 太感谢了!
Error using ==> surf at 78 Z must be a matrix,not a scalar o
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
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
matlab Error using ==> mpower Matrix must be square.
matlab:Error using ==> mtimes Inner matrix dimensions must a
matlab程序问题,Error using ==> mrdivide Matrix dimensions must a