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.

A005818 Numbers n that are primitive solutions to n^2 = a^2 + b^2 + c^2 (a,b,c > 0).

Original entry on oeis.org

3, 7, 9, 11, 13, 15, 17, 19, 21, 23, 25, 27, 29, 31, 33, 35, 37, 39, 41, 43, 45, 47, 49, 51, 53, 55, 57, 59, 61, 63, 65, 67, 69, 71, 73, 75, 77, 79, 81, 83, 85, 87, 89, 91, 93, 95, 97, 99, 101, 103, 105, 107, 109, 111, 113, 115, 117, 119, 121, 123, 125, 127, 129, 131
Offset: 1

Views

Author

N. J. A. Sloane, RALPH PETERSON (ralphp(AT)LIBRARY.NRL.NAVY.MIL)

Keywords

Comments

These are the odd numbers excluding 1 and 5. Every term in A005767 is n*2^k for some k.

Crossrefs

Cf. A005767.

Programs

  • Mathematica
    Join[{3}, Range[7, 200, 2]] (* Paolo Xausa, Feb 14 2025 *)
  • Python
    def A005818(n): return (n<<1)+3 if n>1 else 3 # Chai Wah Wu, Feb 14 2025

Formula

G.f.: x*(-2*x^2 + x + 3)/(x - 1)^2. - Chai Wah Wu, Sep 14 2018
E.g.f.: (exp(x) - 1)*(3 + 2*x). - Stefano Spezia, Feb 19 2023

Extensions

Name corrected by T. D. Noe, Nov 12 2010