OFFSET
1,3
COMMENTS
Integers that can be written as d*e*(d+e-4)/2+1 for positive integers d and e.
LINKS
Jean-François Alcover, Table of n, a(n) for n = 1..10000
MAPLE
filter:= proc(n)
local m, S, Q;
m:= 2*(n-1);
S:= numtheory:-divisors(m);
Q:= map(d ->(4*d-m+sqrt(4*d^3 + 16*d^2 - 8*d*m + m^2))/(2*d), S);
evalb(select(type, Q, posint) <> {})
end proc:
filter(0):= true:
filter(1):= true:
select(filter, [$0..1000]); # Robert Israel, Aug 24 2014
MATHEMATICA
Module[{gmax = 300, g}, Reap[Do[g = d e (d + e - 4)/2 + 1; If[IntegerQ[g], Sow[g]], {d, Ceiling[(3 + Sqrt[1 + 8 gmax])/2]}, {e, d}]][[2, 1]] // Select[#, # <= gmax &]& // Union] (* Jean-François Alcover, Sep 12 2020 *)
CROSSREFS
KEYWORD
nonn
AUTHOR
Richard Shadrach, Aug 22 2014
EXTENSIONS
b-file corrected by Jean-François Alcover, Sep 12 2020
STATUS
approved