@@ -0,0 +1,1569 @@
+%0Apublic class ShiftedQRExample%7B%0A%09public static void main(String%5B%5D args)%7B%0A%09%0A%09%09ComplexMatrix A = ComplexMatrix.parseMatrix(%22%5B%5B1,2,1,1%5D%5B2,7,0,3%5D%5B1,-1,6,4%5D%5B-1,2,4,-2%5D%5D%22);%0A      Eigen eA = new Eigen(A);%0A%09%09//System.out.println(A.toStringMSWord());%0A%09%09%0A%09%09Complex sigma = A.get(4,4);%0A%09%09%0A%09%09ComplexMatrix A1 = A.sub(ComplexMatrix.identity(4).mult(sigma));%0A%09%09//System.out.println(A1.toStringMSWord());%0A%09%09%0A%09%09ComplexMatrix%5B%5D QR = A1.QRfactor();%0A%09%09//System.out.println(QR%5B0%5D.toStringMSWord());%0A      int x = 5;%0A      for(int i=1; i%3Cx; i++)%7B%0A         A = QR%5B0%5D.transpose().mult(A).mult(QR%5B0%5D);%0A         System.out.println(i);%0A         System.out.println(sigma);%0A         System.out.println(A);%0A         System.out.println(A.toStringMSWord());%0A         sigma = A.get(4,4);%0A         A1 = A.sub(ComplexMatrix.identity(4).mult(sigma));%0A         QR = A1.QRfactor();%0A      %7D%0A      %0A      A = A.partition(1,1,3,3);%0A      System.out.println(%22Submatrix:%5Cn%22+A.toStringMSWord());%0A      sigma = A.get(3,3);%0A      A1 = A.sub(ComplexMatrix.identity(3).mult(sigma));%0A      QR = A1.QRfactor();%0A      int y = 7;%0A%09   for(int i=x; i%3Cy; i++)%7B%0A         A = QR%5B0%5D.transpose().mult(A).mult(QR%5B0%5D);%0A         System.out.println(i);%0A         System.out.println(sigma);%0A         System.out.println(A);%0A         System.out.println(A.toStringMSWord());%0A         sigma = A.get(3,3);%0A         A1 = A.sub(ComplexMatrix.identity(3).mult(sigma));%0A         QR = A1.QRfactor();%0A      %7D%0A      %0A      System.out.println(A.partition(1,1,2,2).toStringMSWord());%0A      %0A      %0A      %0A      System.out.println(%22%5Cn%5Cn%22+eA);%0A%09%7D%0A%7D%0A

Update and rename QRfactorExample.java to ShiftedQRExample.java