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”).

For n >= 1, a(n) = A003714(n) mod n.
2

%I #13 Sep 11 2022 16:20:09

%S 0,0,1,1,3,3,3,0,8,8,9,9,6,5,4,4,3,4,3,2,1,21,20,20,19,20,19,18,22,21,

%T 20,20,19,26,24,22,21,19,19,17,15,18,16,14,13,11,19,17,15,14,12,12,10,

%U 8,36,33,30,28,25,24,21,18,20,17,14,12,9,16,13,10,8,5

%N For n >= 1, a(n) = A003714(n) mod n.

%C a(n) = 0 see A276488.

%F a(n) = A003714(n) mod n.

%e a(5) = A003714(5) mod 5 = 8 mod 5 = 3.

%t fib = Select[Range[300], BitAnd[#, 2*#] == 0 &]; Mod[fib, Range[Length[fib]]] (* _Amiram Eldar_, Sep 10 2022 *)

%o (Python)

%o def A357073(n):

%o tlist, s, m = [1, 2], 0, n

%o while (t:=tlist[-1]+tlist[-2]) <= n:

%o tlist.append(t)

%o for d in tlist[::-1]:

%o s = (s<<1)%n

%o if d <= m:

%o s = (s+1)%n

%o m -= d

%o return s # _Chai Wah Wu_, Sep 11 2022

%Y Cf. A003714, A276488.

%K nonn

%O 1,5

%A _Ctibor O. Zizka_, Sep 10 2022