| Algorithm 4: Power method with the proposed Monte Carlo AMM |
| Require: : symmetric positive-semidefinite matrix, : m-dimensional randomized unit vector, |
| Ensure: : the largest absolute eigenvalue of |
| 1: , |
| 2: Set , such that |
| 3: for while not converged do |
| 4: |
| 5: for do |
| 6: Pick with |
| 7: |
| 8: end for |
| 9: |
| 10: |
| 11: end for |
| 12: Return |