code: public Cholesky CholeskyOfAtA() {
          DenseMatrix VD = Matrix.zeros(V.nrows(), V.ncols());
          for (int i = 0; i < V.nrows(); i++) {
              for (int j = 0; j < V.ncols(); j++) {
                  VD.set(i, j, V.get(i, j) * s[j]);
              }
          }
  
          return new Cholesky(VD.aat());
      }
docs: Returns the Cholesky decomposition of A'A.