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-6 of 6 results.

A000415 Numbers that are the sum of 2 but no fewer nonzero squares.

Original entry on oeis.org

2, 5, 8, 10, 13, 17, 18, 20, 26, 29, 32, 34, 37, 40, 41, 45, 50, 52, 53, 58, 61, 65, 68, 72, 73, 74, 80, 82, 85, 89, 90, 97, 98, 101, 104, 106, 109, 113, 116, 117, 122, 125, 128, 130, 136, 137, 145, 146, 148, 149, 153, 157, 160, 162, 164, 170, 173, 178, 180, 181
Offset: 1

Views

Author

Keywords

Comments

Only these numbers can occur as discriminants of quintic polynomials with solvable Galois group F20. - Artur Jasinski, Oct 25 2007
Complement of A022544 in the nonsquare positive integers A000037. - Max Alekseyev, Jan 21 2010
Nonsquare positive integers D such that Pell equation y^2 - D*x^2 = -1 has rational solutions. - Max Alekseyev, Mar 09 2010
Nonsquares for which all 4k+3 primes in the integer's canonical form occur with even multiplicity. - Ant King, Nov 02 2010

References

  • E. Grosswald, Representation of Integers as Sums of Squares, Springer-Verlag, New York Inc., (1985), p.15. - Ant King, Nov 02 2010

Crossrefs

