Pseudo-MTF Tester Project
Related Local Links:
Reading MTF Curves by Ryszard Stasinski
MTF Postings

Related Links:
MTF Interpretation (Photozone)
MTF Lens Charts and Lens Quality .pdf (schneider Optics)
Hasselblad (see lenses for sample MTF curves)

Some recent articles (mid-2002) in the British Journal of Photography describes a simple software plug-in to read a standard digital camera test chart to compute the lens MTF from a pattern of shrinking width bar charts.

A similar java plugin is available to help measure the MTF of other systems. [Reference: Sitter, D.N., Goddard, J.S., and Ferrell, R.K., (1995), "Method for the measurement of the modulation transfer function of sampled imaging systems from bar-target patterns.", Applied Optics, v. 34 n. 4, pp. 746-751].

In other words, photographers and lens testers may now be able to use a (postscript) bar chart to measure the MTF of a given lens or optical system!

An interesting option would be to post the bar chart online, with testing setup standards information. The recommended film (black and white?) could be exposed with any given lens under specified conditions. The film would have to be processed to tight standards to be comparable. The processed film would be scanned in a film scanner. The resulting image would be analysized by the MTF measurement software to compute an MTF graph for the tested lens(es).

Such a system could also make it possible for curious folks to simply shoot a downloaded chart with some film. They could then mail off the film for processing and analysis by a standardized setup (for a small fee?), even if they didn't have the film scanner and software setup.

In short, photographers may soon be able to access some low cost MTF test capabilities using standard film scanning systems and a low cost downloadable bar chart....

