Logical Array Memory Allocation
古いコメントを表示
Why does Matlab allocate one byte for every element in a logical array? Is there a way to make it one bit per element?
採用された回答
その他の回答 (1 件)
Jan
2011 年 11 月 28 日
0 投票
Modern Matlab versions use a byte to store LOGICALs, as most other programming languages do. Storing the single bits is much slower, as David has explained already.
BTW, Matlab 5.3 used DOUBLEs (64 bits!) and set an extra flag to mark the variable as LOGICAL.
カテゴリ
ヘルプ センター および File Exchange で Logical についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!