Question: Remove almost zero elements from matrix

Hi,

i need to remove all the elements from a matrix that are almost zero, for example, from this matrix:

matrix = (Matrix(2, 2, {(1, 1) = 1/1000000000000000000, (1, 2) = 1, (2, 1) = 1, (2, 2) = 1}))

i need to remove the smallest element, so the final matrix will be like:

matrix = (Matrix(2, 2, {(1, 1) = 0, (1, 2) = 1, (2, 1) = 1, (2, 2) = 1}))

Is there a simple way to do that? Maybe forcing Maple to use number above a threshold?

 

Thanks

 

Please Wait...