Chris makes a good point. Rather than relying a bunch of formulas it's vital to be able to visualize the triangles and tetrahedra which which comprise the geometry of the overall roof and the joints. Do that, and the formulas automatically follow.
With a little practice it's possible to produce an equation on the spur of the moment if faced with a situation on the job that's unfamiliar. And if your calculator ever breaks it's entirely possible to construct the angles with a child's geometry set. (I always keep one handy - just in case).
Have a good weekend everyone. smile