ZEMAX Users' Knowledge Base - http://www.zemax.com/kb
Quantifying Veiling Glare
http://www.zemax.com/kb/articles/192/1/Quantifying-Veiling-Glare/Page1.html
By Mike Tocci
Published on 25 May 2007
 
Veiling glare is a term that is often used in the field of imaging system design. Technically, veiling glare is stray light that reaches the sensor plane of an imaging system, and it can cause a decrease in the imaging system’s performance.

Often,  a full non-sequential treatment is needed for accurate results. However, for many optical imaging systems, a first-cut look at forward scattering effects is all that is really required. This article will show how to make just such a preliminary veiling glare measurement using tools that are already built into ZEMAX. This analysis will require just a few minutes to perform, and will give very useful results.

Introduction
Veiling glare is a term that is often used in the field of imaging system design. Technically, veiling glare is stray light that reaches the sensor plane of an imaging system, and it can cause a decrease in the imaging system’s performance. There are many potential sources of stray light, and accurately modeling all of them can be a very labor-intensive task. For example, stray light may originate from the object itself or it may originate from an out-of-field object (for example, a telescope that is aimed at a dim star may be flooded with stray light from a full moon located many degrees outside the telescope’s field of view). Stray light may be caused by multiple reflections from refractive elements, scattering from optical surfaces, scattering from opto-mechanical elements, narcissus, fluorescence, ghost images, etc.

For some highly-sensitive optical systems, modeling many of these different stray light phenomena may be necessary to accurately model the system’s performance. Doing so requires building a comprehensive non-sequential model of the system and devising methods for measuring the reductions in image contrast. See How To Perform Stray Light Analysis in Non-Sequential ZEMAX for a good example of this approach.

However, for many optical imaging systems, a first-cut look at forward scattering effects is all that is really required. This article will show how to make just such a preliminary veiling glare measurement using tools that are already built into ZEMAX. This analysis will require just a few minutes to perform, and will give very useful results.

We’re going to model an imaging system with a protective window. The purpose of the protective window is to shield the sensitive lens elements from the environment. However, as we’ll see, the window itself can become a significant source of scattered light.

We’re going to be modeling a broad scattering effect (we’ll be using a partially Lambertian scattering model), and so we’re going to convert the lens to a Non-Sequential Component. The reason we do this is because ZEMAX will only allow small angle scattering in pure Sequential mode, and we would miss out on some of the very interesting effects if we did not convert the lens to a Non-Sequential Component.

Note that if we were interested in modeling only small-angle scattering, we could skip the step of converting to NSC and simply add scatter properties to any of the surfaces by right-clicking the surface, and then clicking the Scattering tab.

Prepare the Lens for Analysis
We’ll start with a lens that is provided with ZEMAX. The lens file is titled, “Double Gauss 28 degree field.zmx” and it’s located in the Samples\Sequential\Objectives subdirectory of the ZEMAX installation directory. After loading the lens into ZEMAX, the first thing we’ll do is tune it up a bit.

The image below shows the layout of the system when it’s first loaded into ZEMAX:

The starting design

Open a window to view the Geometric MTF of the system, under Analysis|MTF|Geometric MTF. Click Settings, and set the Max Frequency to 50. The settings dialog box should look like this:

MTF settings

The system’s MTF is shown below:

MTF

Note that we’re analyzing an imaging system with a [mostly] round pupil at its focal plane. Therefore Geometric MTF gives extremely accurate results compared to the FFT Diffraction MTF, but the important distinction here is that Geometric MTF gives us the ability to include scattering effects later on. See Understanding the MTF Operands for more details.

To tune the lens we’ll first increase the f-number of the system. Go to System|General and click on the Aperture tab. Set the Aperture Value to 25 and click OK.

Next go to Editors|Merit Function and then in the Merit Function Editor click Tools|Default Merit Function. Click Reset and then click OK. Then click on Tools|Optimization|Optimization and press Automatic. The MTF is now significantly improved:

Improved MTF

