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

A188158 Area A of the triangles such that A and the sides are integers.

Original entry on oeis.org

6, 12, 24, 30, 36, 42, 48, 54, 60, 66, 72, 84, 90, 96, 108, 114, 120, 126, 132, 144, 150, 156, 168, 180, 192, 198, 204, 210, 216, 234, 240, 252, 264, 270, 288, 294, 300, 306, 324, 330, 336, 360, 378, 384, 390, 396, 408, 420, 432, 456, 462, 468, 480, 486, 504, 510, 522, 528
Offset: 1

Views

Author

Michel Lagneau, Mar 22 2011

Keywords

Comments

The area A of a triangle whose sides have lengths a, b, and c is given by Heron's formula: A = sqrt(s*(s-a)*(s-b)*(s-c)), where s = (a+b+c)/2. A given area often corresponds to more than one triangle; for example, a(9) = 60 for the triangles (a,b,c) = (6,25,29), (8,17,15), (13,13,10) and (13,13,24).
If only primitive integer triangles (that is, the lengths of the sides are coprime) are considered, then the possible areas are 6 times the terms in A083875. - T. D. Noe, Mar 23 2011

Examples

			a(3) = 24 because the area of the triangle whose sides are 4, 15, 13 is given by sqrt(p(p-4)(p-15)(p-13)) = 24, where p = (4 + 15 + 13)/2 = 16.
		

Crossrefs

Programs

  • Maple
    # storage of areas in T(i)
    T:=array(1..4000):nn:=100:k:=1:for a from 1
      to nn do: for b from 1 to nn do: for c from 1 to nn do: p:=(a+b+c)/2 : x:=p*(p-a)*(p-b)*(p-c):   if x>0 then x1:=abs(x):s:=sqrt(x1) :else fi:if s=floor(s) then T[k]:=s:k:=k+1:else
      fi:od:od:od:
    # sort of T(i)
    for jj from 1 to k-1 do: ii:=jj:for k1 from  ii+1 to k-1 do:if T[ii]>T[k1] then ii:=k1:else fi:od: m:=T[jj]:T[jj]:=T[ii]:T[ii]:=m:od:liste:=convert(T,set):print(liste):
    # second program:
    isA188158 := proc(A::integer)
        local Asqr, s,a,b,c ;
        Asqr := A^2 ;
        for s in numtheory[divisors](Asqr) do
            if s^2> A then
            for a from 1 to s-1 do
                if modp(Asqr,s-a) = 0 then
                    for b from a to s-1 do
                        c := 2*s-a-b ;
                        if s*(s-a)*(s-b)*(s-c) = Asqr then
                            return true ;
                        end if;
                    end do:
                end if;
            end do:
            end if;
        end do:
        false ;
    end proc:
    for n from 3 to 600 do
        if isA188158(n) then
            printf("%d,\n",n) ;
        end if;
    end do: # R. J. Mathar, May 02 2018
  • Mathematica
    nn = 528; lst = {}; Do[s = (a + b + c)/2; If[IntegerQ[s], area2 = s (s - a) (s - b) (s - c); If[0 < area2 <= nn^2 && IntegerQ[Sqrt[area2]], AppendTo[lst, Sqrt[area2]]]], {a, nn}, {b, a}, {c, b}]; Union[lst] (* T. D. Noe, Mar 23 2011 *)

A096468 Perimeters of primitive Heronian triangles.

Original entry on oeis.org

12, 16, 18, 30, 32, 36, 40, 42, 44, 48, 50, 54, 56, 60, 64, 66, 68, 70, 72, 76, 78, 80, 84, 90, 96, 98, 100, 104, 108, 110, 112, 114, 120, 126, 128, 130, 132, 136, 140, 144, 150, 152, 154, 156, 160, 162, 164, 168, 170, 172, 174, 176, 180, 182, 186, 190, 192, 196
Offset: 1

Views

Author

T. D. Noe, Jun 22 2004

Keywords

Comments

Here a primitive Heronian triangle has integer sides a,b,c with GCD(a,b,c) = 1 and integral area. The perimeter is always even. Cheney's article contains many theorems about these triangles.

Examples

			12 is on this list because the triangle with sides 3, 4, 5 has integral area and perimeter 12.
		

