Added totalMemoryUsage

added only the function and the tests are not included.
Full Commit for totalMemoryUsage
Merge pull request #2 from scriptnull/master

Added a function named totalMemoryUsage