On 16/03/2014 01:31, josef.p...@gmail.com wrote: > > > > On Sat, Mar 15, 2014 at 8:47 PM, Warren Weckesser > <warren.weckes...@gmail.com <mailto:warren.weckes...@gmail.com>> wrote: > > > On Sat, Mar 15, 2014 at 8:38 PM, <josef.p...@gmail.com > <mailto:josef.p...@gmail.com>> wrote: > > I think I wouldn't use anything like @@ often enough to remember > it's meaning. I'd rather see english names for anything that is > not **very** common. > > I find A@@-1 pretty ugly compared to inv(A) > A@@(-0.5) might be nice (do we have matrix_sqrt ?) > > > > scipy.linalg.sqrtm: > > http://docs.scipy.org/doc/scipy/reference/generated/scipy.linalg.sqrtm.html > > > maybe a good example: I could never figured that one out > > M = sqrtm(A) > > A = M @ M > > but what we use in stats is > > A = R.T @ R > (eigenvectors dot diag(sqrt of eigenvalues) > > which sqrt is A@@(0.5) ? > > Josef
Agreed- In general, "the matrix square root" isn't a well-defined quantity. For some uses, the Cholesky decomposition is what you want, for some others it's the matrix with the same eigenvectors, but the square root of the eigenvalues, etc. etc. As an important aside, it would be good if the docs addressed this. Yours, Andrew _______________________________________________ NumPy-Discussion mailing list NumPy-Discussion@scipy.org http://mail.scipy.org/mailman/listinfo/numpy-discussion