Bradford T. answered 10/31/22
Retired Engineer / Upper level math instructor
Let r be the radius of the semicircle, b be the base of the rectangle and h be the height of the rectangle.
Perimeter is half the circumference of a circle plus twice the height plus the base of the rectangle. The base of the rectangle is the diameter of the semicircle or 2r.
p = πr + 2h +2r = 18
h = (18-r(π+2))/2
The Area of the window is the area of the semicircle plus the area of the rectangle:
A = πr2/2 + 2rh
Substituting in for h:
A(r) = πr2/2 + (9 -r(π+2)/2)r
A'(r) = πr+9-r(π+2)
Setting A'(r) to zero and solving for r,
r = 4.5
h =6.43
base = 2r = 9