login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 59th year, we have over 358,000 sequences, and we’ve crossed 10,300 citations (which often say “discovered thanks to the OEIS”).

Other ways to Give
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A260733 a(n) = number of steps needed to reach zero when starting from k = (n^2)-1 and repeatedly applying the map that replaces k with k - A002828(k), where A002828(k) = the least number of squares that add up to k. 12
0, 1, 3, 5, 9, 13, 18, 23, 30, 37, 44, 52, 62, 71, 81, 91, 104, 117, 131, 144, 159, 174, 190, 207, 224, 243, 262, 281, 301, 321, 343, 365, 388, 412, 437, 461, 487, 514, 539, 567, 596, 625, 654, 684, 715, 748, 781, 814, 848, 883, 918, 955, 991, 1030, 1067, 1105, 1145, 1187, 1227, 1269, 1311, 1354, 1396, 1441, 1486, 1531, 1579, 1624, 1673, 1723, 1773, 1821 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,3

LINKS

Antti Karttunen, Table of n, a(n) for n = 1..1024

FORMULA

a(n) = A260731((n^2)-1).

a(n) = A260732(n)-1.

MATHEMATICA

Table[Length[#] - 2 &@ NestWhileList[# - (If[First@ # > 0, 1, Length[ First@ Split@ #] + 1] &@ SquaresR[Range@ 4, #]) &, n^2, # != 0 &], {n, 72}] (* Michael De Vlieger, Sep 08 2016 *)

PROG

(Scheme, two variants, the other one utilizing memoization-macro definec)

(definec (A260733 n) (if (= 1 n) 0 (+ (A260734 (- n 1)) (A260733 (- n 1)))))

(define (A260733 n) (A260731 (- (* n n) 1)))

CROSSREFS

One less than A260732.

Cf. A002828, A255131, A260731, A260734.

Cf. also A261223.

Sequence in context: A152737 A032635 A036713 * A265429 A356254 A122248

Adjacent sequences: A260730 A260731 A260732 * A260734 A260735 A260736

KEYWORD

nonn

AUTHOR

Antti Karttunen, Aug 12 2015

STATUS

approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified December 5 17:16 EST 2022. Contains 358588 sequences. (Running on oeis4.)