anderson-accel-ncm
- MATLAB Codes for Anderson acceleration of the alternating projections method for the nearest correlation matrix
anderson-accel-ncm
contains MATLAB functions for repairing invalid
(indefinite) correlation matrices, based on the paper
N. J. Higham and N. Strabić, "Anderson Acceleration of the Alternating Projections Method for Computing the Nearest Correlation Matrix", Numer. Alg., 72(4):1021-1042, 2016.
The main functions are
-
nearcorr_aa
: the alternating projections method for computing the nearest correlation matrix with Anderson acceleration. It includes the options of fixing elements and imposing a lower bound on the smallest eigenvalue. -
nearcorr_new
: the alternating projections method for computing the nearest correlation matrix. This is a version of the functionnearcorr
at https://nickhigham.wordpress.com/2013/02/13/the-nearest-correlation-matrix/ that has been modified to include the options of fixing elements and imposing a lower bound on the smallest eigenvalue. This unaccelerated code is included for comparison with the accelerated codenearcorr_aa
.
Other M-files:
test_anderson
: a test function. It runs the functions above on two test problems and reports the number of iterations. It can be run by typingtest_anderson
with no arguments.
The codes have been developed under MATLAB 2015a and have been tested with MATLAB 2015b pre-release.
See license.txt
for licensing information.