Re: Splitting sloping walls?

by Puybaret » Thu Feb 12, 2015 8:54 am

In your drawing, intercept theorem says that:

Code: Select all

4.5 / (3.4 - 1.6) = 2.2 / (2.48 - 1.6)
as you probably look for the 2.48 height here, the previous formula isn't very handy, but you can change it like this:

Code: Select all

2.48 = 1.6 + 2.2 x (3.4 - 1.6) / 4.5
If you replace 1.6 by heightAtStart, 3.4 by heightAtEnd, 4.5 by distanceBetweenStartAndEnd and 2.2 by distanceFromStart, you get:

Code: Select all

intermediateWallHeight = heightAtStart + distanceFromStart x (heightAtEnd - heightAtStart) / distanceBetweenStartAndEnd
Note that (heightAtEnd - heightAtStart) / bothWallsLength is a factor that could reapply elsewhere on walls with the same slope. This factor is also equal to tangent of 21.8°. Thus, if you know the 21.8° angle of the slope, you can also use:

Code: Select all

intermediateWallHeight = heightAtStart + distanceFromStart x tan(slopeAngle)
If you want to calculate that angle, just reverse the formula:

Code: Select all

slopeAngle = arctan((heightAtEnd - heightAtStart) / distanceBetweenStartAndEnd)
You might also wonder how to compute the 4.85 roof length. This time, it's Pythagorean theorem that will give you the answer because angles between walls and the floor are right:

Code: Select all

4.85² = 1.8² + 4.5² = (3.4 - 1.6)² + 4.5²
If you replace 1.6 by heightAtStart, 3.4 by heightAtEnd and 4.5 by distanceBetweenStartAndEnd, you get:

Code: Select all

roofLength² = (heightAtEnd - heightAtStart)² + distanceBetweenStartAndEnd²
or:

Code: Select all

roofLength = sqrt((heightAtEnd - heightAtStart)² + distanceBetweenStartAndEnd²)
where sqrt is the square root.

Hope this will help [:)]