Skip to content

Instantly share code, notes, and snippets.

@stephanlachnit
Created August 31, 2023 10:54
Show Gist options
  • Save stephanlachnit/08cec07ad96e19dd21262c780f52235b to your computer and use it in GitHub Desktop.
Save stephanlachnit/08cec07ad96e19dd21262c780f52235b to your computer and use it in GitHub Desktop.
Plot Absorption Length of Photons in Silicon
#!/usr/bin/env python3
# SPDX-License-Identifier: Unlicense
import numpy as np
import matplotlib.pyplot as plt
# Data from https://doi.org/10.1002/pip.4670030303
# wavelength in nm, alpha in cm^-1, abs length in um
wavelength = np.linspace(250, 1450, num=121)
alpha = np.array([1.84e+06,1.97e+06,2.18e+06,2.36e+06,2.24e+06,1.73e+06,1.44e+06,1.28e+06,1.17e+06,1.09e+06,1.04e+06,1.02e+06,6.97e+05,2.93e+05,1.50e+05,9.52e+04,6.74e+04,5.00e+04,3.92e+04,3.11e+04,2.55e+04,2.10e+04,1.72e+04,1.48e+04,1.27e+04,1.11e+04,9.70e+03,8.80e+03,7.85e+03,7.05e+03,6.39e+03,5.78e+03,5.32e+03,4.88e+03,4.49e+03,4.14e+03,3.81e+03,3.52e+03,3.27e+03,3.04e+03,2.81e+03,2.58e+03,2.38e+03,2.21e+03,2.05e+03,1.90e+03,1.77e+03,1.66e+03,1.54e+03,1.42e+03,1.30e+03,1.19e+03,1.10e+03,1.01e+03,9.28e+02,8.50e+02,7.75e+02,7.07e+02,6.47e+02,5.91e+02,5.35e+02,4.80e+02,4.32e+02,3.83e+02,3.43e+02,3.06e+02,2.72e+02,2.40e+02,2.10e+02,1.83e+02,1.57e+02,1.34e+02,1.14e+02,9.59e+01,7.92e+01,6.40e+01,5.11e+01,3.99e+01,3.02e+01,2.26e+01,1.63e+01,1.11e+01,8.00e+00,6.20e+00,4.70e+00,3.50e+00,2.70e+00,2.00e+00,1.50e+00,1.00e+00,6.80e-01,4.20e-01,2.20e-01,6.50e-02,3.60e-02,2.20e-02,1.30e-02,8.20e-03,4.70e-03,2.40e-03,1.00e-03,3.60e-04,2.00e-04,1.20e-04,7.10e-05,4.50e-05,2.70e-05,1.60e-05,8.00e-06,3.50e-06,1.70e-06,1.00e-06,6.70e-07,4.50e-07,2.50e-07,2.00e-07,1.50e-07,8.50e-08,7.70e-08,4.20e-08,3.20e-08])
abs_length = 1e4 / alpha
# select data range (wavelength in nm)
lower_wl = 250
upper_wl = 1050
selected_idx = (wavelength >= lower_wl) & (wavelength <= upper_wl)
selected_wavelengths = np.extract(selected_idx, wavelength)
selected_abs_legnths = np.extract(selected_idx, abs_length)
plt.figure('Absorption Length of Photons in Silicon')
plt.plot(selected_wavelengths, selected_abs_legnths, marker='.')
plt.xlabel('Wavelength [nm]')
plt.xlim(lower_wl - 50, upper_wl + 50)
plt.ticklabel_format(scilimits=(0, 4))
plt.ylabel('Absorption Length [um]')
plt.yscale('log')
plt.ylim(0.5 * np.min(selected_abs_legnths), 2 * np.max(selected_abs_legnths))
plt.show()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment