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.

A339146 a(n) = a(floor(n / 5)) * (n mod 5 + 1); initial terms are 1.

Original entry on oeis.org

1, 1, 1, 1, 1, 1, 2, 3, 4, 5, 1, 2, 3, 4, 5, 1, 2, 3, 4, 5, 1, 2, 3, 4, 5, 1, 2, 3, 4, 5, 2, 4, 6, 8, 10, 3, 6, 9, 12, 15, 4, 8, 12, 16, 20, 5, 10, 15, 20, 25, 1, 2, 3, 4, 5, 2, 4, 6, 8, 10, 3, 6, 9, 12, 15, 4, 8, 12, 16, 20, 5, 10, 15, 20, 25, 1, 2, 3, 4, 5, 2, 4, 6, 8, 10, 3, 6, 9, 12, 15, 4, 8, 12, 16, 20, 5, 10, 15, 20, 25
Offset: 0

Views

Author

Robert Dougherty-Bliss, Nov 25 2020

Keywords

Comments

If a(n) is arranged in a table with row lengths 5, then the first column is the transpose of the first row, followed the transpose of the second row, followed by the transpose of the third row, and so on. The remainder of each row (except the first) is an arithmetic progression whose start and step size equals the first entry of the row.
a(n) = O(n).
limsup_n a(n) = +oo.

Examples

			a(10) = a(2) * 1 = 1.
a(13) = a(2) * 4 = 4.
		

Crossrefs

Cf. A194459.
Cf. A048896 (with 2 instead of 5, but shifted).

Programs

  • PARI
    a(n) = if (n < 5, 1, a(n\5)*(n % 5 + 1)); \\ Michel Marcus, Nov 26 2020
  • Python
    def a(n):
        if n < 5:
            return 1
        q, r = divmod(n, 5)
        return a(q) * (r + 1)