input
:
𝐴
∈
𝑅
𝑛
×
𝑛
,
𝑓
0
∈
𝑅
𝑛
begin
Starting from initial vector
𝑓
0
For
𝑗
=
1
,
2
,
…
begin
Using
global algorithm
, calculate the sequence of Monte Carlo
iterations by solving the following system
𝐴
𝑓
𝑗
=
𝐵
𝑓
𝑗
−
1
Set
𝜆
(
𝑗
)
=
⟨
𝐴
𝑓
𝑗
,
ℎ
𝑗
⟩
⟨
𝐵
𝑓
𝑗
,
ℎ
𝑗
⟩
=
⟨
𝐵
𝑓
𝑗
−
1
,
ℎ
𝑗
⟩
⟨
𝐵
𝑓
𝑗
,
ℎ
𝑗
⟩
Output:
Smallest eigenvector
𝜆
1
(
𝑗
)
, and corresponding eigenvector
𝑓
𝑗
.
end
end
Algorithm 2