bpypolyskel icon indicating copy to clipboard operation
bpypolyskel copied to clipboard

Hipped roof calculation out of a straight skeleton

Open vvoovv opened this issue 4 years ago • 0 comments

Suppose the straight skeleton has been calculated for a polygon. A maximum hipped roof height roofHeight is given. All roof faces have the same pitch α.

image

So we have tg(α) = h1/d1 = h2/d2 = hi/di

di is a distance from the straight skeleton vertex till the related edge of the original polygon. di lies in the plane of the original polygon. di is perpendicular to the related edge of the original polygon.

image

di can be considered as a time when the related straight skeleton event occures.

Since roofHeight defines the maximum roof height and di = hi/tg(α), di is maximal at the vertex of the straight skeleton with roofHeight. Finallly, to get tg(α) one needs to pickup the straight skeleton event that occurs at the very end and take it time di to calculate tg(α) = roofHeight/di.

Once tg(α) is known, the height for every vertex of the straight skeleton is calculated as hi = di * tg(α)

vvoovv avatar Sep 17 '20 12:09 vvoovv