pulsesuite.PSTD3D.phost

Host material polarization calculations for quantum wire simulations.

This module calculates the host material polarization response for propagation simulations.

Author: Rahul R. Sah

Attributes

eps0_val

c0

me0_val

pi

twopi

ii

Classes

HostMaterial

Host material polarization state and calculations.

Functions

MakeTransverse(Ex, Ey, qx, qy, qsq)

Make electric field transverse.

IFFT(f)

Inverse Fast Fourier Transform wrapper.

SetHostMaterial(host, mat, lam[, epsr, n0])

InitializeHost(Nx, Ny, n0, qsq, host)

SetParamsAlAs()

SetParamsGaAs()

SetParamsSilica()

SetParamsNone()

CalcPHost(Ex, Ey, dt, m, epsb, Px, Py)

CalcPHostOld(Ex, Ey, dt, m, epsb, Px, Py)

CalcNextP(P1, P2, E, dt)

CalcMonoP(E)

SetInitialP(Ex, Ey, qx, qy, qsq, dt, Px, Py, epsb)

CalcWq(q)

CalcEpsrWq(q)

CalcEpsrWq_ij(w_ij, aw, bw)

DetermineCoeffs(aw, bw)

Epsr_q(q)

Epsr_qij(i, j)

FDTD_Dispersion(qx, qy, dx, dy, dt, n0)

wq(i, j)

nw2_no_gam(wL)

nw2(wL)

nwp_no_gam(wL)

nwp(wL)

nl2_no_gam(lam)

nl2(lam)

epsrwp_no_gam(wL)

WriteHostDispersion()

Module Contents

pulsesuite.PSTD3D.phost.eps0_val
pulsesuite.PSTD3D.phost.c0
pulsesuite.PSTD3D.phost.me0_val
pulsesuite.PSTD3D.phost.pi
pulsesuite.PSTD3D.phost.twopi
pulsesuite.PSTD3D.phost.ii = 1j
pulsesuite.PSTD3D.phost.MakeTransverse(Ex, Ey, qx, qy, qsq)

Make electric field transverse.

Projects the electric field onto the transverse direction perpendicular to the momentum vector. Modifies Ex, Ey in-place.

pulsesuite.PSTD3D.phost.IFFT(f)

Inverse Fast Fourier Transform wrapper.

Performs 2D IFFT on the input array. Modifies f in-place.

class pulsesuite.PSTD3D.phost.HostMaterial

Host material polarization state and calculations.

Encapsulates all mutable state that was previously at module level: material parameters (oscillator model), time-stepped polarization history arrays, and pre-computed dispersion arrays.

Usage (mirrors Fortran workflow):

hm = HostMaterial()
hm.SetHostMaterial(True, 'AlAs', 1e-6)
hm.InitializeHost(Nx, Ny, n0, qsq, True)
hm.CalcPHost(Ex, Ey, dt, m, epsb, Px, Py)
SetHostMaterial(host, mat, lam, epsr=0.0, n0=1.0)

Set host material parameters.

Parameters:
  • host (bool) – Whether to use host material dispersion

  • mat (str) – Material name (‘AlAs’, ‘fsil’, ‘GaAs’, ‘none’)

  • lam (float) – Wavelength (m)

  • epsr (float) – Dielectric constant (Fortran intent(inout) artifact)

  • n0 (float) – Refractive index (Fortran intent(inout) artifact)

Returns:

  • epsr (float) – Updated dielectric constant

  • n0 (float) – Updated refractive index

InitializeHost(Nx, Ny, n0, qsq, host)

Initialize host material arrays.

Allocates and initializes arrays for host material calculations.

Parameters:
  • Nx (int) – Grid dimensions

  • Ny (int) – Grid dimensions

  • n0 (float) – Refractive index

  • qsq (ndarray) – Squared momentum array, shape (Nx, Ny)

  • host (bool) – Whether to use host material dispersion

SetParamsSilica()

Set material parameters for silica (Sellmeier coefficients).

SetParamsGaAs()

Set material parameters for GaAs (Sellmeier coefficients).

SetParamsAlAs()

Set material parameters for AlAs (Sellmeier coefficients).

SetParamsNone()

Set material parameters for vacuum (no dispersion).

CalcPHost(Ex, Ey, dt, m, epsb, Px, Py)

Calculate host material polarization.

Computes the host material polarization response using a time-stepping scheme. Modifies Px, Py in-place.

