The difference between semicolon and comma

29 visualizaciones (últimos 30 días)
engineerOfPhysics
engineerOfPhysics el 31 de Mzo. de 2013
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.

Respuesta aceptada

Wayne King
Wayne King el 31 de Mzo. de 2013
x = [1,2,3];
creates a 1x3 row vector.
x = [1;2;3];
creates a 3x1 column vector
  1 comentario
engineerOfPhysics
engineerOfPhysics el 31 de Mzo. de 2013
Well Why I get different result when I plot of sin(x) function ? between these values. ?

Iniciar sesión para comentar.

Más respuestas (0)

Categorías

Más información sobre Get Started with MATLAB en Help Center y File Exchange.

Community Treasure Hunt

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

Start Hunting!

Translated by