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!