We have an equilateral triangle and want to inscribe a square, but want to do so in the way that maximizes the area of the square.
I sketched two possible ways, not to scale and not perfect. Note I am not sure if the second way will really have all square corners touching the triangle sides.
The second case appears to have bigger side-lengths of the square, so bigger area. But I do not know how to determine the angles involved. How to solve this?