Solve unknow array/matrix
2 次查看(过去 30 天)
显示 更早的评论
I have a know 2x2 array (3 0; 0 2)that get multiplied by array A and the answer is a known array C(1 2 3; 4 5 6), how can I solve all the elements in array A?
0 个评论
回答(1 个)
the cyclist
2021-11-6
% Input
B = [3 0; 0 2];
C = [1 2 3; 4 5 6];
% Solve for A
A = B\C
% Verify
B * A
1 个评论
John D'Errico
2021-11-6
Yes, of course. With only the caveat that an exact solution need not always exist. If B does not have full rank, then SOME of the time, there will be no solution.
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Multidimensional Arrays 的更多信息
产品
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!