MATLAB爱好者论坛-LabFans.com

MATLAB爱好者论坛-LabFans.com (https://www.labfans.com/bbs/index.php)
-   资料存档 (https://www.labfans.com/bbs/forumdisplay.php?f=72)
-   -   如何在某些操作后删除添加的零元素 (https://www.labfans.com/bbs/showthread.php?t=22368)

poster 2019-12-03 16:43

如何在某些操作后删除添加的零元素
 
我正在使用以下算法将3D数组分为几组:

m=size(A,1); n_blocks = ceil(m / w); A(m+1:w*n_blocks, :,:) = 0; 如果将A(8 x 2 xx)分成w = 3,我将得到一个新的A 9 x 2 x 2。下面的代码添加零矩阵。

之后,我将“新” A的每个切片与另一个2d数组B乘积,得到3D数组C。

现在,我必须删除为C中的A添加的“零”,该怎么做?



[url=https://stackoverflow.com/q/59152929]更多&回答...[/url]


所有时间均为北京时间。现在的时间是 23:19

Powered by vBulletin
版权所有 ©2000 - 2025,Jelsoft Enterprises Ltd.