Use a for-loop for multiply colums of two arrays
조회 수: 1 (최근 30일)
이전 댓글 표시
Hallo guys,
How can i multiply rows of two different arrays in a for loop?
So my starting point is a 4x8 (A) matrix and a 4x1 (B) matrix and I want to multiply point A(1x1) with B(1x1), A(2x1) and B(2x1) ... A(1x2) and B(1x1) etc.
I tried this: Mw(4x8) and m(4x1)
Steigung1_neu = zeros(1,8);
startWert = (1);
endWert = (8);
N1 = 1;
for index = startWert:1:endWert
Steigung1_neu(N1) = Mw(2,index)/m(2);
N1 = N1 +1;
end
This just multiplys every row, but I want to multiply every colum.
Would be nice, if you guys can give some tipps.
댓글 수: 1
참고 항목
카테고리
Help Center 및 File Exchange에서 Loops and Conditional Statements에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!