Code covered by the BSD License  

Highlights from
QUBIT4MATLAB V4.0

from QUBIT4MATLAB V4.0 by Geza Toth
MATLAB package for quantum information science and quantum mechanics.

m=mineig(M);
% mineig   Minimum eigenvalue of a matrix 
%    mineig(M) gives back min(real(eig(M))).
%    Note the function real() in the expression.
%    This takes care of the small imaginary parts
%    appearing in calculations with MATLAB, which could
%    disturb the routine looking for the minimum.

function m=mineig(M);

m=min(real(eig(M)));

Contact us at files@mathworks.com