It's not trig, just simple geometry and you can avoid the math. Easier to draw than explain, but let me try. Lets say you have a 4x5 pinhole camera (landscape orientation) with a 6 inch focal length. Get out your paper, protractor and ruler. Put a point on the paper and draw a 6 inch line. At the terminus of your 6 inch line, draw a 5 inch line (width of your film in landscape orientation) that is at a right angle to your 6 inch line and bisected by your terminus. Now make a triangle by drawing 2 lines from your original point through the termini of your 5 inch line. Now you have a nice isoceles triangle. Draw two lines parallel (anywhere) to your 5 inch line. The distance between your 2 lines is the distance between your wire frames. The length at which they bisect the sides of the triangle is the distance between the edges of your wire frame (sideways, in landscape orientation). Do the same for the vertical dimension preserving the distance between the frames.

Having said all that, one of the pleasures of pinhole is that it's down and dirty in a fun way. If you are sweating framing, angle of view, etc, you might be better served by just pointing the box in whatever direction suits you and pushing the little button. If you are going to worry about something, worry about exposure and reciprocity.