# Nearly Equilateral Heronian Triangles

Heronian triangles are those whose side lengths and areas are integers. There are no Heronian triangles that are equilateral (all sides equal), but there are some that are nearly equilateral. There are three distinct ways this can occur:

(1) side lengths n-1, n, and n+1
(2) side lengths n, n, and n+1
(3) side lengths n, n+1, and n+1

For each case, there are actually infinitely many Heronian triangles which can be generated by recursive formulas.

### Case I: Sides n-1, n, and n+1

Here is a table showing the first five instances of such Heronian triangles:

 Sides Perimeter Area n-1 n n+1 3 4 5 12 6 13 14 15 42 84 51 52 53 156 1170 193 194 195 582 16296 723 724 725 2172 226974

Define a sequence T(n) where T(1) = 4, T(2) = 14, T(3) = 52,... T(n) = the middle side length of the nth nearly equilateral Heronian triangle in Case I. It turns out that T(n) satisfies a second order linear recursive equation:

T(n+2) = 4T(n+1) - T(n).

Using this formula, we can find the sixth row of entries for this table.

T(6) = 4T(5) - T(4)
= 4*724 - 194
= 2702.

This means that the next Heronian triangle in this list has side lengths 2701, 2702, and 2703.

### Case II: Sides n, n, and n+1

Here is a table showing the first five isosceles Heronian triangles in which the longest side is 1 more than the two shorter sides:

 Sides Perimeter Area n n n+1 5 5 6 16 12 65 65 66 196 1848 901 901 902 2704 351780 12545 12545 12546 37636 68149872 174725 174725 174726 524176 13219419708

As you can see, the side lengths increase much more rapidly than in the previous case. Define a sequence V(n) where V(1) = 5, V(2) = 65, V(3) = 901,... V(n) = the shorter side length of the nth nearly equilateral Heronian triangle in Case II. V(n) satisfies a third order linear recursive equation:

V(n+3) = 15V(n+2) - 15V(n+1) + V(n).

Using this formula, we can find the sixth row of entries for this table.

V(6) = 15V(5) - 15V(4) + V(3)
= 15*174725 - 15*12545 + 901
= 2433601.

This means that the next Heronian triangle in this list has side lengths 2433601, 2433601, and 2433602.

### Case III: Sides n, n+1, and n+1

Here is a table showing the first five isosceles Heronian triangles in which the longer sides are 1 more than the shortest side:

 Sides Perimeter Area n n+1 n+1 16 17 17 50 120 240 241 241 722 25080 3360 3361 3361 10082 4890480 46816 46817 46817 140450 949077360 652080 652081 652081 1956242 184120982760

Now define a sequence W(n) where W(1) = 16, W(2) = 240, W(3) = 3360,... W(n) = the shortest side length of the nth nearly equilateral Heronian triangle in Case III. W(n) also satisfies a third order linear recursive equation:

W(n+3) = 15W(n+2) - 15W(n+1) + W(n).

This is the exact same relation as in Case II, except the initial conditions are different. Using this formula, we can find the sixth row of entries for the Case III table.

W(6) = 15W(5) - 15W(4) + W(3)
= 15*652080 - 15*46816 + 3360
= 9082320.

This means that the next Heronian triangle in this list has side lengths 9082320, 9082321, and 9082321.