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.

A261225 n minus the number of positive cubes needed to sum to n using the greedy algorithm: a(n) = n - A055401(n).

This page as a plain text file.
%I A261225 #8 Aug 20 2015 07:42:19
%S A261225 0,0,0,0,0,0,0,0,7,7,7,7,7,7,7,7,14,14,14,14,14,14,14,14,21,21,21,26,
%T A261225 26,26,26,26,26,26,26,33,33,33,33,33,33,33,33,40,40,40,40,40,40,40,40,
%U A261225 47,47,47,52,52,52,52,52,52,52,52,59,59,63,63,63,63,63,63,63,63,70,70,70,70,70,70,70,70,77,77,77,77,77,77,77,77,84,84,84,89
%N A261225 n minus the number of positive cubes needed to sum to n using the greedy algorithm: a(n) = n - A055401(n).
%H A261225 Antti Karttunen, <a href="/A261225/b261225.txt">Table of n, a(n) for n = 0..12167</a>
%F A261225 a(n) = n - A055401(n).
%F A261225 As a recurrence:
%F A261225 a(0) = 0; for n >= 1, a(n) = -1 + A048762(n) + a(n-A048762(n)). [Where A048762(n) gives the largest cube <= n.]
%e A261225 a(8) = 7, because when the greedy algorithm partitions 8 into cubes, it first finds 8 (= 2*2*2), thus A055401(8) = 1, and 8-1 = 7.
%o A261225 (Scheme, two variants)
%o A261225 (define (A261225 n) (- n (A055401 n)))
%o A261225 (definec (A261225 n) (if (zero? n) n (+ -1 (A048762 n) (A261225 (- n (A048762 n))))))
%Y A261225 Cf. A048762, A055401, A261226, A261227, A261228, A261229.
%Y A261225 Cf. also A260740.
%K A261225 nonn
%O A261225 0,9
%A A261225 _Antti Karttunen_, Aug 16 2015