For this simple demonstration, we’re going to be modeling an imaging lens to be used for viewing through a porthole in an aircraft – the idea being that the outer window on this aircraft will get weathered and “bead-blasted” over time and will become a significant source of scattering. So the next thing we’ll do is add a window to the front of the model.

Go to the Lens Data Editor and click on Surface 1 (this is the outermost lens surface). Hit the Insert key twice to insert two new surfaces before the lens. Set the following values for these two new surfaces:

Surface 1
Surf:Type = Standard
Comment = Window-outer
Radius = Infinity
Thickness = 10
Glass = BK7

Surface 2
Surf:Type = Standard
Comment = Window-inner
Radius = Infinity
Thickness = 20

Next, we want to slightly oversize each lens so that it’s just a bit larger than the beam going through it. Go to System|General and click on the Misc. tab and then set the Semi-Diameter Margin Millimeters to 3. Go to the Layout window, click Settings, and set the First Surface to 1. Here is what the layout looks like at this point:

The lens with glass window

Convert the Lens to a Non-Sequential Component Group
In order to perform a stray light analysis on this lens, we need to convert it to a Non-Sequential Component. This is a simple and speedy process in ZEMAX.

The first thing we need to do is to realize that ZEMAX requires that the Aperture Stop of the system be located before any Non-Sequential Component in the Lens Data Editor. Remember: our plan is to make the outer surface of the flat window a scattering surface, so the window must be part of the Non-Sequential Component. Looking at our lens, we see that the Aperture Stop is actually buried deep inside the lens.

To make the Aperture Stop occur before the window in the Lens Data Editor, we need to trick ZEMAX just a little bit. We’ll add the aperture stop before the window, such that its location and size coincide with the Entrance Pupil of the lens. Then we’ll have the Lens Data Editor step backwards in space to the location of the window, and then the rest of the system can follow as usual.

We need to know the Entrance Pupil’s location and size, so let’s go to the Merit Function Editor and insert two new operands: ENPP and EPDI. Update the merit function, and you’ll see these values calculated automatically:

The merit function

{Alternatively, use File|Preferences|Status bar and add these two items to ther status bar at the bottom of the main ZEMAX window.} The entrance pupil location is 86.063994mm after the outer window surface, and its full diameter is 25.0mm.

Click on Surface 1 in the Lens Data Editor and hit the Insert key once. Set the following values for this new surface:

Surface 1
Surf:Type = Standard
Comment = Aperture Stop
Radius = Infinity
Thickness = -86.063994

Now right click on the Surf: Type cell of Surface 1 and, under the Type tab, check the box next to “Make Surface Stop” and then click OK. Note that since this system’s Aperture Type is Entrance Pupil Diameter, we don’t need to set the Semi-Diameter of this surface: it’s already set for us to 12.5mm.

We’re almost ready to convert the lens to a Non-Sequential Component. Go to the last lens surface (Surface 14) in the Lens Data Editor, and make its comment “last surface.” This is not a necessary step, but it’s helpful when we go to find this surface when we convert to NSC, in the next step.

Now go to Tools|Miscellaneous|Convert to NSC Group. For the First Surface choose “2 – Window-outer” and for the Last Surface choose “14 – last surface” and click OK.

You’ll notice that the MTF of the system is identical to what it was before conversion to NSC: this is a good check that everything converted over correctly.

Open a 3D Layout window and set the First Surface to 2, and you’ll see that the system looks nearly identical to the original sequential layout:

The NSC version

Note that the only difference is that the edges of the first group of lenses are bevelled: if this is not desired, just add apertures to these surfaces prior to conversion, or edit the file by hand after conversion.

Add Scatter and Analyze
The next step is to model the outer surface of the window as if it has been subjected to a harsh environment. We do this by adding an appropriate scatter model to the front face of the window element.

Open the Non-Sequential Component Editor and right-click on the Object Type cell of Object 1 (this object represents the flat window of BK7 glass). Click the Coat/Scatter tab and then for Face choose “1, Front Face.” Next click the button next to ABg and then for Transmit choose LAMB-SPEC. The dialog box should look like this when you’re finished:

