login
A253909
1 together with the positive squares.
10
1, 1, 4, 9, 16, 25, 36, 49, 64, 81, 100, 121, 144, 169, 196, 225, 256, 289, 324, 361, 400, 441, 484, 529, 576, 625, 676, 729, 784, 841, 900, 961, 1024, 1089, 1156, 1225, 1296, 1369, 1444, 1521, 1600, 1681, 1764, 1849, 1936, 2025, 2116, 2209, 2304, 2401, 2500
OFFSET
0,3
COMMENTS
Also, right border of A246595 arranged as an irregular triangle.
Engel expansion of A070910. - Benedict W. J. Irwin, Dec 15 2016
FORMULA
a(n) = A028310(n)^2.
a(n) = 3*a(n-1) - 3*a(n-2) + a(n-3) for n>=4. - David Neil McGrath, May 23 2015
G.f.: (1 - 2*x + 4*x^2 - x^3)/(1-x)^3. - David Neil McGrath, May 25 2015
E.g.f.: 1 + exp(x)*x*(1 + x). - Stefano Spezia, Jan 30 2023
MATHEMATICA
Join[{1}, Range[50]^2] (* Alonso del Arte, Feb 23 2015 *)
Range[0, 50]^2 /. 0 -> 1 (* Robert G. Wilson v, Dec 15 2016 *)
PROG
(PARI) a(n)=max(n, 1)^2 \\ Charles R Greathouse IV, Dec 16 2016
(Magma)
A253909:= func< n | n^2 +0^n >; // G. C. Greubel, Jan 22 2026
(Python)
def A253909(n): return n**2 +int(n==0) # G. C. Greubel, Jan 22 2026
CROSSREFS
Essentially the same as A000290 and A174902.
Sequence in context: A174902 A000290 A162395 * A305559 A221222 A144913
KEYWORD
nonn,easy,mult
AUTHOR
Omar E. Pol, Feb 12 2015
EXTENSIONS
Keyword:mult added by Andrew Howroyd, Aug 06 2018
STATUS
approved