Math Help - Optimization calc help. Minimize the perimeter.

1. Optimization calc help. Minimize the perimeter.

( I realize that I posted this earlier, the one I posted earlier i left part of the problem out and then the Gentlemen attempting to help my never responded)
Consider a window the shape of which is a rectangle of height surmounted a triangle having a height that is 1.5 times the width of the rectangle. If the cross sectional area is A, determine the dimensions of the window which minimize the perimeter.

I think over all area will equal

A=w*h+1/2(w*h)

For the rectangle
A=w*h (obviously)
Perimeter = 2w+2h

Triangle
A=1/2w*t
Then i turned the triangle into a right triangle by cutting it in half.
and then to solve for the triangle side we have
z^2=(x/2)^2+t^2

I am not sure where to go from here

2. A = wh + 1/2wT = wh +1/2w(3w/2) = wh + (3w^2)/4

P = 2h + w + (10)^1/2w

since for the side of the triangle s ---- s^2 = (w^2)/4 + T^2

=(w^2)/4 + (3w/2)^2

= (w^2)/4 +9(w^2)/4