OFFSET
1,2
LINKS
Robert G. Wilson v, Table of n, a(n) for n = 1..1000
Matthijs Coster, Een Eigen Rij - Uitslag Prijsvraag, Pythagoras, Number 6, June 2016, pp. 20-21. The sequence was discovered by Pim Spelier.
MAPLE
A278586 := proc(n)
local x, a;
x := n^2 ;
a := 0 ;
while x <> 0 do
x:= x-ceil(x/n) ;
a := a+1 ;
end do:
a;
end proc: # R. J. Mathar, Dec 02 2016
MATHEMATICA
f[n_] := Length@ NestWhileList[# - Ceiling[#/n] &, n^2, # > 1 &]; Array[f, 65] (* Robert G. Wilson v, Dec 01 2016 *)
PROG
(Magma) a:=[]; for n in [1..58] do k:=n^2; count:=0; while k gt 0 do count+:=1; k-:=Ceiling(k/n); end while; a[n]:=count; end for; a; // Jon E. Schoenfield, Dec 01 2016
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
N. J. A. Sloane, Dec 02 2016, based on discussions about the Pythagoras article in the Sequence Fans Mailing List, Dec 01 2016. Jack Brennen provided the definition given here.
STATUS
approved