login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A140397
a(n) = floor(3*phi*n) - 3*floor(phi*n) where phi = (1+sqrt(5))/2.
13
1, 0, 2, 1, 0, 2, 0, 2, 1, 0, 2, 1, 0, 1, 0, 2, 1, 0, 2, 1, 2, 1, 0, 2, 1, 0, 2, 0, 2, 1, 0, 2, 1, 0, 1, 0, 2, 1, 0, 2, 1, 2, 1, 0, 2, 1, 0, 1, 0, 2, 1, 0, 2, 1, 2, 1, 0, 2, 1, 0, 2, 0, 2, 1, 0, 2, 1, 0, 1, 0, 2, 1, 0, 2, 1, 2, 1, 0, 2, 1, 0, 2, 0, 2, 1, 0, 2, 1, 0, 1, 0, 2, 1, 0, 2, 0, 2, 1, 0
OFFSET
1,3
FORMULA
a(n) = floor(n*s^2)-floor(s*floor(n*s)), where s=1+phi.
PROG
(PARI) a(n) = my(fhi=(1+sqrt(5))/2); floor(3*fhi*n) - 3*floor(fhi*n); \\ Michel Marcus, Aug 26 2013
KEYWORD
nonn
AUTHOR
Fred Lunnon, Jun 20 2008
STATUS
approved