%I #11 Sep 30 2016 18:17:14
%S 1,46,23,35,29,32,16,8,4,2,1,46,23,35,29,32,16,8,4,2,1,46,23,35,29,32,
%T 16,8,4,2,1,46,23,35,29,32,16,8,4,2,1,46,23,35,29,32,16,8,4,2,1,46,23,
%U 35,29,32,16,8,4,2,1,46,23,35,29,32,16,8,4,2,1,46,23,35,29,32,16,8,4,2,1,46,23
%N If a(n-1) is divisible by 2 then a(n) = a(n-1)/2. If a(n-1) is not divisible by 2 then a(n) = 47-(a(n-1)+1)/2; a(0)=1.
%C The old entry with this sequence number was a duplicate of A097945.
%C Periodic, with period = 10. - _Harvey P. Dale_, Sep 30 2016
%F Periodic with period of length 10.
%p a:=proc(n) option remember; local k; k:=47;
%p if n=0 then RETURN(1); fi;
%p if a(n-1) mod 2 = 0 then RETURN(a(n-1)/2); fi;
%p RETURN(k-(a(n-1)+1)/2); end;
%t NestList[If[EvenQ[#],#/2,47-(#+1)/2]&,1,90] (* or *) PadRight[{},90,{1,46,23,35,29,32,16,8,4,2}] (* _Harvey P. Dale_, Sep 30 2016 *)
%K nonn
%O 0,2
%A _N. J. A. Sloane_, Sep 25 2008, based on email from Zak Seidov, May 12 2008
%E Definition corrected by _Harvey P. Dale_, Sep 30 2016
|