% 列向量合并
>> a = [1;2;3]
a =
1
2
3
>> b = [4;5;6]
b =
4
5
6
>> c = [a;b]
c =
1
2
3
4
5
6
>> d = [a,b]
d =
1 4
2 5
3 6
% 行向量合并
>> e = [1,2,3]
e =
1 2 3
>> f = [4,5,6]
f =
4 5 6
>> g = [e;f]
g =
1 2 3
4 5 6
>> h = [e,f]
h =
1 2 3 4 5 6
% 空格等同于逗号,
>> h = [e f]
h =
1 2 3 4 5 6
>> g(2,1)
ans =
4
09-21
7183
![](https://csdnimg.cn/release/blogv2/dist/pc/img/readCountWhite.png)
04-01
4621
![](https://csdnimg.cn/release/blogv2/dist/pc/img/readCountWhite.png)
“相关推荐”对你有帮助么?
-
非常没帮助
-
没帮助
-
一般
-
有帮助
-
非常有帮助
提交