Real solutions to a polynomial

4 vues (au cours des 30 derniers jours)
Robert Bag
Robert Bag le 24 Avr 2021
Commenté : Robert Bag le 24 Avr 2021
Hi, I am stuck to this task: I am trying only to get the real solutions to the function
A = [1 -12 55 -120 124 -80]
B = roots(A)
  4 commentaires
Robert Bag
Robert Bag le 24 Avr 2021
>> Matlab412
a =
1
2
2
3
4
b =
root(z^6 - z^4/5 + 14*z^2 - 2*z - 10, z, 1)
root(z^6 - z^4/5 + 14*z^2 - 2*z - 10, z, 2)
c =
root(z^5 - 4*z^3 + 4*z^2 - (4*z)/3 - 10/3, z, 1)
root(z^5 - 4*z^3 + 4*z^2 - (4*z)/3 - 10/3, z, 4)
root(z^5 - 4*z^3 + 4*z^2 - (4*z)/3 - 10/3, z, 5)
d =
2
2
2
2
5
Robert Bag
Robert Bag le 24 Avr 2021
O know b and c are not monomial and coefficents of highest order is non-zero though

Connectez-vous pour commenter.

Réponses (1)

Walter Roberson
Walter Roberson le 24 Avr 2021
A = randi([-9 9], 1, 6)
A = 1×6
-7 -4 4 4 -2 9
B = roots(A)
B =
-1.0813 + 0.6487i -1.0813 - 0.6487i 1.0967 + 0.0000i 0.2472 + 0.8223i 0.2472 - 0.8223i
B(imag(B)==0)
ans = 1.0967

Catégories

En savoir plus sur Mathematics dans Help Center et File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by