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.

A213083 Each square n^2 appears n^2 number of times.

Original entry on oeis.org

1, 4, 4, 4, 4, 9, 9, 9, 9, 9, 9, 9, 9, 9, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36
Offset: 1

Views

Author

Jens Ahlström, Jun 05 2012

Keywords

Crossrefs

Programs

  • Mathematica
    Flatten[Table[Table[n^2, {n^2}], {n, 6}]] (* T. D. Noe, Jun 05 2012 *)
  • Python
    from sympy.core.intfunc import integer_nthroot
    def A213083(n): return ((m:=integer_nthroot(3*n,3)[0])+(6*n>m*(m+1)*((m<<1)+1)))**2 # Chai Wah Wu, Jun 21 2025

Formula

a(n) = A074279(n)^2. Alternatively, a(n) = (m+1)^2 if n > m(m+1)(2m+1)/6 and a(n) = m^2 otherwise where m = floor((3n)^(1/3)). - Chai Wah Wu, Jun 21 2025
Sum_{n>=1} (-1)^(n+1)/a(n) = A006752. - Amiram Eldar, Jun 30 2025