Is it necessary to store column vectors in a column order in cells?

조회 수: 1 (최근 30일)
Xiaohan Du
Xiaohan Du 2018년 4월 7일
Hi all,
I know MATLAB stores data in a column-major order (see https://uk.mathworks.com/help/matlab/matlab_external/matlab-data.html ), therefore it is faster to read a column vector than a row vector (based on same number of elements), and I should store matrices in a column manner rather than a row manner.
I have a cell array with elements of large column vectors like this:
K>> testCell
testCell =
1×M cell array
Columns 1 through M
{N×1 double} {N×1 double} {N×1 double} {N×1 double} {N×1 double} {N×1 double}
Imagine M and N are both quite large numbers. As you can see, here the cell elements are stored in a row. My question is: is it necessary to align these cell elements in a column (M×1 cell array) rather than a row? Is it faster to read M×1 than 1×M cell array in this case when large column vectors are stored in cell elements?
Many thanks!

답변 (0개)

카테고리

Help CenterFile Exchange에서 Data Types에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by