The triangular roof has height and two slopes of length . Hence the area constraint and cost are
The wall height is fixed, so its cost is constant. Assume the physical case . Minimize subject to the area constraint by Lagrange multipliers:
Eliminating the positive common factors gives
Thus the optimum has and
Set , so the area constraint gives . Substituting into the preceding equation and multiplying by yields . Therefore
For a global check, the square of the total roof length is
Its derivative has the sign of . Since , and , it has one root in this interval, with decreasing before that root and increasing afterwards. This proves the unique global minimum, rather than merely a stationary design. The minimum roof length at fixed wall height and cross-sectional area is independent of and of the positive factor . If , every feasible shape has equal cost; the displayed conditions then describe a possible minimizer but are not necessary.
Figure 1.
An original cross-section construction showing the fixed wall height, roof rise and sloping lengths
. Details.