CalcPHostOld(Ex, Ey, dt, m, epsb, Px, Py)

Calculate host material polarization (old version).

Behavior depends on time step index m: - m > 2: use previous values - m >= 2: initialize with monochromatic polarization - m < 2: initialize with monochromatic, set next to zero

Modifies Px, Py in-place.

CalcNextP(P1, P2, E, dt)

Calculate next polarization value.

Uses finite difference scheme for the oscillator model: P_next = f1 * P1 + f2 * P2 + f3 * E

CalcMonoP(E)

Calculate monochromatic polarization.

P = eps0 * E * real(chi1)

SetInitialP(Ex, Ey, qx, qy, qsq, dt, Px, Py, epsb)

Set initial polarization values.

Initializes the polarization arrays for the first time step. Modifies Ex, Ey, Px, Py in-place.

CalcWq(q)

Calculate frequency from momentum using the dispersion relation.

Writes output to ‘fields/host/w.q.dat’.

CalcEpsrWq(q)

Calculate dielectric constant as function of frequency.

CalcEpsrWq_ij(w_ij, aw, bw)

Calculate dielectric constant for a single frequency.

DetermineCoeffs(aw, bw)

Determine expansion coefficients for low/high frequency approximations. Modifies aw, bw in-place.

Epsr_q(q)

Return copy of the dielectric constant array.

Epsr_qij(i, j)

Return dielectric constant at indices (i, j).

FDTD_Dispersion(qx, qy, dx, dy, dt, n0)

Calculate FDTD dispersion relation.

wq(i, j)

Return frequency at indices (i, j).

nw2_no_gam(wL)

Dielectric constant without damping: n^2(w).

nw2(wL)

Dielectric constant with damping: n^2(w).

nwp_no_gam(wL)

Derivative of refractive index without damping: dn/dw.

nwp(wL)

Derivative of refractive index with damping: dn/dw.

nl2_no_gam(lam)

Dielectric constant from wavelength without damping: n^2(lam).

nl2(lam)

Dielectric constant from wavelength with damping: n^2(lam).

epsrwp_no_gam(wL)

Derivative of dielectric constant without damping: depsr/dw.

WriteHostDispersion()

Write host material dispersion data to files.

pulsesuite.PSTD3D.phost.SetHostMaterial(host, mat, lam, epsr=0.0, n0=1.0)
pulsesuite.PSTD3D.phost.InitializeHost(Nx, Ny, n0, qsq, host)
pulsesuite.PSTD3D.phost.SetParamsAlAs()
pulsesuite.PSTD3D.phost.SetParamsGaAs()
pulsesuite.PSTD3D.phost.SetParamsSilica()
pulsesuite.PSTD3D.phost.SetParamsNone()
pulsesuite.PSTD3D.phost.CalcPHost(Ex, Ey, dt, m, epsb, Px, Py)
pulsesuite.PSTD3D.phost.CalcPHostOld(Ex, Ey, dt, m, epsb, Px, Py)
pulsesuite.PSTD3D.phost.CalcNextP(P1, P2, E, dt)
pulsesuite.PSTD3D.phost.CalcMonoP(E)
pulsesuite.PSTD3D.phost.SetInitialP(Ex, Ey, qx, qy, qsq, dt, Px, Py, epsb)
pulsesuite.PSTD3D.phost.CalcWq(q)
pulsesuite.PSTD3D.phost.CalcEpsrWq(q)
pulsesuite.PSTD3D.phost.CalcEpsrWq_ij(w_ij, aw, bw)
pulsesuite.PSTD3D.phost.DetermineCoeffs(aw, bw)
pulsesuite.PSTD3D.phost.Epsr_q(q)
pulsesuite.PSTD3D.phost.Epsr_qij(i, j)
pulsesuite.PSTD3D.phost.FDTD_Dispersion(qx, qy, dx, dy, dt, n0)
pulsesuite.PSTD3D.phost.wq(i, j)
pulsesuite.PSTD3D.phost.nw2_no_gam(wL)
pulsesuite.PSTD3D.phost.nw2(wL)
pulsesuite.PSTD3D.phost.nwp_no_gam(wL)
pulsesuite.PSTD3D.phost.nwp(wL)
pulsesuite.PSTD3D.phost.nl2_no_gam(lam)
pulsesuite.PSTD3D.phost.nl2(lam)
pulsesuite.PSTD3D.phost.epsrwp_no_gam(wL)
pulsesuite.PSTD3D.phost.WriteHostDispersion()