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

A367608 Comma-number associated with A367606(n), but written in base 10, or -1 if A367606(n) = -1.

Original entry on oeis.org

4, 7, 1, -1, 7, 2, 4, 7, 1, 4, 8, 1, 4, 8, 1, 5, 8, 2, 5, 7, 2, -1, 7, 2, 4, 7, 1, 4, 7, 1, 4, 7, 1, 4, 7, 1, 4, 7, 1, 4, 7, 1, 4, 7, 1, 4, 8, 1, 4, 8, 1, 5, 8, 2, 5, 8, 2, 5, 8, 2, 5, 8, 2, 5, 8, 2, 5, 8, 2, 5, 8, 2, 5, 7, 2, -1, 7, 2, 4, 7, 1, 4, 7, 1, 4, 7, 1, 4, 7, 1, 4, 7, 1, 4, 7, 1, 4, 7, 1, 4
Offset: 1

Views

Author

N. J. A. Sloane, Dec 11 2023

Keywords

Comments

If n has a comma-successor m (say) in base 3, then a(n) is the comma-number linking n and m, and is equal to m-n; a(n) = -1 if n has no successor. See A367338 for definitions.
This is a base-3 analog of A367339.

Crossrefs

Programs

  • Python
    from sympy.ntheory.factor_ import digits
    def a(n):
        b = n + 3*(n%3)
        return next((b+y-n for y in [1, 2] if digits(b+y, 3)[1] == y), -1)
    print([a(n) for n in range(1, 101)]) # Michael S. Branicky, Dec 11 2023

A367609 Comma-number associated with A367607(n), and written in base 3, or -1 if A367607(n) = -1.

Original entry on oeis.org

11, 21, 1, -1, 21, 2, 11, 21, 1, 11, 22, 1, 11, 22, 1, 12, 22, 2, 12, 21, 2, -1, 21, 2, 11, 21, 1, 11, 21, 1, 11, 21, 1, 11, 21, 1, 11, 21, 1, 11, 21, 1, 11, 21, 1, 11, 22, 1, 11, 22, 1, 12, 22, 2, 12, 22, 2, 12, 22, 2, 12, 22, 2, 12, 22, 2, 12, 22, 2, 12, 22, 2, 12, 21, 2, -1, 21, 2, 11, 21, 1, 11, 21, 1, 11, 21, 1, 11, 21, 1, 11, 21, 1, 11, 21, 1, 11, 21, 1, 11
Offset: 1

Views

Author

N. J. A. Sloane, Dec 11 2023

Keywords

Comments

This is a base-3 analog of A367339.

Crossrefs

Programs

  • Python
    from sympy.ntheory.factor_ import digits
    def a(n):
        b = n + 3*(n%3)
        return next((int("".join(map(str, digits(b+y-n, 3)[1:]))) for y in [1, 2] if digits(b+y, 3)[1] == y), -1)
    print([a(n) for n in range(1, 101)]) # Michael S. Branicky, Dec 11 2023

A367607 Comma-successor to n working in base 3, and written in base 3, or -1 if n has no successor.

Original entry on oeis.org

12, 100, 11, -1, 110, 22, 102, 120, 101, 112, 201, 111, 122, 211, 121, 210, 221, 202, 220, 1000, 212, -1, 1010, 222, 1002, 1020, 1001, 1012, 1100, 1011, 1022, 1110, 1021, 1102, 1120, 1101, 1112, 1200, 1111, 1122, 1210, 1121, 1202, 1220, 1201, 1212, 2001, 1211, 1222, 2011, 1221, 2010, 2021, 2002, 2020, 2101, 2012, 2100
Offset: 1

Views

Author

N. J. A. Sloane, Dec 11 2023

Keywords

Comments

This is a base-3 analog of A367338.

Crossrefs

Programs

  • Python
    from sympy.ntheory.factor_ import digits
    def a(n):
        b = n + 3*(n%3)
        return next((int("".join(map(str, d3))) for y in [1, 2] if (d3:=digits(b+y, 3)[1:])[0] == y), -1)
    print([a(n) for n in range(1, 61)]) # Michael S. Branicky, Dec 11 2023

A367623 Number of comma-children of n in base 3.

Original entry on oeis.org

2, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1
Offset: 1

Views

Author

N. J. A. Sloane, Dec 23 2023

Keywords

Crossrefs

Programs

  • Python
    from sympy.ntheory.factor_ import digits
    def a(k, base=3):
        m = k + base*(k%base)
        return len([m+y for y in range(1, base) if digits(m+y, base)[1] == y])
    print([a(n) for n in range(1, 96)]) # Michael S. Branicky, Dec 23 2023
Showing 1-4 of 4 results.