# Side length of largest equilateral triangle to fit in a rectangle

I was trying to print out the largest possible equilateral triangle on a standard sheet of paper (8.5 by 11 inches) and got sidetracked into the following question: what is the maximum possible side length of an equilateral triangle to fit in a rectangle of size $$l$$ by $$w$$ ($$l \le w$$), and how would that equilateral triangle be placed in the rectangle?

I found the case of a square easily, but wasn't able to find the answer for a rectangle. I tried placing one vertex in a corner and the other two vertices on sides, but that gives me a solution not even on the rectangle.

Edit: I believe that when the ratio between $$l$$ and $$w$$ is less than a certain value, then a vertex is on a corner. Otherwise, I think the triangle will be set up so a base is on a side of the rectangle.

The equilateral triangle with the largest length should first be created at the corner. This is because any other equilateral triangle that fits can be translated such that one of its vertices is a corner of the rectangle.

Now, we need to split the problem into two cases:

1) $$l\ge \frac{w}{\sqrt3}$$: The largest triangle is the one with length $$l$$ (in dimension $$l$$) and height $$l\sqrt{3}$$ (in dimension $$w$$). If we try to use a different angle, we will only get shorter sides.

2) $$l\le\frac{w}{\sqrt{3}}$$: In this case, we want one vertice of the triangle to be one of the rectangle's vertices and the other two on the sides of the rectangle such that none contain the vertice shared by the rectangle and triangle.

One method to approach this is imaginary coordinates. First, let us put the vertice that the rectangle and triangle share as the origin. We can set up the rectangle's coordinates as $$(0,0),(0,l),(l,w),(0,w)$$.

Let $$(l,x)$$ be the point at which the triangle meets one side. ($$x$$ is an unknown variable and $$l$$ is the length.) Therefore, by imaginary coordinate rotation, we get that the $$y$$-coordinate of the point rotated $$60^\circ$$ counterclockwise about the origin is $$\frac{x}2+\frac{l\sqrt{3}}2$$, which must also be $$w$$. (This is because the rotation of that point $$60^\circ$$ is supposed to be the third vertice of the triangle and is on the top side of the rectangle.) From here, we get $$x+l\sqrt{3}=2w\rightarrow x=2w-l\sqrt{3}$$.

The length of one side is $$\sqrt{l^2+(2w-l\sqrt{3})^2}$$ via distance formula.

Let w be the shorter side.

Now, it's obvious that (you stated it as well) the triangle will be in the middle of the rectangle, not touching its vetices.

Suppose the biggest triangle is kept at an angle theta to the verticle as shown. But it's apparent that when rotated in counter clock wise direction some space is left on the top(possible extension of the side length). This shows that it couldn't have been the longest possible side.

Thus, in conclusion, the biggest possible eq. Triangle is kept with one side along the longer side and the side length being w/2 (where w is the shorter side)

This can also be deduced by starting as above and the side being w·sec(theta), theta ranging from 0 to 30deg.

• But this isn't always true, such as in the case of a square. Look at the bottom of this page mathworld.wolfram.com/EquilateralTriangle.html – automaticallyGenerated May 22 at 5:32
• Yes, that's indeed the case. However, we can take advantage of rotation since it's a rectangle and rotate the biggest triangle fixed at a vertice to see if it's the one, which is not possible for a square since the sides are equal and there's no room(if you know what I mean). (Argument very loosely placed, sorry about that) – Mike Karter May 22 at 5:39