Object Properties

The system now simulates a highly-scattering front window surface, followed by perfectly smooth (non-scattering) lens surfaces behind the outer window.

Note that we have chosen a built-in ABg scatter model (LAMB-SPEC) for this article, but for modeling a real system you will need to carefully select a scatter model that accurately simulates whatever scatter you expect the system to encounter.

Go to the already-open Geometric MTF window and click on Settings. Check the box next to Scatter Rays and hit OK. The resulting plot shows the effects of veiling glare on the system’s MTF curves:

The MTF with scatter effects included

A very interesting result here is that the on-axis field suffers the most from the effects of veiling glare in this set up. To understand why this is, we will look to the Spot Diagram next.

To look at the spot diagrams, go to Analysis|Spot Diagrams|Standard, and then fill in the Settings as shown below:

Spot diagram settings

Note that we have left the Scatter Rays box un-checked for now. Here are the resulting Spot Diagrams when scattered light is neglected:

Spot diagram, no scattering

These are very good spots, measuring just a few tens of microns across (note the RMS radius values at the bottom of the diagram, in units of microns). The small white ring at the center of each spot diagram shows the calculated size of the diffraction Airy Disc, which has a diameter of 5.5 microns.

Now go to Settings and check the box next to Scatter Rays and then click OK. Here are the Spot Diagrams when the effects of scattered light are included in the calculation:

Spot diagram with scattering included

You can see now that the spots measure several tens of millimeters across (the RMS Radius values are shown at the bottom of the diagram again), and you can further see that the on-axis field (whose spot is located at the top left of the diagram) has most of its light scattered in a tight cluster near the center, whereas the off-axis fields are not nearly as concentrated around the center. Zoom in on the two locations shown below to see the difference in light concentration for the on-axis and off-axis spot diagrams:
More details

Below is a zoomed-in image of the on-axis spot diagram:

The on-axis spot, with scattering

And here is a zoomed-in image of the off-axis spot diagram:

Off-axis spot with scattering

Usually, we consider an imaging system to be better if it concentrates more light toward the central image spot, so we might think that the spot diagram for the on-axis spot would be better than the spot diagram for the off-axis spot. Let’s zoom even further into the on-axis spot and see just what’s going on here…

I’ve changed the Settings for the Spot Diagram window to the following:

New settings

Next I zoomed way in on the center of the on-axis spot, and here is what we see:

Detailed spot

The small white ring in the center of the tiny spot diagram represents a calculation of the Airy Disc size, as we saw in the spot diagrams before considering scattering. We can see now that the highest concentration of light is still in the exact same size and shape as the original spot diagram (back when we had neglected scattering effects), but the effect of scattering is to put some light around this small spot and thereby change what had been a perfectly dark background to a more-light-filled background. This, in turn, reduces the system’s contrast and thus the MTF drops.

Note that adding scatter to our model did nothing to the shape or size of the tiny spot diagram: it merely shifted some of the light away from the tiny spot.

We see that because the off-axis beam scatters light farther away from the central spot, the background in the vicinity of the tiny spot diagram is less intense than it is for the on-axis beam. Therefore we can expect the off-axis fields to have better contrast, and higher MTF, than the on-axis fields. And this is exactly what ZEMAX showed us in the MTF curves when we included scatter.

Note that there are two other Analysis features that allow you to “Scatter Rays”: Geometric Image Analysis and Geometric Encircled Energy. Feel free to check the effect of scatter on those, as well.

Summary
We used ZEMAX to measure the effects of forward scattering on the MTF and Spot Diagrams of an imaging system, quantifying the effects of veiling glare. We saw that ZEMAX accurately predicted that the effect of scattering is to redistribute light from a small spot to a large region of what had previously been a perfectly dark background.

The overall effect of scattering is to lower the contrast of the image and the system’s MTF, not through a blurring of the image spot (as is usually the case when MTF drops) but through an increase in background light.

We saw that, as expected, the decrease in MTF is proportional to the amount of light that was scattered nearby the image point, as shown in the Spot Diagrams.