Crossrefs

Cf. A070138 (number of primitive Heronian triangles having perimeter n), A083875 (area/6 of primitive Heronian triangles), A096467 (longest side of primitive Heronian triangles).

Programs

  • Mathematica
    nn=150; lst={}; Do[s=(a+b+c)/2; If[IntegerQ[s] && GCD[a, b, c]==1, area2=s(s-a)(s-b)(s-c); If[area2>0 && IntegerQ[Sqrt[area2]], AppendTo[lst, 2s]]], {a, nn}, {b, a}, {c, b}]; Union[lst]

Extensions

Name changed by Wesley Ivan Hurt, May 17 2020

A239246 Number of primitive Heronian triangles with n as greatest side length.

Original entry on oeis.org

0, 0, 0, 0, 1, 1, 0, 1, 0, 0, 0, 0, 2, 0, 2, 0, 3, 0, 0, 2, 2, 0, 0, 1, 3, 2, 0, 1, 2, 3, 0, 0, 0, 0, 2, 1, 5, 0, 4, 3, 4, 1, 0, 2, 1, 0, 0, 2, 0, 2, 4, 6, 4, 0, 2, 2, 0, 2, 0, 1, 3, 0, 1, 0, 8, 2, 0, 5, 1, 2, 0, 0, 6, 2, 7, 0, 3, 0, 0, 3, 0, 2, 0, 0, 9
Offset: 1

Views

Author

Frank M Jackson, Mar 13 2014

Keywords

Examples

			a(17)=3 as there are 3 primitive Heronian triangles with greatest side length of 17. They are (9, 10, 17), (8, 15, 17) and (16, 17, 17).
		

Crossrefs

