Find the area of the right triangle with a right triangle I came up with a problem myself:
What is the area/sides of the largest right triangle?

Question: Point $D$ is the midpoint of $AB$ and point $E$. It is also known that $\triangle AEF$ is also a right triangle. The goal is to find the area and sides of the largest right triangle.
My attempts:

*

*Complete the two right triangles such that they become rectangles, let $AGBC$ and $AEFH$ be the rectangles, assume that point $I$ be the point such that $BI$ is perpendicular to $AH$, thus $\angle GAH=\angle GBI$, this may be able to be solved by similar triangles.

*Rotate $\triangle AED$ such that $AD$ overlap with $BD$ and $EBD$ is a triangle.

*Let $G$ be a point such that $BG$ is perpendicular to $EF$, that may possible be done using similar triangles.

 A: Off the top of my head, there are two solutions that come to mind.  I will only provide an outline of each.
Method 1.  Trigonometry.

*

*Let $EC = x$.  By the law of cosines, $10^2 = x^2 + 6^2 - 12x \cos \theta$, where $\theta = \angle ECB$.  But since $\angle BCD$ is supplemental and $\triangle BCD$ is isosceles, it follows that $\cos \theta = - \frac{3}{5}$.  This lets us solve for $x$.

*This gives us the length of $ED = 5+x$.  Then the altitude of $\triangle AEF$ is $$h = ED \sin \angle BDE = (5+x) \cdot 2 \cdot \frac{3}{5} \cdot \frac{4}{5},$$ from which the area of $\triangle AEF$ is easily deduced.

Method 2.  Coordinate geometry.

*

*Place the figure on a coordinate plane with $B$ at the origin, $A = (-10,0)$, $F = (10,0)$, $D = (-5,0)$.  It is easy to conclude that $C = (-18/5, 24/5)$, either by solving for the intersection of the circles with centers at $A$ and $B$ with radii $8$ and $6$ respectively, or by other elementary means.

*The point $E$ must take the form $E = (10 \cos \varphi, 10 \sin \varphi)$, where $\varphi$ is the counterclockwise angle measured from the ray $BF$.  We want to find $\varphi$ such that $E$ is collinear with $C$, $D$.  This is easily accomplished by solving for the intersection of the line passing through $C$, $D$ and the circle $x^2 + y^2 = 10^2$.  The $y$-coordinate of $E$ gives the altitude $h$.

In both cases, the area I get is $$|\triangle AEF| = \frac{48}{25}(7 + 2 \sqrt{481}).$$
A: 
Let
\begin{align} 
|BC|&=a=6
,\quad 
|AC|=b=8
,\quad
|AB|=|BE|=|BF|=c=10
,\\ 
|AD|&=|BD|=|CD|=\tfrac c2=5
,\\ 
\angle BCA&=
\angle FEA=
\angle DGC=
\angle DHE=
90^\circ
.
\end{align}
Then $\triangle EDH\sim\triangle CDG$
and
\begin{align} 
\frac{|EH|}{|CG|}&=
\frac{|DE|}{|DC|}
=\frac{|DC|+|CE|}{|DC|}
\tag{1}\label{1}
,\\
|CG|&=\frac{ab}c
\tag{2}\label{2}
\end{align}
and we can express $|EH|$ in terms of $|CE|$:
\begin{align} 
|EH| &= \frac{ab(2|CE|+c)}{c^2}
\tag{3}\label{3}
,
\end{align}
where $|CE|$ can be found from $\triangle BED$
with the help of [Stewart's theorem]
%(https://en.wikipedia.org/wiki/Stewart%27s_theorem):
\begin{align} 
|BE|^2\cdot|CD|+
|BD|^2\cdot|CE|
&=(|CD|+|CE|)(|BC|^2+|CD|\cdot|CE|)
\tag{4}\label{4}
,\\
|CE|&=
\frac1c\,(-a^2+\sqrt{a^4+b^2 c^2})
\tag{5}\label{5}
,
\end{align}
hence
\begin{align} 
|EH|&=
\frac{ab}{c^3}\,(b^2-a^2+2\sqrt{a^4+b^2 c^2})
\tag{6}\label{6}
\end{align}
and the area of $\triangle AFE$ is
\begin{align}
[AFE]&=\tfrac12|EH|\cdot|AF|
=
\frac{ab}{c^2}\,(b^2-a^2+2\sqrt{a^4+b^2 c^2})
\\
&=
\tfrac1{25}(336+96\sqrt{481})
\approx 97.65777
\tag{7}\label{7}
\end{align}
The two other sides of $\triangle AFE$ can then be found as
\begin{align}
u&=\sqrt{2c^2 +2\sqrt{c^4-[AFE]^2}}
=\tfrac15(14\sqrt{37}-2\sqrt{13})
\tag{8}\label{8}
\\
v&=\sqrt{2c^2 -2\sqrt{c^4-[AFE]^2}}
=\tfrac15(14\sqrt{13}+2\sqrt{37})
\tag{9}\label{9}
.
\end{align}