Programs

  • Mathematica
    c = {}; Do[Do[k = a^2 + b^2; If[IntegerQ[Sqrt[k]], Null, AppendTo[c,k]], {a, 1, 100}], {b, 1, 100}]; Union[c] (* Artur Jasinski, Oct 25 2007 *)
    Select[Range[181],Length[PowersRepresentations[ #,2,2]]>0 && !IntegerQ[Sqrt[ # ]] &] (* Ant King, Nov 02 2010 *)
  • PARI
    is(n)=my(f=factor(n)); for(i=1, #f[, 1], if(f[i, 2]%2 && f[i, 1]%4==3, return(0))); !issquare(n) \\ Charles R Greathouse IV, Feb 07 2017
    
  • Python
    from itertools import count, islice
    from sympy import factorint
    def A000415_gen(startvalue=2): # generator of terms >= startvalue
        for n in count(max(startvalue,2)):
            f = factorint(n).items()
            if any(e&1 for p,e in f if p&3<3) and not any(e&1 for p,e in f if p&3==3):
                yield n
    A000415_list = list(islice(A000415_gen(),20)) # Chai Wah Wu, Aug 01 2023

Formula

{ A000404 } minus { A134422 }. - Artur Jasinski, Oct 25 2007

Extensions

More terms from Arlin Anderson (starship1(AT)gmail.com)

A000548 Squares that are not the sum of 2 nonzero squares.

Original entry on oeis.org

1, 4, 9, 16, 36, 49, 64, 81, 121, 144, 196, 256, 324, 361, 441, 484, 529, 576, 729, 784, 961, 1024, 1089, 1296, 1444, 1764, 1849, 1936, 2116, 2209, 2304, 2401, 2916, 3136, 3249, 3481, 3844, 3969, 4096, 4356, 4489
Offset: 1

Views

Author

Keywords

Comments

Squares of nonhypotenuse numbers A004144(n). - Lekraj Beedassy, Jul 06 2004
A143574(a(n)) = a(n); intersection of A000290 and A143575. - Reinhard Zumkeller, Aug 24 2008

Programs

  • Mathematica
    okQ[n_] := n == 1 || AllTrue[FactorInteger[n][[All, 1]], Mod[#, 4] != 1& ]; A000548 = Select[Range[100], okQ]^2 (* Jean-François Alcover, Feb 09 2016 *)

Formula

A000290 \ A134422. - R. J. Mathar, Feb 06 2011

A292313 Numbers that are the sum of three squares in arithmetic progression.

Original entry on oeis.org

75, 300, 507, 675, 867, 1200, 1875, 2028, 2523, 2700, 3468, 3675, 4107, 4563, 4800, 5043, 6075, 7500, 7803, 8112, 8427, 9075, 10092, 10800, 11163, 12675, 13872, 14700, 15987, 16428, 16875, 18252, 19200, 20172, 21675, 22707, 23763, 24300, 24843, 27075, 28227, 30000, 30603
Offset: 1

Views

Author

Antonio Roldán, Sep 14 2017

Keywords

Examples

			75 = 1^2 + 5^2 + 7^2 = 1 + 25 + 49, with 25 - 1 = 49 - 25 = 24.
675 = 3^2 + 15^2 + 21^2 = 9 + 225 + 441, with 225 - 9 = 441 - 225 = 216.
		

Crossrefs

Programs

  • PARI
    t=4; k=3; while(t<=13000, i=k; e=0; v=t+i; while(i>1&&e==0, if(issquare(v), m=3*t; e=1; print1(m,", ")); i+=-2; v+=i); k+=2; t+=k)

Formula

Sequence is 3*(distinct elements in A198385).
Numbers of the form 3*m^2 where 2*m^2 is in A004431. - Chai Wah Wu, Oct 05 2017

A266927 Perfect powers of the form x^2 + y^2 where x and y are positive integers.

Original entry on oeis.org

8, 25, 32, 100, 125, 128, 169, 225, 289, 400, 512, 625, 676, 841, 900, 1000, 1156, 1225, 1369, 1521, 1600, 1681, 2025, 2048, 2197, 2500, 2601, 2704, 2809, 3025, 3125, 3364, 3600, 3721, 4225, 4624, 4900, 4913, 5329, 5476, 5625, 5832, 6084, 6400, 6724, 7225, 7569
Offset: 1

Views

Author

Altug Alkan, Jan 06 2016

Keywords

Comments

Intersection of A000404 and A001597.
A134422 is a subsequence.
Obviously, this sequence contains all numbers of the form 2^(2*n+1), for n > 0.
Motivation for this sequence is the equation m^k = x^2 + y^2 where m,x,y > 0, k >= 2. - Altug Alkan, Jan 11 2016

Examples

			25 is a term because 25 = 5^2 = 3^2 + 4^2.
32 is a term because 32 = 2^5 = 4^2 + 4^2.
125 is a term because 125 = 5^3 = 10^2 + 5^2.
169 is a term because 169 = 13^2 = 5^2 + 12^2.
		

Crossrefs

Programs

  • Maple
    N:= 10000: # to get all terms <= N
    g:= proc(k)
        local F,F1,F2,F3,f;
        F:= ifactors(k)[2];
        F2,F:= selectremove(f->f[1]=2,F);
        F1,F3:= selectremove(f -> f[1] mod 4 = 1, F);
        if F1 <> [] then
           if hastype(map(f -> f[2],F3),odd) then
              seq(k^j, j=2..floor(log[k](N)),2)
           else seq(k^j, j=2..floor(log[k](N)))
           fi
        elif F2 = [] or F2[1][2]::even or hastype(map(f -> f[2],F3),odd) then NULL
        else seq(k^j, j=3..floor(log[k](N)),2)
        fi
    end proc:
    sort(convert(map(g,{$2..floor(sqrt(N))}),list)); # Robert Israel, Jan 11 2016
  • Mathematica
    lim = 7600; fQ[n_] := n == 1 || GCD @@ FactorInteger[n][[All, 2]] > 1; Select[Union@ Flatten@ Table[a^2 + b^2, {a, Floor[Sqrt[lim - 1]]}, {b, a, Floor[Sqrt[lim - a^2]]}], fQ] (* Michael De Vlieger, Jan 06 2016, after N. J. A. Sloane and J. H. Conway at A000404 and Ant King at A001597 *)
  • PARI
    is(n) = {for( i=1, #n=factor(n)~%4, n[1, i]==3 && n[2, i]%2 && return); n && ( vecmin(n[1, ])==1 || (n[1, 1]==2 && n[2, 1]%2))}
    for(n=1, 1e4, if((ispower(n) || n==1) && is(n), print1(n, ", ")));

A309779 Squares that can be expressed as the sum of two positive squares but not as the sum of three positive squares.

Original entry on oeis.org

25, 100, 400, 1600, 6400, 25600, 102400, 409600, 1638400, 6553600, 26214400, 104857600, 419430400, 1677721600, 6710886400, 26843545600, 107374182400, 429496729600, 1717986918400, 6871947673600, 27487790694400, 109951162777600, 439804651110400, 1759218604441600
Offset: 1

Views

Author

Bernard Schott, Aug 17 2019

Keywords

Comments

This sequence comes from the study of A309778, exactly, A309778(n) = 2 iff n^2 belongs to this sequence here.
According to Draxl link, a(n) is a term of this sequence iff a(n) = 5^2 * 4^(n-1) with n >= 1.
This sequence is a subsequence of A219222 whose terms are all of the form b_0 * 4^k with b_0 in A051952, hence, the only primitive term of this sequence here is 25.

Examples

			25 = 5^2 = 3^2 + 4^2,
100 = 10^2 = 6^2 + 8^2,
5^2 * 4^(n-1) = (5 * 2^(n-1))^2 = (3 * 2^(n-1))^2 + (4 * 2^(n-1))^2, but these terms are not the sum of three positive squares.
		

Crossrefs

Intersection of A000290 and A219222.

Programs

Formula

a(n) = 5^2 * 4^(n-1) with n >= 1.
a(n) = 4*a(n-1) for n > 1. G.f.: 25*x/(1 - 4*x). - Chai Wah Wu, Aug 29 2019
a(n) = 25 * A000302(n-1). - Alois P. Heinz, Aug 29 2019
E.g.f.: 25*(exp(4*x) - 1)/4. - Stefano Spezia, Oct 28 2023

A191765 Integers that are a sum of two nonzero triangular numbers and also the sum of two nonzero square numbers.

Original entry on oeis.org

2, 13, 18, 20, 25, 29, 34, 37, 58, 61, 65, 72, 73, 90, 97, 100, 101, 106, 130, 136, 137, 146, 148, 157, 160, 164, 169, 181, 193, 200, 202, 205, 208, 218, 225, 226, 232, 234, 241, 244, 245, 265, 272, 274, 277, 281, 288, 289, 298, 306, 328, 340, 346, 353, 370, 373, 388, 389, 400
Offset: 1

Views

Author

Ant King, Jun 22 2011

Keywords

Comments

A134422 is a subsequence. - Franklin T. Adams-Watters, Jun 25 2011

Examples

			25 is the sum of two nonzero triangular numbers: 10 + 15, and of two nonzero squares: 9 + 16; so 25 is in the sequence.
9 is the sum of two nonzero triangular numbers: 3 + 6, but can be represented as the sum of two squares only using zero: 0 + 9; so 9 is not in the sequence.
		

Crossrefs

Cf. A000217, A000290, A191766, intersection of A000404 and A051533, A134422.

Programs

  • Mathematica
    data=Length[Reduce[a^2+b^2==1/2 c (c+1)+1/2 d(d+1)== # && a>0 && b>0 && c>0 && d>0,{a,b,c,d},Integers]] &/@Range[400];DeleteCases[Table[If[data[[k]]>0,k,0],{k,1,Length[data]}],0]
Showing 1-6 of 6 results.