Suppose I have a cell array like the following:
mycell =
[-1.6411e-16 + 1.4863e-19i] [ 0.6450 + 0.6433i]
[ 0.6450 + 0.6433i] [-1.6411e-16 + 1.4863e-19i]
I want it to be a matrix, so I use the command cell2mat
:
>> mymatrix = cell2mat(mycell)
mymatrix =
-0.0000 + 0.0000i 0.6450 + 0.6433i
0.6450 + 0.6433i -0.0000 + 0.0000i
I certainly get the result I expect in terms of cell arrays and matrices, but why -1.6411e-16 + 1.4863e-19i is rounded to -0.0000 + 0.0000i?
And, the most important thing, how could I avoid this situation?
Thank you.
EDIT: I've figured out the solution by myself.