How to initialize a row vector with value zero of size 1xn?
300 次查看(过去 30 天)
显示 更早的评论
Say, I have a row vector A having n elements. I want to make all elements zero.
- For e.g., in 2-d, we write A=zeros(n)
0 个评论
采纳的回答
jgg
2016-2-19
Look up the documentation for the zeros function, which you are using:
A = zeros(1,n);
更多回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Startup and Shutdown 的更多信息
产品
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!