简体   繁体   English

Matlab中3D矩阵的解决方案

[英]Solution to 3D matrix in matlab

In AX = B , if A is 3D(n×n×i) matrix and B is 3D(1×n×i) matrix but more like a single row in 3D, then what will be the dimension of X ? AX = B ,如果A是3D(n×n×i)矩阵,而B是3D(1×n×i)矩阵,但更像3D中的单行,那么X的维数是多少? and How to solve this in matlab ? 以及如何在matlab解决这个问题?

It seems like you are describing a set of i systems of equations with n equations in n unknowns for each system. 似乎您正在描述一组i n方程组,每个系统具有n n未知数的n方程。 A way to solve this would be 解决这个问题的方法是

 X = zeros( n, ii ); %//pre-allocate
 for jj=1:ii
     X(:,ii) = A(:,:,jj) \ squeeze(B(1,:,jj));
 end

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM