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.

A338835 a(n) is the greatest number not yet in the sequence with the same number of digits and the same sum of digits as n in primorial base.

Original entry on oeis.org

0, 1, 2, 4, 3, 5, 6, 12, 8, 18, 14, 24, 7, 13, 10, 20, 19, 26, 9, 16, 15, 25, 22, 28, 11, 21, 17, 27, 23, 29, 30, 60, 36, 90, 66, 120, 32, 62, 61, 96, 92, 150, 42, 91, 72, 126, 122, 180, 68, 121, 102, 156, 152, 186, 98, 151, 132, 182, 181, 192, 31, 38, 37, 67
Offset: 0

Views

Author

Rémy Sigrist, Nov 11 2020

Keywords

Comments

This sequence is a self-inverse permutation of the nonnegative integers.

Examples

			For n = 8:
- the numbers with 3 digits and sum of digits 2 in primorial base are: 7 ("101"), 8 ("110") and 12 ("200"),
- so a(7) = 12,
     a(8) = 8,
     a(12) = 7.
		

Crossrefs

Cf. A235224, A276150, A333658, A338829 (decimal analog), A338834 (factorial base analog).

Programs

  • PARI
    See Links section.

Formula

A235224(a(n)) = A235224(n).
A276150(a(n)) = A276150(n).

A338829 a(n) is the greatest number not yet in the sequence with the same number of digits and the same sum of digits as n.

Original entry on oeis.org

0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 20, 30, 40, 50, 60, 70, 80, 90, 91, 11, 21, 31, 41, 51, 61, 71, 81, 82, 92, 12, 22, 32, 42, 52, 62, 72, 73, 83, 93, 13, 23, 33, 43, 53, 63, 64, 74, 84, 94, 14, 24, 34, 44, 54, 55, 65, 75, 85, 95, 15, 25, 35, 45, 46, 56, 66, 76
Offset: 0

Views

Author

Rémy Sigrist, Nov 11 2020

Keywords

Comments

This sequence is a self-inverse permutation of the nonnegative integers.
We have a fixed point with m digits and sum of digits k whenever A289410(m, k) is odd.

Examples

			For n = 23:
- the numbers with 2 digits and sum of digits 5 are: 14, 23, 32, 41 and 50,
- so  a(14) = 50,
      a(23) = 41,
      a(32) = 32,
      a(41) = 23,
      a(50) = 14.
		

Crossrefs

Cf. A055642, A289410, A331274 (binary analog), A333659, A338834 (factorial base analog), A338835 (primorial base analog).

Programs

  • Mathematica
    Block[{a = {}, f, k}, f[x_] := Total@ IntegerDigits@ x; Do[k = f[i]; AppendTo[a, SelectFirst[Range[10^# - 1, 10^(# - 1), -1] &@ Floor[1 + Log10[i]], And[f[#] == k, FreeQ[a, #]] &]], {i, 67}]; a] (* Michael De Vlieger, Nov 13 2020 *)
  • PARI
    See Links section.

Formula

A055642(a(n)) = A055642(n).
A007953(a(n)) = A007953(n).
Showing 1-2 of 2 results.