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

A385737 Perimeters of nondegenerate triangles with integer areas, whose side lengths are triangular numbers.

Original entry on oeis.org

176, 224, 264, 336, 504, 644, 756, 950, 1196, 1232, 1280, 1500, 1566, 1650, 1700, 2100, 2112, 2250, 2366, 2754, 3036, 3306, 5676, 5796, 7296, 8064, 8316, 8526, 9576, 10206, 10260, 12474, 13200, 15872, 16236, 16896, 17094, 17150, 20172, 21714, 21726, 22382, 22644
Offset: 1

Views

Author

Felix Huber, Jul 16 2025

Keywords

Comments

224 and 1280 are the only perimeters <= 10^6 of nondegenerate triangles whose side lengths (28, 91, 105 or 325, 325, 630, respectively) and areas (1176 or 25200, respectively) are triangular numbers.

Examples

			176 is a term because it is the perimeter of the triangle [55, 55, 66], where 55 and 66 are triangular numbers, which has an integer area of sqrt(88*(88 - 55)*(88 - 55)*(88 - 66)) = 1452.
224 is a term because it is the perimeter of the triangle [28, 91, 105], where 28, 91 and 105 are triangular numbers, which has an integer area of sqrt(112*(112 - 28)*(112 - 91)*(112 - 105)) = 1176 (which is also a triangular number).
		

Crossrefs

Subsequence of A380875.

Programs

  • Maple
    A385737:=proc(P) # To get all perimeters <= P.
        local p,x,y,z,u,v,w,s;
        p:=[];
        for z to floor((sqrt(24*P+9)-3)/6) do
            for x from z to floor((sqrt(4*P-3)-1)/2) do
                for y from max(z,floor((sqrt(1+4*(x^2+x-z^2-z))-1)/2)+1) to min(x,floor((sqrt(1+4*(2*P-x^2-x-z^2-z))-1)/2)) do
                	u:=z*(z+1)/2;
                	v:=y*(y+1)/2;
                	w:=x*(x+1)/2;
                	s:=(u+v+w)/2;
                	if issqr(s*(s-u)*(s-v)*(s-w)) then
                   	    p:=[op(p),u+v+w]
                   	fi
                od
            od
        od;
        return op(sort(p))
    end proc;
    A385737(22644);

A385872 Areas of nondegenerate triangles with perimeter A385737(n) whose side lengths are triangular numbers.

Original entry on oeis.org

1452, 1176, 2376, 3780, 8316, 10626, 14742, 28500, 12558, 32340, 25200, 94500, 18792, 130680, 89250, 158760, 130680, 155250, 53508, 93636, 122958, 208278, 893970, 1199772, 2183328, 1130976, 2058210, 1414098, 3160080, 4000752, 3898800, 324324, 4900500, 1845120, 7427970
Offset: 1

Views

Author

Felix Huber, Jul 18 2025

Keywords

Comments

45189144 is the smallest integer area of a right triangle whose sides are triangular numbers. This area corresponds to the triangle [8778, 10296, 13530].
From David A. Corneth, Jul 18 2025: (Start) If sidelengths are u, v, w where 0 < u < v < w < u + v then the area can be written as A = ((u + v + w) * (u + v - w) * (u - v + w) * (-u + v + w)) / 16 = k^2. If A is a square then 16*A is a square (possible extraneous resulting from this can be removed at the end).
We may rewrite 16*A as ((u + v)^2 - w^2) * (w^2 - (v - u)^2) = k^2
Since their product is a square we may write
((u + v)^2 - w^2) * t^2 = (w^2 - (v - u)^2). where t > 1 is a rational. When u, v and t are chosen we can solve for w.
w^2 = (t^2*(u-v)^2 + (u+v)^2) / (t^2 + 1). (End)

Examples

			a(1) = 1452 is the area of the triangle [55, 55, 66] with perimeter A385737(1) = 176, where 55 and 66 are triangular numbers.
a(2) = 1176 is the area of the triangle [28, 91, 105] with perimeter A385737(2) = 224, where 28, 91 and 105 are triangular numbers.
From _David A. Corneth_, Jul 18 2025: (Start)
From (u, v) = (28, 91) we get
((u + v)^2 - w^2) * t^2 = (w^2 - (v - u)^2)
(119 - w^2) * t^2 = (w^2 - 63^2). Testing t = 2/3 gives the desired w. (End)
		

Crossrefs

Programs

  • Maple
    A385872:=proc(P) # To get all integer areas of triangles with perimeters <= P.
        local p,x,y,z,u,v,w,s,i;
        p:=[];
        for z to floor((sqrt(24*P+9)-3)/6) do
            for x from z to floor((sqrt(4*P-3)-1)/2) do
                for y from max(z,floor((sqrt(1+4*(x^2+x-z^2-z))-1)/2)+1) to min(x,floor((sqrt(1+4*(2*P-x^2-x-z^2-z))-1)/2)) do
                	u:=z*(z+1)/2;
                	v:=y*(y+1)/2;
                	w:=x*(x+1)/2;
                	s:=(u+v+w)/2;
                	if issqr(s*(s-u)*(s-v)*(s-w)) then
                   	    p:=[op(p),[u+v+w,sqrt(s*(s-u)*(s-v)*(s-w))]]
                   	fi
                od
            od
        od;
        return seq(sort(p)[i,2],i=1..nops(p))
    end proc;
    A385872(16236);

A385860 a(n) is the number of distinct multisets of sides of quadrilaterals with perimeter n, where all four sides are squares.

Original entry on oeis.org

0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0, 1, 0, 0, 0, 1, 1, 0, 1, 0, 0, 1, 0, 1, 0, 0, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 0, 1, 1, 0, 1, 0, 0, 0, 1, 1, 1, 3, 0, 1, 1, 0, 1, 2, 1, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0, 1, 2, 1, 1, 2, 1, 2, 1, 1, 2, 0, 2, 1, 1, 1
Offset: 0

Views

Author

Felix Huber, Jul 22 2025

Keywords

Comments

a(n) is the number of partitions of n into 4 nonzero squares < n/2.

Examples

			The a(51) = 1 multiset is [1, 9, 16, 25].
The a(52) = 3 multisets are [1, 1, 25, 25], [4, 16, 16, 16] and [9, 9, 9, 25].
		

Crossrefs

Programs

  • Maple
    # After Alois P. Heinz (A025428)
    b:=proc(n,i,t)
        option remember;
        `if`(n=0,`if`(t=0,1,0),`if`(i<1 or t<1, 0, b(n,i-1,t)+`if`(i^2>n,0,b(n-i^2,i,t-1))))
        end:
    A385860:=n->b(n,floor(sqrt((n-1)/2)),4):
    seq(A385860(n),n=0..87);

Formula

a(n) <= A025428(n).
Showing 1-3 of 3 results.