Mercurial > matrix-functions
view mftoolbox/sqrtm_pd.m @ 8:a587712dcf5f draft default tip
funm_atom.m: rename fun_atom to funm_atom
* funm_atom.m: rename fun_atom to funm_atom.
author | Antonio Pino Robles <data.script93@gmail.com> |
---|---|
date | Fri, 29 May 2015 09:48:36 +0200 |
parents | 8f23314345f4 |
children |
line wrap: on
line source
function [X,k] = sqrtm_pd(A) %SQRTM_PD Square root of positive definite matrix via polar decomposition. % [X,K] = SQRT_PD(A) computes the Hermitian positive definite % square root X of the Hermitian positive definite matrix A. % It computes the Hermitian polar factor of the Cholesky factor of A. % K is the number of Newton polar iterations used. R = chol(A); [U,H,k] = polar_newton(R); X = H;