Good evening
I have a matrix H which has the dimensions 16×16×10
I want to multiply H by a vector of ones x to result in having a vector of 16×10
How can I accomplish this?
Kind regards,

댓글 수: 1

Adam
Adam 2019년 3월 14일
How are you expecting to lose a dimension by multiplying by a vector? What is the operation here?
Generally, with array expansion or broadcasting (python) you might expect to gain a dimension when multiplying by a vector rather than lose one.

댓글을 달려면 로그인하십시오.

답변 (1개)

madhan ravi
madhan ravi 2019년 3월 14일

0 개 추천

[m,n,p]=size(H); % size of H =>16X16X10 , size of x => 1X16
aa=reshape(a,[m n*p]);
Result=reshape(x*aa,n,p); % size of Result => 16X10

카테고리

도움말 센터File Exchange에서 Creating and Concatenating Matrices에 대해 자세히 알아보기

태그

질문:

2019년 3월 14일

답변:

2019년 3월 14일

Community Treasure Hunt

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

Start Hunting!

Translated by