Soon, we will launch a new and updated customer portal, which is an important step toward providing our customers with one place to learn, interact, and get help.

# How to Define Metal Materials in Zemax OpticStudio

This article explains how to add metal materials in Zemax and how to apply them to sequential surfaces or non-sequential object faces.  Additional information on coatings can be found in the following KB articles:

How to Add Coating and Scattering Functions to Non-Sequential Objects
How to Model a Partially Reflective and Partially Scattering Surface
Kristen Norton
09/23/2014
First-Time Users
Polarization and Thin Film Coatings
Sequential Ray Tracing
Non Sequential Ray Tracing

### Introduction

There are two different ways to define materials in Zemax OpticStudio (ZOS):

(1) Using the Materials Catalog
(2) Using the Coating File

Glass materials can be easily defined in both the Materials Catalog and the Coating File, but the easiest way to add metal materials is using the Coating File.  For most metals, any interaction with light occurs primarily at or within a few microns of the surface, so modeling the metal as a coating is a good representation of this thin layer.

This article describes how to define a metal as new material in the Zemax Coating file, and then how to apply the coating to any relevant surfaces or faces of an object.

### Defining a Metal Coating

For dielectric materials, like glasses, the index of refraction is real and the imaginary part of the index is zero. For metals, the index of refraction is complex. Zemax OpticStudio models this using the following expresssion:

η = n + ik ,

where n is the index of refraction and k is the extinction coefficient.  In ZOS, a negative extinction coefficient, k, indicates an absorbing material.  For example, using the ZOS convention, the index of aluminum is approximately given by

η = 0.7 – 7.0i .

ZOS uses a text file format to define all coating data. A sample file called COATING.DAT is supplied with Zemax, and this is the default coating file used for new lenses. Multiple coating files may be defined and saved in the ZOS data folder, which usually is located in \Documents\Zemax\Coatings. However, only one file is in use a time.  The name of the coating file in use is specified in the Files section of the System Explorer.  It is highly recommended that any modifications to COATING.DAT be saved in a file with a different name, so that subsequent updates to OpticStudio will not overwrite the changes made to COATING.DAT.

In the coating file, multiple keywords are used to define different types of coating data. These include:

MATE (for material)
TAPR (for taper profile)
COAT (for coating)
TABLE (for coatings defined by a table of points)
IDEAL (for ideal coatings)
IDEAL2 (for ideal type 2 coatings)

All of the material and taper definitions come first, then all of the coating definitions.

To create a coating with a new material, the new material must first be defined using the MATE data section.  The MATE data section has the following syntax:

MATE <user-defined material name>
wavelength   real   imaginary
wavelength   real   imaginary
....

The wavelength argument is always in micrometers, and the wavelengths must be specified in ascending order. The “real” value is the real index of refraction of the material at that wavelength. The “imaginary” value is the extinction coefficient.

Here are two examples of this in the default COATING.DAT coating file:

Materials defined in the MATE data section can then be referenced in the COAT data sections.  The non-ideal COAT data sections have the following syntax:

COAT <coating name>
material   thickness   is_absolute loop_index   tapername
material   thickness   is_absolute loop_index   tapername
...

When the coating file is first read, ZOS verifies that each coating consists of materials that were defined in the material section. If the referenced materials are not defined, an error is issued.

The coating thickness is measured either in relative units of primary wavelength thickness in that medium, or in absolute micrometers.  If the relative units are used, then the thickness is defined by:

d= λ0·T / n0

where λ0 is the primary wavelength in micrometers, n0 is the real part of the index of refraction of the coating at the primary wavelength, and T is the optical thickness of the coating specified in the coating file.  If the “is_absolute” flag is zero, then the units are relative, otherwise, the coating thickness is absolute in micrometers.

The “loop_index” parameter is a shorthand syntax that replicates layers.  Please see this section of the Help Files for more information on using this term: Technical Reference > Polarization Analysis > Defining coatings in Zemax > Defining replicated groups of coating layers.

If the “is_absolute”, “loop_index”, and “tapername” values are omitted from the syntax, then they are assumed to be zero.  So, to add a layer of a material in units scaled by the wavelength, use the following syntax:

COAT <user-defined coating name>
material   thickness
material   thickness
...

Here are examples in the coating file:

### Editing the Coating File

To access the coating file, go to the Libraries Tab > Coating Tools > Edit Coating File:

Click "Yes" to save the coating file to a new name, since you’ll be editing it:

The new file will be saved in the Coatings folder, which is in the Zemax user data folder :

After editing a coating file, you need to reload the file so that ZOS sees the changes, and the next message you’ll see is just a reminder to do so:

Then, the coating file will open in a text window:

Materials are defined in the first section with the MATE syntax.  Here is an example of a new material:

Coatings using the COAT syntax are defined in the next section.  Note that the MATE material needs to be defined in the coating file before it can be used in the COAT coating definition.

Once you’ve added your material using the MATE syntax and defined the coating in the Coating file, click the Save button in the toolbar to save you changes:

Go to the Files section of the System Explorer, and verify that the new coating file is selected. Click the “Reload” button to load the newly saved changes:

To apply this coating to a sequential surface, go to the Coating section of the Surface Properties in the Lens Data editor.  The new coating will be listed in the drop-down menu:

Similarly, to use this material with a non-sequential object, go to the Coat/Scatter section of the Object Properties in the NSC editor.  The coating can be applied to the different faces of the object:

In order to see the effect of the coating, “Use Polarization” must be selected in the Ray Trace or other analysis settings. If you want to trace both the reflected and transmitted rays, you must also check the "Split NSC Rays" option:

The NSC Layout plots have an additional control for “Split NSC rays” that must be selected to see both the reflected and transmitted rays: