What does squaring a frame mean and why is it important?
Squaring a frame means making sure the overall outline of the frame forms a rectangle. Every corner of the outline forms a 90 degree angle.
This is important because you're going to be mounting solar panels of some sort to this frame and solar panels are themselves squared and more importantly, the solar array formed by all the panels is squared.
In the following diagram, we are mounting an array of solar panels made up of 3 rows with 3 panels per row. The frame on the left, made up of 6 sets of rails, is squared but the frame on the right is not. The result is that one of the solar panels is hanging off the frame. This is not something you want to discover only after you've attached the frame to a roof and are mounting your last panel.
Two different methods for squaring a frame are squaring using diagonals and the 3-4-5 method.
Squaring a frame for a solar array using diagonals
This method can be used on small frames where any side of the frame is made of a single steel rail or wooden beam. If there is more than one rail or beam to a side then the 3-4-5 method is more doable.
The basic idea is that if the distances from opposite corners of a box are the same then the box is squared.
There are many ways to apply this when installing rails on a roof but here's one example. There will be four solar panels, two rows of two, and the rails will be 10 feet long, each composed of an 8 foot piece spliced with a 2 foot peice. This extra 2 feet is added so that attachment to the roof trusses can be made near the ends of the rails (the trusses are 2 feet apart on center.)
Following the above diagram, install your bottom rail exactly where you want it. If you're on a roof, and you're sure the bottom edge of the roof is reasonably horizontal and uniform, then you can use the bottom of the roof as a reference point. To make it horizontal with respect to the roof, measure up from the bottom of the roof to where you want the rail to be. If you want the array to be attached to the roof trusses inside the roof then you'll also want to pay attention to where the trusses are located before you fix any rails in place. Another factor might be if the roof is not a rectangle. For example, it might be tapered like above. You'd have to make some rough measurements to make sure the top of your completed array would still be on the roof. If you don't feel sure enough to permanently install the bottom rail at this time, just mark out where it would be with chalk or a wax pencil until you've finished the whole measuring process.
Now that you have the bottom rail positioned, as shown in the following diagram, measure from the bottom rail up to where the top rail will go and make a horizontal chalk line there. Make it longer than the top rail will be.
Then take you top rail and hold it against the chalk line.
Next, measure the diagonals. Measure from the left end of the bottom rail to the right end of the top rail. Remember this distance. Then measure from the right end of the bottom rail to the left end of the top rail. If these two distances are the same then the result is a rectangle with squared corners.
If, however, the distance from bottom-left to top-right is longer, then the top rail needs to move to the left. If the distance from the bottom-right to top-left is longer, then the top rail needs to move to the right.
Once the two distances are the same, you can permanently install the top rail. Make vertical chalking lines at the two ends and you can install rails in between.
Squaring a solar array using the 3-4-5 method
If each row of rails is made up of multiple parts, such as two or more 8 foot steel rails or two or more 8 foot wooden beams, then the diagonals method becomes harder to do. In this case it's easier to square things using the 3-4-5 method.
This method uses the fact that if you have a triangle where the bottom is 3 feet long, and the left side is 4 feet long, and the right side is 5 feet long, then the bottom and left side form a right triangle. In other words the angle formed by the bottom and the left sides is 90 degrees. It's square. The same is true if the measurements are 6 feet, 8 feet and 10 feet respectively.
It's not necessary to know it but this is just the pythagorean theorum that you learned in school. You learned it then as a2 + b2 = c2. But that doesn't matter here. Most of the times just remembering 3-4-5 is enough. And 2x3=6, 2x4=8, 2x5=10, which gives us 6-8-10 as useful measurements as well.
So once again, go up to the roof and permanently install your bottom row, even if it's made up of multiple 8 foot rails. In this case we'll have three rows of three solar panels and the panels will be much larger ones. Taking all the same things into account as mentioned above, install the bottom row as in the following diagram. Notice that the frame is not centered on the roof. This is because the rails need to be secured to the trusses near their ends. If we centered the rails then the rail ends would be around 1 1/2 feet from the nearest truss. We could center it by making the rails longer but then they'd stick out from under the solar panels quite a bit. We could also add some supporting cross-beams inside the roof between the trusses but we'll assume it doesn't matter in this case.
Step 1. Go to the left end of the rail and measure 6 feet towards the center of the rail. Make a mark there.
Step 2. Then, with one person holding one end of the measuring tape at the 6 foot mark, have a second person pull out the measuring tape until 10 feet is reached. That second person would then hold a wax pencil or chalk at the 10 foot point and sweep the measuring tape through an arc, drawing an arc on the roof. Every point on that arc is now 10 feet away from the 6 foot point which you'd marked on the bottom rail.
So now you have the 6 foot bottom side of the triangle and a bunch of possible locations for the 10 foot side.
Step 3. Lastly, have one person hold one end of the measuring tape at the left end of the bottom rail while the second person pulls it out to an 8 foot length and walks up to the arc that was previously drawn. Find where the 8 foot point on the measuring tape meets the arc. Mark the roof there. Then draw a chalk line from that mark back down to the left end of the bottom rail.
You now have a triangle whose sides are 6, 8 and 10 feet. The bottom and left sides form a 90 degree angle... they're squared.
You can now start installing rows of rails by lining up all their left ends with the left side chalk line that you'd made. Space each rail the apropriate distance apart. The result will be a squared array.
This example started from the left side, but it could have just as easily started from the right side instead.
It's best to use the lengths that are closer to the length of the sides of your frame. Doing so minimizes error. For example, if you frame is 12 feet high, don't use 3-4-5. Use 6-8-10 instead. That's because 8 is closer to 12 than is 4. By using 6-8-10 you'll have a smaller error.
Illustrating a common mistake when squaring something
Here's a common mistake. You're making a standing frame for mounting a large solar panel onto (see diagram below.) You attach two horizontal rails. Each rail is 8 feet long. The rails must be squared because there are holes in the rails that must match up with holes in brackets that are fixed to the sides of the panel.
You measure the distance between the rails at each end and find that they're the same, both 4 feet. So since the rails are both the same length and since the distances between them at the ends are the same, they must be squared. Wrong.
As the following diagram shows, they can be offset from each other and the distances between them can still be the same.
You can find this out by measuring the diagonals. When the diagonals are the same, then you can be sure the rails are squared.