Syntax error in simulink function

3 visualizaciones (últimos 30 días)
Akylas Strathgakos
Akylas Strathgakos el 27 de Nov. de 2015
Comentada: Akylas Strathgakos el 28 de Nov. de 2015
Hello, can you help me find the error in this function?
(1/L)*(-R*u(1)+ws*L*u(2)-md*u(3)+Ud)

Respuesta aceptada

Walter Roberson
Walter Roberson el 27 de Nov. de 2015
There is no obvious syntax error there, but the code would fail if L is a vector (or matrix) or if both L and ws are vectors or matrices when size(ws,2) is not the same as size(L,1)
You might need
(1./L) .* (-R*u(1) + ws .* L * u(2) - md*u(3) +Ud)
  1 comentario
Akylas Strathgakos
Akylas Strathgakos el 28 de Nov. de 2015
They are simple variables ,thank you for the answer though

Iniciar sesión para comentar.

Más respuestas (0)

Categorías

Más información sobre Simulink Functions en Help Center y File Exchange.

Etiquetas

Community Treasure Hunt

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

Start Hunting!

Translated by