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.

A022556 Numbers that are a sum of a square and 2 nonnegative cubes.

This page as a plain text file.
%I A022556 #17 Jul 08 2025 09:17:18
%S A022556 0,1,2,3,4,5,6,8,9,10,11,12,13,16,17,18,20,24,25,26,27,28,29,31,32,33,
%T A022556 34,35,36,37,38,39,41,43,44,45,49,50,51,52,53,54,55,57,58,60,63,64,65,
%U A022556 66,68,69,70,71,72,73,74,76,77,79,80,81,82,83,84,88,89,90,91,92,95,97,99,100
%N A022556 Numbers that are a sum of a square and 2 nonnegative cubes.
%H A022556 Jean-François Alcover, <a href="/A022556/b022556.txt">Table of n, a(n) for n = 1..39986</a>
%p A022556 isA022556 := proc(n)
%p A022556     local a2,b,c ;
%p A022556     for b from 0 do
%p A022556         if b^3 > n then
%p A022556             return false;
%p A022556         end if;
%p A022556         for c from b do
%p A022556             a2 := n-b^3-c^3 ;
%p A022556             if a2 < 0 then
%p A022556                 break;
%p A022556             end if;
%p A022556             if issqr(a2) then
%p A022556                 return true;
%p A022556             end if;
%p A022556         end do:
%p A022556     end do:
%p A022556 end proc: # _R. J. Mathar_, Sep 02 2016
%t A022556 smax = 50000;
%t A022556 Table[s = i^2 + j^3 + k^3; If[s <= smax, s, Nothing], {i, 0, Sqrt[smax] // Ceiling}, {j, 0, smax^(1/3) // Ceiling}, {k, j, smax^(1/3) // Ceiling}] // Flatten // Union (* _Jean-François Alcover_, Feb 17 2023 *)
%Y A022556 Cf. A022557 (complement).
%K A022556 nonn
%O A022556 1,3
%A A022556 _N. J. A. Sloane_
%E A022556 More terms from _Jean-François Alcover_, Apr 07 2020