Does Eigen contains an algorithm for solving nearest correlation matrix problems?
You can use the SelfAdjointEigenSolver
to decompose your non-positive definite matrix, edit the negative eigenvalues to something slightly positive and (manually) re-compose the matrix.