why my empty cell array taking 104 bytes instead of 112 bytes..?
Show older comments
Hello,
it is mentioned in the document that,
an empty cell array will take
30 bytes for 32 bit systems
& 112 bytes for 64 bit systems.

i got confused why my 64 bit system is taking 104 bytes of memory for an empty cell array..
can someone please explain me..?
Thanks in advance ..!
2 Comments
Bruno Luong
on 6 Sep 2020
can you post a link to the document?
OMKARAM RAJESHWARA RAJU
on 6 Sep 2020
Accepted Answer
More Answers (1)
Image Analyst
on 6 Sep 2020
1 vote
Cell arrays take a huge amount of overhead. Don't use them unless you have to, which means you'll have different kinds of variables in each cell. Otherwise use a double array if they're all numbers, or a table if it's a mixture of variable classes (e.g. strings and numbers) but each column will be all of the same class.
See the very first item on the FAQ: What is a cell array?
Categories
Find more on Matrix Indexing in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!