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.

A367355 Comma sequence, analogous to A121805, starting at 1, but the calculations are done in base 3.

This page as a plain text file.
%I A367355 #11 Dec 22 2023 11:47:35
%S A367355 1,5,12,13,17,25,29,36,37,41,48,49,53,61,66,68,76
%N A367355 Comma sequence, analogous to A121805, starting at 1, but the calculations are done in base 3.
%p A367355 # Comma Successor in Maple in base "bas", from _N. J. A. Sloane_, Dec 06 2023
%p A367355 bas := 3;
%p A367355 Ldigit:=proc(n) local v; v:=convert(n, base, bas); v[-1]; end; # Returns leading digit
%p A367355 # Return comma-successor to a or -1 if no successor exists
%p A367355 commsucc := proc(a) local f,i,d;
%p A367355 f := (a mod bas);
%p A367355 d:=bas*f;
%p A367355 for i from 1 to bas-1 do
%p A367355 d := d+1;
%p A367355 if Ldigit(a+d) = i then return(a+d); fi;
%p A367355 od:
%p A367355 return(-1);
%p A367355 end;
%p A367355 a:=[1]; s:=1; for n from 1 to 16 do s:=commsucc(s); a:=[op(a),s]; od: a;
%Y A367355 Cf. A121805, A367343, A367344, A367356.
%Y A367355 A367605 and A367605 give the length and last term for the analogous sequence in base b.
%K A367355 nonn,base,fini,full
%O A367355 1,2
%A A367355 _N. J. A. Sloane_, Nov 18 2023