%I #15 May 13 2023 08:26:42
%S 0,0,0,0,0,1,0,0,0,1,0,0,0,0,1,0,0,0,0,0,0,1,2,1,0,0,0,0,0,0,0,0,1,2,
%T 3,2,1,0,0,0,0,0,0,0,0,0,0,0,1,2,3,4,3,2,1,0,0,0,0,0,0,0,0,0,0,0,0,0,
%U 0,0,0,1,2,3,4,5,6,5,4,3,2,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,2,3,4,5,6,7,8,9,8,7,6,5,4,3,2,1,0
%N a(n) = b(n) - b(b(n)) - b(n - b(n)) for n >= 3, where b(n) = A356989(n).
%C The sequence appears to consist of blocks of terms of the form 1, 2, 3, ..., A(k) - 1, A(k), A(k) - 1, ..., 3, 2, 1, where A(k) = A000930(k), separated by blocks of consecutive zeros.
%C The sequence of local peak values of the line graph of the sequence {a(n)} begins 1, 1, 1, 2, 3, 4, 6, 9, 13, 19, ..., conjecturally A000930; the local peaks occur at abscissa values n = 8, 12, 17, 25, 37, 54, 79, 116, 170, 249, ..., conjecturally {A179070(k): k >= 7}. Cf. A356995 and A356997.
%F a(n+1) - a(n) belongs to {1, 0, -1}.
%e Sequence arranged as an irregular triangle; after the first row of zeros the row lengths are conjecturally equal to A164316(k) for k >= 2.
%e 0, 0, 0, 0, 0;
%e 1, 0, 0, 0;
%e 1, 0, 0, 0, 0;
%e 1, 0, 0, 0, 0, 0, 0;
%e 1, 2, 1, 0, 0, 0, 0, 0, 0, 0, 0;
%e 1, 2, 3, 2, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0;
%e 1, 2, 3, 4, 3, 2, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0;
%e 1, 2, 3, 4, 5, 6, 5, 4, 3, 2, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0;
%e ...
%p # b(n) = A356989
%p b := proc(n) option remember; if n = 1 then 1 else n - b(b(b(n - b(b(b(b(n-1))))))) end if; end proc:
%p seq(b(n) - b(b(n)) - b(n - b(n)), n = 3..300);
%Y Cf. A000930, A164316, A179070, A356989, A356995, A356997.
%K nonn,easy
%O 3,23
%A _Peter Bala_, Sep 10 2022