フィルターのクリア

Choosing one answer from 3 in Solve

3 ビュー (過去 30 日間)
Behrang Tavousi
Behrang Tavousi 2015 年 9 月 19 日
コメント済み: Behrang Tavousi 2015 年 9 月 19 日
i solved a eq with command solve() and get answer -1.35-4.59i , -0.136-4.59i , 1.18+9.18e-41i
i need just real part of positive answer,1.18 from these answers. i want to store this answer in Array, but i have get error because there are 3 answers
thanks

採用された回答

James Tursa
James Tursa 2015 年 9 月 19 日
To get the real part of the 3rd element, e.g.,
>> x = [-1.35-4.59i , -0.136-4.59i , 1.18+9.18e-41i]
x =
-1.3500 - 4.5900i -0.1360 - 4.5900i 1.1800 + 0.0000i
>> real(x(3))
ans =
1.1800
  1 件のコメント
Behrang Tavousi
Behrang Tavousi 2015 年 9 月 19 日
thanks,helpful <3

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeCalculus についてさらに検索

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by