how to multiply matrix vectors with one column?
조회 수: 2 (최근 30일)
이전 댓글 표시
if i have matrix M = [1 0 1 0; 1 0 0 1;1 1 1 0;1 1 1 1; ...] and i want to multiply each row with one cloumn B=[1 0 0 1] how to do this?
댓글 수: 0
채택된 답변
Mohammad Abouali
2014년 11월 9일
M*B'
댓글 수: 3
Mohammad Abouali
2014년 11월 9일
편집: Mohammad Abouali
2014년 11월 9일
B' is 4x1 M is 4x4 then C=M*B' would be also 4x1. then you can not compute C*M since C is 4x1 and M is 4x4.
But you can compute C1=M*C and then C2=M*C1. Exactly as we are writing this.
추가 답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Matrix Indexing에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!