login
Numbers which can be expressed as the product of 3 positive integers in arithmetic progression.
2

%I #8 Jul 03 2023 14:31:10

%S 1,6,8,15,24,27,28,45,48,60,64,66,80,91,105,120,125,153,162,168,190,

%T 192,210,216,224,231,276,280,288,312,315,325,336,343,360,378,384,405,

%U 435,440,480,496,504,510,512,528,561,585,624,627,630,640,648,693,703,720

%N Numbers which can be expressed as the product of 3 positive integers in arithmetic progression.

%C Numbers of the form i*(i+j)*(i+2j), where i > 0 and j >= 0.

%H Robert Israel, <a href="/A162651/b162651.txt">Table of n, a(n) for n = 1..10000</a>

%e 1 = 1*1*1, 6 = 1*2*3, 8 = 2*2*2, 15 = 1*3*5, 24 = 2*3*4.

%e 120 = 1*8*15 = 2*6*10 = 4*5*6.

%p N:= 1000: # for all terms <= N

%p S:= {}:

%p for i from 1 to floor(N^(1/3)) do

%p S:= S union {seq(i*(i+j)*(i+2*j),j=0..floor((sqrt(i^4 + 8*i*N)-3*i^2)/(4*i)))}

%p od:

%p A:= sort(convert(S,list)); # _Robert Israel_, Feb 05 2020

%o (PARI) al(n)={local(v,inc,prd);

%o v=vector(n);inc=[0];prd=[1];

%o for(k=1,n,

%o v[k]=vecmin(prd);

%o if(v[k]==prd[ #prd],inc=concat(inc,[0]);prd=concat(prd,[(#inc)^3]));

%o for(j=1,#prd,if(prd[j]==v[k],inc[j]++;prd[j]=j*(j+inc[j])*(j+2*inc[j]))));

%o v}

%o (Python)

%o from itertools import count, islice

%o from sympy import divisors

%o from sympy.ntheory.primetest import is_square

%o def A162651_gen(startvalue=1): # generator of terms >= startvalue

%o for m in count(max(startvalue,1)):

%o for r in divisors(m,generator=True):

%o if is_square(r**2-m//r):

%o yield m

%o break

%o A162651_list = list(islice(A162651_gen(),20)) # _Chai Wah Wu_, Jul 03 2023

%Y Cf. A000578, A007531, A000384, A033996, A011199.

%K nonn

%O 1,2

%A _Franklin T. Adams-Watters_, Jul 08 2009