Error with symbolic summation of complex matrixes

1 次查看(过去 30 天)
Hi,
I have an issue with a symbolic summation of complex matrices..
In particular, I have defined two matrixes in a symbolic way:
A=(exp(1i*norm(r))./(norm(r).^3)).*(((1-1i*norm(r))./(norm(r).^2))
B=(exp(1i*norm(r))./norm(r).^3).*((cross(r,cross(p,r))));
A and B are 3x1 complex matrixes.
If I perform summation in a symbolic way C=plus(A,B); and then replace symbols by numbers the result is wrong...
Contrary to that, if I calculate it in numbers, first A and then B, and then sum up them - the result is correct...
Does anyone face with such kind of problem? What is wrong with the "plus" operator when I do it in a symbolic way?
Thank you!

回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Matrix Indexing 的更多信息

产品


版本

R2019b

Community Treasure Hunt

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

Start Hunting!

Translated by