How to use variable?

21 visualizaciones (últimos 30 días)
Ivor Horton
Ivor Horton el 15 de Jun. de 2020
Comentada: madhan ravi el 15 de Jun. de 2020
If I run
det([1 2;3 4])
Matlab gives the result -2.
I want to calculate
det([a b;c d])
and how can I get the result
ad - bc

Respuesta aceptada

David Hill
David Hill el 15 de Jun. de 2020
syms a b c d;
det([a b;c d]);
  1 comentario
madhan ravi
madhan ravi el 15 de Jun. de 2020
First line doesn’t output anything.

Iniciar sesión para comentar.

Más respuestas (0)

Etiquetas

Community Treasure Hunt

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

Start Hunting!

Translated by