QPMS
Electromagnetic multiple scattering library and toolkit.
Functions | Variables
qpms.constants Namespace Reference

Functions

def nm2eV (lambda_nm, n=1)
 
def eV2nm (e_eV, n=1)
 
def SU2eV (e_SU)
 
def eV2SU (e_eV)
 
def SU2nm (e_SU, n=1)
 
def nm2SU (lambda_nm, n=1)
 

Variables

float epsilon_0 = 8.8541878128e-12
 
int c = 299792458.
 
float eV = 1.602176487e-19
 
float hbar = 1.054571800e-34
 
float mu_0 = 1.25663706212e-6
 
 π = pi
 
int μm = 1e-6
 
int nm = 1e-9
 
int SU = 3e14
 
int SCUFF_OMEGAUNIT = SU
 

Detailed Description

Constants and unit conversion, mostly for standalode usage.

Previously, QPMS used scipy.constants in the python parts.
Now the relevant ones are set explicitly here in order
to avoid dependency on the whole scipy (which needs a fortran
compiler to build.

The values are taken from scipy / "2018 CODATA recommended values".
They slightly differ from the constants in GSL that are used
in the C code. It would be desirable to use the same source,
hence the values here might be subject to change in future versions.

Function Documentation

◆ SU2eV()

def qpms.constants.SU2eV (   e_SU)
Scuff frequency units to eV.