Finding diameter of a circle How can I find the diameter of a circle that's been rolled up to a wall when the circle is touching a rectangle in the corner of the wall with height $8$ and width $5$?
Here's a picture of what I mean:

I tried drawing a right triangles in several different areas, but none of them helped me out. I'm pretty sure that's the right approach, but I still can't figure out this problem.
 A: I think you might be misinterpreting your question. As it is stated, there is no unique solution since there are many possible circles that satisfy your configuration. But since you write that "the circle that's been rolled up to a wall" I think the picture should look more like:

A: Let the tangents be the coordinate axes and hence the intersection point be the origin.
You get the equation of circle as $$(x-r)^2+(y-r)^2=r^2$$
This circle passes through $(5,8)$. You can find $r$ by these information.

Alternate method:
Use Pythagoras theorem.

A: Geometric solution.

Start with the rectangle $ABCD$, $|AC|=|BD|=5$,
$|AD|=|BC|=8$. Its diagonal $AB$ makes the right-angled $\triangle ABC$
with $|AB|=\sqrt{89}$.
Construct the inscribed circle and its center $I$.
For the reference, its radius is
\begin{align}
r&=\tfrac12\,(|AC|+|BC|-|AB|)
=\tfrac{13}2-\tfrac12\,\sqrt{89}
\tag{1}\label{1}
,
\end{align}
and the center is $I(r,\, r)$,
assuming that $C(0,0)$ is the origin.
Next, find the point $E$ as the lower intersection of the line $CD$
with the incircle.
The center of the sought circle is found at the intersection
of the line $CI$ (the bisector of the $\angle BCA$)
and the line through the point $D$ parallel to the line $EI$.
