Let the center of the circle = O
Let the midpoint of the large semi-circle = F
Let the midpoint of the the right semi-circle = D
Let the center of the semi-circle on the left = E
Form triangles EOF and DOF
DO = (5 + r)
FO = (8 - r)
EO = (3 + r)\
DF = 3
EF = 5
By the Law of Cosines we have two equations
EO^2 = EF^2 + FO^2 - 2(EF * FO) cos (EFO)
DO^2 = DF^2 + FO^2 - 2(DF * FO) cos ( DFO)
Because angles EFO and DFO are supplementary cos (DFO) = - cos (EFO)
So re-writing....we have
EO^2 = EF^2 + FO^2 - 2(EF * FO) cos (EFO)
DO^2 = DF^2 + FO^2 - 2(DF * FO) -cos ( EFO)
EO^2 = EF^2 + FO^2 - 2(EF * FO) cos (EFO)
DO^2 = DF^2 + FO^2 + 2(DF * FO) cos ( EFO)
(3+r)^2 = 5^2 +(8-r)^2 - 2 (5 * (8-r)) cos (EFO)
(5+ r)^2 = 3^2 + (8-r)^2 + 2( 3 (8-r)) cos EFO
cos EFO = [ (3 + r)^2 - 25 - (8-r)^2] /[ -2 * (40 - 5r) ]
cos EFO = [ (5 + r)^2 - 9 - (8-r)^2] / [ 2 *(24 - 3r) ]
Then
[ (3 + r)^2 - 25 - (8-r)^2] /[ -2 * (40 - 5r) ] = [ (5 + r)^2 - 9 - (8-r)^2] / [2 *(24 - 3r) ]
This is a little sticky to simplify, but WolframAlpha helps
We get that
272 / (r-8) + 49 = 0
272 / (r -8) = -49
272 = -49 ( r -8)
272 = -49r + 392
-120 =-49r
r = 120 / 49 ≈ 2.449