public void performStep ( ) { // check for zeros for ( int i = helper . x2 - 1 ; i >= helper . x1 ; i -- ) { if ( helper . isZero ( i ) ) { helper . splits [ helper . numSplits ++ ] = i ; helper . x1 = i + 1 ; return ; } } double lambda ; if ( followingScript ) { if ( helper . steps > 10 ) { followingScript = false ; return ; } else { // Using the true eigenvalues will in general lead to the fastest convergence // typically takes 1 or 2 steps lambda = eigenvalues [ helper . x2 ] ; } } else { // the current eigenvalue isn't working so try something else lambda = helper . computeShift ( ) ; } // similar transforms helper . performImplicitSingleStep ( lambda , false ) ; }
First looks for zeros and then performs the implicit single step in the QR Algorithm .