[N.B. Another approach might put a standardized film or glass slide at the film gate of the camera or mounting support and project the bar chart through the lens. I suspect that a regular scanner would not be a good match for this project, but this would have to be tested.

As an alternative, the image could be scanned with an optical sensor directly. The mechanics of an older scanner might be used (with the glass plate removed) to do the desired movement of the sensor across the projected image. A linear optical sensor, such as those by Texas Instruments with a built-in op-amp, could be used to provide the varying current signal. This signal could be readily converted or measured (e.g., labview hardware and software) to provide the data files for analysis. The java source code is available, making it relatively straightforward to modify the software to interpret the data files.


Date: Mon, 30 Mar 1998
From: Michael Gudzinowicz ab366@osfn.rhilinet.gov
To: rmonagha@post.cis.smu.edu
Subject: Re: query about pseudo-MTF tester

An old reply which might help: 

>Can someone suggest how resolution as measured visually using a
>resolution chart would relate to MTF?  For example, if a lens has a 10%
>modulation for 40 line pairs/mm, would this correspond to about 40 lpmm
>measured visually with a chart?   A rule of thumb about this fairly
>subjective question would be helpful.

This isn't quite what you looking for, which may be impossible to do
without directly scanning the bars.  It is relevant though, and is based
on experimental data, not just theory.  Sorry for the delay in replying,
but it took a while to find the references.     

There were a few "MTF" articles published 25 years ago when Modern and
Popular Photography started to use simple contrast measurements for
their tests.  However, they were interested in comparing lens and film
modulation to the three bar AF resolution targets.

If you are interested in setting up Pop's contrast test bench, the
details are in an old article by Norman Goldberg (May 71, p106). You
have most of the parts; I had all of them, but wasn't motivated to put
it together (I look at prints instead).

Their approach used a light source whose beam (filtered if desired) ran
through a condenser to evenly illuminate a diffuser, which backlit a
double slit.  The slit widths are chosen so one gives about 5 line
pair per mm (0.1mm bar width plus 0.1mm space width ) and 50 lpmm (0.01
mm bar/space widths) at the _test lens_ focus plane.   

A collimating lens was used between the test lens and slits, to permit
the use of large slits which appear at the distance for which the lens is
optimized (1:20 or infinity).  At the plane of focus of the test lens, a
microscope is used to project the slit images to a revolving mirror, which
reflects the pattern through a slit to a PMT.  The latter is hooked up
to an oscilloscope, which records the mirror's sweeps as a "100%" square
wave (the wide slit), and a smaller wave of less intensity
corresponding to the narrow slit.  They used the ratio of those two
intensities to express percentage contrast.  They have examples of on-
and off-axis traces.  The test bed isn't hard to build; a $1 Radio Shack
phototransitor can replace the PMT; and "obsolete" scopes can be found
for a few dollars.

light->condenser->diffuser->slits->collimator->test lens->
microscope->revolving mirror->slit->PMT->scope

Bennett Sherman described Modern's approach in the May 72 issue (p. 76),
which is close to the MTF test using different frequencies, but was
modified to to use one frequency (30 lpmm; now called CTF; Mar 75, p 96).
Their approach looks like more of a pain for home use.  However, the
Pop approach (above) using multiple frequencies may give a useful
pseudo-MTF plot.  (The small single slit could be varied in width.)

An article relating the contrast test to the 3 bar target was written by
Bennett Sherman and printed in Modern (Mar 73, p 44).  The approach he
outlined was suggested by a Dr. Roy Welch of the U. of GA, and was
published in Image Technology (no details, referred to as a "recent
article").

The simple expression he used for modulation of contrast was:

Modulation = (Max - Min)/(Max + Min)

where Max is the maximum brightness of the light line, and Min, the     
minumum brightness of the dark area.  If the contrast ratio were 1:1000
or 1:100, the value approaches 1 ((100-1)/(100+1)) or 100%.  At a level
of 1.6:1, it would be (1.6-1)/(1.6+1) = 0.23 (23 %).

Welch felt that one could take the typical log/log plot of lens
modulation vs. line pairs or frequency, and plot the film mtf data on the
same graph, and its intersection would yield the resolution to be
expected for the combination.  At that time, lens mtf data wasn't widely
available, but the Pop method is relatively simple to set-up.

The film modulation data plotted was the contrast ratio or modulation
required to resolve lines at different frequencies.  The data he used was
for a film similar to Panatomic-X.  Getting that data isn't easy, but EKC
provides a clue in their resolution data vs. contrast level.

For instance, at 1:1000, PXP resolution is 125 lpmm and at 1.6:1, it is
50 lpmm, which gives two data points (res, modulation):  (0.23, 50) and   
(.99, 125).  The article indicates that the relationship between
lpmm and modulation for the film is linear over a wide range, but
flattens at very low modulation (contrast) and at very high frequencies
(high contrast = higher film resolution in this case).  Welch apparently
used data which related film resolution to gamma and the high contrast
resolution (further details would be nice, but they're not there).

For an example in the article, lens modulation is plotted on a log/log
plot, and gives the typical curve.  Some lens data points are (x=lpmm,
y=modulation): (10, .90); (20, .7); (40, .4); (60, .2); (80, 0.09);
(100, 0.037).

The linear film curve ("film similar to "Panatomic-X) can be represented
by the line connecting the following two points: (40, 0.03) and (120,
.6), with a toe and shoulder below/above those values.

Welch indicates that the predicted on film resolution is given by the   
intersection of those two curves.  The intersection occurs around 65
lpmm, with a modulation around 0.15 .  Sherman hints that he was going to
check it out further, but i never found the article.  The required data
included 1. high contrast resolution of the film; 2. its gamma; 3. film
consistency; 4. errors in measurement (electronic and film).

Another article (May 72 article p. 76), examined prints made by 4
lenses, the lens contrast values (2 & 30 cycles per mm), and three bar
target tests on film.  The rank order correlation looked good, though
the glass got a lot better over the next 10 years.

There are problems with something as simple as the three bar target.  I
use targets with a finer gradation (1/12th power rather than 1/6th),
which was reproduced on lith film at a contrast ratio of 1:1000 when
transilluminated. Reflection targets are made from contacts of the lith
negative, and the finer bar gradation between steps makes it easier to
get consistent results.                                                 

The resolution can be defined in a number of different ways.  "Complete"
resolution is described when two points do not overlap, but just touch at
their perimeter.  It is analogous to a separation between centers equal
to the sum of their radii, and leads to the conservative empirical
estimate of resolution using the sum of inverses of the resolution in
lpmm or sum of mm/line pair to the first power, which EKC often used.

For diffraction, Rayleigh choose to place the maxima for two points over
the minimum between the maximum and first ring.  With a telescope and a
high power objective to magnify the image, the criteria is valid.
However, on film using a typical camera, the maxima and rings can't be
resolved because of grain, the spread function, etc.  In this type of
situation, one also has to recognize the difference in intensity between
the central maxima and Airy rings - using high contrast film at a high
gamma may not record the rings at all even when one may see them.
                                                                   

This sort of leads to Sherman's suggestion that the film's gamma
is important.  With underexposure and high gamma, one can get "better"
resolution since one is primarily recording the high intensity central
portion of the bar or disk, permitting the first diffraction ring maxima
to fall below the film's threshold.  For that reason, I use fine grain
film developed to "normal" contrast at a "normal" EI, and look for
complete bar resolution.  Comparing those test results to others which
are shot with high contrast films is nearly impossible.

Although the "CTF" approach may seem like a pain, it was probably more
reproducible than efforts directed at keeping all of the factors for the
three bar test under control including tester interpretation/interpolation
of what consititutes resolution.
                                         


From: brianc1959@aol.com (brian)
Newsgroups: rec.photo.equipment.35mm
Subject: Re: Nikon - primes that deliver creamy bokeh
Date: 7 Dec 2001 

Robert:

I didn't use MTF equipment for that particular measurement, but rather
a fairly simple projection device that uses a precision glass test
slide that you project onto a wall.  The test slide has numerous bar
targets marked in cycles/mm, so you can read the resolution directly
from the projected image.  At the time I was in charge of optical
design and testing at a U.S. based camera company.

You can do a similar test by photographing a large test target that
you can print on an ordinary inkjet printer, but in this case the
performance of the film/processing will be mixed in with the pure
optical performance of the lens.  For this reason I usually prefer
projection testing, which is standard practice at many optical
companies.  MTF testing is very useful, but it is somewhat cumbersome
and slow, and unless you spend an enormous amount of effort you can't
get an overall impression of optical performance the way you can at a
glance with projection testing.

Brian


Roberto Strappafelci roberto.strappafelci@tin.it> wrote 
> brian at
> brianc1959@aol.com wrote 
> 
> 
> > - I've done projection testing with this lens that revealed resolution
> > well in excess of 100 cycles/mm even wide open.
> > 
> 
> Brian,
> 
> just out of curiosity, did you make your own MTF or what?
> 
> Roberto

From: brianc1959@aol.com (brian) Newsgroups: rec.photo.equipment.35mm Subject: Re: Nikon - primes that deliver creamy bokeh Date: 8 Dec 2001 Hi Bob: I used Pearl projectors, which look something like miniature WW1 tanks. They sell a wide variety of projectors and test charts suitable for testing lenses ranging from 1/5" digicam lenses up to medium format. The contact information is Pearl Optical Industry Co., Ltd., Tokyo, Japan TEL: 81-3-3760-8871, FAX: 81-3-3793-2722. The test targets themselves are solid glass with either black on white or white on black patterns on one side. Their stuff isn't cheap - around $4500 for a projector and $450 per test target, but they have been a standard for many years and you might be able to locate a surplus used one for a good price. Personally, if I were putting together one for my own use I would build something and put an interchangeable lens mount on it. The MTF equipment I used was designed and built by Optikos in Cambridge, Mass., and worked on the principle of performing a Fourier transform of a point image formed by the lens. Good commercial equipment is extremely expensive, but all you really need is a good collimated light source, a precision high-NA microscope objective, and some good mechanical parts to hold everything together. Plus a computer and the willingness to write the analysis software. A more direct approach would be to photograph sinewave targets of varying spatial frequency. You might want to check out http://www.sinepatterns.com/ for more information on this. These targets are pretty expensive, but you can probably do a reasonable job printing your own on a good inkjet printer (see http://www.normankoren.com/ ). Photographing with film might lead to large errors because of enhanced mid-range MTF due to adjacency effects in processing, so some type of digital image detection might help here. You could use a microscope objective to relay the image formed by the lens onto a CCD to greatly enlarge the pattern so that the limited resolution of a CCD will not effect accuracy. Off-axis measurements might be a challenge here, however. Of course, you could always simply measure the combined MTF of the lens and the film. Brian rmonagha@smu.edu (Robert Monaghan) wrote > Hi Brian, > > an interesting observation and point, thanks again for sharing this tip! > > I would be interested in any sources for such precision projection slides > (esp. surplus? ;-) and info on how to do such a setup? I think I have > seen a similar X shaped chart used by Nikon, IIRC, to project slides and > check lenses on final assembly... > > I have seen something I suspect is similar, using a kodalith film slice of > a series of stripes, projected thru the lens, for use with a scanner or > other photosensor to derive a pseudo-MTF chart and response value for a > given cycle frequency. > > I'd also be interested in any homebrew MTF or similar contrast testing > gizmo designs out there, esp. any that could be made to work using more > modern electronics (e.g. interface to a PC, use a scanner and existing > software?) in place of older commercial MTF testing gear... > > thanks for any pointers or tips on above! bobm

From: Acme Optics acmeoptics@earthlink.net Newsgroups: sci.optics Subject: Re: MTF Programming language Date: Tue, 07 May 2002 "Bob May" bobmay@nethere.com wrote: >Actually, you don't calculate a MTF but rather observe it in a finished >optical system. MTF is one of the things that can be calculated in the >better optical design programs. Roadrunner is free and I do believe it >calculates that particular spec. Hi, Yes, we do both Geometrical MTF as per the discussion in Smith and Diffraction MTF by the autocorrelation of the pupil function method. We take into account non-uniform lumination of the pupil function in direction cosine space for focal systems in the presence of pupil aberrations. We agree quite closely with the CODE-V diffraction based MTF results even with f-numbers less than 1.0. This is done without resorting to the Huygens Method as used in ZEMAX. All MTF results are available graphically and tabularly. The results are also "gettable" using the GET function which makes MTF results available in MACRO programs. Finally, both types of MTFs are available in both optimization and tolerancing. Instead of changing the sampling spaceing in the pupil function to accomodate polychromatic effects, we sample the same grid so as to sample the aberrations properly at all wavelengths and then scale the results at non-control wavelengths before putting things together. All MTF results are available for both FOCAL and AFOCAL systems and the results can be cast in terms of target (object) space or image space. We take a lot of pride in the work we have done to provide the very best, solid results in our MTF routines. Acme Optics >BTW, I assume that you mean Modulation Transfer Function rather than Mean >Time to Failure.


From: skeckhardt@mmm.com (Steve Eckhardt) Newsgroups: sci.optics Subject: Re: MTF Programming language Date: 7 May 2002 david@sti-hawaii.com says... >Hello, > >I am considering writing a program to calculate MTF but my programming >skills are non-existent any suggestions. > >David Breitwieser I second the vote for MathCAD. It has FFT's built in, so you only need to give it the input line spread function, properly scaled, and it will give you the MTF. If you want to compute an MTF from measured data, you will probably need to smooth the data first to avoid aliasing. Steve Eckhardt skeckhardt@mmm.com


From: skeckhardt@mmm.com (Steve Eckhardt) Newsgroups: sci.optics Subject: Re: MTF Programming language Date: 7 May 2002 rmonagha@smu.edu says... > >I'd be very interested in a pseudo-MTF tester for lenses (35mm SLR, other >cameras..?)... > >see http://medfmt.8k.com/mf/mtftester.html for some general notes etc. > >with the right tester, this should be pretty straightforward; e.g., >measure response curve to various black/white line patterns across the >lens coverage, then plot points (pass data to excel charting program as >data file, or VB script it?). A low cost film scanner could be used as the >base unit, using existing software to get the data in to PC/Mac (lens and >light source and pattern grid mounted on film scanner). > >let me know of your project's progress... ;-) > >regards bobm I would also love to get my hands on a "hand-held MTF meter". I conceived of using a hand scanner as a base for building one, but the surplus house sold out before I made up my mind. As you say, all it would take is a linear CCC, a DSP and a readout. Steve Eckhardt skeckhardt@mmm.com


From: "Rich Mig" rmigliac@optonline.net Newsgroups: sci.optics Subject: Re: MTF Programming language Date: Tue, 07 May 2002 I'm working on this right now and its easier said than done. Design of the light source (divergence, bandwidth, on-axis, off-axis), conjugate distance, pixel size of the sensor, alignment, and of course the focus all have to be considered for the MTF to be accurate (and useful IMHO). - Rich Migliaccio {snip} > I would also love to get my hands on a "hand-held MTF meter". I conceived of > using a hand scanner as a base for building one, but the surplus house sold out > before I made up my mind. As you say, all it would take is a linear CCC, a DSP > and a readout. > > Steve Eckhardt skeckhardt@mmm.com


sci.optics From: "OpticsNotes" Nichols@OpticsNotes.Com [1] Re: MTF Programming language Date: Wed May 08 2002 FWIW, Optikos has "focused" on MTF testing / instruments. Bruce http://www.OpticsNotes.Com Optics and Photonics Tutorials, References and Resources


From: sprince@optics1.com (Simon Prince) Newsgroups: sci.optics Subject: Re: MTF Programming language Date: 8 May 2002 Hi, If you're looking to buy an MTF testing station you could have a look at the Optima system that we sell: www.optics1.com. We test a lot of lenses here with it and it's pretty versatile. It uses a CCD to obtain the line spread function and fourier transforms that to obtain the MTF. Alternatively, you can use a PSF though that is less often used (mainly, I think because the experimental setup is a little harder to align, particularly for fast lenses where you may not have much energy coming through a small pinhole). If you need any additional suggestions I can point you in the direction of the engineer who deals with this stuff. Simon > I'm working on this right now and its easier said than done. Design of the > light source (divergence, bandwidth, on-axis, off-axis), conjugate distance, > pixel size of the sensor, alignment, and of course the focus all have to be > considered for the MTF to be accurate (and useful IMHO).


From: skeckhardt@mmm.com.deletethis (Steve Eckhardt) Newsgroups: sci.optics Subject: Re: MTF Programming language Date: 8 May 2002 rmigliac@optonline.net says... > >I'm working on this right now and its easier said than done. Design of the >light source (divergence, bandwidth, on-axis, off-axis), conjugate distance, >pixel size of the sensor, alignment, and of course the focus all have to be >considered for the MTF to be accurate (and useful IMHO). >- Rich Migliaccio > ... I guess I need to be more clear about what I mean by "hand-held MTF meter". I would use it to test projectors, so the light source is unnecessary. I just want a device with a linear CCD onto which I can focus the image of an edge (or a square wave). If an edge is detected, the meter would take the derivative of the edge spread function and FFT it to obtain the MTF. The user would enter a spatial frequency, and the meter would display the modulation at that frequency. If a square wave is detected, the meter could just display the modulation. As for bandwidth, I'd just want a photopic correction filter in front of the CCD. This meter could also be used for measuring photographic lenses if the user can provide the proper target with sufficiently uniform illumination. The chief limitation here would be the pixel spacing of the CCD; 6 micron pixels limit you to about 80 cy/mm (or 40 cy/mm with double sampling). Does this make the job easy enough that I'll be able to buy a meter from you in the near future? Best regards, Steve Eckhardt


From: westin@graphics.cornell.edu (Stephen H. Westin) Newsgroups: sci.optics Subject: Re: MTF Programming language Date: 08 May 2002 skeckhardt@mmm.com.deletethis (Steve Eckhardt) writes: ... > This meter could also be used for measuring photographic lenses if > the user can provide the proper target with sufficiently uniform > illumination. The chief limitation here would be the pixel spacing > of the CCD; 6 micron pixels limit you to about 80 cy/mm (or 40 cy/mm > with double sampling). Actually, it's typical to take a 2D image of an oblique edge; the angle between the edge and the sampling grid essentially multiplies your sampling rate. The ISO 12233 standard uses this method to calculate SFR (related to MTF) for digital cameras. See http://www.pima.net/standards/iso/tc42/wg18/WG18_POW.htm#12233 for more. ISO 16067 is the analogous method for scanners; see http://www.pima.net/standards/iso/tc42/wg18/WG18_POW.htm#16067. ... -- -Stephen H. Westin


From: pandys@263.net (pandy) Newsgroups: sci.optics Subject: Re: Compute the PSF from the MTF measurement Date: 25 Aug 2002 A paper I am reading says: If PSF is a minimum phase function,i.e a real,causal, and stable PSF. PTF can be calculated from the MTF by: PTF(u)=-1/2*Pi* { |(0-2*pi) ln{MTF(a)}cot((u-a)/2) da } here,|(0-2*pi) means the integral from 0 to 2*pi. I don't know How to type equation here,sorry :) The paper says that this equation is from references: M.Kunt, Digital Processing, Chap.7, Artech House,Norwood,MA(1986) My problem goes here.I don't now what "cot" in equation means.I cann't get the book mentioned above. Can any one figured out for me? [Ed. note: cot = cotangent function] jon@messuage.demon.co.uk (Jonathon) wrote > This is a question that I've wondered about before. Do I have this > right? > > The OTF can be computed from the PSF using the Fourier transform. The > PSF is real, but the OTF is/may be complex. > > Given the OTF, the PSF can be computed using the Fourier transform. > > The MTF, often quoted as a performance indicator, is the modulus of > the OTF. As phase information is lost by taking the modulus, it is > impossible to compute the PSF from this. > > If this is right so far, given the MTF, is it possible to put some > bounds on the PSF, using some 'reasonable' assumptions? I seem to > remember that there is an analogue in electronic circuit theory, > whereby assuming minimum complexity (minimum phase?), it is possible > to make estimates of the response, even though some phase information > has been lost by taking the modulus. > > Any comments/suggestions gratefully received. > > Jon > > > "Luis Diaz-Santana" luisd@ic.ac.uk wrote > > Hello Patricia, > > > > To recover the PSF from the MTF alone it's a bit of a tricky one. As I > > understand the problem, the MTF is the modulus of the OTF as you said. This > > means that your problem has an infinite number of solutions, there are > > infinite number of PSF that can give you the same MTF with different phase. > > You have to make certain assumptions about your system, in order to find a > > solution. I guess you will need an iterative algorithm that tests your > > estimated PSF against the measured MTF, and then refine your assumptions and > > try again, etc. > > > > There are also experimental ways to measure the phase transfer function, but > > that can be tricky depending on your system. > > > > Luis > > > > "Patricia" plecoupa@san-jose.tt.slb.com wrote > > > Hello, > > > > > > Can anyone give me some information or some references (article, > > > chapters in optical books)on how to compute the PSF of my optical > > > system from the measurement of its MTF ? > > > > > > If I well understand, the PSF and the OTF are Fourier Transform of one > > > the other. And the MTF is the modulus of the OTF. Is this correct ? > > > > > > So if I want to do an inverse fourier transform of the OTF, I miss > > > something because I only have the modulus. > > > > > > Thank you very much for your help in advance, > > > > > > Regards, > > > > > > PAtricia


From: brianc1959@aol.com (brian) Newsgroups: rec.photo.equipment.medium-format Subject: Re: Is Zeiss batch testing lenses? Date: 1 Nov 2002 ...(query about batch lens testing..) Hi Bob: I have no idea what Zeiss does with their photographic lenses, but I do challenge the notion that 100% testing is rare and expensive. I once toured a factory in China in which small scanner lenses were 100% MTF tested using some fairly clever and economical equipment. I think that for this application is was critical that the lenses actually come very close to the design performance. It took only about 10 seconds to completely evaluate each lens. Mind you, these lenses undoubtedly cost less than $10! Another tidbit; on page 213 of "Eyes of Nikon" (a Nikon publication from 1985), there is the following quote: "As an additional benefit, MTF testing is incredibly fast (individual testing takes only 6 seconds!), so every single Nikkor or Nikon Series E lens coming off the production line can be tested." Brian www.caldwellphotographic.com