start of pseudo-code for coarse grained search thread ascending move iterator (ami) := 0; ascending move counter (amc) := 0; repeat until (amc == 2) shaking; local search; ami := ami + 1; if f(x_new) < f(x_current) then ami := 0; x_current := x_new; if f(x_new) < f(x_best) then x_best := x_new; else if ami > sigma and f(x_new) <= f(x_best) + f(x_best) * theta % then ami := 0; amc = amc + 1; if amc < 2 then x_current := x_new; end of pseudo-code for coarse grained search thread