what does y(:,1) means if y is a matrix ?
18 ビュー (過去 30 日間)
古いコメントを表示
trig= -1*Y(:,1);
s= -1*Y(:,2);
0 件のコメント
回答 (2 件)
Mukhtar Ullah
2017 年 8 月 15 日
If you define a bidimensional array y, and you want to access all its elements on the first column: y(:,1) will do it. If you want to access to all the elements of the fift row: y(5,:) is the syntax you have to use. The colon means: take all the elements along the specified dimension. --Franco 18:36, 29 September 2006 (PDT)
0 件のコメント
参考
カテゴリ
Help Center および File Exchange で Operators and Elementary Operations についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!