Solving for height of a composite shape