[go: up one dir, main page]

login
A340462
Triangular numbers that are the hypotenuse of a primitive Pythagorean triple (PPT) such that another member of the triple is also triangular.
1
325, 49141, 104653, 354061, 3059101, 24735061, 33697945, 72884701, 406509841, 408565405, 1081752841, 1690914781, 3234130525, 4521006505, 4759123141, 6432672025, 10850633641, 27812493325, 33549177061, 39343911841, 49017527065, 145684193005, 157819451653, 221156059645
OFFSET
1,1
COMMENTS
A PPT is generated from the Euclid formula using parameters m, n where the hypotenuse is m^2+n^2, the odd leg is m^2-n^2 and the even leg is 2*m*n with m>n, m+n odd and GCD(m,n) = 1. For a triangular number to be the hypotenuse of a PPT it must be the sum of two squares and have all its prime factors congruent to 1 (mod 4). If a(n) is the k-th triangular number, then k is a member of A337156 such that the PPT has a second triangular number as either the odd or even leg.
Conjecture: No PPT exists with all its members triangular numbers.
EXAMPLE
a(1) = 325 because 325 is the 25th triangular number and has all its prime factors congruent to 1 (mod 4). It is the sum of two squares m^2 + n^2 where (m,n) = (1,18), (6,17), (10,15). The first and second pair can be used to generate two PPT's (325,323,36) and (325,253,204) and these PPT's contain a second triangular number 36 and 253 respectively.
MATHEMATICA
TriQ[n_] := Module[{m=Floor@Sqrt[2n]}, If[n==m(m+1)/2, True, False]]; flst[n_] := Module[{p, lst={}, p2=Ceiling@Sqrt[n/2], p1=1}, Do[If[IntegerQ[s=Sqrt[n-p^2]]&&s>0&&GCD[s, p]==1&&OddQ[s+p], AppendTo[lst, {p, s}]], {p, p1, p2}]; lst]; lst={}; Do[If[Union@Mod[First/@FactorInteger[p(p+1)/2], 4]=={1}, AppendTo[lst, Map[#[[1]]^2+#[[2]]^2 &, Select[flst[p(p+1)/2], TriQ[2#[[1]]*#[[2]]]||TriQ[#[[2]]^2-#[[1]]^2] &], 1]]], {p, 2, 10^4}]; Union@Flatten@lst
PROG
(PARI) isokt(k) = my(f=factor(k)[, 1]~); for (i=1, #f, if ((f[i]%4) != 1, return (0))); return(1); \\ A337156
isok(h, n) = {if (ispolygonal(h, 3) && isokt(h), for (it=1, n-1, my(i=it*(it+1)/2, c); if (issquare(h^2-i^2, &c) && (gcd([i, c, h]) == 1), return (1); ); ); ); }
lista(nn) = {for (n=1, nn, my(t=n*(n+1)/2); if (isok(t, n), print1(t, ", ")); ); } \\ Michel Marcus, Apr 25 2021
CROSSREFS
Cf. A337156.
Sequence in context: A145414 A298106 A266365 * A166220 A121000 A290949
KEYWORD
nonn
AUTHOR
Frank M Jackson, Jan 08 2021
STATUS
approved