Corrected QR method