I am confused by this post. I can derive the above equation, but only by using minimum subject distance X in the lens equation, as in: distance=1/(1/f-1/X). However, my understanding of subject distance is that it's the camera-subject distance, and doesn't go directly into the lens equation, which incorporates only camera-lens and lens-subject distances. Of course, subject distance is the sum of these, but correctly using subject distance changes the structure of the lens equation significantly, preventing it from reducing to the equation described above. Let me clarify:

Lens equation: 1/f = 1/g + 1/h where f=focal length, g=camera-lens distance, h=lens-subject distance. Therefore, when inserting a minimum lens focal distance X, that is, X = g+h, the equation becomes:

1/f = 1/(X-h) + 1/h

Rearranging, this becomes solvable as a quadratic:

h^2 - Xh + fX = 0

Using the quadratic formula one then solves for h as follows:

h = (X +/- sqrt(X^2 - 4fX))/2 = (X +/- sqrt(X(X-4f))/2

Where the +/- indicates two solutions are possible for h.

(BTW, this equation shows why a simple lens cannot focus closer than 4f: the X-4f becomes negative, and the square root of a negative number doesn't make sense in photography.)

Using the prior example where X=200 and f=50, the square root becomes zero, and there is only one solution:

h = (200 +/- sqrt(200(200-4(50)))/2 = 100

Then, adding the extension tube,

h' = h + L = 100 + 25 = 125

Then, solving for g', gives

g' = 1/(1/f-1/h') = 1/(1/50-1/125) = 83.3

Finally, the answer to the minimum subject distance for the extension tube is:

Min distance = h' + g' = 125 + 83.3 = 208.3

This said, however, I prefer to use the following method. Because modern lenses do typically change their focal length at close distances, calculating the minimum focal length at closest distance will prevent the prior quadratic equation from becoming unsolvable. That is, if a lens is rated at 100mm but focuses down to 300mm, it violates the 4xfocal length minimum distance of 400mm. This means, therefore, that one could say this lens is working at 75mm at the closest distance (300mm/4=75mm), and 75mm should be used as the focal length in the optical equations at this distance.

Once you know the working focal length at minimal distance, you could use the maximum magnification (M) at that distance to calculate h', where L is the length of the extension tube:

h' = f (1 + M) + L

Note that previously I used the lens equation to calculate h', but knowing the maximum magnification and calculating h' from this gives even more accurate information. Then g' is calculated as before from the lens equation, and g' and h' summed to give the subject distance. The results for the previous example turn out to be identical if M=1.0, since h'=f(2)+L=50(2)+25=125, as before, and the example did use a lens with a minimum working distance of exactly four times the focal length.