Home

Please support mflenses.com if you need any graphic related work order it from us, click on above banner to order!

SearchSearch MemberlistMemberlist RegisterRegister ProfileProfile Log in to check your private messagesLog in to check your private messages Log inLog in

A formula to calculate the travel distance from Inf
View previous topic :: View next topic  


PostPosted: Sun Mar 20, 2022 7:19 pm    Post subject: A formula to calculate the travel distance from Inf Reply with quote

I wonder if there are any formulas for calculating the travel distance (in mm) needed from infinity to a certain distance.

For example, let's say a 35mm lens with a back focal distance of 24mm. If I make a simple, fixed adapter with the back focal distance fixed at 24mm from the sensor, I'd have it fixed-focus at infinity. How do I calculate how millimeters are required to get it focused at, let's say 0.5m? I could build a simple screw adapter or use a helicoid adapter to measure that, but it would be a lot easier to have a proper formula.

I also notice a shorter focal length requires a short travel distance while a longer focal length requires a lot longer travel distance for the same amount of distance (ie. from Inf to 0.5m).


PostPosted: Sun Mar 20, 2022 10:04 pm    Post subject: Re: A formula to calculate the travel distance from Inf Reply with quote

au8ust wrote:
I wonder if there are any formulas for calculating the travel distance (in mm) needed from infinity to a certain distance.

For example, let's say a 35mm lens with a back focal distance of 24mm. If I make a simple, fixed adapter with the back focal distance fixed at 24mm from the sensor, I'd have it fixed-focus at infinity. How do I calculate how millimeters are required to get it focused at, let's say 0.5m? I could build a simple screw adapter or use a helicoid adapter to measure that, but it would be a lot easier to have a proper formula.

I also notice a shorter focal length requires a short travel distance while a longer focal length requires a lot longer travel distance for the same amount of distance (ie. from Inf to 0.5m).


Let's define the following parameters (assuming an idealised thin lens):

f = focal length of lens (in mm)
s = subject distance (in mm)
i = image distance (in mm, from lens nodal plane to image)
bf = back focal distance (in mm, between lens mount and film/sensor)

The thin lens formula gives us:

1/f = 1/s + 1/i

or:

1/i = i/f - 1/s

thus:

image distance: i = 1 / (1/f - 1/s) : (formula 1)

That gives you the image distance between the lens' nodal plane and the image.

However, you are after something related to the back focal distance bf, ideally the distance travelled from the back focal distance to the image distance for a finite distance subject.

Consider that for a subject at infinity, you would like your formula to return the back focal distance bf, then what you are looking for is a formula that returns:

i - f + bf : (formula 2)

in other words, the difference between the image distances for the target subject and that for an infinitely distant subject, plus the back focal distance. Given that the image distance for an infinitely distant subject is the same as the focal length f, you get the above formula 2.

Substituting formula 1 in formula 2 gives the formula for the:

* distance between the lens mount and the image = ( 1 / (1/f - 1/s) ) - f + bf

Subtract the back focal distance from that and you end up with:

* travel distance = ( 1 / (1/f - 1/s) ) - f

As you can see, for the travel distance you wanted to calculate, you don't actually need to know the back focal distance Wink

In your example with a 35mm lens and 24mm back focal distance:

* distance between the lens mount and the image = ( 1 / (1/35 - 1/s) ) - 35 + 24

for s = infinity this gives 24.00mm
for s = 1m = 1000mm this gives 25.27mm

* travel distance = ( 1 / (1/35 - 1/s) ) - 35

for s = infinity this gives 0.00mm
for s = 1m = 1000mm this gives 1.27mm


PostPosted: Thu Mar 24, 2022 1:39 am    Post subject: Re: A formula to calculate the travel distance from Inf Reply with quote

RokkorDoctor wrote:

Let's define the following parameters (assuming an idealised thin lens):

. . . . . . .


Like 1


PostPosted: Thu Mar 24, 2022 10:55 pm    Post subject: Reply with quote

Like 1 Like 1


PostPosted: Fri Mar 25, 2022 3:29 pm    Post subject: Reply with quote

Hi Mark! Thanks a lot for your informative reply!

I've tried your formula on a 50mm with a BFD of 34.6mm (-/+ 0.5mm). The distance should be 6.03mm according to a calculation based on the formula.