Programs

  • Mathematica
    nn=200; lst={}; Do[s=(a+b+c)/2; If[IntegerQ[s]&&GCD[a, b, c]==1, area2=s(s-a)(s-b)(s-c); If[area2>0&&IntegerQ[Sqrt[area2]], AppendTo[lst, c]]], {c, 3, nn}, {b, c}, {a, b}]; Table[Length@Select[lst, #==n &], {n, 1, nn}] (* using T. D. Noe's program at A083875 *)

A096467 Numbers that can be the longest side of a primitive Heronian triangle.

Original entry on oeis.org

5, 6, 8, 13, 15, 17, 20, 21, 24, 25, 26, 28, 29, 30, 35, 36, 37, 39, 40, 41, 42, 44, 45, 48, 50, 51, 52, 53, 55, 56, 58, 60, 61, 63, 65, 66, 68, 69, 70, 73, 74, 75, 77, 80, 82, 85, 87, 88, 89, 90, 91, 92, 93, 95, 96, 97, 100, 101, 102, 104, 105, 106, 109, 110, 111, 112, 113
Offset: 1

Views

Author

T. D. Noe, Jun 22 2004

Keywords

Comments

Here a primitive Heronian triangle has integer sides a,b,c with gcd(a,b,c) = 1 and integral area. Note that all primes of the form 4k+1 are in this sequence. It appears that a prime of the form 4k+3 is never the longest side of a Heronian triangle. Cheney's article contains many theorems about these triangles.

Examples

			5 is on this list because the triangle with sides 3, 4, 5 has integral area.
		

Crossrefs

Cf. A083875 (area/6 of primitive Heronian triangles), A096468 (perimeter of primitive Heronian triangles).

Programs

  • Mathematica
    nn=150; lst={}; Do[s=(a+b+c)/2; If[IntegerQ[s] && GCD[a, b, c]==1, area2=s(s-a)(s-b)(s-c); If[area2>0 && IntegerQ[Sqrt[area2]], AppendTo[lst, a]]], {a, nn}, {b, a}, {c, b}]; Union[lst]

A227003 Number of primitive Heronian triangles with area 6n.

Original entry on oeis.org

1, 2, 0, 1, 1, 2, 1, 0, 0, 4, 1, 1, 0, 4, 2, 0, 0, 0, 1, 3, 3, 1, 0, 0, 0, 2, 0, 3, 0, 2, 0, 0, 1, 1, 6, 1, 0, 0, 1, 1, 0, 3, 0, 2, 1, 0, 0, 1, 0, 2, 1, 0, 0, 0, 4, 4, 0, 0, 0, 3, 0, 0, 0, 0, 1, 3, 0, 1, 0, 15, 0, 0, 0, 0, 0, 3, 2, 1, 0, 1, 0, 0, 0, 3, 2, 0, 1, 2, 0, 0
Offset: 1

Views

Author

Frank M Jackson, Jun 26 2013

Keywords

Comments

The Mathematica program captures all primitive Heronian areas up to 540 by searching through integer triangles with a longest side ranging from 3 to at least 484. This upper limit for the longest side is determined by observing that the shortest side of a Heronian triangle is >= 3 and the smallest area of an integer triangle with longest side z and shortest side 3 is generated by the integer triple (3, z-2, z).

Examples

			a(10) = 4 as there are 4 primitive Heronian triangles with area 60. The triples are (10,13,13), (8,15,17), (13,13,24), (6,25,29).
		

Crossrefs

Programs

  • Mathematica
    nn=540; lst={}; Do[s=(a+b+c)/2; If[IntegerQ[s]&&GCD[a, b, c]==1, area2=s(s-a)(s-b)(s-c); If[area2>0&&IntegerQ[Sqrt[area2]], AppendTo[lst, Sqrt[area2]]]], {a, 3, nn}, {b, a}, {c, b}]; lst1=Sort@lst/6; Table[Length@Select[lst1, n==# &], {n, 1, nn/6}] (* using T. D. Noe's program A083875 *)
  • PARI
    a(n)=sum(z=sqrtint(sqrtint(192*n^2)-1)+1,sqrtint(9*(64*n^2+5)\20), sum(y=z\2+1,z, my(t=(y*z)^2-(12*n)^2,x,g=gcd(y,z)); if(issquare(t,&t), (issquare(y^2+z^2-2*t,&x) && gcd(x,g)==1 && x<=y) + (t && issquare(y^2+z^2+2*t,&x) && gcd(x,g)==1 && x<=y), 0))) \\ Charles R Greathouse IV, Jun 27 2013

A218243 Triangle numbers: m = a*b*c such that the integers a,b,c are the sides of a triangle with integer area.

Original entry on oeis.org

60, 150, 200, 480, 780, 1200, 1530, 1600, 1620, 1690, 1950, 2040, 2100, 2730, 2860, 3570, 3840, 4050, 4056, 4200, 4350, 4624, 5100, 5400, 5460, 6240, 7500, 8120, 8250, 8670, 8750, 9600, 10812, 11050, 11900, 12180, 12240, 12800, 12960, 13260, 13520, 13650
Offset: 1

Views

Author

Michel Lagneau, Oct 24 2012

Keywords

Comments

A triangle number m is an integer with at least one decomposition m = a*b*c such that the area of the triangle of sides (a,b,c) is an integer. Because this property is not always unique, we introduce the notion of "triangle order" for each triangle number m, denoted by TO(m). For example, TO(60) = 1 because the decomposition 60 = 3*4*5 is unique with the triangle (3,4,5) whose area A is given by Heron's formula: A = sqrt(s*(s-a)*(s-b)*(s-c)), where s = (a+b+c)/2 => A = sqrt(6*(6-3)*(6-4)*(6-5)) = 6, but TO(780) = 2 because 780 = 4*13*15 = 5*12*13 and the area of the triangle (4,13,15) is sqrt(16*(16-4)*(16-13)*(16-15)) = 24 and the area of the triangle (5,12,13) is sqrt(15*(15-5)*(15-12)*(15-13)) = 30.
Given an area A of A188158, there exists either a unique triangle number (for example for A = 6 => m = 60 = 3*4*5), or several triangle numbers (for example for A=60 => m1 = 4350 = 6*25*29, m2 = 2040 = 8*15*17, m3 = 1690 = 13*13*10).
The number of ways to write m = a*b*c with 1<=a<=b<=c<=m is given by A034836, thus: TO(m) <= A034836(m).
If n is in this sequence, so is nk^3 for any k > 0. Thus this sequence is infinite. - Charles R Greathouse IV, Oct 24 2012
In view of the preceding comment, one might call "primitive" the elements of the sequence for which there is no k>1 such that n/k^3 is again a term of the sequence. These elements 60, 150, 200, 780, 1530, 1690, 1950,... are listed in A218392. - M. F. Hasler, Oct 27 2012

Examples

			60 is in the sequence because 60 = 3*4*5 and the corresponding area is sqrt(6*(6-3)*(6-4)*(6-5)) = 6 = A188158(1).
		

Crossrefs

Subsequence of A139270.

Programs

  • Mathematica
    nn = 500; lst = {}; Do[s = (a + b + c)/2; If[IntegerQ[s], area2 = s (s - a) (s - b) (s - c); If[0 < area2 <= nn^2 && IntegerQ[Sqrt[area2]], AppendTo[lst, a*b*c]]], {a, nn}, {b, a}, {c, b}]; Union[lst] (* Program from T. D. Noe, adapted for this sequence - see A188158 *)
  • PARI
    Heron(a,b,c)=a*=a;b*=b;c*=c;((a+b+c)^2-2*(a^2+b^2+c^2))
    is(n)=fordiv(n,a, if(a^3<=n, next); fordiv(n/a,b, my(c=n/a/b,h); if(a>=b && b>=c && aCharles R Greathouse IV, Oct 24 2012

A227166 Areas of indecomposable non-Pythagorean primitive integer Heronian triangles, sorted increasingly.

Original entry on oeis.org

72, 126, 168, 252, 252, 288, 336, 336, 396, 396, 420, 420, 420, 420, 456, 462, 528, 528, 624, 714, 720, 720, 756, 792, 798, 840, 840, 840, 840, 864, 924, 924, 924, 924, 936, 990, 1008, 1092, 1092, 1188, 1200, 1218, 1248, 1260, 1260, 1320, 1320, 1320
Offset: 1

Views

Author

Frank M Jackson, Jul 03 2013

Keywords

Comments

An indecomposable integer Heronian triangle that is not Pythagorean cannot be decomposed into two separate Pythagorean triangles because it has no integer altitudes.
See comments in A227003 about the Mathematica program below to ensure that all primitive Heronian areas up to 1320 are captured.

Examples

			a(2) = 126 as this is the second smallest area of an indecomposable non-Pythagorean primitive Heronian triangle. The triple is (5,51,52).
		

Crossrefs

Programs

  • Mathematica
    nn=1320; lst={}; Do[s=(a+b+c)/2; If[IntegerQ[s]&&GCD[a, b, c]==1, area2=s(s-a)(s-b)(s-c); If[area2>0 && IntegerQ[Sqrt[area2]] && !IntegerQ[2Sqrt[area2]/a] && !IntegerQ[2Sqrt[area2]/b] && !IntegerQ[2Sqrt[area2]/c], AppendTo[lst, Sqrt[area2]]]], {a, 3, nn}, {b, a}, {c, b}]; Sort@Select[lst, #<=nn &] (* using T. D. Noe's program A083875 *)

Extensions

Name clarified by Frank M Jackson, Mar 17 2014

A239978 Areas of indecomposable primitive integer Heronian triangles (including primitive Pythagorean triangles), in increasing order.

Original entry on oeis.org

6, 30, 60, 72, 84, 126, 168, 180, 210, 210, 252, 252, 288, 330, 336, 336, 396, 396, 420, 420, 420, 420, 456, 462, 504, 528, 528, 546, 624, 630, 714, 720, 720, 756, 792, 798, 840, 840, 840, 840, 840, 864, 924, 924, 924, 924, 924, 936, 990, 990, 1008
Offset: 1

Views

Author

Frank M Jackson, Mar 30 2014

Keywords

Comments

An indecomposable Heronian triangle is a Heronian triangle that cannot be split into two Pythagorean triangles. In other words, it has no integer altitude that is not a side of the triangle. Note that all primitive Pythagorean triangles are indecomposable.
See comments in A227003 about the Mathematica program below to ensure that all primitive Heronian areas up to 1008 are captured.

Examples

			a(5) = 84 as this is the fifth ordered area of an indecomposable primitive Heronian triangle. The triple is (7,24,25) and it is Pythagorean.
		

Crossrefs

Programs

  • Mathematica
    nn=1008; lst={}; Do[s=(a+b+c)/2; If[IntegerQ[s]&&GCD[a, b, c]==1, area2=s(s-a)(s-b)(s-c); If[area2>0&&IntegerQ[Sqrt[area2]]&&((!IntegerQ[2Sqrt[area2]/a]&&!IntegerQ[2Sqrt[area2]/b]&&!IntegerQ[2Sqrt[area2]/c])||(c^2+b^2==a^2)), AppendTo[lst, Sqrt[area2]]]], {a,3,nn}, {b,a}, {c,b}]; Sort@Select[lst, #<=nn &] (*using T. D. Noe's program A083875*)

A240240 Consider primitive Heronian triangles with integer area and with sides {m, m+1, c}, where c > m+1. The sequence gives the possible values of m.

Original entry on oeis.org

3, 9, 13, 19, 20, 33, 51, 65, 73, 99, 119, 129, 163, 170, 174, 193, 201, 203, 220, 243, 260, 269, 287, 289, 339, 362, 377, 393, 450, 451, 513, 532, 559, 579, 615, 649, 696, 702, 714, 723, 740, 771, 801, 883, 909, 940, 969, 975, 1059, 1112, 1153, 1155, 1156, 1164, 1251, 1299, 1325, 1332, 1353, 1424, 1455, 1459, 1569, 1605, 1615, 1683, 1690, 1716, 1801, 1869, 1919, 1923
Offset: 1

Views

Author

Zak Seidov, Apr 03 2014

Keywords

Comments

Corresponding values of c are 5, 17, 15, 37, 29, 65, 101, 109, 145.
And corresponding values of area/6 are 1, 6, 14, 19, 35, 44, 85, 330, 146, 231, 1190.
The sequence includes all terms of A016064 (where c = m+2) except for the first term, 1 (case with zero area).
Note that in all cases c is odd and m+2 <= c < 2m+1.

Examples

			First triangle has sides (3,4,5) and area 6.
2nd triangle has sides (9,10,17) and area 36.
3rd triangle has sides (13,14,15) and area 84.
		

Crossrefs

Programs

  • Mathematica
    re=Reap[Do[a=m;b=m+1;Do[s=(a+b+c)/2;area=Sqrt[s(s-a)(s-b)(s-c)];If[IntegerQ[area],Sow[{a,b,c,area}];Break[]],{c,2m-1,m+2,-2 }],{m,3,2000}]][[2,1]];#[[1]]&/@ re

A248108 Areas of primitive Heronian triangles K which are perfect squares.

Original entry on oeis.org

36, 900, 7056, 32400, 41616, 44100, 54756, 63504, 69696, 108900, 112896, 176400, 213444, 298116, 396900, 435600, 509796, 608400, 705600, 736164, 756900, 777924, 853776, 980100, 1040400, 1192464, 1299600, 1368900, 1920996, 2039184, 2304324, 2340900, 2414916, 2433600, 2683044, 2722500, 2822400, 2944656, 3755844, 3802500, 3920400, 4161600, 4588164, 4769856, 5336100, 5731236
Offset: 1

Views

Author

Frank M Jackson, Oct 01 2014

Keywords

Comments

It is known that every positive integer is the area of some rational triangle. Hence for every n > 0 there exists at least one primitive Heronian triangle with area K such that n*k^2 = K for some positive integer k. Therefore for the integer 1 there exists primitive Heronian triangles with area K = k^2. This sequence identifies all such occurrences of square areas from lists of primitive Heronian triangles generated by Sascha Kurz (see link). The sequence excludes repetitive terms and is exhaustive as the Kurz lists searched include all primitive Heronian triangles up to a maximum side length of 6000000 and this sequence only includes areas that do not exceed 6000000 (see T. D. Noe comments at A083875). All 46 terms found are displayed. It is conjectured that this sequence is infinite.

Examples

			The first term 36 corresponds to the 5th term of A083875, 6 (area/6).
a(14) = 298116 = 546^2. There are two such Heronian triangles; they have sides (1183,865,696) and (7202,4395,2809).
		

Crossrefs

Showing 1-10 of 10 results.