AnalyticWaveguideTimeStepper¶
- class photonforge.AnalyticWaveguideTimeStepper(*, n_eff, length=None, propagation_loss=0.0, extra_loss=0.0, n_group=0, dispersion=0.0, dispersion_slope=0.0, reference_frequency=None, fir_taps=None, dn_kerr=_zero, tau_fc=0, dn_fc=_zero, dn_fc_map=None, tau_th=0, dn_th=_zero, sections=None, peak_power=None, max_phase=0.05, power_samples=1024)[source]¶
Analytic waveguide time-stepper with power-dependent effects.
Two-port optical waveguide whose effective index is perturbed by power-dependent effects, plus chromatic dispersion:
\[ \begin{align}\begin{aligned}&n(t) = n_\text{eff} + \Delta n_\text{K}(P(t)) + n_\text{fc}(t) + n_\text{th}(t)\\&\tau_\text{fc}\frac{{\rm d}n_\text{fc}}{{\rm d}t} + n_\text{fc}(t) = \Delta n_\text{fc}(P(t))\\&\tau_\text{th}\frac{{\rm d}n_\text{th}}{{\rm d}t} + n_\text{th}(t) = \Delta n_\text{th}(P(t))\end{aligned}\end{align} \]The perturbation interpolators may be complex: the imaginary part is an index change and therefore a power-dependent loss, used to express two-photon and free-carrier absorptions. The relaxation form above is the carrier rate equation once \(\Delta n_\text{fc}(P)\propto P^2\) is supplied. \(\Delta n_\text{K}\) has no relaxation at all: it follows the power within the step, which is the Kerr effect, and is supplied as
dn_kerr.Relaxing the index change is exact only when it is proportional to the carrier density. Otherwise, as for the hole term of silicon plasma dispersion, \(\propto N^{0.8}\), supply
dn_fc_map:dn_fcthen gives the steady-state carrier density \(N_\text{ss}(P)\), the density itself relaxes, and the map converts it to the index change:\[ \begin{align}\begin{aligned}&\tau_\text{fc}\frac{{\rm d}N}{{\rm d}t} + N = N_\text{ss}(P(t))\\&n_\text{fc}(t) = \Delta n_\text{fc}(N(t))\end{aligned}\end{align} \]Dispersion is applied as an all-pass filter on the envelope,
\[H(\Omega) = \exp\left[i\left(\frac{\beta_2\Omega^2}{2} + \frac{\beta_3\Omega^3}{6}\right)\ell\right]\]with the linear-in-\(\Omega\) term already carried by the group delay.
dispersionanddispersion_slopeuse the same names, units and \(\beta\) conversion asAnalyticWaveguideModel.Every mode of the ports propagates with the same parameters, and \(P\) is the total power over the modes in each direction, so two modes are the two polarizations of one waveguide mode.
- Parameters:
n_eff (complex) – Effective refractive index (loss can be included here by using complex values).
length (Annotated[float, units='μm'] | None) – Length of the waveguide. If not provided, the length is measured by
route_length()or ports distance.propagation_loss (Annotated[float, minimum=0, units='dB/μm']) – Propagation loss.
extra_loss (Annotated[float, minimum=0, units='dB']) – Length-independent additional loss.
n_group (float) – Group index of the optical mode, used to calculate delay.
dispersion (Annotated[float, units='s/μm²']) – Group velocity dispersion D at
reference_frequency.dispersion_slope (Annotated[float, units='s/μm³']) – Dispersion slope S at
reference_frequency.reference_frequency (Annotated[float, minimum=0, units='Hz'] | None) – Frequency at which
dispersionapplies. IfNone, the carrier frequency is used.fir_taps (Annotated[int, exclusiveMinimum=0] | None) – Length of the dispersion filter, ignored when dispersion is zero. If
None, it is set at setup, based on the time step.dn_kerr (Interpolator) – Instantaneous power-dependent index variation, for the Kerr effect. May be complex, the imaginary part being loss.
tau_fc (Annotated[float, minimum=0, units='s']) – Time constant for the free-carrier effects. If zero, free-carrier effects are disabled.
dn_fc (Interpolator) – Power-dependent, steady-state index variation due to free-carrier effects. May be complex. If
dn_fc_mapis given, the real, steady-state carrier density instead.dn_fc_map (Interpolator | None) – Index variation as a function of the relaxed carrier density. May be complex. If
None,dn_fcis an index variation and relaxes directly.tau_th (Annotated[float, minimum=0, units='s']) – Time constant for the thermal effects. If zero, thermal effects are disabled.
dn_th (Interpolator) – Power-dependent, steady-state index variation due to thermal effects. May be complex.
sections (Annotated[int, exclusiveMinimum=0] | None) – Number of sections the waveguide is split into. If
None, it is chosen frompeak_powerandmax_phase.peak_power (Annotated[float, minimum=0, units='W'] | None) – Highest optical power expected at the input, used only to choose the number of sections. If
NonewithsectionsalsoNone, a single section is used.max_phase (Annotated[float, exclusiveMinimum=0, units='rad']) – Largest Kerr phase per section when the number of sections is chosen from
peak_power.power_samples (Annotated[int, exclusiveMinimum=0]) – Number of points used to tabulate the interpolators that are neither linear nor a single polynomial.
Note
Each section is a lumped element: its perturbations are evaluated at the power entering it and assumed uniform along it, and its dispersion is applied after its nonlinear phase. Splitting the waveguide into sections interleaves the nonlinear phase, the loss and the dispersion, which is a split-step scheme; its error falls with the nonlinear phase per section.
Sections are stepped in the frame moving with the envelope, so the group delay is applied once for the whole waveguide. Each dispersion filter adds latency, so when a filter per section would need more than the group delay, dispersion is applied in fewer, longer steps, as many as the group delay allows. Light travelling in the opposite direction enters the index of each section with the power it had there one time step earlier, except at the section where it enters the waveguide.
When the number of sections is chosen from
peak_power, a warning is issued at the end of a run if the Kerr phase in one section exceededmax_phaseby more than 20%, which means the power exceeded the hint.Methods
bind_native(step, keys[, state, cstate, context])Bind a compiled step function.
reset()Reset any internal state of the time stepper.
setup(component, time_step, *[, ...])Initialize the time stepper.
setup_state(*, component, time_step, ...)Initialize internal state.
step([inputs, steps, time_step, show_progress])Compute the outputs of this time stepper, given inputs.
step_single(inputs, outputs, time_index, ...)Take a single time step on the given inputs.
update(*args, **kwargs)Update this time stepper.
write_verilog_a(path, *[, backend, ...])Write this configured time stepper as one Verilog-A module.
Attributes
parametric_functionFunction used to update the time stepper.
parametric_kwargsKeyword arguments used to update the time stepper.
path_delaysMinimum delay in time steps of each (input key, output key) signal path; missing pairs have no path and None means every input reaches every output within the time step.
propertiesObject properties.
random_variablesRandom variables associated to the time stepper's parameters.
- setup_state(*, component, time_step, carrier_frequency, **kwargs)[source]¶
Initialize internal state.
- Parameters:
component (Component) – Component representing the waveguide.
time_step (Annotated[float, minimum=0, units='s']) – The interval between time steps (in seconds).
carrier_frequency (Annotated[float, minimum=0, units='Hz']) – The carrier frequency used to construct the time stepper. The carrier should be omitted from the input signals, as it is handled automatically by the time stepper.
kwargs (object) – Unused.
- Return type:
None