By using the basic lens formula
1/F = 1/A +1/B where A and B are positions of the images (virtual or real) and F is the focal length of the Barlow, it could be shown that closer the Barlow focal point is to the main mirror focal plane, the greater effect it has.
Also, have a look at this link:
http://www.scopesim.com/
I also included two files here, optic is optical path simulator (very general ray tracing program), very simple and easy to use and other one is html with optical formulas... All very useful stuff