Symbolic matrix operations without breaking it down to the element level.
조회 수: 3 (최근 30일)
이전 댓글 표시
Hi all, I want to check some derivations and gradients involving matrices and vectors and I would like to check it using the Symbolic Toolbox. But I do not want Matlab to break the matrix operations down on an element level since this blows up the equations and makes them almost impossible to read. For example I want the scalar product of a vector a with itself be displayed like this
a' * a
since there is nothing more to simplify. But if I use scalar symbolic variables I get
>> a = sym('a', 'real');
>> a' * a
ans =
a^2
which is not true if a is vector and if I use vectors of symbolic variables I get
>> a = sym('a', [3, 1], 'real');
>> a' * a
ans =
a1^2 + a2^2 + a3^2
which is hard to read in complex equations. I basically want Matlab to NOT break vectors and matrices down to their elements, just like a human would do, when deriving stuff on paper.
Is this possible? Thanks in advance.
댓글 수: 0
답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Operators and Elementary Operations에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!