Is there a way to list the variable/list/matrixs in memory and the space it uses?



Hi, I run into a problem that give me heap error. I want to understand which variable/list/matrix is using such huge memory.I am looking for a command like who and whos in octave/matlab can give me a list of variables.
thanks