to check you memory of you matlab type :memory on command windows, for me output of memory command is:
Maximum possible array: 10859 MB (1.139e+10 bytes) *
Memory available for all arrays: 10859 MB (1.139e+10 bytes) *
Memory used by MATLAB: 719 MB (7.544e+08 bytes)
Physical Memory (RAM): 14211 MB (1.490e+10 bytes)
To increase the memory goto properties of my computer>advanced setting>>system performance setting>>advance option.
increase the virtual memory of each drive and it will reflect immediately as follows:
Maximum possible array: 12918 MB (1.355e+10 bytes) *
Memory available for all arrays: 12918 MB (1.355e+10 bytes) *
Memory used by MATLAB: 721 MB (7.560e+08 bytes)
Physical Memory (RAM): 14211 MB (1.490e+10 bytes)
This is the best solution. If you want to more memory then install X64 OS with Matlab X64 version. You feel the power of matlab....and memory violation error never come.