cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A351646 a(n) = A097465(n) - n.

This page as a plain text file.
%I A351646 #13 May 07 2022 08:40:10
%S A351646 0,1,2,-2,2,-2,2,3,-3,3,-3,3,4,-4,4,-4,6,-4,6,-4,0,4,6,-6,6,-6,0,-6,6,
%T A351646 -6,6,-4,0,4,6,-6,6,-6,0,-6,4,5,-7,5,-5,5,-3,5,-7,5,-5,5,-3,5,-7,5,-5,
%U A351646 5,-1,5,-7,5,-7,5,-3,5,-7,5,-5,5,-3,5,-1,5,-9,7
%N A351646 a(n) = A097465(n) - n.
%C A351646 Zeros correspond to fixed points in A097465, which are listed in A352096.
%H A351646 Michael De Vlieger, <a href="/A351646/a351646.png">Annotated scatterplot of a(n)</a>, n = 1..300000, showing even terms in red, odd in blue, with positions of zeros in italic.
%t A351646 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]; Sow[k - i]; If[k == u, While[MemberQ[c, u], u++]; c = DeleteCases[c, _?(# < u &)]], {i, 2, nn}]][[-1, -1]]
%Y A351646 Cf. A097465, A352096.
%K A351646 sign,easy
%O A351646 1,3
%A A351646 _Michael De Vlieger_, May 05 2022