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-2 of 2 results.

A256299 Apply the transformation 0 -> 1 -> 2 -> 3 -> 4 -> 5 -> 6 -> 7 -> 8 -> 0 to the digits of n written in base 9, then convert back to base 10.

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 7, 8, 0, 19, 20, 21, 22, 23, 24, 25, 26, 18, 28, 29, 30, 31, 32, 33, 34, 35, 27, 37, 38, 39, 40, 41, 42, 43, 44, 36, 46, 47, 48, 49, 50, 51, 52, 53, 45, 55, 56, 57, 58, 59, 60, 61, 62, 54, 64, 65, 66, 67, 68, 69
Offset: 0

Views

Author

M. F. Hasler, Mar 22 2015

Keywords

Comments

Base 9 variant of A035327 (base 2) and A048379 (base 10). See A256293 - A256298 for bases 3 through 8, and A256289 for the variant where the result is not converted back to base 10.

Examples

			a(9) = 19 because 9 = 10[9] becomes 21[9] = 19.
a(80) = 0 because 80 = 88[9] becomes 00[9] = 0.
		

Programs

  • PARI
    A256299(n,b=9)=!n+apply(t->(t+1)%b,n=digits(n,b))*vector(#n,i,b^(#n-i))~

A256308 Apply the transformation 0 -> 1 -> 2 -> 3 -> 4 -> 5 -> 6 -> 7 -> 0 to the digits of n written in base 8; do not convert back to base 10.

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 7, 0, 21, 22, 23, 24, 25, 26, 27, 20, 31, 32, 33, 34, 35, 36, 37, 30, 41, 42, 43, 44, 45, 46, 47, 40, 51, 52, 53, 54, 55, 56, 57, 50, 61, 62, 63, 64, 65, 66, 67, 60, 71, 72, 73, 74, 75, 76, 77, 70, 1, 2, 3, 4
Offset: 0

Views

Author

M. F. Hasler, Mar 22 2015

Keywords

Comments

Base 8 variant of A256078 (base 2) and A048379 (base 10). See A256303 - A256307 for bases 3 through 7, A256289 for base 9, and A256298 for the variant where the result is converted back to base 10.

Examples

			a(8) = 21 because 8 = "10" in base 8 becomes "21".
a(63) = 0 because 63 = "77" in base 8 becomes "00".
		

Programs

  • Mathematica
    Table[FromDigits[IntegerDigits[n,8]/.{0->1,1->2,2->3,3->4,4->5,5->6,6->7,7->0}],{n,0,60}] (* Harvey P. Dale, Mar 29 2015 *)
  • PARI
    A256308(n,b=8)=!n+eval(Strchr(apply(d->(d+1)%b+48, digits(n,b))))

Extensions

Examples corrected by Harvey P. Dale, Mar 29 2015
Showing 1-2 of 2 results.