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.

A351372 Array of triples (x,y,z) satisfy the Diophantine equation (x+y)^2 + (y+z)^2 + (z+x)^2 = 12*x*y*z, 1 <= x <= y <= z. (sorted by z).

Original entry on oeis.org

1, 1, 1, 1, 1, 3, 1, 3, 13, 1, 13, 61, 3, 13, 217, 1, 61, 291, 1, 291, 1393, 3, 217, 3673, 13, 61, 4683, 1, 1393, 6673, 13, 217, 16693, 1, 6673, 31971, 3, 3673, 62221, 61, 291, 106153, 1, 31971, 153181, 13, 4683, 360517, 1, 153181, 733933, 3, 62221, 1054081
Offset: 1

Views

Author

Seiichi Manyama, Feb 15 2022

Keywords

Examples

			The array of triples begins:
  ( 1,    1,     1),
  ( 1,    1,     3),
  ( 1,    3,    13),
  ( 1,   13,    61),
  ( 3,   13,   217),
  ( 1,   61,   291),
  ( 1,  291,  1393),
  ( 3,  217,  3673),
  (13,   61,  4683),
  ( 1, 1393,  6673),
  (13,  217, 16693),
  ...
		

Crossrefs

Cf. A291694.

Programs

  • PARI
    N=5000;
    for(k=1, N, for(j=1, k, for(i=1, j, if(i*j>k, break); if((i+j)^2+(j+k)^2+(k+i)^2==12*i*j*k, print1(i, ", ", j, ", ", k, ", ")))));
    
  • Python
    from math import isqrt
    from itertools import count, islice
    def A351372_gen(): # generator of terms
        for z in count(1):
            z2 = z**2
            for y in range(1,z+1):
                a = isqrt(d := 3*y**2*(12*z2 - 4*z - 1) - 3*z2*(4*y + 1) - 2*y*z)
                if a**2 == d:
                    x, r = divmod(12*y*z - 2*y - 2*z - 2*a,4)
                    if y <= x <= z and r == 0:
                        yield from (y,x,z)
    A351372_list = list(islice(A351372_gen(),21)) # Chai Wah Wu, Feb 16 2022

Extensions

More terms from Chai Wah Wu, Feb 16 2022