I machined a simple part to check this and I got 0.6m instead of 0.5m.

I double-checked the tolerance and the part seems to be just 16 microns different. It shouldn't affect the distance that much.






What could have gone wrong?


PostPosted: Fri Mar 25, 2022 5:05 pm    Post subject: Reply with quote

Remember listed focal lengths are nominal and may differ somewhat from the claimed figures...


PostPosted: Fri Mar 25, 2022 5:44 pm    Post subject: Reply with quote

DConvert wrote:
Remember listed focal lengths are nominal and may differ somewhat from the claimed figures...


I was thinking the same but then the part with 34.6mm gives me exactly inf focus. So, yeah, still trying to find an answer for this.


PostPosted: Fri Mar 25, 2022 9:09 pm    Post subject: Reply with quote

au8ust wrote:
DConvert wrote:
Remember listed focal lengths are nominal and may differ somewhat from the claimed figures...


I was thinking the same but then the part with 34.6mm gives me exactly inf focus. So, yeah, still trying to find an answer for this.


DConvert makes a valid point, but there is another issue that needs consideration;

TBH, when I wrote that formula I assumed you were talking about focusing on distances much further out!

If you are targeting a focus distance as small as 0.5m for a 50mm lens, the thin lens condition no longer holds and you need to be mindful as to how exactly you measure the subject distance. For the formulas to still work, the subject distance would need to be measured between the subject and the front principal plane of the lens.

The position of that front principal plane is usually an unknown to the user, although the lens designer will be well aware of where this plane is located in the lens.

In order to make life easier for the photographer, most lenses (35mm format, medium format etc.) will therefore have their distances marked as those measured between the subject and the film plane/sensor, something which is easy to measure. That distance indicated on the focus ring however, is not the same as the subject distance used in doing lens calculations. Only for longer subject distances does this difference become negligible (to the casual user).

If you want to use the thin lens formula (paraxial optics, Gaussian optics) more accurately, esp. for very short focus distances, you will need to know where the front principal plane of the lens is located so that you have the correct reference point from which to measure the subject distance. Unless you can work out where the front principal plane is located in the lens, you are probably better off finding your desired travel distance by trial & error...

Plus, as DConvert already mentioned, whilst the manufacturers can control the focal length of the produced lenses very accurately, they may simply label them with the nearest convenient round number. A lens labelled "50mm" may well come out of the factory as a consistently produced 48.3mm, or 52.4mm etc.)

NOTE: the front and rear principal planes are often referred to as resp. P and P'. You may also see reference to the front and rear nodal planes N and N'. When the refractive index of the object and images space is identical (e.g air-air), then N=P and N'=P', so likely you will not need to worry about the difference between the prinicipal and nodal planes. Lenses used under water (e.g. Nikonos lenses etc.) have different nodal and principal planes, but that is not relevant in your case I assume. The subject distance should be measured to the front principal plane P, the image distance is measured from the rear principal plane P'. The focal length is measured from the rear nodal plane N'.


PostPosted: Sat Mar 26, 2022 12:10 am    Post subject: Reply with quote

RokkorDoctor wrote:

Let's define the following parameters (assuming an idealised thin lens):




au8ust wrote:
Hi Mark! Thanks a lot for your informative reply!

I've tried your formula on a 50mm with a BFD of 34.6mm (-/+ 0.5mm). The distance should be 6.03mm according to a calculation based on the formula.
...
I machined a simple part to check this and I got 0.6m instead of 0.5m.

What could have gone wrong?


See above ... Wink


I remember well that, starting my chemistry studies in Basel, I was attending the lectures for scientific photography as well. Usually held by F. Tomamichel from the Swiss Federal Institute of Technology Zurich, sometimes an engineer from Sinar was giving lectures, too. The latter, talking about the subject mentioned above (plus depth-of-field calculations), was quite adamant that all the usual formulas given in textbooks were ... not correct! Back then, I was more interested in the chemical and artistic side of photography, and I didn't pay much attention to the mathematical details given, but I still do remember that the Sinar guys around 1985 had to re-develop some formulae related to the OP's question Wink

S


PostPosted: Sat Mar 26, 2022 5:35 pm    Post subject: Reply with quote

This makes a lot of sense! Thank you!

I'll use the formula to get an approximate distance first and make a couple more parts to check the exact (or close to exact) distance.