three order complex coefficient polynomial root matlab
5 ビュー (過去 30 日間)
表示 古いコメント
Hi, I would like to find the root for a 3rd order polynomial with complex coefficient.
The polynomial is like:
28x^3 + Ax^2 + Bx - C = 0;
A,B,C are complex numbers.
I appreciate if anyone can help.
0 件のコメント
回答 (3 件)
Star Strider
2023 年 5 月 26 日
There are at least two options —
z = complex(randn(3,1), randn(3,1))
r = roots([28; z])
syms x
p = 28*x.^3 + z(1,:)*x.^2 + z(2,:)*x + z(3,:);
vpap = vpa(p, 5)
r = vpa(solve(p), 5)
.
0 件のコメント
John D'Errico
2023 年 5 月 26 日
Another classic solution is to find the matrix that has the same eigenvalues as your polynomial has roots. Then use eig to compute the eigenvalues of this "companion matrix". This is in fact what roots does.
0 件のコメント
Walter Roberson
2023 年 5 月 26 日
syms x A B C
eqn = 28*x^3 + A*x^2 + B*x - C == 0;
solutions = solve(eqn, x, 'MaxDegree', 3)
char(solutions(1))
char(solutions(2))
char(solutions(3))
0 件のコメント
参考
カテゴリ
Help Center および File Exchange で Polynomials についてさらに検索
製品
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!