Reference

Internals

ElectricFields.calc_params!Function
calc_params!(field_params)

This function performs the calculation of different quantities from the information provided.

source
ElectricFields.@namespace!Macro
@namespace!(exprs, params)

This macro uses the dictionary params as a "namespace", i.e. all symbols are assumed to be keys in this dictionary. We need to escape the generated expression tree to modify in the scope of the caller, not the global scope.

source
ElectricFields.gaussian_common!Function
gaussian_common!(field_params, carrier[; Tmax_rounder, verbosity])

Compute parameters common to Gaussian envelopes, i.e. GaussianEnvelope and TruncatedGaussianEnvelope; most importantly, given an intensity FWHM or σ, we need to figure out the coefficient $\alpha$ for the envelope of the vector potential $\exp(-\alpha t^2)$, such that the electric field amplitude and intensity have the desired durations. The optional function Tmax_rounder determines if the envelop should be extended to encompass an integer amount of cycles of the carrier (default).

source
ElectricFields.convolutionFunction
convolution(f̂::Function, dc::DiracComb, ω)

Evaluate the convolution between the function (assumed to be the Fourier transform of a function f) with the DiracComb dc. This is used to implement the Fourier transform of a function product $f(t)g(t)$, where $g(t)$ is a sum of monochromatic waves:

\[f(t)g(t) \rightsquigarrow \frac{1}{\sqrt{2\pi}} (\hat{f}\star\hat{g})(\omega)\]

source
ElectricFields.DiracCombType
DiracComb(frequencies)

Represents a Dirac frequency comb, where frequencies is a vector of Tuples: (ωᵢ,cᵢ), representing a frequency and an amplitude:

\[\mathrm{DC}(\omega) = \sum_i c_i \delta(\omega-\omega_i).\]

source

Index