The difference between semicolon and comma

27 ビュー (過去 30 日間)
engineerOfPhysics
engineerOfPhysics 2013 年 3 月 31 日
Hi matlab community ,
I am working on let' s say a homework. I realized that during the homework, The representations one of them x=[1,2,3] and x=[1;2;3] are different. What is the different between them? I get a solution using both of them but different.

採用された回答

Wayne King
Wayne King 2013 年 3 月 31 日
x = [1,2,3];
creates a 1x3 row vector.
x = [1;2;3];
creates a 3x1 column vector
  1 件のコメント
engineerOfPhysics
engineerOfPhysics 2013 年 3 月 31 日
Well Why I get different result when I plot of sin(x) function ? between these values. ?

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeGet Started with MATLAB についてさらに検索

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by