フィルターのクリア

Finding corresponding value of one vector in another vector

1 回表示 (過去 30 日間)
Yamana Uno
Yamana Uno 2023 年 11 月 13 日
回答済み: Voss 2023 年 11 月 13 日
Hi, for example if I have vectors A = [0 1 2 3 4 5 6 7 8 9 10] and B = [0 100 200 300 400 500 600 700 800 900 1000]. and am getting asked to find the value of B when A=7, how do I do that?
Thank you!

採用された回答

Voss
Voss 2023 年 11 月 13 日
A = [0 1 2 3 4 5 6 7 8 9 10];
B = [0 100 200 300 400 500 600 700 800 900 1000];
result = B(A==7)
result = 700

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeGet Started with MATLAB についてさらに検索

タグ

製品

Community Treasure Hunt

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

Start Hunting!

Translated by