why do I get this error while using find to determine the element in my list?

1 回表示 (過去 30 日間)
mehmet salihi
mehmet salihi 2022 年 1 月 17 日
コメント済み: mehmet salihi 2022 年 1 月 17 日
Hello dear friends.
I am encountring an error wile using the find command. could you please help.
kff is vector and my k flutter is equal to 0.3000.
when i enter 0.3000 directly to my find command it works but when i enter k_flutter it is not working.
thanks.

採用された回答

KSSV
KSSV 2022 年 1 月 17 日
You should not comapre floating point numbers like that.
Try:
tol = 10^-5 ; % try changing the tolerance
find(abs(kff-k_flutter)<tol)
  3 件のコメント
mehmet salihi
mehmet salihi 2022 年 1 月 17 日
thank you

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

その他の回答 (0 件)

カテゴリ

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

Community Treasure Hunt

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

Start Hunting!

Translated by