Memory Usage
29
Strategies for Efficient Use of Memory.............. 29-2
Ways to Reduce the Amount of Memory Required ..... 29-2
Using Appropriate Data Storage.................. 29-4
How to Avoid Fragmenting Memory............... 29-7
Reclaiming Used Memory....................... 29-8
Resolve “Out of Memory” Errors................... 29-9
General Suggestions for Reclaiming Memory ........ 29-9
Increase System Swap Space................... 29-10
Set the Process Limit on Linux Systems........... 29-10
Disable Java VM on Linux Systems............... 29-10
Free System Resources on Windows Systems ....... 29-11
How MATLAB Allocates Memory.................. 29-12
Memory Allocation for Arrays ................... 29-12
Data Structures and Memory ................... 29-16
Avoid Unnecessary Copies of Data................. 29-21
Passing Values to Functions.................... 29-21
Why Pass-by-Value Semantics ................... 29-23
Handle Objects .............................. 29-24
Custom Help and Documentation
30
Create Help for Classes........................... 30-2
Help Text from the doc Command................. 30-2
Custom Help Text............................. 30-3
Check Which Programs Have Help................. 30-9
Create Help Summary Files — Contents.m.......... 30-12
What Is a Contents.m File?..................... 30-12
Create a Contents.m File ...................... 30-12
Check an Existing Contents.m File............... 30-13
xxix