repeated numbers in roots

2 次查看(过去 30 天)
Ali
Ali 2020-6-8
评论: KSSV 2020-6-8
Hi
can anybody tell how to remove repeated number in roots of polynomial eqaution.
w =
0.2278
0.2278
1.0382
1.0382
1.5292
1.5292
0.1738
0.1738
0.3461
0.3461
0.5647
0.5647
0.8437
0.8437
0.9098
0.9098
1.0873
1.0873
1.2007
1.2007

回答(1 个)

KSSV
KSSV 2020-6-8
iwant = unique(w)
  2 个评论
Ali
Ali 2020-6-8
To find roots of w is
w=roots(w);
r-roots(w);
which is one better and accurate way??
KSSV
KSSV 2020-6-8
Use roots. See to it that the coefficients of the polynomials are arranged as required for the function.

请先登录,再进行评论。

类别

Help CenterFile Exchange 中查找有关 Polynomials 的更多信息

Community Treasure Hunt

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

Start Hunting!

Translated by