MultilayerMirror#

class optika.materials.MultilayerMirror(layers=None, substrate=None)[source]#

Bases: AbstractMultilayerMirror

A model of a mirror coating consisting of alternating layers of different materials.

Examples

Reproduce Example 2.3.2 in the IMD User’s Manual, the reflectivity of a \(\text{Si/Mo}\) multilayer stack with interfacial roughness.

import numpy as np
import matplotlib.pyplot as plt
import astropy.units as u
import astropy.visualization
import named_arrays as na
import optika

# Period length of the multilayer sequence
d = 66.5 * u.AA

# Number of periods
N = 60

# Define the thickness to period ratios for each layer
thickness_ratio = 0.6

# Define the interface profile between successive layers
interface = optika.materials.profiles.ErfInterfaceProfile(
    width=7 * u.AA,
)

# Define the periodic sequence of layers
layers = optika.materials.PeriodicLayerSequence(
    [
        optika.materials.Layer(
            chemical="Si",
            thickness=thickness_ratio * d,
            interface=interface,
            kwargs_plot=dict(
                color="tab:blue",
                alpha=0.5,
            ),
        ),
        optika.materials.Layer(
            chemical="Mo",
            thickness=(1- thickness_ratio) * d,
            interface=interface,
            kwargs_plot=dict(
                color="tab:orange",
                alpha=0.5,
            ),
        ),
    ],
    num_periods=60,
)

# Define the substrate layer
substrate = optika.materials.Layer(
    chemical="SiO2",
    thickness=10 * u.mm,
    interface=interface,
    kwargs_plot=dict(
        color="gray",
        alpha=0.5,
    ),
)

# Define a representation of multilayer coating
multilayer = optika.materials.MultilayerMirror(
    layers=layers,
    substrate=substrate,
)

# Define the wavelengths of the incident light
wavelength = na.linspace(100, 150, axis="wavelength", num=501) * u.AA

# Define the rays incident on the multilayer coating
rays = optika.rays.RayVectorArray(
    wavelength=wavelength,
    direction=na.Cartesian3dVectorArray(0, 0, 1),
)

# Compute the reflectivity of this multilayer coating
reflectivity = multilayer.efficiency(
    rays=rays,
    normal=na.Cartesian3dVectorArray(0, 0, -1),
)

# Plot the reflectivity as a function of wavelength
fig, ax = plt.subplots()
na.plt.plot(
    wavelength,
    reflectivity,
    ax=ax,
    axis="wavelength",
    label=rf"Si/Mo $\times$ {N}",
);
ax.legend();
ax.set_xlabel(f"wavelength ({wavelength.unit:latex_inline})");
ax.set_ylabel("reflectivity");
../_images/optika.materials.MultilayerMirror_0_1.png

Plot a visual representation of the multilayer coating

fig, ax = plt.subplots(constrained_layout=True)
ax.set_axis_off()
with astropy.visualization.quantity_support():
    multilayer.plot_layers()
../_images/optika.materials.MultilayerMirror_1_0.png

Attributes

is_mirror

flag controlling whether this material reflects or transmits light

layers

A sequence of layers representing the multilayer stack.

shape

The array shape of this object.

substrate

A layer representing the substrate that the layers are deposited onto.

transformation

the coordinate transformation between the global coordinate system and this object's local coordinate system

Methods

__init__([layers, substrate])

attenuation(rays)

the attenuation coefficient of the given rays

efficiency(rays, normal)

Compute the efficiency of this multilayer film using optika.materials.multilayer_efficiency().

index_refraction(rays)

the index of refraction of this material for the given input rays

plot_layers([width, ax, thickness_substrate])

Plot the multilayer stack using optika.materials.AbstractLayer.plot().

to_string([prefix])

Public-facing version of the __repr__ method that allows for defining a prefix string, which can be used to calculate how much whitespace to add to the beginning of each line of the result.

Inheritance Diagram

Inheritance diagram of optika.materials.MultilayerMirror
Parameters:
attenuation(rays)#

the attenuation coefficient of the given rays

Parameters:

rays (RayVectorArray) – input rays to calculate the attenuation coefficient for

Return type:

int | float | complex | ndarray | Quantity | AbstractScalar

efficiency(rays, normal)#

Compute the efficiency of this multilayer film using optika.materials.multilayer_efficiency().

Parameters:
Return type:

int | float | complex | ndarray | Quantity | AbstractScalar

index_refraction(rays)#

the index of refraction of this material for the given input rays

Parameters:

rays (RayVectorArray) – input rays used to evaluate the index of refraction

Return type:

int | float | complex | ndarray | Quantity | AbstractScalar

plot_layers(width=<Quantity 100. nm>, ax=None, thickness_substrate=<Quantity 10. nm>, **kwargs)#

Plot the multilayer stack using optika.materials.AbstractLayer.plot().

Parameters:
Return type:

list[Polygon]

to_string(prefix=None)#

Public-facing version of the __repr__ method that allows for defining a prefix string, which can be used to calculate how much whitespace to add to the beginning of each line of the result.

Parameters:

prefix (None | str) – an optional string, the length of which is used to calculate how much whitespace to add to the result.

Return type:

str

property is_mirror: bool#

flag controlling whether this material reflects or transmits light

layers: None | AbstractLayer | Sequence[AbstractLayer] = None#

A sequence of layers representing the multilayer stack.

property shape: dict[str, int]#

The array shape of this object.

substrate: None | Layer = None#

A layer representing the substrate that the layers are deposited onto.

property transformation: None#

the coordinate transformation between the global coordinate system and this object’s local coordinate system