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.

Showing 1-7 of 7 results.

A165307 Minimum number n, not already present, that permits the cyclic repetition of the decimal digits 1,2,3,4,5,6,7,8,9 in the sequence.

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 7, 8, 9, 12, 34, 56, 78, 91, 23, 45, 67, 89, 123, 456, 789, 1234, 567, 891, 234, 5678, 912, 345, 678, 9123, 4567, 8912, 3456, 7891, 2345, 6789, 12345, 67891, 23456, 78912, 34567, 89123, 45678, 91234, 56789, 123456, 789123, 456789, 1234567
Offset: 1

Views

Author

Keywords

Comments

This sequence has a nice graph. - M. F. Hasler, Aug 16 2015

Examples

			Starting from 1,2,3,4,5,6,7,8,9 the next number is 12 because after 1,2,3,4,5,6,7,8,9 we must continue with a digit '1'. But 1 is already in the sequence so we need to append a 2, which yields 12. And so on.
		

Crossrefs

Cf. A081549 (strictly increasing version).

Programs

  • Mathematica
    a = {1}; c = 0; Do[c = 10 c + Mod[n, 9] + 1; If[! MemberQ[a, c], AppendTo[a, c]; c = 0], {n, 160}]; a (* Ivan Neretin, Aug 14 2015 *)
  • PARI
    a(n,show=0,u=[],d=[1,1])={my(s(d)=Strchr(vectorsmall(d[1],i,(d[2]-2+i)%9+49)));while(n--,show&&print1(s(d)",");u=setunion(u,[d]);#u>9 && u[10]==[u[1][1]+1,1] && u=u[10..-1];d=(d[1]+d[2]-1)%9+1;for(nd=u[1][1],9e9,if(!setsearch(u,[nd,d]),d=[nd,d];next(2))));eval(s(d))} \\ M. F. Hasler, Aug 16 2015

Extensions

Edited by Charles R Greathouse IV, Aug 03 2010

A165301 a(n) is the smallest number not already in the sequence, such that the concatenation of all a(n) displays the periodic digit string 1, 2, 3 (and repeat).

Original entry on oeis.org

1, 2, 3, 12, 31, 23, 123, 1231, 231, 2312, 312, 3123, 12312, 31231, 23123, 123123, 1231231, 231231, 2312312, 312312, 3123123, 12312312, 31231231, 23123123, 123123123, 1231231231, 231231231, 2312312312, 312312312, 3123123123, 12312312312, 31231231231
Offset: 1

Views

Author

Keywords

Examples

			Starting from 1, 2, 3, the next number must be 12 because we need to continue with a 1. But 1 is already in the sequence so we need to attach a 2 -> 12. And so on.
		

Crossrefs

Programs

  • Maple
    cyc3 := proc(n) op(n,[2,3,1]) ; end:
    A165301 := proc(n) option remember ; local k,prev,d,a ; if n = 1 then 1; else d := cyc3(procname(n-1) mod 10) ; a := d ; while true do prev := false; for k from 1 to n-1 do if procname(k) = a then prev := true; break; end if; end do; if not prev then return a; end if; d := cyc3(d) ; a := 10*a+d ; end do; end if ; end proc:
    seq(A165301(n),n=1..60) ; # R. J. Mathar, Oct 16 2009

Extensions

Keyword:base added, sequence extended by R. J. Mathar, Oct 16 2009

A165302 a(n) is the smallest number not already in the sequence, such that the concatenation of all a(n) displays the periodic digit string 1, 2, 3, 4 (and repeat).

Original entry on oeis.org

1, 2, 3, 4, 12, 34, 123, 41, 23, 412, 341, 234, 1234, 12341, 2341, 23412, 3412, 34123, 4123, 41234, 123412, 341234, 1234123, 412341, 234123, 4123412, 3412341, 2341234, 12341234, 123412341, 23412341, 234123412, 34123412, 341234123, 41234123, 412341234
Offset: 1

Views

Author

Keywords

Examples

			Starting from 1, 2, 3, 4, the next number must be 12 because we need to continue with a 1. But 1 is already in the sequence so we need to attach a 2 -> 12. And so on.
		

Crossrefs

Programs

  • Maple
    cyc4 := proc(n) op(n,[2,3,4,1]) ; end:
    A165302 := proc(n) option remember ; local k,prev,d,a ; if n = 1 then 1; else d := cyc4(procname(n-1) mod 10) ; a := d ; while true do prev := false; for k from 1 to n-1 do if procname(k) = a then prev := true; break; end if; end do; if not prev then return a; end if; d := cyc4(d) ; a := 10*a+d ; end do; end if ; end proc:
    seq(A165302(n),n=1..60) ; # R. J. Mathar, Oct 16 2009

Extensions

Keyword:base added, sequence extended by R. J. Mathar, Oct 16 2009

A165303 a(n) is the smallest number not already in the sequence, such that the concatenation of all a(n) displays the periodic digit string 1, 2, 3, 4, 5 (and repeat).

Original entry on oeis.org

1, 2, 3, 4, 5, 12, 34, 51, 23, 45, 123, 451, 234, 512, 345, 1234, 5123, 4512, 3451, 2345, 12345, 123451, 23451, 234512, 34512, 345123, 45123, 451234, 51234, 512345, 1234512, 3451234, 5123451, 2345123, 4512345, 12345123, 45123451, 23451234, 51234512
Offset: 1

Views

Author

Keywords

Examples

			Starting from 1, 2, 3, 4, 5, the next number must be 12 because we need to continue with a 1. But 1 is already in the sequence so we need to attach a 2 -> 12. And so on.
		

Crossrefs

Programs

  • Maple
    cyc5 := proc(n) op(n,[2,3,4,5,1]) ; end:
    A165303 := proc(n) option remember ; local k,prev,d,a ; if n = 1 then 1; else d := cyc5(procname(n-1) mod 10) ; a := d ; while true do prev := false; for k from 1 to n-1 do if procname(k) = a then prev := true; break; end if; end do; if not prev then return a; end if; d := cyc5(d) ; a := 10*a+d ; end do; end if ; end proc:
    seq(A165303(n),n=1..60) ; # R. J. Mathar, Oct 16 2009

Extensions

Keyword:base added, sequence extended by R. J. Mathar, Oct 16 2009

A165304 a(n) is the smallest number not already in the sequence, such that the concatenation of all a(n) displays the periodic digit string 1, 2, 3, 4, 5, 6 (and repeat).

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 12, 34, 56, 123, 45, 61, 23, 456, 1234, 561, 234, 5612, 345, 612, 3456, 12345, 6123, 4561, 2345, 61234, 56123, 45612, 34561, 23456, 123456, 1234561, 234561, 2345612, 345612, 3456123, 456123, 4561234, 561234, 5612345, 612345, 6123456, 12345612
Offset: 1

Views

Author

Keywords

Examples

			Starting from 1, 2, 3, 4, 5, 6, the next number must be 12 because the leading digit must be a 1. But 1 is already in the sequence so we need to attach a 2 -> 12.
		

Crossrefs

Programs

  • Maple
    cyc6 := proc(n) op(n,[2,3,4,5,6,1]) ; end:
    A165304 := proc(n) option remember ; local k,prev,d,a ; if n = 1 then 1; else d := cyc6(procname(n-1) mod 10) ; a := d ; while true do prev := false; for k from 1 to n-1 do if procname(k) = a then prev := true; break; end if; end do; if not prev then return a; end if; d := cyc6(d) ; a := 10*a+d ; end do; end if ; end proc:
    seq(A165304(n),n=1..60) ; # R. J. Mathar, Oct 16 2009

Extensions

Keyword:base added, sequence extended by R. J. Mathar, Oct 16 2009

A165305 a(n) is the smallest number not yet in the sequence such that the concatenation of all terms yields a periodic stream of digits 1, 2, 3, ..., 7 (repeat from 1).

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 7, 12, 34, 56, 71, 23, 45, 67, 123, 456, 712, 345, 671, 234, 567, 1234, 5671, 2345, 6712, 3456, 7123, 4567, 12345, 67123, 45671, 23456, 71234, 56712, 34567, 123456, 712345, 671234, 567123, 456712, 345671, 234567, 1234567
Offset: 1

Views

Author

Keywords

Examples

			For a(8), having already 1, 2, 3, 4, 5, 6, 7, the next number must be 12 because after 1,2,3,4,5,6,7 we shall continue with a 1.
But 1 is already in the sequence so we need to add a 2 -> 12. And so on.
		

Crossrefs

Extensions

Keyword base added by R. J. Mathar, Feb 02 2010

A165306 a(n) is the smallest number not yet in the sequence such that concatenation of all terms yields an infinite periodic stream of digits 1, 2, 3, ..., 8 (repeat from 1).

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 7, 8, 12, 34, 56, 78, 123, 45, 67, 81, 23, 456, 781, 234, 567, 812, 345, 678, 1234, 5678, 12345, 6781, 2345, 67812, 3456, 7812, 34567, 8123, 4567, 81234, 56781, 23456, 78123, 45678, 123456, 781234, 567812, 345678, 1234567, 812345
Offset: 1

Views

Author

Keywords

Examples

			Considering a(9), having already 1,2,3,4,5,6,7,8, the next number must be 12 because after 1,2,3,4,5,6,7,8 we shall continue with a 1.
But 1 is already in the sequence so we need to add a 2 -> 12. And so on.
		

Crossrefs

Programs

  • Maple
    cyc8 := proc(n) op(n, [2, 3, 4, 5, 6, 7, 8, 1]) ; end:
    A165306 := proc(n) option remember ; local k, prev, d, a ; if n = 1 then 1; else d := cyc8(procname(n-1) mod 10) ; a := d ; while true do prev := false; for k from 1 to n-1 do if procname(k) = a then prev := true; break; end if; end do; if not prev then return a; end if; d := cyc8(d) ; a := 10*a+d ; end do; end if ; end proc:
    seq(A165306(n), n=1..60) ; # R. J. Mathar, Feb 02 2010

Extensions

Keyword base added by R. J. Mathar, Feb 02 2010
Showing 1-7 of 7 results.