标题: 看了半天求助啊Attempted to access A(1,0); index must be a positive integer or l [打印本页] 作者: tygt12 时间: 2011-11-26 20:13 标题: 看了半天求助啊Attempted to access A(1,0); index must be a positive integer or l for N=1:1:8
A(N,0)=1;
end
??? Attempted to access A(1,0); index must be a positive integer or logical.
看了半天好像没问题吧,为什么说索引不对呢?作者: madio 时间: 2011-11-26 20:57
你大概之前一直在使用C语言,C的数组是从0开始的,Matlab的矩阵怎么会有第0列呢?你把A(N,0)改成A(N,1)