Where the semicircle has radius of 3 and the rectangle with height x and width y touches the edges of the semicircle.

My thoughts are

Area (rectangle) = [semicircle] - [2 segments]

where the area a segment is

I need to find where

and I also think

I have all these relationships yet I can't reduce it to one variable.