code: private static void balbak(DenseMatrix V, double[] scale) {
          int n = V.nrows();
          for (int i = 0; i < n; i++) {
              for (int j = 0; j < n; j++) {
                  V.mul(i, j, scale[i]);
              }
          }
      }
docs: Form the eigenvectors of a real nonsymmetric matrix by back transforming
  those of the corresponding balanced matrix determined by balance.