OFFSET
0,3
COMMENTS
a(n) is the smallest number different from a(i) and a(i)+i for i < n.
The losing positions in the game of Wythoff-Nim are precisely the pairs (a(n), a(n)+n).
LINKS
G. C. Greubel, Table of n, a(n) for n = 0..10000
FORMULA
a(n) = A000201(n).
Duplicate values in A060143.
a(n) = floor(n*phi), where phi = (1 + sqrt(5))/2. - Peter Munn, Jan 12 2018
a(n) = A026351(n) - 1. - Philippe Deléham, Jan 15 2023
MATHEMATICA
Floor[GoldenRatio*Range[0, 80]] (* G. C. Greubel, Sep 12 2023 *)
PROG
(PARI) a(n) = (n+sqrtint(5*n^2))\2;
[a(n)|n<-[0..100]] \\ Simon Strandgaard, Jun 28 2022
(Magma) [Floor((1+Sqrt(5))*n/2): n in [0..80]]; // G. C. Greubel, Sep 12 2023
(SageMath) [floor(golden_ratio*n) for n in range(81)] # G. C. Greubel, Sep 12 2023
CROSSREFS
Essentially the partial sums of A001468.
KEYWORD
nonn,easy
AUTHOR
Michele Dondi (bik.mido(AT)tiscalenet.it), Dec 30 2001
EXTENSIONS
Name corrected by Peter Munn, Dec 06 2017
New name using a formula from Peter Munn by Peter Luschny, Jan 18 2023
STATUS
approved