How this instrument works
A gambrel roof, the shape most associated with a classic barn, has two slopes on each side rather than one continuous pitch: a shallow upper slope near the ridge, and a much steeper lower slope closer to the eave. That double break is what maximizes usable headroom in the upper level of the building compared to a single-pitch roof of the same overall height, which is why the style shows up so often on barns and converted-attic homes.
Because the two slopes have different pitches, they need two separate rafter-length calculations, not one. Each slope forms a right triangle: the horizontal run is one leg, the vertical rise — the run times the slope's pitch expressed as inches of rise per 12 inches of run — is the other leg, and the rafter itself is the hypotenuse, found with the Pythagorean theorem. This instrument runs that calculation once for the upper slope and once for the lower slope, then adds the two rafter lengths for a combined total.
Overall building width (ft) is included as a reference field only — it isn't used in the rafter-length formulas themselves, which depend solely on each slope's own run and pitch. Use it to note the full width you're designing for while you work out how much horizontal run belongs to the upper slope versus the lower slope on your actual drawings; the split between the two isn't fixed by any formula and varies by design.
- Enter Overall building width (ft) as a reference note for your design; it doesn't feed into the rafter calculations below.
- Enter Upper slope run (ft) and Upper slope rise (in per 12 in run) — the horizontal distance and pitch of the shallow upper slope.
- Enter Lower slope run (ft) and Lower slope rise (in per 12 in run) — the horizontal distance and pitch of the steep lower slope.
- Read Upper rafter length (ft) and Lower rafter length (ft) for each slope's individual rafter piece.
- Read Total rafter length (ft) for the combined length of both pieces — useful for ordering lumber long enough to span or splice both slopes.
Worked example — 4 ft upper run at 6/12, 6 ft lower run at 18/12
Enter 10 into Overall building width (ft) as a reference note, 4 into Upper slope run (ft) and 6 into Upper slope rise (in per 12 in run), then 6 into Lower slope run (ft) and 18 into Lower slope rise (in per 12 in run). The upper slope's rise is 4 × 6/12 = 2 ft, so Upper rafter length (ft) reads 4.4721 — the hypotenuse of a 4 ft and 2 ft right triangle, √(4² + 2²) = √20.
The lower slope's rise is 6 × 18/12 = 9 ft, a steep pitch, so Lower rafter length (ft) reads 10.8167 — √(6² + 9²) = √117. Total rafter length (ft) reads 15.2888, the sum of both pieces: 4.4721 + 10.8167.
Questions
Why does a gambrel roof need two separate rafter calculations?
Because its defining feature is two different pitches per side — a shallow slope near the ridge and a steep slope near the eave — and each pitch forms its own right triangle with its own run and rise. A single rafter-length formula only works for a roof with one continuous pitch, so a gambrel roof needs the calculation run twice, once per slope, rather than once for the whole side.
What does 'rise per 12 in run' mean?
It's standard roofing notation for pitch, sometimes written as '6/12' or '6-in-12': for every 12 inches the roof runs horizontally, it rises that many inches vertically. A 6/12 pitch is moderate, while an 18/12 pitch — like this instrument's lower-slope default — is very steep, closer to a wall than a typical roof, which is exactly the point on a gambrel's lower slope.
Why is the rafter length calculated with the Pythagorean theorem?
Because each roof slope, run and rise form a right triangle: the horizontal run is one leg, the vertical rise is the other leg, and the sloped rafter itself is the hypotenuse connecting them. The Pythagorean theorem — hypotenuse² = leg₁² + leg₂² — is the standard way to find that third side's length from the two legs, which is exactly what a rafter length is.
Does Overall building width (ft) need to match my two slope runs?
No — this instrument doesn't enforce any relationship between the width field and the two run fields, since how a building's total width splits between an upper and lower slope run varies by design and is set on your actual working drawings, not derived automatically. The width field is included purely as a place to note your project's overall dimension for reference.
Does Total rafter length (ft) represent one continuous board?
Not necessarily — many real gambrel roofs frame the upper and lower slopes as two separate rafter pieces meeting at a horizontal purlin or knee brace where the pitch changes, rather than one continuous bent board. Total rafter length (ft) simply adds the two pieces' lengths together, which is useful for a combined lumber estimate whether you build it as two pieces or, less commonly, steam-bend or scarf-join a single continuous rafter.