Info

この質問は閉じられています。 編集または回答するには再度開いてください。

How can I calculate row to row values in a matrix.?

2 ビュー (過去 30 日間)
Noman Abir
Noman Abir 2021 年 1 月 5 日
閉鎖済み: Rik 2021 年 1 月 5 日
I am looking for a way to multiply one row values with every row values.
Let's assume we have:
A=[1 2 3;
4 5 6;
7 8 9]
B=[a b c]
I am looking for a way to have:
C=[1*a 2*b 3*c;
4*a 5*b 6*c;
7*a 8*b 9*c]
Thanks in advance for your comments.
NB : bsxfun working fine on my version. But, It is showing correct calculations when I have a small row numbers. But, when I have a very large row numbers (say, 10,00000) then it's showing me wrong calculations..
Is there other ways you can help me..?
  7 件のコメント
Noman Abir
Noman Abir 2021 年 1 月 5 日
I didn't calculated million rows manually. I just calculated first 8/10 rows and saw that the value i expect is not equal to the value i am getting from the MATLAB Calculations. I think, you got my point.
Rik
Rik 2021 年 1 月 5 日
Since this is a follow-up question to your other question, I'm closing this as a duplicate.

回答 (0 件)

この質問は閉じられています。

タグ

製品


リリース

R2014b

Community Treasure Hunt

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

Start Hunting!

Translated by