login
Positions k such that A097465(k) and A097465(k+1) are odd.
2

%I #13 May 07 2022 10:22:53

%S 1,2,7,12,41,100,521,1150,10391,15008,255247,1786778,4849835,5870858,

%T 6561553,557732162,3234846601,3457939474,4360010651

%N Positions k such that A097465(k) and A097465(k+1) are odd.

%C Fixed points in A097465 appear in the intervals [12, 41], [100, 521], [1150, 10391], etc.

%H Rémy Sigrist, <a href="/A353069/a353069.txt">C program</a>

%t nn = 2^20; c = {1}; j = 1; u = 2; {1}~Join~Reap[Do[k = u; While[Nand[FreeQ[c, k], CoprimeQ[j, k], k != j + 1, k != j - 1], k++]; j = k; AppendTo[c, k]; If[# != s, s = #; Sow[i - 1]] &@ Mod[#, 2] &@ Abs[k - i]; If[k == u, While[MemberQ[c, u], u++]; c = DeleteCases[c, _?(# < u &)]], {i, 2, nn}]][[-1, -1]]

%o (C) See Links section.

%Y Cf. A097465, A351646, A352096.

%K nonn,more

%O 1,2

%A _Michael De Vlieger_, May 05 2022

%E a(17)-a(19) from _Rémy Sigrist_, May 07 2022