I am trying to multiply the same matrix by the transpose of itself and it is giving me the error of matrix dimensions must agree. Code: XX=X.*X';

답변 (1개)

Rick Rosson
Rick Rosson 2016년 3월 23일

0 개 추천

Try using * instead of .*

댓글 수: 3

mike moran
mike moran 2016년 3월 23일
that will not work because X is a matrix of 135x100, therefore would need to use element by element multiplication.
Rick Rosson
Rick Rosson 2016년 3월 23일
Have you tried it?
mike moran
mike moran 2016년 3월 23일
I figured it out. My matrix was in uint8 and it needed to be in double.

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

카테고리

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

질문:

2016년 3월 23일

댓글:

2016년 3월 23일

Community Treasure Hunt

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

Start Hunting!

Translated by