Materials

The materials are characterized by refractive index, which is a square root (complex valued) of macroscopic dielectric function. Generally, this should be the spectral function, i. e.

\[n_c(\lambda) = n(\lambda) + i \cdot k(\lambda) = \sqrt{ \epsilon_1(\omega) + i \cdot \epsilon_2(\omega) }\]

so that

\[\begin{split}n = \sqrt{(|\epsilon|+\epsilon_1)/2} \\ k = \sqrt{(|\epsilon|-\epsilon_1)/2}\end{split}\]

with \(\hbar \omega = 2 \pi \hbar c / \lambda\).

Constant Material

The material with constant refreactive index can be specified as first constructor argument (file_name):

>>> from mstm_studio.mstm_spectrum import Material
>>> mat_glass = Material('1.5')
>>> mat_glass.get_n(500)
array(1.5)

Complex value can be supplied too:

>>> mat_lossy = Material('3+1j')
>>> mat_lossy.get_n(500)
array(3.)
>>> mat_lossy.get_k(500)
array(1.)

Also the predifned names can be used: air, water, glass.

Loading from file

The tabular data on refractive index is convinient to store in file. The header of the file required to have special labels: lambda        n       k. The example file “etaGold.txt” can be found in directory “nk” of source distribution.

Assuming the file “etaGold.txt” is in the same directory where script is running, it can be loaded with

gold = Material('etaGold.txt')
fig, axs = gold.plot()
fig.savefig('loaded_gold.png', bbox_inches='tight')

Resulted plot

../_images/loaded_gold.png

Note

The extending database of refractive indeces of materials <https://refractiveindex.info/>.

Material from numpy array

Material data can be specified directly by numpy (complex) array by passing nk or eps. Next examples shows loading of Drude-like dielectric function:

from mstm_studio.mstm_spectrum import Material
import numpy as np

wls = np.linspace(300, 800, 51)  # spectral region
omega = 1240. / wls              # freq. domian

omega_p = 9.        # plasma frequency, eV
gamma   = 0.03      # damping, eV
# Drude's dielectric function:
epsilon = 1 + omega_p**2 / (omega * (omega - 1j * gamma))

mat = Material('drude', eps=epsilon, wls=wls)

Material class members

class mstm_studio.mstm_spectrum.Material(file_name, wls=None, nk=None, eps=None)[source]

Material class.

Use get_n() and get_k() methods to obtain values of refraction index at arbitraty wavelength (in nm).

Parameters:

file_name:
  1. complex value, written in numpy format or as string;
  2. one of the predefined strings (air, water, glass);
  3. filename with optical constants.

File header should state lambda, n and k columns If either nk= n + 1j*k or eps = re + 1j*im arrays are specified, then the data from one of them will be used and filename content will be ignored.

wls: float array
array of wavelengths (in nm) used for data interpolation. If None then np.linspace(300, 800, 500) will be used.
plot(wls=None, fig=None, axs=None)[source]

plot n and k dependence from wavelength

Parameters:

wls: float array
array of wavelengths (in nm). If None then np.linspace(300, 800, 500) will be used.

fig: matplotlib figure

axs: matplotlib axes

Return:

filled/created fig and axs objects

Analytical formula for AuAg

Silver, gold and thier alloy materials can be specified using analytical expression proposed in the study [Rioux2014]. Example for Au:Ag = 1:2 alloy:

from mstm_studio.alloy_AuAg import AlloyAuAg

au1ag2 = AlloyAuAg(x_Au=1./3)
fig, axs = au1ag2.plot()
fig.savefig('mat_au1ag2.png', bbox_inches='tight')

Resulted plot

../_images/mat_au1ag2.png
class mstm_studio.alloy_AuAg.AlloyAuAg(x_Au)[source]

Material class for AuAg alloys.

Use get_n() and get_k() to obtain values of refraction indexes (real and imaginary) at arbitraty wavelength (in nm) by model and code from Rioux et al doi:10.1002/adom.201300457

Parameters:

x_Au: float
fraction of gold
[Rioux2014]
  1. Rioux, S. Vallières, S. Besner, P. Muñoz, E. Mazur, and M. Meunier, “An Analytic Model for the Dielectric Function of Au, Ag, and their Alloys” Adv. Opt. Mater. (2014) 2 176-182 <http://dx.doi.org/10.1002/adom.201300457>