Divide the total span of the roof by 2. The result is the horizontal distance from the edge of the roof to a point directly below the center. For example, if the roof is designed to cover 16 feet, half the width is 8 feet: 16 divided by 2 equals 8. Call this the "roof span."
Decide on the difference in height between the edge of the roof and the center point. This determines the angle of the roof and thus the angle of the rafters. Call this value "roof height." For example, if you want the center to be 4 feet higher than the edge, the roof height is 4 feet.
Substitute the roof span and height into this equation: The tangent of the rafter angle equals roof height divided by roof span. Using the example from the previous steps, the equation becomes the tangent of the angle, which equals 4/8, or 0.5.
Determine the rafter angle by ascertaining the inverse function of the tangent, the arc tangent of the value obtained in step 3. For example, the angle required for the rafters of the example roof is 26.56 degrees, because the arc tangent of 0.5 is 26.56.