totalmem_ed.m
by Eric
11 Feb 2008
(Updated 12 Feb 2008)
Displays the total memory allocated.
|
Watch this File
|
| File Information |
| Description |
This is an extremely elementary function that tells you the total memory currently allocated in MB.
It accepts the whos command as an input argument. Which allows the code to see the total memory usage from outside of it's scope (being a function). It sums the bytes field of the structure for all variables.
The function uses variable outputs:
If no output variable is specified then a string in the command window is displayed that tells you the total MB in memory.
If an output variable is specified that variable is set to the total MB.
ex.
totalmem_ed(whos).m
bob = totalmem_ed(whos).m |
| MATLAB release |
MATLAB 7.4 (R2007a)
|
| Other requirements |
None |
|
Tags for This File
|
| Everyone's Tags |
|
| Tags I've Applied |
|
| Add New Tags |
Please login to tag files.
|
|
Contact us at files@mathworks.com