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

A282095 Larger member of a coprime pair (x,y) which solves x^2 + y^2 = z^3 with positive x, y and z.

Original entry on oeis.org

11, 46, 52, 117, 142, 198, 236, 286, 415, 488, 524, 549, 621, 666, 835, 873, 908, 970, 1001, 1199, 1388, 1432, 1692, 1757, 1962, 1964, 1971, 2035, 2041, 2366, 2392, 2630, 2655, 2681, 2702, 2815, 2826, 3195, 3421, 3544, 3664, 3715, 4048, 4070, 4097, 4356
Offset: 1

Views

Author

R. J. Mathar, Feb 06 2017

Keywords

Comments

If x and y are coprime, so obviously are also (x,z) and (y,z).
The ordered values of the bases of the cubes, z, are a subsequence of (and conjecturally the same as) A008846.
For production purposes we advice to use the parametrized representations (see references).

Examples

			2^2 + 11^2 = 5^3, so 11 is in the sequence.
9^2 + 46^2 = 13^3, so 46 is in the sequence.
47^2 + 52^2 = 17^3, so 52 is in the sequence.
44^2 + 117^2 = 25^2, so 117 is in the sequence.
		

Crossrefs

Subsequence of A282093. Cf. A099533.

Programs

  • Maple
    # slow version for demonstration only.
    isA282095 := proc(y)
        local x,z3 ;
        for x from 1 to y do
            if igcd(x,y) = 1 then
                z3 := x^2+y^2 ;
                if isA000578(z3) then
                    return true ;
                end if;
            end if;
        end do:
        return false ;
    end proc:
    for y from 1 do
        if isA282095(y) then
            printf("%d,\n",y) ;
        end if;
    end do:
  • Mathematica
    okQ[y_] := Module[{x, z3}, For[x=1, xJean-François Alcover, Dec 04 2017, after R. J. Mathar *)

Formula

{y: x^2 + y^2 = z^3; gcd(x,y) = 1; 1 <= x <= y; x, y, z in N}

A282094 Larger member of a pair (x,y) which solves x^2 + y^2 = z^3 for nonnegative x, y and z.

Original entry on oeis.org

0, 1, 2, 8, 10, 11, 16, 26, 27, 30, 39, 46, 52, 54, 64, 68, 80, 88, 100, 110, 117, 120, 125, 128, 130, 142, 145, 170, 198, 205, 208, 216, 222, 236, 240, 250, 270, 286, 297, 310, 312, 322, 343, 350, 366, 368, 371, 377, 406, 414, 415, 416, 432, 455, 481
Offset: 1

Views

Author

R. J. Mathar, Feb 06 2017

Keywords

Comments

Values y such that x^2 + y^2 = z^3 has a solution 0 <= x <= y with integer x, y and z.
Differs from A282093 because solutions with x=0 are admitted; (x,y) = (0,t^3) solves the equation with z = t^2.

Examples

			0^2 + 0^2 = 0^3, so 0 is in. 0^2 + 1^2 = 1^3, so 1 is in. 2^2 + 2^2 = 2^3, so 2 is in. 0^2 + 8^2 = 4^3, so 8 is in. 5^2 + 10^2 = 5^3, so 10 is in.
		

Crossrefs

Cf. A282093.

Programs

  • Maple
    isA282094 := proc(y)
        local x,z3 ;
        for x from 0 to y do
            z3 := x^2+y^2 ;
            if isA000578(z3) then
                return true ;
            end if;
        end do:
        return false ;
    end proc:
    for y from 0 to 800 do
        if isA282094(y) then
            printf("%d,",y) ;
        end if;
    end do:
  • Mathematica
    isA282094[y_] := If[IntegerQ[y^(1/3)], True, Module[{x, z3}, For[x = 1, x <= y, x++, z3 = x^2 + y^2; If[IntegerQ[z3^(1/3)], Return[True]]]; Return[False]]];
    Reap[For[y = 0, y <= 800, y++, If[isA282094[y], Print[y]; Sow[y]]]][[2, 1]] (* Jean-François Alcover, Nov 03 2023, after R. J. Mathar *)
  • PARI
    is(n)=my(n2=n^2); for(x=0,n, if(ispower(n2+x^2,3), return(1))); 0 \\ Charles R Greathouse IV, Jun 30 2017
  • Python
    from sympy import factorint
    def is_cube(n):
        if n==0: return True
        return all(i%3==0 for i in factorint(n).values())
    def ok(n):
        return any(is_cube(x**2 + n**2) for x in range(n + 1))
    print([n for n in range(501) if ok(n)]) # Indranil Ghosh, Jun 30 2017
    

Formula

Equals A282093 union A000578.
Showing 1-2 of 2 results.