求助:matlab 编程问题
在matlab中,用到一个大型的0,1矩阵。比如第一行是 1 0 0 0 0 0 0 1 1 1 1 1 1
1 0 0 0 0 0 0 1 1 1 1 1 1
输入的是[ 1 zeros(6,1) ones(6,1)
1 zeros(6,1) ones(6,1)]
但是一直出错,是怎么回事? 不懂啊,郁闷着呢 zeros(6,1) =[1
1
1
1
1
1] 应该是zeros
ans =
Columns 1 through 5
1 0 0 0 0
1 0 0 0 0
Columns 6 through 10
0 0 1 1 1
0 0 1 1 1
Columns 11 through 13
1 1 1
1 1 1
是这样吧。 水木年华zzu 发表于 2011-7-9 11:49 static/image/common/back.gif
应该是zeros
大侠就是大侠,太感谢啦 lovelymetoo 发表于 2011-7-9 13:25 static/image/common/back.gif
ans =
:)是滴,太谢谢啦~ 刚入门,过来瞧瞧,学点知识,长长见识。。
页:
[1]