Question: How can I release the occupied memory through matrix, sequence and list without using "restart" command?

 

In the name of God

Dear friends

Hi

I have a question about releasing a part of memory occupied by some lists, sequences and matrices, for example matrix "M" or list "L".

If we use the following commands to allocate amount of memory for a matrix or list:

M:=Matrix(2000,2000,float[8]);
L:=[seq(equ[i],i=1..10000)]:

where equ[i] is a large equation with respect to variable x.

Now, if we want to clear all of matrix "M" or list "L" or a part of then (for example, for indexes between 1 to 1000 (M[1..1000,1..1000] and L[1..1000]), how can we do it?

The following commands can clear data of matrix "M" or list "L", however the occupied memory through "M" and "L" can not be released.

M:='M';
L:='L';

The following commands can not also remove the occupied memory.

M:=unassign('M');
L:=unassign('L');

How can we clear the content of "M" and "L" and release the occupied memory without using "restart" command?

 Best regards

 

Please Wait...