# 3D matrix transpose and dimensioning

2 visualizaciones (últimos 30 días)
Vecihi He el 24 de En. de 2023
Comentada: KSSV el 25 de En. de 2023
When I take the pagetranspose of the matrix I, which has the size shown in Fig. 1 below, I get the matrix "Itilde", which has the size shown in Fig. 2. But I want the size of each cell of the Itilde matrix to be 29x64. Below, the cells in a single column are 29x64x4. How can I divide it into 4 columns and make the size of each cell 29x64 as shown in Fig. 3?
Fig .1
Fig.2
Fig.3
Thanks.
##### 1 comentarioMostrar -1 comentarios más antiguosOcultar -1 comentarios más antiguos
Steven Lord el 24 de En. de 2023
When I take the pagetranspose of the matrix I, which has the size shown in Fig. 1 below, I get the matrix "Itilde", which has the size shown in Fig. 2.
The pagetranspose function does not change a double array (your original matrix, shown in Fig. 1) into a cell array (Fig. 2). Therefore your code performs some other operation that you're not showing us. If you show us that operation we may be able to help you modify it to achieve your goal.

Iniciar sesión para comentar.

### Respuestas (1)

KSSV el 24 de En. de 2023
% Data for demo
A{1,1} = rand(3,3,3) ;
A{2,1} = rand(3,3,3) ;
A{3,1} = rand(3,3,3) ;
A{4,1} = rand(3,3,3) ;
A
A = 4×1 cell array
{3×3×3 double} {3×3×3 double} {3×3×3 double} {3×3×3 double}
% Conversion
B = cell(4,3) ;
for i = 1:4
for j = 1:3
B{i,j} = A{i}(:,:,j) ;
end
end
B
B = 4×3 cell array
{3×3 double} {3×3 double} {3×3 double} {3×3 double} {3×3 double} {3×3 double} {3×3 double} {3×3 double} {3×3 double} {3×3 double} {3×3 double} {3×3 double}
##### 2 comentariosMostrar NingunoOcultar Ninguno
Vecihi He el 25 de En. de 2023
This is exactly the answer I was looking for thank you very much :)
KSSV el 25 de En. de 2023
Thanks is accepting the answer.. :)

Iniciar sesión para comentar.

### Categorías

Más información sobre Resizing and Reshaping Matrices en Help Center y File Exchange.

### Community Treasure Hunt

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

Start Hunting!

Translated by
{"found_math": false, "script_math_tex": 0, "script_math_asciimath": 0, "math_annotations": 0, "math_alttext": 0, "mathml": 0, "mathjax_tag": 0, "mathjax_inline_tex": 0, "mathjax_display_tex": 0, "mathjax_asciimath": 0, "img_math": 0, "codecogs_latex": 0, "wp_latex": 0, "mimetex.cgi": 0, "/images/math/codecogs": 0, "mathtex.cgi": 0, "katex": 0, "math-container": 0, "wp-katex-eq": 0, "align": 0, "equation": 0, "x-ck12": 0, "texerror": 0}