replaced diag(X %*% Y) with more efficient rowSums(X * t(Y))

git-svn-id: svn://svn.r-forge.r-project.org/svnroot/mumin@282 edb9625f-4e0d-4859-8d74-9fd3b1da38cb
fixed typo in documentation 

git-svn-id: svn://svn.r-forge.r-project.org/svnroot/mumin@283 edb9625f-4e0d-4859-8d74-9fd3b1da38cb