OFFSET
1,2
COMMENTS
LINKS
Tiberiu Szocs-Mihai, Convergence of euclidean summation function, Math Ticks Blog, January 2011.
PROG
(PARI) t(n, k) = {x = n; y = k; r = 1; s = 0; while (r, q = x\y; r = x - y*q; s +=r; x = y; y = r; ); s; }
row(n) = vector(n, k, t(n, k));
a(n) = v = row(n); vm = vecmax(v); forstep(k=n, 1, -1, if (v[k] == vm, return(k))); \\ Michel Marcus, Aug 31 2015
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Tiberiu Szocs-Mihai, Aug 10 2015
STATUS
approved