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.

Showing 1-5 of 5 results.

A047700 Numbers that are the sum of 5 positive squares.

Original entry on oeis.org

5, 8, 11, 13, 14, 16, 17, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79
Offset: 1

Views

Author

Arlin Anderson (starship1(AT)gmail.com)

Keywords

Comments

Complement of A047701.

Examples

			From _David A. Corneth_, Aug 04 2020: (Start)
2009 is in the sequence as 2009 = 18^2 + 18^2 + 18^2 + 19^2 + 26^2.
2335 is in the sequence as 2335 = 19^2 + 19^2 + 20^2 + 22^2 + 27^2.
3908 is in the sequence as 3908 = 24^2 + 24^2 + 26^2 + 28^2 + 36^2. (End)
		

Crossrefs

Formula

a(n) = n + 12 for n >= 22. - David A. Corneth, Aug 04 2020

A025367 Numbers that are the sum of 4 nonzero squares in 2 or more ways.

Original entry on oeis.org

28, 31, 34, 36, 37, 39, 42, 43, 45, 47, 49, 50, 52, 54, 55, 57, 58, 60, 61, 63, 66, 67, 68, 69, 70, 71, 73, 74, 75, 76, 77, 78, 79, 81, 82, 83, 84, 85, 86, 87, 90, 91, 92, 93, 94, 95, 97, 98, 99, 100, 102, 103, 105, 106, 107, 108, 109, 110, 111, 112, 113, 114, 115, 116, 117, 118
Offset: 1

Views

Author

Keywords

Crossrefs

Programs

  • Maple
    N:= 1000: # to get all terms <= N
    V:= Vector(N):
    for x from 1 while x^2 +3 <= N do
    for y from 1 to x while x^2 + y^2 + 2 <= N do
      for z from 1 to y while x^2 + y^2 + z^2 + 1 <= N do
        for w from 1 to z while x^2 + y^2 + z^2 + w^2 <= N do
           t:= x^2 + y^2 + z^2 + w^2;
           V[t]:= V[t]+1;
    od od od od:
    select(t -> V[t] >= 2, [$1..N]); # Robert Israel, Jul 05 2017
  • Mathematica
    Select[Range@ 200, 2 == Length@ Quiet@ IntegerPartitions[#, {4}, Range[Sqrt@ #]^2, 2] &] (* Giovanni Resta, Jul 05 2017 *)
    M = 1000;
    Clear[V]; V[_] = 0;
    For[a = 1, a <= Floor[Sqrt[M/4]], a++,
      For[b = a, b <= Floor[Sqrt[(M - a^2)/3]], b++,
        For[c = b, c <= Floor[Sqrt[(M - a^2 - b^2)/2]], c++,
          For[d = c, d <= Floor[Sqrt[M - a^2 - b^2 - c^2]], d++,
            m = a^2 + b^2 + c^2 + d^2;
            V[m] = V[m] + 1;
    ]]]];
    Select[Range[M], V[#] >= 2&] (* Jean-François Alcover, Mar 22 2019, after Robert Israel *)

Formula

{n: A025428(n) >= 2}. - R. J. Mathar, Jun 15 2018

A343702 Numbers that are the sum of five positive cubes in two or more ways.

Original entry on oeis.org

157, 220, 227, 246, 253, 260, 267, 279, 283, 286, 305, 316, 323, 342, 344, 361, 368, 377, 379, 384, 403, 410, 435, 440, 442, 468, 475, 487, 494, 501, 523, 530, 531, 549, 562, 568, 586, 592, 594, 595, 599, 602, 621, 625, 640, 647, 657, 658, 683, 703, 710, 712, 719, 729, 731, 738, 745, 752, 759, 764, 766, 771, 773, 778, 785
Offset: 1

Views

Author

David Consiglio, Jr., Apr 26 2021

Keywords

Comments

This sequence differs from A048927:
766 = 1^3 + 1^3 + 2^3 + 3^3 + 9^3
= 1^3 + 4^3 + 4^3 + 5^3 + 8^3
= 2^3 + 2^3 + 4^3 + 7^3 + 7^3.
So 766 is a term, but not a term of A048927.

Examples

			227 = 1^3 + 1^3 + 1^3 + 2^3 + 6^3
    = 2^3 + 3^3 + 4^3 + 4^3 + 4^3
so 227 is a term of this sequence.
		

Crossrefs

Programs

  • Mathematica
    Select[Range@1000,Length@Select[PowersRepresentations[#,5,3],FreeQ[#,0]&]>1&] (* Giorgos Kalogeropoulos, Apr 26 2021 *)
  • Python
    from itertools import combinations_with_replacement as cwr
    from collections import defaultdict
    keep = defaultdict(lambda: 0)
    power_terms = [x**3 for x in range(1,50)]#n
    for pos in cwr(power_terms,5):#m
        tot = sum(pos)
        keep[tot] += 1
    rets = sorted([k for k,v in keep.items() if v >= 2])#s
    for x in range(len(rets)):
        print(rets[x])

A344796 Numbers that are the sum of five squares in three or more ways.

Original entry on oeis.org

29, 32, 35, 37, 40, 43, 44, 46, 51, 52, 53, 56, 58, 59, 61, 62, 64, 65, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, 102, 103, 104, 106, 107, 108, 109, 110, 111, 112
Offset: 1

Views

Author

Sean A. Irvine, May 28 2021

Keywords

Crossrefs

A344806 Numbers that are the sum of six squares in two or more ways.

Original entry on oeis.org

21, 24, 29, 30, 33, 36, 38, 39, 41, 42, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98
Offset: 1

Views

Author

David Consiglio, Jr., Jun 20 2021

Keywords

Examples

			24 = 1^2 + 1^2 + 1^2 + 1^2 + 2^2 + 4^2
   = 2^2 + 2^2 + 2^2 + 2^2 + 2^2 + 2^2
so 24 is a term.
		

Crossrefs

Programs

  • Python
    from itertools import combinations_with_replacement as cwr
    from collections import defaultdict
    keep = defaultdict(lambda: 0)
    power_terms = [x**2 for x in range(1, 1000)]
    for pos in cwr(power_terms, 6):
        tot = sum(pos)
        keep[tot] += 1
        rets = sorted([k for k, v in keep.items() if v >= 2])
        for x in range(len(rets)):
            print(rets[x])
Showing 1-5 of 5 results.