what's the program mistake?

1 view (last 30 days)
MA
MA on 4 Jun 2014
Answered: MA on 10 Nov 2014
clear all clc; syms x A=[x 2 1;1 0 -x;5 1 x]; b=det(A) r=solve('b=0','x')

Accepted Answer

MA
MA on 10 Nov 2014
r=solve(b)

More Answers (2)

Mischa Kim
Mischa Kim on 4 Jun 2014
Hello Ali, use instead
r = solve(b==0)
  2 Comments
Mahdi
Mahdi on 4 Jun 2014
Why isn't it working? What's the error that you're getting?

Sign in to comment.


Mahdi
Mahdi on 4 Jun 2014
Try this?
clear all
clc;
syms x
A=[x 2 1;1 0 -x;5 1 x];
b=det(A)
r=eval(solve(b==0))
  3 Comments

Sign in to comment.

Categories

Find more on Mathematics in Help Center and File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by