%I #18 Mar 20 2018 16:14:45
%S 0,1,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,1,0,0,0,0,
%T 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
%U 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1
%N Gives the value (either 0 or 1) that the trajectory of n under A241663 eventually reaches.
%C a(n) = 1 for n = 1, 5, 25, 29, 125, 145, 149, 625, 725, 745, 841, ... - _Alois P. Heinz_, Apr 30 2014
%H Antti Karttunen, <a href="/A241666/b241666.txt">Table of n, a(n) for n = 0..65537</a>
%H C. Defant, <a href="https://cs.uwaterloo.ca/journals/JIS/VOL18/Defant/defant5.html">On Arithmetic Functions Related to Iterates of the Schemmel Totient Functions</a>, J. Int. Seq. 18 (2015) # 15.2.1
%H Colin Defant, <a href="/A241666/a241666.py.txt">Python program</a>
%H <a href="/index/Ch#char_fns">Index entries for characteristic functions</a>
%F a(0) = 0, a(1) = 1, and for n > 1, a(n) = a(A241663(n)). - _Antti Karttunen_, Nov 05 2017
%e A241663(A241663(7))=0, so a(7)=0. A241663(A241663(A241663(29)))=1, so a(29)=1.
%o (Python) # The link above provides a Python program. Input m=4, as well as starting and ending values of n. The fourth string of numbers will be this sequence.
%o (Scheme, with memoization-macro definec)
%o (definec (A241666 n) (if (<= n 1) n (A241666 (A241663 n)))) ;; _Antti Karttunen_, Nov 05 2017
%K nonn
%O 0
%A _Colin Defant_, Apr 26 2014
%E Term a(0)=0 prepended and more terms added by _Antti Karttunen_, Nov 05 2017
|